Пример #1
0
    def save(self, config, configs_child):

        if config.experiment.task_params is None or config.experiment.task_params['type'] == 'run':

            if isinstance(config.experiment_data['fig'], list):

                for fig_id, fig in enumerate(config.experiment_data['fig']):

                    if config.experiment.method == Method.scatter:
                        item = config.experiment_data['item'][fig_id]
                        config.experiment.method_params.pop('items', None)
                        config.experiment.method_params.pop('x_ranges', None)
                        config.experiment.method_params.pop('y_ranges', None)
                        config.experiment.method_params['item'] = item

                    file_name = config.experiment_data['item'][fig_id]
                    fn = get_save_path(config) + '/' + file_name
                    save_figure(fn, fig)
            else:

                if config.experiment.method == Method.scatter_comparison:
                    config.experiment.method_params.pop('items', None)
                    config.experiment.method_params.pop('aux', None)
                    config.experiment.method_params.pop('data_bases', None)
                    config.experiment.method_params.pop('x_ranges', None)
                    config.experiment.method_params.pop('y_ranges', None)

                file_name = 'regular'
                fn = get_save_path(config) + '/' + file_name
                save_figure(fn, config.experiment_data['fig'])

        elif config.experiment.task_params['type'] == 'prepare':
            pass
Пример #2
0
 def save(self, config, configs_child):
     fn = get_save_path(config) + '/' + \
         get_file_name(config)
     save_figure(fn, config.experiment_data['fig'])
Пример #3
0
 def save_plot(self, config, configs_primary):
     save_figure(config, config.plot_data['fig'])