In execute python module. The line
import humanfriendly
gives error. How to fix this?
Your description is not clear, I don't know what happended when you got error via import humanfriendly
as you said. So I just can do for you that only post my steps about how to install humanfriendly
Python package in Azure ML, as below.
According to the section Technical Notes
of the document "Execute Python Script", I download the humanfriendly
package from here. I decompressed the package (the same for either .whl
file or .tar.gz
file), and package its humanfriendly
directory as a zip file.
Then I click the botton +New
and select the DATASET
tab to Upload a new dataset from a local file, as the figures below.
Fig 1. Click the botton +New
Fig 2. Select the tab DATASET
Fig 3. Upload a new dataset from a local file
Drag & drop the dataset module humanfriendly.zip
and a Execute Python Script
module to connect them and write the Python code, as below.
Here is My testing code in the Execute Python Script
.
import humanfriendly
def azureml_main(dataframe1 = None, dataframe2 = None):
user_input = '16G'
num_bytes = humanfriendly.parse_size(user_input)
print num_bytes
Finally, I ran the experiment successfully.
Update: The file structure tree of my humanfriendly
zip. I decompressed the wheel file and just package the humanfriendly
directory.
humanfriendly
├── data.csv
└── humanfriendly
├── cli.py
├── compat.py
├── __init__.py
├── prompts.py
├── sphinx.py
├── tables.py
├── terminal.py
├── tests.py
├── text.py
└── usage.py