Exemple #1
0
from __future__ import absolute_import

import numpy as np
import os
from scipy.stats import norm
from scipy.stats import foldnorm

from stratified_bayesian_optimization.initializers.log import SBOLog
from stratified_bayesian_optimization.util.json_file import JSONFile

logger = SBOLog(__name__)


class RandomPolicy(object):

    def __init__(self, dict_stat_models, name_model, problem_name, type_model='grad_epoch', n_epochs=1,
                 stop_iteration_per_point=100, random_seed=None, n_restarts=None):
        self.dict_stat_models = dict_stat_models
        self.points_index = range(len(self.dict_stat_models))
        self.current_index = 0

        self.type_model = type_model
        self.problem_name = problem_name

        self.name_model = name_model
        self.n_epochs = n_epochs

        self.chosen_points = {}
        self.evaluations_obj = {}

        self.stop_iteration_per_point = stop_iteration_per_point
Exemple #2
0
 def test_info(self):
     logger = SBOLog(__name__)
     logger.info('testing')