(self, callback_data, model, epochs)
Called when training is about to begin

        Arguments:
            callback_data (HDF5 dataset): shared data between callbacks
            model (Model): model object
            epochs (int): Total epochs
Called when training is about to begin
Called when training is about to begin
def on_train_begin(self, callback_data, model, epochs):
        """
        Called when training is about to begin

        Arguments:
            callback_data (HDF5 dataset): shared data between callbacks
            model (Model): model object
            epochs (int): Total epochs
        """
        # preallocate space for the number of minibatches in the whole run
        points = callback_data['config'].attrs['total_minibatches']
        callback_data.create_dataset("gan/gen_iter", (points,))
        callback_data.create_dataset("gan/cost_dis", (points,))

        # clue in the data reader to use the 'minibatch' time_markers
        callback_data['gan/gen_iter'].attrs['time_markers'] = 'minibatch'
        callback_data['gan/cost_dis'].attrs['time_markers'] = 'minibatch'
def on_train_begin ( self , callback_data , model , epochs ) : # preallocate space for the number of minibatches in the whole run points = callback_data [ 'config' ] . attrs [ 'total_minibatches' ] callback_data . create_dataset ( "gan/gen_iter" , ( points , ) ) callback_data . create_dataset ( "gan/cost_dis" , ( points , ) ) # clue in the data reader to use the 'minibatch' time_markers callback_data [ 'gan/gen_iter' ] . attrs [ 'time_markers' ] = 'minibatch' callback_data [ 'gan/cost_dis' ] . attrs [ 'time_markers' ] = 'minibatch'