-
Notifications
You must be signed in to change notification settings - Fork 47
fix(trainer): Fix empty image for Runtime trainer #143
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
Conversation
Pull Request Test Coverage Report for Build 19113108843Warning: This coverage report may be inaccurate.This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.
Details
💛 - Coveralls |
| return UNKNOWN | ||
|
|
||
|
|
||
| def resolve_image(runtime: types.Runtime) -> str: |
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.
@Fiona-Waters It looks like we don't need image resolver, since we fallback to the default runtime in case we can't get it online:
| def _create_default_runtimes() -> list[base_types.Runtime]: |
Is that correct ?
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.
Yes if image is not optional then we don't need this function.
| class RuntimeTrainer: | ||
| trainer_type: TrainerType | ||
| framework: str | ||
| image: str |
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.
@astefanutti @Fiona-Waters I made image mandatory for the RuntimeTrainer.
The container should always has an image, but for the local subprocess backend, we can populate some const value there.
What do you think about it ?
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.
I think it makes sense for the image to be mandatory. Adding a dummy const to local process backend seems fine to me as long as we make sure it's purpose is mentioned clearly in a comment.
Fiona-Waters
left a comment
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 @andreyvelich - responsed to your comments.
| return UNKNOWN | ||
|
|
||
|
|
||
| def resolve_image(runtime: types.Runtime) -> str: |
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.
Yes if image is not optional then we don't need this function.
| class RuntimeTrainer: | ||
| trainer_type: TrainerType | ||
| framework: str | ||
| image: str |
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.
I think it makes sense for the image to be mandatory. Adding a dummy const to local process backend seems fine to me as long as we make sure it's purpose is mentioned clearly in a comment.
|
/milestone v0.2 |
Signed-off-by: Andrey Velichkevich <[email protected]>
a9c5244 to
f6ab049
Compare
Signed-off-by: Andrey Velichkevich <[email protected]>
| trainer: Optional[ | ||
| Union[types.CustomTrainer, types.CustomTrainerContainer, types.BuiltinTrainer] | ||
| ] = None, | ||
| options: Optional[list] = 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.
This should fix E2Es in this PR: kubeflow/trainer#2907
Signed-off-by: Andrey Velichkevich <[email protected]>
Signed-off-by: Andrey Velichkevich <[email protected]>
Signed-off-by: Andrey Velichkevich <[email protected]>
| self, | ||
| name: str, | ||
| follow: Optional[bool] = False, | ||
| follow: bool = False, |
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.
Why do we need this change?
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.
Properties should not be Optional if they can't be None.
By default follow=False
|
Thanks @andreyvelich! |
|
/approve |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: andreyvelich The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
As we discussed here, we should move
imageto the Runtime trainer: #140 (comment)/assign @kubeflow/kubeflow-sdk-team @Fiona-Waters