diff --git a/src/iguana/algorithms/clas12/CalorimeterLinker/Config.yaml b/src/iguana/algorithms/clas12/CalorimeterLinker/Config.yaml new file mode 100644 index 00000000..acc6974b --- /dev/null +++ b/src/iguana/algorithms/clas12/CalorimeterLinker/Config.yaml @@ -0,0 +1 @@ +clas12::CalorimeterLinker: diff --git a/src/iguana/algorithms/clas12/TrajLinker/Config.yaml b/src/iguana/algorithms/clas12/TrajLinker/Config.yaml new file mode 100644 index 00000000..9d8b2f33 --- /dev/null +++ b/src/iguana/algorithms/clas12/TrajLinker/Config.yaml @@ -0,0 +1 @@ +clas12::TrajLinker: diff --git a/src/iguana/algorithms/clas12/rga/FTEnergyCorrection/Config.yaml b/src/iguana/algorithms/clas12/rga/FTEnergyCorrection/Config.yaml new file mode 100644 index 00000000..1fd31554 --- /dev/null +++ b/src/iguana/algorithms/clas12/rga/FTEnergyCorrection/Config.yaml @@ -0,0 +1 @@ +clas12::rga::FTEnergyCorrection: diff --git a/src/iguana/algorithms/clas12/rga/MomentumCorrection/Algorithm.cc b/src/iguana/algorithms/clas12/rga/MomentumCorrection/Algorithm.cc index 27e9f283..fc3a5a2c 100644 --- a/src/iguana/algorithms/clas12/rga/MomentumCorrection/Algorithm.cc +++ b/src/iguana/algorithms/clas12/rga/MomentumCorrection/Algorithm.cc @@ -10,6 +10,7 @@ namespace iguana::clas12::rga { b_particle = GetBankIndex(banks, "REC::Particle"); b_sector = GetBankIndex(banks, "REC::Particle::Sector"); b_config = GetBankIndex(banks, "RUN::config"); + ParseYAMLConfig(); /////////// FIXME: can we make this happen automatically?? } diff --git a/src/iguana/algorithms/clas12/rga/MomentumCorrection/Config.yaml b/src/iguana/algorithms/clas12/rga/MomentumCorrection/Config.yaml new file mode 100644 index 00000000..e1cacd44 --- /dev/null +++ b/src/iguana/algorithms/clas12/rga/MomentumCorrection/Config.yaml @@ -0,0 +1 @@ +clas12::rga::MomentumCorrection: diff --git a/src/iguana/algorithms/example/ExampleAlgorithm/Config.yaml b/src/iguana/algorithms/example/ExampleAlgorithm/Config.yaml index 786acd47..fac24b09 100644 --- a/src/iguana/algorithms/example/ExampleAlgorithm/Config.yaml +++ b/src/iguana/algorithms/example/ExampleAlgorithm/Config.yaml @@ -3,6 +3,9 @@ # files from other algorithms # - See also the test configuration files in ../../tests/config and how they # may be accessed in ../../tests/include/TestConfig.h +# - All algorithms must have a Config.yaml file; if the algorithm has no +# configuration parameters, it may just be a single line with the algorithm +# name, ending with a colon example::ExampleAlgorithm: exampleInt: 8 exampleDouble: 7.5 diff --git a/src/iguana/algorithms/meson.build b/src/iguana/algorithms/meson.build index 60a53f0a..d790108d 100644 --- a/src/iguana/algorithms/meson.build +++ b/src/iguana/algorithms/meson.build @@ -5,7 +5,6 @@ # { # 'name': str # algorithm name (REQUIRED) # 'directory': str # algorithm source code directory (default is based on 'name', replacing '::' with '/') -# 'has_config': bool # assumes Config.yaml exists (default=true) # 'has_validator': bool # assumes Validator{cc,h} exist (default=true) # 'has_action_yaml': bool # assumes Action.yaml exists (default=true) # 'algorithm_needs_ROOT': bool # whether this algorithm (or its prerequisites) needs ROOT or not (default=false) @@ -60,7 +59,6 @@ algo_dict = [ }, { 'name': 'clas12::CalorimeterLinker', - 'has_config': false, 'has_validator': false, 'has_action_yaml': false, 'test_args': { @@ -69,7 +67,6 @@ algo_dict = [ }, { 'name': 'clas12::TrajLinker', - 'has_config': false, 'has_validator': false, 'has_action_yaml': false, 'test_args': { @@ -78,13 +75,11 @@ algo_dict = [ }, { 'name': 'clas12::rga::FTEnergyCorrection', - 'has_config': false, 'has_validator': false, 'test_args': {'banks': [ 'RECFT::Particle' ]}, }, { 'name': 'clas12::rga::MomentumCorrection', - 'has_config': false, 'test_args': { 'banks': [ 'RUN::config', @@ -122,7 +117,6 @@ algo_dict = [ { 'name': 'physics::Depolarization', 'algorithm_needs_ROOT': true, # since `physics::InclusiveKinematics` needs ROOT - 'has_config': false, 'test_args': { 'banks': [ ], 'prerequisites': [ 'physics::InclusiveKinematics' ], @@ -147,7 +141,6 @@ algo_dict = [ 'name': 'clas12::MatchParticleProximity', 'algorithm_needs_ROOT': true, 'has_validator': false, # FIXME # need an MC file for non-empty validator plots - 'has_config': true, 'has_action_yaml': false, 'test_args': { 'banks': [ 'REC::Particle', 'MC::Particle' ], @@ -181,7 +174,6 @@ foreach algo : algo_dict algo_name = algo.get('name') algo_dir = algo.get('directory', '/'.join(algo_name.split('::'))) - algo_has_config = algo.get('has_config', true) algo_has_validator = algo.get('has_validator', true) algo_has_action_yaml = algo.get('has_action_yaml', true) algo_needs_ROOT = algo.get('algorithm_needs_ROOT', false) @@ -201,9 +193,7 @@ foreach algo : algo_dict endforeach # config files - if algo_has_config - algo_configs += algo_dir / 'Config.yaml' - endif + algo_configs += algo_dir / 'Config.yaml' # run chameleon if use_chameleon and algo_has_action_yaml diff --git a/src/iguana/algorithms/physics/Depolarization/Config.yaml b/src/iguana/algorithms/physics/Depolarization/Config.yaml new file mode 100644 index 00000000..fff7474e --- /dev/null +++ b/src/iguana/algorithms/physics/Depolarization/Config.yaml @@ -0,0 +1 @@ +physics::Depolarization: