Skip to content

[Feature description] Experimental parameter sweep #37

@nikohansen

Description

@nikohansen

The file example_experiment_parameter_sweep.py in this folder implements an (example of an) experimental parameter sweep. An algorithm is run over the full benchmark for each parameter setting and each data are written in a dedicated subfolder. The name of the subfolder contains the parameter float value. (Since v2.7.4, the float value must contain a decimal point . or an e to make it distinct from simple digits or a counter).

The post-processing cocopp is then run with the argument --parameter-sweep, as done in the end of the script, like

import glob  # to get a list of matching paths using wildcards
import cocopp

dsl = cocopp.main('--parameter-sweep ' + ' '.join(glob('exdata/*')))

This interprets, separately for each run algorithm, the float numbers in the path names, sorts them, and uses heat map line colors according to the sorting. Instead of passing the above option, it is also possible to assign

cocopp.genericsettings.parameter_sweep = True

see here. The colormap(s) can be chosen by setting cocopp.genericsettings.parameter_sweep_colormaps.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions