Markus S.
Markus S.

Reputation: 2812

Optimize conda dependencies from Azure Machine Learning AutoML Model

I have trained an Object Detection Instance Segmentation Model using Azure Machine Learning Studio and AutoML. The resulting model is of type ML-Flow.

When i download the model, the conda.yaml contains a huge list of dependencies.

This causes problems when i pack the model into a container because the resulting container is 9GB in size with the conda environment creation step responsible for ~8GB.

Are all of the dependencies really needed or can i get rid of some of them? My guess would be that the Azure Dependencies are not needed for local inference but is there another way to find out besides trial and error?

My conda.yaml looks like this:

channels:
- conda-forge
- anaconda
dependencies:
- python=3.9.7
- pip:
  - adal==1.2.7
  - aiohttp==3.9.4
  - aiosignal==1.3.1
  - annotated-types==0.7.0
  - applicationinsights==0.11.10
  - arch==5.6.0
  - argcomplete==3.4.0
  - asttokens==2.4.1
  - async-timeout==4.0.3
  - attrs==24.1.0
  - azure-common==1.1.28
  - azure-core==1.30.2
  - azure-graphrbac==0.61.1
  - azure-identity==1.17.1
  - azure-mgmt-authorization==4.0.0
  - azure-mgmt-containerregistry==10.3.0
  - azure-mgmt-core==1.4.0
  - azure-mgmt-keyvault==10.3.1
  - azure-mgmt-network==26.0.0
  - azure-mgmt-resource==23.1.1
  - azure-mgmt-storage==21.2.1
  - azure-storage-blob==12.19.0
  - azure-storage-queue==12.11.0
  - azureml-automl-core==1.57.0
  - azureml-automl-dnn-vision==1.57.0
  - azureml-automl-runtime==1.57.0
  - azureml-core==1.57.0
  - azureml-dataprep==5.1.6
  - azureml-dataprep-native==41.0.0
  - azureml-dataprep-rslex==2.22.2
  - azureml-dataset-runtime==1.57.0
  - azureml-defaults==1.57.0
  - azureml-inference-server-http==1.2.2
  - azureml-interpret==1.57.0
  - azureml-mlflow==1.57.0
  - azureml-responsibleai==1.57.0
  - azureml-telemetry==1.57.0
  - azureml-train-automl-client==1.57.0
  - azureml-train-automl-runtime==1.57.0
  - azureml-train-core==1.57.0
  - azureml-train-restclients-hyperdrive==1.57.0
  - azureml-training-tabular==1.57.0
  - backports-tempfile==1.0
  - backports-weakref==1.0.post1
  - bcrypt==4.2.0
  - blinker==1.8.2
  - bokeh==2.4.3
  - cachetools==5.4.0
  - captum==0.5.0
  - colorcet==3.0.1
  - coloredlogs==15.0.1
  - comm==0.2.2
  - contextlib2==21.6.0
  - cryptography==43.0.0
  - dask==2023.2.0
  - databricks-sdk==0.29.0
  - dataclasses==0.6
  - debugpy==1.8.2
  - decorator==5.1.1
  - deprecated==1.2.14
  - dice-ml==0.11
  - dill==0.3.8
  - distributed==2023.2.0
  - distro==1.9.0
  - docker==7.1.0
  - dotnetcore2==3.1.23
  - econml==0.15.1
  - entrypoints==0.4
  - erroranalysis==0.5.4
  - exceptiongroup==1.2.2
  - executing==2.0.1
  - fairlearn==0.7.0
  - fire==0.6.0
  - flask==2.3.2
  - flask-cors==3.0.10
  - flatbuffers==24.3.25
  - frozenlist==1.4.1
  - fsspec==2024.6.1
  - fusepy==3.0.1
  - fvcore==0.1.5.post20221221
  - gensim==4.3.2
  - gitdb==4.0.11
  - gitpython==3.1.43
  - google-api-core==2.19.1
  - google-auth==2.32.0
  - googleapis-common-protos==1.63.2
  - gunicorn==22.0.0
  - humanfriendly==10.0
  - imageio==2.34.2
  - importlib-metadata==7.2.1
  - inference-schema==1.7.2
  - interpret-community==0.31.0
  - interpret-core==0.5.0
  - iopath==0.1.10
  - ipykernel==6.29.5
  - ipython==8.18.1
  - isodate==0.6.1
  - itsdangerous==2.2.0
  - jedi==0.19.1
  - jeepney==0.8.0
  - jinja2==3.1.4
  - jmespath==0.10.0
  - jsonpickle==3.2.2
  - jsonschema==4.23.0
  - jsonschema-specifications==2023.12.1
  - jupyter-client==8.6.2
  - jupyter-core==5.7.2
  - keras2onnx==1.6.0
  - knack==0.11.0
  - lightgbm==3.2.1
  - locket==1.0.0
  - markupsafe==2.1.5
  - matplotlib==3.6.3
  - matplotlib-inline==0.1.7
  - ml-wrappers==0.5.5
  - mlflow-skinny==2.15.0
  - mpmath==1.3.0
  - msal==1.30.0
  - msal-extensions==1.2.0
  - msgpack==1.0.8
  - msrest==0.7.1
  - msrestazure==0.6.4.post1
  - multidict==6.0.5
  - munch==4.0.0
  - ndg-httpsclient==0.5.1
  - nest-asyncio==1.6.0
  - networkx==2.5
  - nose==1.3.7
  - nvidia-cublas-cu11==11.10.3.66
  - nvidia-cuda-nvrtc-cu11==11.7.99
  - nvidia-cuda-runtime-cu11==11.7.99
  - nvidia-cudnn-cu11==8.5.0.96
  - oauthlib==3.2.2
  - onnx==1.16.1
  - onnxconverter-common==1.13.0
  - onnxmltools==1.11.2
  - onnxruntime==1.17.3
  - opencensus==0.11.4
  - opencensus-context==0.1.3
  - opencensus-ext-azure==1.1.13
  - opencv-python-headless==4.4.0.46
  - opentelemetry-api==1.26.0
  - opentelemetry-sdk==1.26.0
  - opentelemetry-semantic-conventions==0.47b0
  - param==2.1.1
  - paramiko==3.4.0
  - parso==0.8.4
  - partd==1.4.2
  - pathspec==0.12.1
  - patsy==0.5.6
  - pexpect==4.9.0
  - pkginfo==1.11.1
  - pmdarima==1.8.5
  - portalocker==2.10.1
  - pretrainedmodels==0.7.4
  - prompt-toolkit==3.0.47
  - property-cached==1.6.4
  - proto-plus==1.24.0
  - protobuf==3.20.3
  - ptyprocess==0.7.0
  - pure-eval==0.2.3
  - pyarrow==14.0.2
  - pyasn1==0.6.0
  - pyasn1-modules==0.4.0
  - pyct==0.5.0
  - pydantic==2.8.2
  - pydantic-core==2.20.1
  - pydantic-settings==2.4.0
  - pygments==2.18.0
  - pyjwt==2.9.0
  - pynacl==1.5.0
  - pynvml==8.0.4
  - pyopenssl==24.2.1
  - python-dotenv==1.0.1
  - pytorch-ignite==0.4.13
  - pywavelets==1.6.0
  - pyyaml==6.0.1
  - pyzmq==26.1.0
  - raiutils==0.4.2
  - recordclass==0.21.1
  - referencing==0.35.1
  - requests-oauthlib==2.0.0
  - resnest==0.0.6b20210504
  - responsibleai==0.36.0
  - rpds-py==0.19.1
  - rsa==4.9
  - s3transfer==0.5.2
  - saliency==0.1.3
  - scikit-image==0.19.3
  - secretstorage==3.3.3
  - semver==2.13.0
  - simplification==0.5.10
  - skl2onnx==1.15.0
  - sklearn-pandas==1.7.0
  - smart-open==6.4.0
  - smmap==5.0.1
  - sortedcontainers==2.4.0
  - sparse==0.15.4
  - sqlparse==0.5.1
  - stack-data==0.6.3
  - statsmodels==0.13.5
  - sympy==1.13.1
  - tabulate==0.9.0
  - tblib==3.0.0
  - termcolor==2.4.0
  - tifffile==2024.7.24
  - timm==0.4.12
  - toolz==0.12.1
  - torch==1.13.1
  - torchvision==0.14.1
  - tornado==6.4.1
  - traitlets==5.14.3
  - typing-extensions==4.12.2
  - urllib3==1.26.19
  - wcwidth==0.2.13
  - werkzeug==3.0.3
  - wrapt==1.16.0
  - yacs==0.1.8
  - yarl==1.9.4
  - zict==3.0.0
