You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have read and agree to submit bug reports in accordance with the issues policy
Where did you encounter this bug?
Local machine
Willingness to contribute
No. I cannot contribute a bug fix at this time.
MLflow version
Client: 2.11.3
Tracking server: 1.x.y
System information
OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Microsoft Windows 11 Enterprise 10.0.22631 Build 22631
Python version: 3.10.14
yarn version, if running the dev UI:
Describe the problem
if logging a keras model to local filesystem, and when loading the model with a missing artifact dir "models" at the end, it says that it could not find a registered artifact repository saying that currently registered schemes are: ['', 'file', 's3', 'r2', 'gs', 'wasbs', 'ftp', 'sftp', 'dbfs', 'hdfs', 'viewfs', 'runs', 'models', 'http', 'https', 'mlflow-artifacts'] although the artifact path starts indeed with 'file' and that is not the problem, it was just "models" was missing at the end of the string, so the error does not describe the problem correctly
Tracking information
REPLACE_ME
Code to reproduce issue
import mlflow
from tensorflow import keras
from tensorflow.keras.layers import Dense
if __name__=="__main__":
mlflow.set_experiment("test")
mlflow.start_run()
model = keras.Sequential(
Dense(1, input_dim=2, activation='sigmoid')
)
mlflow.keras.log_model(model, "models")
#this load will throw a bug because it should be mlflow.get_artifact_uri() + "/models", but the error log is saying that the problem is at the start of the string
mlflow.keras.load_model(mlflow.get_artifact_uri())
Stack trace
Traceback (most recent call last):
File "C:\Program Files\JetBrains\PyCharm Community Edition 2024.1\plugins\python-ce\helpers\pydev\_pydevd_bundle\pydevd_exec2.py", line 3, in Exec
exec(exp, global_vars, local_vars)
File "<input>", line 1, in <module>
File "C:\Users\user\AppData\Local\miniconda3\envs\<env_name>\lib\site-packages\mlflow\tensorflow\__init__.py", line 624, in load_model
model_conf = Model.load(model_configuration_path)
File "C:\Users\user\AppData\Local\miniconda3\envs\<env_name>\lib\site-packages\mlflow\models\model.py", line 548, in load
path = download_artifacts(artifact_uri=path)
File "C:\Users\user\AppData\Local\miniconda3\envs\<env_name>\lib\site-packages\mlflow\artifacts\__init__.py", line 63, in download_artifacts
return _download_artifact_from_uri(artifact_uri, output_path=dst_path)
File "C:\Users\user\AppData\Local\miniconda3\envs\<env_name>\lib\site-packages\mlflow\tracking\artifact_utils.py", line 105, in _download_artifact_from_uri
return get_artifact_repository(artifact_uri=root_uri).download_artifacts(
File "C:\Users\user\AppData\Local\miniconda3\envs\<env_name>\lib\site-packages\mlflow\store\artifact\artifact_repository_registry.py", line 124, in get_artifact_repository
return _artifact_repository_registry.get_artifact_repository(artifact_uri)
File "C:\Users\user\AppData\Local\miniconda3\envs\<env_name>\lib\site-packages\mlflow\store\artifact\artifact_repository_registry.py", line 73, in get_artifact_repository
raise MlflowException(
mlflow.exceptions.MlflowException: Could not find a registered artifact repository for: c:. Currently registered schemes are: ['', 'file', 's3', 'r2', 'gs', 'wasbs', 'ftp', 'sftp', 'dbfs', 'hdfs', 'viewfs', 'runs', 'models', 'http', 'https', 'mlflow-artifacts']
Other info / logs
REPLACE_ME
What component(s) does this bug affect?
area/artifacts: Artifact stores and artifact logging
area/build: Build and test infrastructure for MLflow
area/deployments: MLflow Deployments client APIs, server, and third-party Deployments integrations
area/docs: MLflow documentation pages
area/examples: Example code
area/model-registry: Model Registry service, APIs, and the fluent client calls for Model Registry
area/models: MLmodel format, model serialization/deserialization, flavors
the bug error says the problem is in "C:" part of the string, when in fact that is not the problem, the problem is that "/models" is missing from the end of the string
so if I pass 'file:///C:/Users/users/repo/source/mlruns/340704544098555564/5a03e43832f94e30aec44bbba19e277d/artifacts/models'
to mlflow.keras.load_model(), the issue is resolved
Issues Policy acknowledgement
Where did you encounter this bug?
Local machine
Willingness to contribute
No. I cannot contribute a bug fix at this time.
MLflow version
System information
Describe the problem
if logging a keras model to local filesystem, and when loading the model with a missing artifact dir "models" at the end, it says that it could not find a registered artifact repository saying that currently registered schemes are: ['', 'file', 's3', 'r2', 'gs', 'wasbs', 'ftp', 'sftp', 'dbfs', 'hdfs', 'viewfs', 'runs', 'models', 'http', 'https', 'mlflow-artifacts'] although the artifact path starts indeed with 'file' and that is not the problem, it was just "models" was missing at the end of the string, so the error does not describe the problem correctly
Tracking information
Code to reproduce issue
Stack trace
Other info / logs
What component(s) does this bug affect?
area/artifacts
: Artifact stores and artifact loggingarea/build
: Build and test infrastructure for MLflowarea/deployments
: MLflow Deployments client APIs, server, and third-party Deployments integrationsarea/docs
: MLflow documentation pagesarea/examples
: Example codearea/model-registry
: Model Registry service, APIs, and the fluent client calls for Model Registryarea/models
: MLmodel format, model serialization/deserialization, flavorsarea/recipes
: Recipes, Recipe APIs, Recipe configs, Recipe Templatesarea/projects
: MLproject format, project running backendsarea/scoring
: MLflow Model server, model deployment tools, Spark UDFsarea/server-infra
: MLflow Tracking server backendarea/tracking
: Tracking Service, tracking client APIs, autologgingWhat interface(s) does this bug affect?
area/uiux
: Front-end, user experience, plotting, JavaScript, JavaScript dev serverarea/docker
: Docker use across MLflow's components, such as MLflow Projects and MLflow Modelsarea/sqlalchemy
: Use of SQLAlchemy in the Tracking Service or Model Registryarea/windows
: Windows supportWhat language(s) does this bug affect?
language/r
: R APIs and clientslanguage/java
: Java APIs and clientslanguage/new
: Proposals for new client languagesWhat integration(s) does this bug affect?
integrations/azure
: Azure and Azure ML integrationsintegrations/sagemaker
: SageMaker integrationsintegrations/databricks
: Databricks integrationsThe text was updated successfully, but these errors were encountered: