提交 03c53111 编写于 作者: Z zhangxuefei

update modelbased to populationbased

上级 5e4450a7
......@@ -157,9 +157,9 @@ class FullTrailEvaluator(BaseEvaluator):
return reward
class ModelBasedEvaluator(BaseEvaluator):
class PopulationBasedEvaluator(BaseEvaluator):
def __init__(self, params_file, finetunee_script, options_str=""):
super(ModelBasedEvaluator, self).__init__(
super(PopulationBasedEvaluator, self).__init__(
params_file, finetunee_script, options_str=options_str)
self.half_best_model_path = []
self.run_count = 0
......
......@@ -33,7 +33,7 @@ from paddlehub.common.arg_helper import add_argument, print_arguments
from paddlehub.autofinetune.autoft import PSHE2
from paddlehub.autofinetune.autoft import HAZero
from paddlehub.autofinetune.evaluator import FullTrailEvaluator
from paddlehub.autofinetune.evaluator import ModelBasedEvaluator
from paddlehub.autofinetune.evaluator import PopulationBasedEvaluator
from paddlehub.common.logger import logger
import paddlehub as hub
......@@ -84,8 +84,8 @@ class AutoFineTuneCommand(BaseCommand):
self.arg_config_group.add_argument(
"--evaluate_choice",
type=str,
default="modelbased",
help="Choices: fulltrail or modelbased.")
default="populationbased",
help="Choices: fulltrail or populationbased.")
self.arg_config_group.add_argument(
"--tuning_strategy",
type=str,
......@@ -147,8 +147,8 @@ class AutoFineTuneCommand(BaseCommand):
self.args.param_file,
self.fintunee_script,
options_str=options_str)
elif self.args.evaluate_choice.lower() == "modelbased":
evaluator = ModelBasedEvaluator(
elif self.args.evaluate_choice.lower() == "populationbased":
evaluator = PopulationBasedEvaluator(
self.args.param_file,
self.fintunee_script,
options_str=options_str)
......
......@@ -13,5 +13,5 @@
# See the License for the specific language governing permissions and
# limitations under the License.
""" PaddleHub version string """
hub_version = "1.2.0"
hub_version = "1.2.1"
module_proto_version = "1.0.0"
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册