microsoft / MLOps_VideoAnomalyDetection

Operationalize a video anomaly detection model with Azure ML
MIT License
129 stars 57 forks source link

The mysterious aml_config directory #13

Closed masoncusack closed 4 years ago

masoncusack commented 4 years ago

Hello, I'm missing where the aml_config directory comes from. When I run create_docker_image.py, an error is thrown because it doesn't exist.

I notice that files it's supposed to contain such as model.json are written to the remote outputs directory when training finishes, but at no point is it downloaded or created locally as part of the process up to this point.

Could you inform me where this is supposed to be coming from?

Error on running create_docker_image.py:

(prednet) MLOps_VideoAnomalyDetection git:master ❯ cd deployment                                                                                                                                                      
(prednet) deployment git:master ❯ ls                                                                                                                                                                                  
azure-pipelines-deploy.yml  create_docker_image.py  deploy.py  environment.yml  inferenceConfig.json  myenv.yml  score.py  test_data  test_local_docker.py  test_webservice.py
(prednet) deployment git:master ❯ py3 create_docker_image.py                                                                                                                                                          
ERROR - Dependency aml_config/model.json doesn't exist. 

Traceback (most recent call last):
  File "create_docker_image.py", line 44, in <module>
    dependencies=['../models/prednet/prednet.py', 'aml_config/model.json']
  File "/home/masoncusack/miniconda3/envs/prednet/lib/python3.6/site-packages/azureml/core/image/container.py", line 159, in image_configuration
    base_image, base_image_registry, cuda_version=cuda_version)
  File "/home/masoncusack/miniconda3/envs/prednet/lib/python3.6/site-packages/azureml/core/image/container.py", line 320, in __init__
    self.validate_configuration()
  File "/home/masoncusack/miniconda3/envs/prednet/lib/python3.6/site-packages/azureml/core/image/container.py", line 488, in validate_configuration
    validate_path_exists_or_throw(dependency, "Dependency")
  File "/home/masoncusack/miniconda3/envs/prednet/lib/python3.6/site-packages/azureml/_model_management/_util.py", line 877, in validate_path_exists_or_throw
    logger=module_logger)
azureml.exceptions._azureml_exception.WebserviceException: WebserviceException:
        Message: Dependency aml_config/model.json doesn't exist. 
        InnerException None
        ErrorResponse 
{
    "error": {
        "message": "Dependency aml_config/model.json doesn't exist. "
    }
}
wmpauli commented 4 years ago

Hi Mason,

Thank you for raising this issue. The file create_docker_image.py should have been deleted. Please use deploy.py in the same folder instead. I'll update the documentation momentarily.