Skip to content
RED SAG Skills
easy5 pts · first answer countsml-pipelinesscikit-learntraining-serving-skew

Bundling preprocessing with the model

Why save a scikit-learn Pipeline instead of just the fitted classifier?

pipe = Pipeline([
    ("scale", StandardScaler()),
    ("clf", LogisticRegression()),
])
pipe.fit(X_train, y_train)
joblib.dump(pipe, "model.joblib")
Choose one answer

Discussion 0

Join free to post in the discussion.

Related questions