1

I have executed "pip install azureml-automl-runtime" in azure notebook. When I try to load the model with below code

model_path = "forecast/model.pkl"

loaded_model = pickle.load(open(model_path, 'rb'))

I have tried loaded_model = joblib.load(open(model_path, 'rb')) as well but same error is displayed.

then "ModuleNotFoundError: No module named 'azureml.automl.runtime._automl_forecast_freq' " error message is displayed.

enter image description here

1 Answers1

0

replace existing library with the below library and retry

from azureml.automl.core.forecasting_parameters import ForecastingParameters

Make sure that the code is being executed in virtual environment not in root environment.

For further reference check the document designed by Larry Franks and team

Sairam Tadepalli
  • 1,563
  • 1
  • 3
  • 11
  • Hi, Thank you for your reply. I have used this in my code as shown below , but still I am getting the error. from azureml.automl.core.forecasting_parameters import ForecastingParameters – S Mahapatra Jun 15 '22 at 09:09
  • I have referred https://github.com/Azure/azureml-examples/blob/main/python-sdk/tutorials/automl-with-azureml/forecasting-energy-demand/auto-ml-forecasting-energy-demand.ipynb (content#4) – S Mahapatra Jun 15 '22 at 09:19
  • Check the pickle file once whether it is executing in local with the same libraries or not. Once test and local. Update the result in comments to understand the situation. – Sairam Tadepalli Jun 15 '22 at 10:47
  • I am using Azure notebook for execution. Can you please explain the meaning of virtual environment not in root environment. ? – S Mahapatra Jun 15 '22 at 11:38