|
Neko-TOP
A portable framework for high-order spectral element flow toplogy optimization.
|
This document describes the continuation framework introduced in Neko-TOP to support gradual variation of optimization parameters during the optimization loop.
The implementation is based on the module continuation_scheduler.
The continuation framework allows selected parameters to change over optimization iterations according to a predefined schedule.
Instead of keeping parameters fixed, users can define:
This adds the flexibility to guide the optimizer using different values for various parameters through the optimization loop.
Each continuation parameter is defined as:
At runtime at the end of each optimization iteration:
Represents a single continuation-controlled variable.
This is a continuation_scheduler_t, which allows registration of multiple continuation parameters and provides an update functionality that updates all registered parameters.
A global instance of the continuation scheduler is provided as nekotop_continuation. It is initialized in the driver at the beginning of the simulation. Any other module that requires a continuation strategy for one or more of its parameters can register them through this global object. Note that nekotop_continuationupdate(iter) is called at each iteration in the optimization loop.
Reads optimization.solver.continuation_iterations in the case file as the default frequency of updating all parameters registered in the scheduler. Note that individual frequency for can be registered in the json file as {parameters_name}_iterations in the case file.
It is possible to use json_get_or_register function in the scheduler to read the parameter form the json file. Note that if the parameter in the json is an array, then it will automatically register in the scheduler as well. If a single scalar is given in the json, then this function will work as a single call of json_get_or_default.
idx = (iter - 1) / iterations_per_value + 1 target = values(idx)
The following utility function helps to read a parameter with continuation strategy form the case file:
If the parameter is a single scalar, this will be a constant parameter in the optimization loop and will not be registered to nekotop_continuation. If it is an array, then it will be registered with these values with optimization.solver.continuation_iterations as the default value for its frequency, unless the individual frequency is defined for that particular parameter as {parameters_name}_iterations.
Continuation parameters are appended to log headers and values in the optimizer.
The scheduler should be freed at the end of the simulation in the driver.
Continuation enables gradual parameter variation during optimization to improve robustness and convergence.