Slackbot
08/04/2023, 8:12 PMChaoyu
08/06/2023, 9:27 PMChaoyu
08/06/2023, 9:27 PMChaoyu
08/06/2023, 9:28 PM/Users/me/path/to/local/model
../relative/path/to/local/model
<s3://my_bucket/path/to/model>
runs:/<mlflow_run_id>/run-relative/path/to/model
models:/<model_name>/<model_version>
models:/<model_name>/<stage>
See https://docs.bentoml.com/en/latest/integrations/mlflow.html#import-an-mlflow-model이호민
08/06/2023, 9:57 PMmlflow artifact as a callback of pytorch lighting. Below is the code I’m using.
# get artifact path
mlflow_artifact_uri = mlflow.get_artifact_uri()
# import model to bentoml
bentoml.mlflow.import_model(
"mlflow_project_classification",
mlflow_artifact_uri,
signatures={"predict": {"batchable": True}},
)
Thank you for your help even though it’s the weekend.Chaoyu
08/06/2023, 10:13 PMmlflow.get_artifact_uri?이호민
08/06/2023, 10:40 PMfile:///some/thing/classification_trainer/mlruns/0/5b864c88bec740eab980fae71015a291/artifacts이호민
08/06/2023, 10:41 PM├── model
│ ├── MLmodel
│ ├── conda.yaml
│ ├── data
│ │ ├── model.pth
│ │ └── pickle_module_info.txt
│ ├── python_env.yaml
│ └── requirements.txt
└── model_summary.txtChaoyu
08/06/2023, 10:46 PMChaoyu
08/06/2023, 10:46 PMChaoyu
08/06/2023, 10:48 PM