-
Notifications
You must be signed in to change notification settings - Fork 180
ML command supports category_field parameter #3909
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
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Binlong Gao <gbinlong@amazon.com>
|
@LantaoJin @qianheng-aws @songkant-aws please help to review this PR, thanks! |
|
This PR is stalled because it has been open for 30 days with no activity. |
|
LGTM |
|
@LantaoJin @qianheng-aws @yuancu Need other reviews. |
| String categoryField = | ||
| arguments.containsKey(CATEGORY_FIELD) | ||
| ? (String) arguments.get(CATEGORY_FIELD).getValue() | ||
| : null; |
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.
categoryField is null will throw NPE in generateCategorizedInputDataset
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.
How so? generateCategorizedInputDataset has null checking:
Line 83 in 0c1ec27
| ExprValue categoryValue = categoryField == null ? null : tupleValue.get(categoryField); |
If we want, we can add a @Nullable annotation to that field to document that contract in the signature
|
This PR is stalled because it has been open for 2 weeks with no activity. |
|
This PR is stalled because it has been open for 2 weeks with no activity. |
|
@LantaoJin can you re-review? |
|
This PR is stalled because it has been open for 2 weeks with no activity. |
Description
From the document of ML command, it shows that ml supports
category_fieldcommand, but actually it doesn't work. This PR makes ML command supports category_field parameter.Request:
Response:
Related Issues
#3406
Check List
--signoff.By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.