Skip to content
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

Multiple Trials for Reinforcement Learning Suggestion #416

Merged
merged 6 commits into from
Mar 6, 2019

Conversation

jinan-zhou
Copy link
Contributor

@jinan-zhou jinan-zhou commented Mar 2, 2019

Now the reinforcement learning suggestion supports spawning multiple trials in each iteration. Users can activate this function by specifying the num_trials suggestion parameter in StudyJob yaml file.

Please notice that this multiple trials support is for extending exploration only, not for asynchronous update. The suggestion will use the average metrics of all the trials to calculate the policy gradient, which provides a more justified evaluation of the LSTM cell's internal state compared to using single trial. And the suggestion will not generate new candidates until all the previous ones are finished.

Fixes #396


This change is Reviewable

@jinan-zhou
Copy link
Contributor Author

/assign @hougangliu @YujiOshima

@jinan-zhou jinan-zhou changed the title Support Multiple Trials Multiple Trials for Reinforcement Learning Suggestion Mar 2, 2019
@@ -33,11 +35,13 @@ def __init__(self, request, logger):
self.search_space = None
self.opt_direction = None
self.objective_name = None
self.num_trials = 1
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

api.GetSuggestionsRequest.request_number has defined num_trials, you need not add a new one in suggestionParameters
Thanks!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for notice! We will change it.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed. I removed num_trials from the suggestion parameters and used requestNumber instead.

@jinan-zhou
Copy link
Contributor Author

/retest

@hougangliu
Copy link
Member

/lgtm
/approve

@k8s-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: hougangliu

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@andreyvelich
Copy link
Member

/retest

@k8s-ci-robot k8s-ci-robot merged commit feee2f9 into kubeflow:master Mar 6, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants