experiments.py
def eval_model(self, b):
        """Extract parameters from a UserHyperparams module and uses then to 
        udpate the values of certain hyperparameters of the evaluator. This 
        code is still very much based on ClassifierEvaluator.
        """

        ### this part is AWFUL
        # NOTE: I'm breaking encapsulation here for now.
        if self.args['bisect_search_space']:
            # has a ChoiceBisection, followed by Concat [UserHyperparams, b_search]
            b_hp, b_search = b.b.bs
        else:
            # just the concat module
            b_hp, b_search = b.bs
        b_hp.compile(None, None, None)
        hpsc_name = self.user_hyperparams_scope_name
        order = b_hp.scope.s[hpsc_name]['hyperp_names']
        vals = b_hp.scope.s[hpsc_name]['hyperp_vals']
        hps = dict(zip(order, vals))

        evaluator = ev.ClassifierEvaluator(train_dataset=self.train_dataset,
                                        val_dataset=self.val_dataset,
                                        test_dataset=self.test_dataset,
                                        in_d=self.in_d,
                                        nclasses=self.nclasses,
                                        training_epochs_max=int(1e6),
                                        time_minutes_max=self.max_minutes_per_model,
                                        display_step=1,
                                        stop_patience=hps['stop_patience'], ###
                                        rate_patience=hps['rate_patience'], ###
                                        batch_patience=int(1e6),
                                        save_patience=2, 
                                        rate_mult=hps['rate_mult'], ###
                                        optimizer_type=hps['optimizer_type'], ###
                                        learning_rate_init=hps['learning_rate_init'], ###
                                        learning_rate_min=hps['learning_rate_min'], ###
                                        batch_size_init=64,
                                        model_path=self.model_path,
                                        output_to_terminal=self.output_to_terminal)
        return evaluator.eval_model(b_search)
Extract parameters from a UserHyperparams module and uses then to 
        udpate the values of certain hyperparameters of the evaluator. This 
        code is still very much based on ClassifierEvaluator.
        
Extract parameters from a UserHyperparams module and uses then to
udpate the values of certain hyperparameters of the evaluator. This
code is still very much based on ClassifierEvaluator.
Extract parameters from a UserHyperparams module and uses then to udpate the values of certain hyperparameters of the evaluator . This code is still very much based on ClassifierEvaluator .
def eval_model(self, b):
        if self.args['bisect_search_space']:
            b_hp, b_search = b.b.bs
        else:
            b_hp, b_search = b.bs
        b_hp.compile(None, None, None)
        hpsc_name = self.user_hyperparams_scope_name
        order = b_hp.scope.s[hpsc_name]['hyperp_names']
        vals = b_hp.scope.s[hpsc_name]['hyperp_vals']
        hps = dict(zip(order, vals))
        evaluator = ev.ClassifierEvaluator(train_dataset=self.train_dataset,
                                        val_dataset=self.val_dataset,
                                        test_dataset=self.test_dataset,
                                        in_d=self.in_d,
                                        nclasses=self.nclasses,
                                        training_epochs_max=int(1e6),
                                        time_minutes_max=self.max_minutes_per_model,
                                        display_step=1,
                                        stop_patience=hps['stop_patience'], 
                                        rate_patience=hps['rate_patience'], 
                                        batch_patience=int(1e6),
                                        save_patience=2, 
                                        rate_mult=hps['rate_mult'], 
                                        optimizer_type=hps['optimizer_type'], 
                                        learning_rate_init=hps['learning_rate_init'], 
                                        learning_rate_min=hps['learning_rate_min'], 
                                        batch_size_init=64,
                                        model_path=self.model_path,
                                        output_to_terminal=self.output_to_terminal)
        return evaluator.eval_model(b_search)
def eval_model ( self , b ) : if self . args [ 'bisect_search_space' ] : b_hp , b_search = b . b . bs else : b_hp , b_search = b . bs b_hp . compile ( None , None , None ) hpsc_name = self . user_hyperparams_scope_name order = b_hp . scope . s [ hpsc_name ] [ 'hyperp_names' ] vals = b_hp . scope . s [ hpsc_name ] [ 'hyperp_vals' ] hps = dict ( zip ( order , vals ) ) evaluator = ev . ClassifierEvaluator ( train_dataset = self . train_dataset , val_dataset = self . val_dataset , test_dataset = self . test_dataset , in_d = self . in_d , nclasses = self . nclasses , training_epochs_max = int ( 1e6 ) , time_minutes_max = self . max_minutes_per_model , display_step = 1 , stop_patience = hps [ 'stop_patience' ] , rate_patience = hps [ 'rate_patience' ] , batch_patience = int ( 1e6 ) , save_patience = 2 , rate_mult = hps [ 'rate_mult' ] , optimizer_type = hps [ 'optimizer_type' ] , learning_rate_init = hps [ 'learning_rate_init' ] , learning_rate_min = hps [ 'learning_rate_min' ] , batch_size_init = 64 , model_path = self . model_path , output_to_terminal = self . output_to_terminal ) return evaluator . eval_model ( b_search )
Extract parameters from a UserHyperparams module and uses then to
udpate the values of certain hyperparameters of the evaluator.
Extract parameters from a UserHyperparams module and uses then to udpate the values of certain hyperparameters of the evaluator .
"""Extract parameters from a UserHyperparams module and uses then to 
        udpate the values of certain hyperparameters of the evaluator. This 
        code is still very much based on ClassifierEvaluator.
        """ ### this part is AWFUL # NOTE: I'm breaking encapsulation here for now. # has a ChoiceBisection, followed by Concat [UserHyperparams, b_search] # just the concat module ### ### ### ### ### ###
self
b