Note: This is documentation for version 4.3 of Source. For a different version of Source, select the relevant space by using the Spaces menu in the toolbar above
Setting up an optimisation run
Decision variables and objectives must be defined in the Source project as functions. Insight can then run the Source model thousands of times, setting different values for the decision variable expressions and evaluating the corresponding objectives for every individual run. Therefore, in order for a Source parameter to be included in an optimisation problem, that parameter needs to be defined using the Function manager in Source.
- Open Insight and choose File » Load RiverSystem project directory or click Browse to choose the directory containing the project(s). Projects can also be in sub-directories below the directory pointed to. In Source (public version), you can only load a single scenario;
- Once the project has finished loading (indicated by a green progress bar), you can now set up the remaining configuration (see Configuring expressions);
- Under Run Configuration, choose the number of generations and the population size of each generation. These parameters define how many simulation runs are performed by the optimiser. The required values will depend on the complexity of the optimisation project. If the number of runs is too small, the optimiser will not be given sufficient time to search for the multi-objective optimal set of results. The population size also sets the maximum number of points on the Pareto front or surface;
- Optional: Configure the parameters under Advanced options. Note that these are intended for advanced users of the NSGA-II;
- Next, choose how to run the optimisation. This can be done either locally or across server endpoints by enabling the respective radio buttons. Server endpoints allow you to run the optimisation across several machines simultaneously. Load the endpoints settings file by clicking Load Endpoints and point Insight to the appropriate file;
- Click Run to start the optimisation run; and
- Save your settings using File » Save Settings. This creates a settings file, which can be used later.
The optimisation is now ready to be run.
Figure 1. Insight, Objectives
Configuring expressions
- Click New Expressions in the Insight toolbar and choose the component you wish to add;
- The resulting dialog contains a list of all pre-defined expressions. Choose the one you wish to add and click OK;
- Continue this process until you have added all components. Figure 1 shows an example of objectives, real decisions and tracked variables that have been added to the Insight project. Each component has additional parameters that must be defined:
- For discrete decisions, specify the allowed values of the function;
- For objectives and tracked variables, specify Multi-project Aggregation Method drop-down menu allows you to choose how you want to process the objective function values passed from individual scenarios. By default Insight uses the final value of the specified function as the value of the objective function for each scenario. The Aggregate over full timeseries checkbox allows you to use the values of the objective function determined at each time-step, rather than just the last value (via the selected statistical function). Â
- For real decisions, specify the allowed minimum and maximum values.