wtf section
wtf stands for what to fit.
This section parametrizes the failed cavities, as well as how they are fixed.
If you want to use the k out of n method:
Entry |
Type |
Description |
Allowed values |
Mandatory? |
|---|---|---|---|---|
failed |
|
Index/name of failed cavities. Must be a list[list[int]] or list[list[str]]. |
✅ |
|
history_kwargs |
|
kwargs for the |
❌ |
|
id_nature |
|
Indicates if failed is element index/cavity index/name, |
(‘element’, ‘cavity’, ‘name’) |
✅ |
objective_preset |
|
Objectives for the optimisation algorithm. |
(‘EnergyPhaseMismatch’, ‘simple_ADS’, ‘EnergyMismatch’, ‘rephased_ADS’, ‘EnergySyncPhaseMismatch’, ‘sync_phase_as_objective_ADS’, ‘experimental’) |
✅ |
optimisation_algorithm |
|
Name of optimisation algorithm. |
(‘least_squares’, ‘least_squares_penalty’, ‘nsga’, ‘downhill_simplex’, ‘downhill_simplex_penalty’, ‘nelder_mead’, ‘nelder_mead_penalty’, ‘differential_evolution’, ‘explorator’, ‘experimental’) |
✅ |
optimisation_algorithm_kwargs |
|
Keyword arguments passed to the optimisation algorithm. |
❌ |
|
strategy |
|
How compensating cavities are selected. |
(‘k out of n’, ‘l neighboring lattices’, ‘global’, ‘global_downstream’, ‘manual’) |
✅ |
tie_politics |
|
How to select the compensating elements when several are equidistant to the failure. |
(‘upstream first’, ‘downstream first’) |
❌ |
shift |
|
Distance increase for downstream elements ( |
❌ |
|
k |
|
Number of compensating cavities per failed cavity. |
✅ |
If you want to use the l neighboring lattices method:
Entry |
Type |
Description |
Allowed values |
Mandatory? |
|---|---|---|---|---|
failed |
|
Index/name of failed cavities. Must be a list[list[int]] or list[list[str]]. |
✅ |
|
history_kwargs |
|
kwargs for the |
❌ |
|
id_nature |
|
Indicates if failed is element index/cavity index/name, |
(‘element’, ‘cavity’, ‘name’) |
✅ |
objective_preset |
|
Objectives for the optimisation algorithm. |
(‘EnergyPhaseMismatch’, ‘simple_ADS’, ‘EnergyMismatch’, ‘rephased_ADS’, ‘EnergySyncPhaseMismatch’, ‘sync_phase_as_objective_ADS’, ‘experimental’) |
✅ |
optimisation_algorithm |
|
Name of optimisation algorithm. |
(‘least_squares’, ‘least_squares_penalty’, ‘nsga’, ‘downhill_simplex’, ‘downhill_simplex_penalty’, ‘nelder_mead’, ‘nelder_mead_penalty’, ‘differential_evolution’, ‘explorator’, ‘experimental’) |
✅ |
optimisation_algorithm_kwargs |
|
Keyword arguments passed to the optimisation algorithm. |
❌ |
|
strategy |
|
How compensating cavities are selected. |
(‘k out of n’, ‘l neighboring lattices’, ‘global’, ‘global_downstream’, ‘manual’) |
✅ |
tie_politics |
|
How to select the compensating elements when several are equidistant to the failure. |
(‘upstream first’, ‘downstream first’) |
❌ |
shift |
|
Distance increase for downstream elements ( |
❌ |
|
l |
|
Number of compensating lattices per failed cavity. |
✅ |
|
min_number_of_cavities_in_lattice |
|
Minimum number of compensating cavities in the lattice; when a lattice does not reach this number, we use it anyway for compensation, but we also take another lattice. Designed to remove the lattices that do not have any cavity. |
❌ |
If you want to manually associate each failed cavity with its compensating cavities:
Entry |
Type |
Description |
Allowed values |
Mandatory? |
|---|---|---|---|---|
failed |
|
Index/name of failed cavities. Must be a list[list[int]] or list[list[str]]. |
✅ |
|
history_kwargs |
|
kwargs for the |
❌ |
|
id_nature |
|
Indicates if failed is element index/cavity index/name, |
(‘element’, ‘cavity’, ‘name’) |
✅ |
objective_preset |
|
Objectives for the optimisation algorithm. |
(‘EnergyPhaseMismatch’, ‘simple_ADS’, ‘EnergyMismatch’, ‘rephased_ADS’, ‘EnergySyncPhaseMismatch’, ‘sync_phase_as_objective_ADS’, ‘experimental’) |
✅ |
optimisation_algorithm |
|
Name of optimisation algorithm. |
(‘least_squares’, ‘least_squares_penalty’, ‘nsga’, ‘downhill_simplex’, ‘downhill_simplex_penalty’, ‘nelder_mead’, ‘nelder_mead_penalty’, ‘differential_evolution’, ‘explorator’, ‘experimental’) |
✅ |
optimisation_algorithm_kwargs |
|
Keyword arguments passed to the optimisation algorithm. |
❌ |
|
strategy |
|
How compensating cavities are selected. |
(‘k out of n’, ‘l neighboring lattices’, ‘global’, ‘global_downstream’, ‘manual’) |
✅ |
failed |
|
Index/name of failed cavities. Must be a list[list[list[int]]] or list[list[list[str]]]. |
✅ |
|
compensating_manual |
|
Index/name of compensating cavities cavities. Must be a list[list[list[int]]] or list[list[list[str]]]. The number of FaultScenarios (length of most outer list) must match |
✅ |
Note
You can type the index of failed cavities on several lines if you want to study several fault scenarios at once.
Example
# Indexes are cavity indexes
idx = "cavity"
failed = [
[0, 1], # First simulation first cryomodule is down
[0], # Second simulation only first cavity is down
[1, 45] # Third simulation second and 46th cavity are down
]