MachineLearningNotebooks icon indicating copy to clipboard operation
MachineLearningNotebooks copied to clipboard

ImportError: Missing required package "azureml-dataset-runtime"

Open levalencia opened this issue 1 year ago • 9 comments

I am having a weird issue in Azure ML.

I like to work in isolated conda environments with its own kernel, so for each little project I create my own environment and kernel like this:


conda create — name myenv
conda activate myenv
conda install pip
conda install ipykernel
python -m ipykernel install --user --name myenv  --display-name myenv

This creates the environment and the kernel, and then it's totally empty which means I have to install all modules myself. (including Azure SDK)

So I tried to install the following:

%pip install azureml %pip install azureml-core %pip install pandas %pip install azureml-dataset-runtime --upgrade

And then I tried to run a simple Load Dataset code

# azureml-core of version 1.0.72 or higher is required
# azureml-dataprep[pandas] of version 1.1.34 or higher is required
from azureml.core import Workspace, Dataset

subscription_id = 'xx'
resource_group = 'mlplayground'
workspace_name = 'mlplayground'

workspace = Workspace(subscription_id, resource_group, workspace_name)

dataset = Dataset.get_by_name(workspace, name='BelgiumRealEstate')
df=dataset.to_pandas_dataframe()

But then I get this error:

Missing required package "azureml-dataset-runtime", which can be installed by running: "/anaconda/envs/LightGBM/bin/python" -m pip install azureml-dataset-runtime --upgrade

And Yes, I tried to run this command, but got errors when trying to install it:

1

Can someone please enlighten me? Am I doing something wrong?

Thanks a lot.

levalencia avatar Aug 12 '22 09:08 levalencia

Having the same issue. Tried both in Intel and M1 Macs but I keep getting the same error when trying to pip install azure-dataset-runtime:

clang: build/src.macosx-12-arm64-3.9/numpy/core/src/umath/loops.c
        clang: error: the clang compiler does not support 'faltivec', please use -maltivec and include altivec.h explicitly
        clang: numpy/core/src/umath/ufunc_object.c
        clang: numpy/core/src/umath/ufunc_type_resolution.c
        clang: error: the clang compiler does not support 'faltivec', please use -maltivec and include altivec.h explicitly
        clang: error: the clang compiler does not support 'faltivec', please use -maltivec and include altivec.h explicitly
        clang: build/src.macosx-12-arm64-3.9/numpy/core/src/npymath/ieee754.c
        clang: error: the clang compiler does not support 'faltivec', please use -maltivec and include altivec.h explicitly
        clang: error: the clang compiler does not support 'faltivec', please use -maltivec and include altivec.h explicitly
        clang: numpy/core/src/common/ucsnarrow.c
        clang: error: the clang compiler does not support 'faltivec', please use -maltivec and include altivec.h explicitly
        clang: numpy/core/src/common/array_assign.c
        clang: /private/var/folders/_g/ttw1ghl95rjcn1sx78rv214h0000gn/T/pip-install-tc_pdfun/numpy_2ff78cf9ab9649a490052e547f808106/numpy/_build_utils/src/apple_sgemv_fix.c
        clang: build/src.macosx-12-arm64-3.9/numpy/core/src/common/npy_cpu_features.c
        clang: error: the clang compiler does not support 'faltivec', please use -maltivec and include altivec.h explicitly
        clang: error: the clang compiler does not support 'faltivec', please use -maltivec and include altivec.h explicitly
        clang: error: the clang compiler does not support 'faltivec', please use -maltivec and include altivec.h explicitly
        clang: error: the clang compiler does not support 'faltivec', please use -maltivec and include altivec.h explicitly
        clang: error: the clang compiler does not support 'faltivec', please use -maltivec and include altivec.h explicitly
        clang: error: the clang compiler does not support 'faltivec', please use -maltivec and include altivec.h explicitly
        clang: error: the clang compiler does not support 'faltivec', please use -maltivec and include altivec.h explicitly
        clang: error: the clang compiler does not support 'faltivec', please use -maltivec and include altivec.h explicitly
        error: Command "clang -Wno-unused-result -Wsign-compare -Wunreachable-code -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX12.sdk -DNPY_INTERNAL_BUILD=1 -DHAVE_NPY_CONFIG_H=1 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE=1 -D_LARGEFILE64_SOURCE=1 -DNO_ATLAS_INFO=3 -DHAVE_CBLAS -Ibuild/src.macosx-12-arm64-3.9/numpy/core/src/umath -Ibuild/src.macosx-12-arm64-3.9/numpy/core/src/npymath -Ibuild/src.macosx-12-arm64-3.9/numpy/core/src/common -Inumpy/core/include -Ibuild/src.macosx-12-arm64-3.9/numpy/core/include/numpy -Inumpy/core/src/common -Inumpy/core/src -Inumpy/core -Inumpy/core/src/npymath -Inumpy/core/src/multiarray -Inumpy/core/src/umath -Inumpy/core/src/npysort -I/opt/homebrew/Cellar/[email protected]/3.9.13_1/Frameworks/Python.framework/Versions/3.9/include/python3.9 -Ibuild/src.macosx-12-arm64-3.9/numpy/core/src/common -Ibuild/src.macosx-12-arm64-3.9/numpy/core/src/npymath -c numpy/core/src/multiarray/alloc.c -o build/temp.macosx-12-arm64-cpython-39/numpy/core/src/multiarray/alloc.o -MMD -MF build/temp.macosx-12-arm64-cpython-39/numpy/core/src/multiarray/alloc.o.d -faltivec -I/System/Library/Frameworks/vecLib.framework/Headers" failed with exit status 1
        [end of output]
  
    note: This error originates from a subprocess, and is likely not a problem with pip.
    ERROR: Failed building wheel for numpy
  Failed to build numpy
  ERROR: Could not build wheels for numpy, which is required to install pyproject.toml-based projects
  [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip. error: subprocess-exited-with-error

aekundayo avatar Aug 18 '22 10:08 aekundayo

Any working solution for this?

We are running into the same issue.

s0rhe1m avatar Sep 05 '22 09:09 s0rhe1m

If its with AzureML then the issue for me was fairly simple. I had the wrong version of python. Created a venv using python 3.6 and it worked after installing the necessary libraries.

aekundayo avatar Sep 05 '22 09:09 aekundayo

so the Azure ML SDK for Python does not support Python 3.8 and greater yet?

levalencia avatar Sep 05 '22 20:09 levalencia

I've stumbled upon the same problem on a Mac M1. Is there a solution for this yet when using newer Python versions?

maxvfischer avatar Oct 08 '22 16:10 maxvfischer