yasfpy.benchmark.mstm3 ====================== .. py:module:: yasfpy.benchmark.mstm3 .. autoapi-nested-parse:: Convenience wrapper around the MSTM3 binary. Provides a small manager used in benchmarks and regression comparisons. Attributes ---------- .. autoapisummary:: yasfpy.benchmark.mstm3.mstm Classes ------- .. autoapisummary:: yasfpy.benchmark.mstm3.MSTM3Manager Module Contents --------------- .. py:class:: MSTM3Manager(config_path = None, binary = None, input_file = 'mstm3.inp', output_file = 'mstm3.dat') Manage MSTM3 benchmark runs. The manager can generate an MSTM3 input file from a YASF configuration, run the external MSTM3 binary, and parse the resulting output file into basic scattering quantities. .. rubric:: Notes This helper is intended for benchmarking/regression comparisons rather than production simulations. .. py:attribute:: binary :type: str :value: './mstm' .. py:attribute:: input_file :type: str :value: 'mstm3.inp' .. py:attribute:: output_file :type: str :value: 'mstm3.dat' .. py:attribute:: config .. py:method:: clean() Delete generated MSTM3 files. .. py:method:: run(runner = None, cleanup = True) Run MSTM3 and parse output. :param runner: Optional :class:`pyperf.Runner` to benchmark the command. When omitted, the binary is executed directly and outputs are parsed. :param cleanup: If True, remove generated input/output files afterwards. .. py:method:: export(file = None, cleanup = False) Run MSTM3 and export parsed results. :param file: Output filename. Supported extensions are ``.json``, ``.yaml``/``.yml``, and ``.bz2``. :param cleanup: If True, also remove generated MSTM3 files afterwards. .. py:data:: mstm