-
Notifications
You must be signed in to change notification settings - Fork 455
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
[GSoC] Add unit tests for tune
API
#2423
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: helenxie-bit <[email protected]>
Signed-off-by: helenxie-bit <[email protected]>
/area gsoc |
Ref: #2339 |
Signed-off-by: helenxie-bit <[email protected]>
tune
APItune
API
Signed-off-by: helenxie-bit <[email protected]>
Signed-off-by: helenxie-bit <[email protected]>
Signed-off-by: helenxie-bit <[email protected]>
Signed-off-by: helenxie-bit <[email protected]>
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.
Thank you for doing this @helenxie-bit!
Signed-off-by: helenxie-bit <[email protected]>
Signed-off-by: helenxie-bit <[email protected]>
Signed-off-by: helenxie-bit <[email protected]>
Signed-off-by: helenxie-bit <[email protected]>
Signed-off-by: helenxie-bit <[email protected]>
Signed-off-by: helenxie-bit <[email protected]>
tune
APItune
API
Signed-off-by: helenxie-bit <[email protected]>
@andreyvelich The unit test for |
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.
Thank you for doing this @helenxie-bit!
/assign @tenzen-y @johnugeorge @deepanker13 @droctothorpe @Electronic-Waste
…yword argument Signed-off-by: helenxie-bit <[email protected]>
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Signed-off-by: helenxie-bit <[email protected]>
Signed-off-by: helenxie-bit <[email protected]>
Signed-off-by: helenxie-bit <[email protected]>
@andreyvelich Thank you so much for reviewing this! I’ve replied to all your feedback, and please take a look when you have time. |
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.
Thanks for your great contribution @helenxie-bit ! I left some suggestions about the name of UTs for your reference
I guess it will be more friendly for other developers to understand these UTs if we could specify the scope of each UTs:)
Signed-off-by: helenxie-bit <[email protected]>
Signed-off-by: helenxie-bit <[email protected]>
@Electronic-Waste Thank you so much for your suggestions! I have incorporated your advice into the UTs. |
…ing[huggingface' into dependencies Signed-off-by: helenxie-bit <[email protected]>
Signed-off-by: helenxie-bit <[email protected]>
@andreyvelich I’ve added the
Additionally, I have added verification for the experiment object in two valid flow cases in the following section: katib/sdk/python/v1beta1/kubeflow/katib/api/katib_client_test.py Lines 587 to 639 in b24b44f
Please review when you have time. Thanks! |
@andreyvelich Please review this PR when you have time 👀. I'll adjust the e2e tests for the tune API after this PR is merged, as it fixes some small bugs in the tune API. |
Since @mahdikhashan is currently working on the notebook with instructions for this API, and this PR also includes some bug fixes for the API, @andreyvelich, would it be better to separate the bug fixes into a standalone PR to make the review process more convenient? Please let me know your thoughts. |
Sure, please create separate PR for the bug fixes. |
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.
Basically LGTM! I left a few comments concerned with objective_metric_name
for you.
Thanks for your great contribution! @helenxie-bit
if test_name == "valid flow with custom objective tuning": | ||
# Verify input_params | ||
args_content = "".join( | ||
experiment.spec.trial_template.trial_spec.spec.template.spec.containers[ | ||
0 | ||
].args | ||
) | ||
assert "'a': '${trialParameters.a}'" in args_content | ||
# Verify trial_params | ||
assert experiment.spec.trial_template.trial_parameters == [ | ||
V1beta1TrialParameterSpec(name="a", reference="a"), | ||
] | ||
# Verify experiment_params | ||
assert experiment.spec.parameters == [ | ||
V1beta1ParameterSpec( | ||
name="a", | ||
parameter_type="int", | ||
feasible_space=V1beta1FeasibleSpace(min="10", max="100"), | ||
), | ||
] |
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.
It would be better if we also verify the objective_metric_name
parameter.
What this PR does / why we need it:
This PR adds unit tests and fix some minor bugs of
tune
API.Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close the issue(s) when PR gets merged):Fixes #
Checklist: