Exemplo n.º 1
0
def to_spec(chromo):
    scaled_values = {}
    for val, (spec_name, (low, high)) in zip(chromo, chromo_index.iteritems()):
        scaled_values[spec_name] = low + val*(high-low)
    print scaled_values
    spec_id = specs.create_spec(**scaled_values)
    return specs.get_spec(spec_id)
Exemplo n.º 2
0
def height_std(param1, param2):
    ana.height_std_field.phase_diagram_2d(param1, param2,
                                          **_phase_diagram_kwargs())
    _setup_figure(title='Std. Deviation of Height',
                  xlabel=_map_param_name(param1),
                  ylabel=_map_param_name(param2))
    name = 'height_std-{0}-vs-{1}'.format(param1, param2)
    _save_figure(name)

    max_std = ana.height_std_field.find_max_spec_id()
    spec = specs.get_spec(max_std)
    spec.dump(_make_path(name + '-max-spec.txt'))
    models.show_first_for_spec_id(max_std, show=False)
    _save_figure(name + "-max")