diff --git a/template/steps/data_preprocessor.py b/template/steps/data_preprocessor.py index cd87063..c4039a9 100644 --- a/template/steps/data_preprocessor.py +++ b/template/steps/data_preprocessor.py @@ -7,7 +7,7 @@ from sklearn.preprocessing import MinMaxScaler from typing_extensions import Annotated from utils.preprocess import ColumnsDropper, DataFrameCaster, NADropper -from zenml import log_artifact_metadata, step +from zenml import log_metadata, step @step @@ -67,7 +67,7 @@ def data_preprocessor( dataset_tst = preprocess_pipeline.transform(dataset_tst) # Log metadata so we can load it in the inference pipeline - log_artifact_metadata( + log_metadata( artifact_name="preprocess_pipeline", metadata={"random_state": random_state, "target": target}, ) diff --git a/template/steps/model_evaluator.py b/template/steps/model_evaluator.py index 835d9ea..95cc6be 100644 --- a/template/steps/model_evaluator.py +++ b/template/steps/model_evaluator.py @@ -4,7 +4,7 @@ import pandas as pd from sklearn.base import ClassifierMixin -from zenml import log_artifact_metadata, step +from zenml import log_metadata, step from zenml.logger import get_logger logger = get_logger(__name__) @@ -79,7 +79,7 @@ def model_evaluator( for message in messages: logger.warning(message) - log_artifact_metadata( + log_metadata( metadata={"train_accuracy": float(trn_acc), "test_accuracy": float(tst_acc)}, artifact_name="sklearn_classifier", )