yasfpy.benchmark.adda#
Wrapper for ADDA-based benchmarks.
This module provides a manager/helper to run ADDA (if available) and collect results for comparison/benchmarking.
Attributes#
Classes#
Manage and run ADDA benchmarks. |
Module Contents#
- yasfpy.benchmark.adda.DEFAULT_BIN_PATH = ''#
- yasfpy.benchmark.adda.DEFAULT_CONF_PATH = ''#
- class yasfpy.benchmark.adda.ADDAManager(config_path=DEFAULT_CONF_PATH, binary=DEFAULT_BIN_PATH, output_file='wow')#
Manage and run ADDA benchmarks.
This is a lightweight wrapper that:
reads a YASF configuration via
yasfpy.config.Configruns the external ADDA binary (if present)
parses basic cross sections/efficiencies from ADDA output
Notes
This module is primarily used for benchmarking and comparisons; it does not attempt to expose the full ADDA feature set.
- config#
- binary = ''#
- output_file = 'wow'#
- clean()#
Remove ADDA run directories.
Notes
This deletes directories matching
run_sphere*in the current working directory.
- run(runner=None, cleanup=True)#
Run ADDA and optionally parse output.
- Parameters:
runner – Optional
pyperf.Runnerto benchmark the command. When omitted, the external binary is executed directly and outputs are parsed.cleanup – If True, delete ADDA output directories after the run.
- export(file=None, cleanup=False)#
Run ADDA and export results to a file.
- Parameters:
file – Output filename. Supported extensions are
.json,.yaml/.yml, and.bz2.cleanup – If True, delete ADDA output directories after exporting.
- yasfpy.benchmark.adda.adda#