def _inner_callback(self, model, validation_data, confusion_matrix, polar, model_index, run_result, test_results, test_data_fit, temp_path):
    plotter = Plotter(path=temp_path, data_results_dict=run_result.history, model_name=model.name)
    self.pandas_full_data = pd.concat([self.pandas_full_data, plotter.get_full_pandas_dataframe()], sort=False)
    if self.output_config['confusion_matrix']:
        if (validation_data is not None):
            if model.inputs[0].dtype.is_complex:
                (x_test, y_test) = validation_data
            else:
                (x_test, y_test) = (transform_to_real(validation_data[0], mode=polar), validation_data[1])
            try:
                confusion_matrix[model_index]['matrix'] = pd.concat((confusion_matrix[model_index]['matrix'], get_confusion_matrix(model.predict(x_test), y_test)))
            except ValueError:
                logger.warning('ValueError: Could not do confusion matrix. No objects to concatenate.')
        else:
            print('Confusion matrix only available for validation_data')
    if self.output_config['save_weights']:
        np.save((temp_path / 'final_weights.npy'), model.get_weights())
    if (test_results is not None):
        tmp_result = ([model.name] + model.evaluate(x=test_data_fit[0], y=test_data_fit[1], verbose=0))
        cols = (['network'] + [n.get_config()['name'] for n in self.models[0].metrics])
        test_results = test_results.append(pd.DataFrame([tmp_result], columns=cols), ignore_index=True)
    return test_results
def _inner_callback(self, model, validation_data, confusion_matrix, polar, model_index, run_result, test_results, test_data_fit, temp_path):
    plotter = Plotter(path=temp_path, data_results_dict=run_result.history, model_name=model.name)
    self.pandas_full_data = pd.concat([self.pandas_full_data, plotter.get_full_pandas_dataframe()], sort=False)
    if self.output_config['confusion_matrix']:
        if (validation_data is not None):
            if model.inputs[0].dtype.is_complex:
                (x_test, y_test) = validation_data
            else:
                (x_test, y_test) = (transform_to_real(validation_data[0], mode=polar), validation_data[1])
            try:
                confusion_matrix[model_index]['matrix'] = pd.concat((confusion_matrix[model_index]['matrix'], get_confusion_matrix(model.predict(x_test), y_test)))
            except ValueError:
                logger.warning('ValueError: Could not do confusion matrix. No objects to concatenate.')
        else:
            print('Confusion matrix only available for validation_data')
    if self.output_config['save_weights']:
        np.save((temp_path / 'final_weights.npy'), model.get_weights())
    if (test_results is not None):
        tmp_result = ([model.name] + model.evaluate(x=test_data_fit[0], y=test_data_fit[1], verbose=0))
        cols = (['network'] + [n.get_config()['name'] for n in self.models[0].metrics])
        test_results = test_results.append(pd.DataFrame([tmp_result], columns=cols), ignore_index=True)
    return test_results