-
Notifications
You must be signed in to change notification settings - Fork 87
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
Add supported_problem_types
as required field for Pipelines and Components
#515
Conversation
supported_problem_types
as required field for Pipelines and Componentssupported_problem_types
as required field for Pipelines and Components
46551cf
to
7cb4485
Compare
Codecov Report
@@ Coverage Diff @@
## master #515 +/- ##
==========================================
+ Coverage 98.26% 98.67% +0.40%
==========================================
Files 113 113
Lines 3972 3985 +13
==========================================
+ Hits 3903 3932 +29
+ Misses 69 53 -16
Continue to review full report at Codecov.
|
supported_problem_types
as required field for Pipelines and Componentssupported_problem_types
as required field for Pipelines and Components
def problem_types(cls): | ||
return NotImplementedError("This pipeline must have `problem_types` as a class variable.") | ||
def supported_problem_types(cls): | ||
return NotImplementedError("This pipeline must have `supported_problem_types` as a class variable.") |
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. This field is deleted by @angela97lin 's feature branch! Heads up @angela97lin this rename will cause conflicts, but they shouldn't be too bad since your branch is just deleting this :)
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.
Sounds good. I'm planning on merging this and #516 after @angela97lin's feature branch so we can take turns dealing with the conflicts! Is that ok @dsherry?
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.
@jeremyliweishih oh, sure. If you do that, it will only contain changes for components, because PipelineBase.problem_types
will be deleted. But that sounds fine to me!
@@ -78,7 +79,7 @@ def test_describe_component(): | |||
|
|||
def test_missing_attributes(X_y): | |||
class MockComponentName(ComponentBase): | |||
model_family = None | |||
model_family = ModelFamily.NONE |
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.
Awesome. Glad we added this to the enum 👍
@@ -28,6 +29,7 @@ Changelog | |||
* Components and Pipelines now have a `model_family` field instead of `model_type` | |||
* `get_pipelines` utility function now accepts `model_families` as an argument instead of `model_types` | |||
* `PipelineBase.name` no longer returns structure of pipeline and has been replaced by `PipelineBase.summary` | |||
* `PipelineBase.problem_types` and `Estimator.problem_types` has been renamed to `supported_problem_types` |
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.
Awesome. I think @angela97lin 's feature branch merge should delete this from the breaking changes list, because, well, it deletes the field entirely 😂
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.
@jeremyliweishih looks good to me!
One question for you before merge: have you checked that you got all the call-sites? I scanned through git grep -n "problem_types"
and didn't see any.
I would suggest we should make the same update for ObjectiveBase
and subclasses, but I happen to know @angela97lin's work will delete ObjectiveBase.problem_types
as well, so 👍
@dsherry thanks for the review! Just checked again, should be good with all references to |
Fixes #377.