- boto3=1.20.19
- botocore=1.23.19
- brotli=1.1.0
- brotli-bin=1.1.0
- brotli-python=1.1.0
- ca-certificates=2024.7.4
- certifi=2024.7.4
- cffi=1.14.6
- charset-normalizer=3.3.2
- cloudpickle=2.2.1
- colorama=0.4.6
- contourpy=1.2.1
- cycler=0.12.1
- cython=3.0.11
- fonttools=4.53.1
- freetype=2.12.1
- h2=4.1.0
- hpack=4.0.0
- hyperframe=6.0.1
- idna=3.7
- importlib-resources=6.4.0
- importlib_resources=6.4.0
- joblib=1.2.0
- kiwisolver=1.4.5
- lcms2=2.16
- lerc=4.0.0
- libblas=3.9.0
- libbrotlicommon=1.1.0
- libbrotlidec=1.1.0
- libbrotlienc=1.1.0
- libcblas=3.9.0
- libdeflate=1.20
- libffi=3.3
- libgfortran-ng=14.1.0
- libgfortran5=14.1.0
- libjpeg-turbo=3.0.0
- liblapack=3.9.0
- libllvm11=11.1.0
- libopenblas=0.3.25
- libpng=1.6.43
- libsqlite=3.46.0
- libtiff=4.6.0
- libwebp-base=1.4.0
- libxcb=1.15
- libzlib=1.2.13
- llvmlite=0.39.1
- munkres=1.1.4
- numba=0.56.4
- numpy=1.23.5
- openjpeg=2.5.2
- packaging=24.1
- pandas=1.3.5
- pillow=10.3.0
- pip=21.3.1
- platformdirs=4.2.2
- pooch=1.8.2
- psutil=5.8.0
- pthread-stubs=0.4
- pycocotools=2.0.6
- pycparser=2.22
- pyparsing=3.1.2
- pysocks=1.7.1
- python-dateutil=2.9.0
- python-tzdata=2024.1
- python_abi=3.9
- pytz=2024.1
- qhull=2020.2
- requests=2.32.3
- scikit-learn=1.5.1
- scipy=1.10.1
- setuptools=65.5.1
- six=1.16.0
- slicer=0.0.7
- tbb=2021.1.1
- threadpoolctl=3.5.0
- tqdm=4.66.5
- tzdata=2024a
- unicodedata2=15.1.0
- wheel=0.38.1
- xorg-libxau=1.0.11
- xorg-libxdmcp=1.1.3
- zipp=3.19.2
- zstandard=0.23.0
- zstd=1.5.6
name: project_environment

Upvotes: 0

Views: 77

Answers (0)

Related Questions