def test_validate_deployment_flavor_validates_python_function_flavor_successfully(
        pretrained_model):
    model_config_path = os.path.join(_get_model_log_dir(
        pretrained_model.model_path, pretrained_model.run_id), "MLmodel")
    model_config = Model.load(model_config_path)
    mfs._validate_deployment_flavor(
            model_config=model_config, flavor=mlflow.pyfunc.FLAVOR_NAME)
示例#2
0
def test_validate_deployment_flavor_validates_python_function_flavor_successfully(
        pretrained_model):
    model_config_path = os.path.join(
        _download_artifact_from_uri(pretrained_model.model_uri), "MLmodel")
    model_config = Model.load(model_config_path)
    mfs._validate_deployment_flavor(model_config=model_config,
                                    flavor=mlflow.pyfunc.FLAVOR_NAME)