-
Notifications
You must be signed in to change notification settings - Fork 133
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Plugin/mlflow custom flavor - fixed small bug #1068
Plugin/mlflow custom flavor - fixed small bug #1068
Conversation
Thanks @jernejfrank ! For the pre-commit failure you just need to do something like:
|
I'll plan to push this in the release on Monday. If you don't get to the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good. just a few things:
- pre-commit.
- you added some files in by accident I assume from the hamilton_ui example.
Thanks @jernejfrank ! |
ff40dd4
into
DAGWorks-Inc:plugin/mlflow-custom-flavor
Thanks for adding the custom flavor option to mlflow. I tested it and only the flavor specific kwargs somehow got mixed up and tried to be called somewhere else which lead to a fatal error. Changes renamed class attribute to avoid conflicting calls How I tested this added unit test that doubles as minimal example for reproducing the error Notes only tested the DataSaver (due to internal legacy structure, DataLoader is not utilised/hard to implement) * working mlflow plugin need to add kwargs for custom flavor * flavor kwargs used outside of mlflow saver/loader class * updated class description * flavor kwargs used outside of mlflow saver/loader class * removed incidental files --------- Co-authored-by: Jernej Frank <jernej.frank@oxehealth.com>
Before, the MLFlow plugin would allow for 2 main patterns. ```python to.mlflow(...) # infer the flavor to.mlflow(..., flavor="sklearn") # mlflow supported flavor ``` ^Note that this should support the pyfunc flavor, which is a convenient way to create custom estimators (MLFlow reference) Now, we can also pass in modules for mlflow flavors: ```python import custom_flavor to.mlflow(..., flavor=custom_flavor) ``` consequently, this would also work ``` import mlflow to.mlflow(..., flavor=mlflow.sklearn) ``` Squashed commits: * saver and loader now accept ModuleType for flavor kwarg * Plugin/mlflow custom flavor - fixed small bug (#1068) Thanks for adding the custom flavor option to mlflow. I tested it and only the flavor specific kwargs somehow got mixed up and tried to be called somewhere else which lead to a fatal error. Changes renamed class attribute to avoid conflicting calls How I tested this added unit test that doubles as minimal example for reproducing the error Notes only tested the DataSaver (due to internal legacy structure, DataLoader is not utilised/hard to implement) * working mlflow plugin need to add kwargs for custom flavor * flavor kwargs used outside of mlflow saver/loader class * updated class description * flavor kwargs used outside of mlflow saver/loader class * removed incidental files --------- Co-authored-by: Jernej Frank <jernej.frank@oxehealth.com> * Adds ML loader test for kwargs To complement saver. --------- Co-authored-by: zilto <tjean@DESKTOP-V6JDCS2> Co-authored-by: jernejfrank <50105951+jernejfrank@users.noreply.github.com> Co-authored-by: Jernej Frank <jernej.frank@oxehealth.com>
Thanks for adding the custom flavor option to mlflow. I tested it and only the flavor specific kwargs somehow got mixed up and tried to be called somewhere else which lead to a fatal error.
Changes
How I tested this
Notes
Checklist