microsoftarchive / BatchAI

Repo for publishing code Samples and CLI samples for BatchAI service
MIT License
125 stars 62 forks source link

ImportError: No module named 'skopt' #45

Closed kishanakbari21 closed 6 years ago

kishanakbari21 commented 6 years ago

I am using keras method for BatchAI training for my python script. Python script requires 'skopt' to be imported in that. I am getting error message saying,

/anaconda/envs/py35/lib/python3.5/site-packages/h5py/init.py:36: FutureWarning: Conversion of the second argument of issubdtype from float to np.floating is deprecated. In future, it will be treated as np.float64 == np.dtype(float).type. from ._conv import register_converters as _register_converters Using TensorFlow backend. Traceback (most recent call last): File "/mnt/batch/tasks/shared/LS_root/mounts/afs/KerasSamples/cnn_for_Azure.py", line 27, in import skopt ImportError: No module named 'skopt'

AlexanderYukhanov commented 6 years ago

You need to create your own docker image which includes skopt or setup it using jobpreparation task (see here https://github.com/Azure/BatchAI/blob/master/documentation/using-azure-cli-20.md#job-preparation-task or take a look at horovod recipe) which uses it. e.g "jobPreparation": { "commandLine": "pip install scikit-optimize" },

JamesHallam1 commented 3 years ago

I'm having this same error but I think it is because my path to the package skopt is wrong. I have installed scikit-optimizer through pip and conda in my virtual environment but I am unable to load the package.