in3Utils.cfgHandling
Utilities for working with cfg info
Functions
Add parameterName and value to simNames of simulation dataframe |
|
override configuration parameter values with the values provided in cfgWithOverrideParameters[modName_override] if addModValues True update the cfgWithOverrideParameters with the values for all parameters that are not provided in the override parameters |
|
check if duplicate entries appear in a list and raise Assertion error using message |
|
Filter simulations results using a list of parameters and a flag if in ascending or descending order |
|
create a validation string to be checked if simDFrow matches filtering criteria (given by val) |
|
thickness settings different if read from shpfile - requires more complex filtering if read from shp - thickness values are provided per feature!! for example relTh = '' but relTh0 = 1 is appended for feature with id 0, relTh1 for feature with id 1, etc. |
|
Filter simulations using a list of parameters and a pandas dataFrame of simulation configurations if ~ is used as a prefix for a parameter - it is filtered according to values that do NOT match the value provided with the ~Parameter |
|
Add keys and values to name, in between parts of name split by index |
|
Filter simulations results using a list of parameters and a flag if in ascending or descending order |
|
Order simulations datadframe using a list of parameters and a flag if in ascending or descending order |
|
remove simulations from simDF that do not match filtering critera |
|
fetch all override sections in cfgFull and write a local_NAMEOVERRIDE.ini configuration file for the available sections - naming is collection_module_override if no localCfgPath is provided, default saved to avalancheDir/Inputs/configurationOverrides where package refers to e.g. |