aa51e79cdbcbedbedeef68bcef646b2d43993753,src/sdk/pynni/nni/ppo_tuner/ppo_tuner.py,PPOTuner,_actions_to_config,#PPOTuner#Any#,492
Before Change
for cnt, act in enumerate(actions):
act_name = self.full_act_space[act]
(block_name, layer_name, key) = self.actions_to_config[cnt]
if key == "chosen_inputs":
if act_name == "None":
chosen_arch[block_name][layer_name][key] = []
else:
chosen_arch[block_name][layer_name][key] = [act_name]
elif key == "chosen_layer":
chosen_arch[block_name][layer_name][key] = act_name
else:
raise ValueError("unrecognized key: {0}".format(key))
return chosen_arch
def generate_multiple_parameters(self, parameter_id_list, **kwargs):
After Change
for cnt, act in enumerate(actions):
act_name = self.full_act_space[act]
(_key, _type) = self.actions_to_config[cnt]
if _type == "input_choice":
if act_name == "None":
chosen_arch[_key] = {"_value": [], "_idx": []}
else:
candidates = self.search_space[_key]["_value"]["candidates"]
idx = candidates.index(act_name)
chosen_arch[_key] = {"_value": [act_name], "_idx": [idx]}
elif _type == "layer_choice":
idx = self.search_space[_key]["_value"].index(act_name)
chosen_arch[_key] = {"_value": act_name, "_idx": idx}
else:
raise ValueError("unrecognized key: {0}".format(_type))
return chosen_arch
def generate_multiple_parameters(self, parameter_id_list, **kwargs):
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 11
Instances
Project Name: microsoft/nni
Commit Name: aa51e79cdbcbedbedeef68bcef646b2d43993753
Time: 2019-11-25
Author: Quanlu.Zhang@microsoft.com
File Name: src/sdk/pynni/nni/ppo_tuner/ppo_tuner.py
Class Name: PPOTuner
Method Name: _actions_to_config
Project Name: dmlc/gluon-cv
Commit Name: c96649bb6e1dfeb9479de6c5e8547d510c6b7a32
Time: 2021-01-19
Author: tmwang428@outlook.com
File Name: gluoncv/auto/tasks/utils.py
Class Name:
Method Name: auto_suggest
Project Name: tryolabs/luminoth
Commit Name: 35999e65a83c8b9f67b833623a5b9ce47af7cc71
Time: 2017-09-19
Author: javirey@gmail.com
File Name: luminoth/utils/training.py
Class Name:
Method Name: get_learning_rate