McStas and McXtrace 3.10.0 released

McStas and McXtrace 3.10.0 released

img

Highlights

  • New Scipp/Plopp-based plotting and display tools (preview): mcplot-plopp and mcdisplay-plopp are early versions of plotting and 3D display built on Scipp and Plopp. mcplot-plopp reads both McCode and NeXus output, including Monitor_nD event data shown as a pixel map. Both are offered as choices in mcgui/mxgui. By @willend.
  • NeXus output scales with MPI: in MPI runs, event lists are now written to one HDF5 file per process and joined into a single view (HDF5 “virtual data sets”), instead of being funnelled through one process. NeXus files are now compressed by default, --scan_split scans give a single NeXus file, and the requested ray count is stored in the file. List-mode Monitor_nDs that also bin in wavelength or time no longer crash in NeXus mode, and Mantid-mode monitors binned only in x or y now load in Mantid. The NeXus writer is also more robust: text containing % is stored as given, very long monitor file names no longer crash the run or corrupt the file, and large event lists are no longer silently dropped. By @willend.
  • Better-quality random numbers in parallel runs: with the default KISS generator, rays from different seeds, MPI processes and GPU batches could repeat each other’s random sequences. Every ray now gets its own independent seed, and neutron IDs are unique across GPU batches and MPI processes. Note: results for a given seed change compared to earlier versions. Mersenne Twister runs are unaffected. By @willend (fixes #2807).
  • Much improved instrument display: mcdisplay-webgl-classic now shows the detailed --trace=2 component shapes by default, shaded and with a wireframe toggle. Hollow boxes and cylinders are drawn as the cavities they are in the physics, polyhedra with faces of any size display correctly, and mcdisplay-cad exports to STEP, PLY and plain OFF, including particle rays. By @willend and @farhi.
  • New Text component in McStas and McXtrace: puts 3D text labels into your instrument drawings. With the new Text2OFF template instrument, any text can also be turned into OFF geometry for components that read OFF files. By @farhi and @willend.
  • More accurate conic mirrors: the conic.h library behind the ConicSurf/FlatEllipse mirror family now applies the reflectivity once and with the correct scattering vector, no longer re-hits the surface it just reflected from, and has a configurable figure error (waviness model of Hansen et al.). New Mirror_conic test component and test instruments. By @willend (fixes #2787).
  • Statistically smarter testing with mctest: new %TestScan: (aka %Scan:) lines run a test over a whole parameter scan. Tests can now pass on Monte Carlo error bars (--nsigma/--pvalue) instead of only a fixed ±20 % window, and --statfactor scales the statistics of every test. %Example: lines are now called %Test:. By @willend.
  • Union framework refactored: the inner scattering loop of Union was reorganised for clarity and maintainability, and Union_mesh now uses a new general triangle-mesh library (geometry-mesh-lib) that reads STL, OFF and PLY files and ray-traces them efficiently. By Daniel Lomholt Christensen (@Lomholy), @mads-bertelsen-agentic and @willend.
  • More SOLEIL in McXtrace: new PX1, NANOSCOPIUM and GALAXIES beamlines, plus a model of the full SOLEIL synchrotron assembling the beamlines, mainly for rendering. By @farhi.
  • MCPL_input consolidated: MCPL_input now includes the MPI splitting of MCPL_input_once yet allows to repeat by repeat_count. MCPL_input_once is moved to the obsolete components. MCPL_output now uses weight_mode=1 by default, which records the initial ray count and rescales weights, adapting with the stat:sum convention from MCPL. By @willend.

The full, categorised list of changes, common to McStas and McXtrace as well as specific to each, is in the McCode v3.10.0 release notes on GitHub.

New Contributors

Full Changelog: https://github.com/mccode-dev/McCode/compare/v3.9.2…v3.10.0

Best regards on behalf of the McStas-McXtrace team,

Peter Willendrup

Forskningsingeniør, Specialkonsulent

DTU Physics