GEMC 0.5
GEMC 0.5 adds streaming readout, Geant4 macro execution, and more reliable geometry and multithreaded
simulation. The coordinated release also includes pygemc 0.5.0 and CLAS12 systems 0.3.
This version includes:
- Streaming readout with one collector thread per crate and experiment-defined frame encoding
- Geant4 macros, mixed native and CAD systems, and safer multithreaded primary generation
- Clearer configuration and geometry handling, with optional Qt SVG and Charts modules
pygemcgeometry-authoring helpers, CAD metadata updates, and more reliable PyVista previews- CLAS12 Forward Tagger and HTCC geometry and digitization, plus installation from a bare Geant4 environment
GEMC core
- The
srooutput factory combines contributions from all event workers in one collector thread per crate. Experiment plugins define the payloads, electronics response, frame processing, and output encoding. TheeventTimeWidthoption places consecutive events on a continuous timeline. - Use
-geant4_macro=run.macto execute a Geant4 macro after startup in batch, terminal, or GUI mode. Macros control batch event generation with/run/beamOn; missing files and command errors fail the run. - SQLite and ASCII systems can now mix native and CAD volumes in one system. Configuration and geometry loading distinguish missing optional values from required values, with clearer errors for invalid input.
- Multithreaded primary generation no longer shares mutable event state or changes shared logical-volume
step limits from workers, preventing crashes when increasing
nthreads. - Hit calculations now keep derived energy, time, position, process, and track metadata consistent. Translation-table lookups expose the stored electronics entry directly.
- Qt SVG and Qt Charts are optional. Builds without SVG omit toolbar icons; builds without Charts show a notice on the GUI analysis page. Geant4 pkg-config files are generated and resolved inside the build tree.
pygemc 0.5.0
- CAD uploads store mesh paths and scales in geometry parameters, leaving descriptions available for text. Updated consumers continue to accept the legacy CAD layout.
- Optional geometry metadata is normalized before publication and written as ASCII
NULLor SQLiteNULL. GVolume.publish_passive()supports GEMC2 placement conventions. Tube and polycone builders default to a full azimuth, and a configurable numeric formatter controls dimensions, positions, and rotations.- PyVista adds cut
G4Ellipsoidmeshes and supports absolute-coordinate boolean expressions. Invisible volumes are omitted while their transforms still apply to visible daughters. - Boolean previews handle thin elliptical mirrors and curved-solid intersections more reliably. Failed operations omit the invalid result, and missing native boolean filters produce a diagnostic.
CLAS12 systems 0.3
- CLAS12 systems can install from scratch on a Geant4 environment. Meson reuses an existing GEMC installation or builds GEMC as a subproject and installs it into the same prefix.
- The Forward Tagger includes the FTCAL calorimeter, FTHODO hodoscope, variation-dependent FTTRK tracker, support structures, custom materials, calibration constants, and digitization plugins.
- HTCC adds native gas volumes, windows, 48 elliptical mirrors, and 48 photomultiplier tubes, with CAD beamline cones and the GEMC2-compatible photoelectron response.
- FT-Cal streaming readout routes calibrated payloads through translation tables and writes JLAB integral
frames through GEMC’s
srofactory. - Field maps come from the
magfieldgit-lfs subproject. Existing maps can be reused with-Duse-fields-location; bundled dependency installation and tests are optional.
Documentation and examples
- Added 11 generator manipulation cards with verified vertex and angular distributions, prepared Analyzer plots, and 100-event GEMC views inside a transparent tube target.
- Added a random-ADC streaming example and guides for worker payloads, crate ownership, timing, framing, implementation factories, and FT-Cal JLAB output.
- Added the CLAS12 Forward Tagger and HTCC example pages and expanded source-installation instructions.
- Expanded tests for streaming readout, concurrent event generation, geometry, PyVista booleans, and CLAS12 detector construction. Thread-scaling reports and CI workflow guides document validation and deployment.
Compatibility notes
- GEMC 0.5 requires a C++20 compiler. Meson build defaults replace the former
core.ininative file; remove--native-file=core.iniand create a fresh build directory when migrating. - Replace
format: jlabsrowithformat: sroand animplementationplugin name. FT-Cal usesimplementation: ft_calfrom CLAS12 systems and requires an expliciteventTimeWidth. - Rebuild native digitization and streaming plugins against GEMC 0.5. Replace
getScalar*()option accessors withgetRequiredScalar*()orgetOptionalScalar*(), and update code for optional geometry and hit metadata. - Newly generated CAD databases require consumers that understand mesh paths and scales in geometry parameters.
make_polycone()now raisesValueErrorfor missing or mismatched arrays.
See the installation guide for release downloads and source builds.