Last active
June 26, 2024 20:14
-
-
Save elijahbenizzy/07c6442632249eb63d2e3509e07db0c4 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from hamilton import driver | |
from hamilton.io.materialization import to | |
model_saver = to.mlflow( | |
id="trained_model_mlflow", # name given to the saver | |
dependencies=["trained_model"], # node returning the model | |
register_as="my_predictor", # name of the model in the MLFlow registry | |
) | |
dr = ( | |
driver.Builder() | |
.with_modules(model_training) | |
.with_materializers(model_saver) | |
.build() | |
) | |
dr.execute(["trained_model_mlflow"]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment