Skip to content

feat: add requireMatchingMatrix option; disable for OFFM in CI #1862

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions .github/workflows/linux-eic-shell.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,8 @@ env:
detector-version: ${{ inputs.detector-version || 'main' }}
clang-tidy-iwyu-CXX: clang++
clang-tidy-iwyu-CMAKE_BUILD_TYPE: Debug
JANA_OPTIONS: -Pjana:ticker_interval=60000 -Pjana:warmup_timeout=0 -Pjana:timeout=0
# FIXME: FOFFMTRK has only 130 GeV matrix
JANA_OPTIONS: -PFOFFMTRK:ForwardOffMRecParticles:requireMatchingMatrix=false -Pjana:ticker_interval=60000 -Pjana:warmup_timeout=0 -Pjana:timeout=0
JANA_OPTIONS_GUN: -PFOFFMTRK:ForwardOffMRecParticles:requireBeamProton=false -PRPOTS:ForwardRomanPotRecParticles:requireBeamProton=false -PLOWQ2:TaggerTrackerTrajectories:requireBeamElectron=false -PLOWQ2:TaggerTrackerTransportationPreML:requireBeamElectron=false -PLOWQ2:TaggerTrackerTransportationPostML:requireBeamElectron=false
ASAN_OPTIONS: suppressions=${{ github.workspace }}/.github/asan.supp:malloc_context_size=20:detect_leaks=1:verify_asan_link_order=0:detect_stack_use_after_return=1:detect_odr_violation=1:new_delete_type_mismatch=0:intercept_tls_get_addr=0
LSAN_OPTIONS: suppressions=${{ github.workspace }}/.github/lsan.supp
Expand Down Expand Up @@ -886,7 +887,7 @@ jobs:
export LD_LIBRARY_PATH=$PWD/install/lib:$LD_LIBRARY_PATH
export JANA_PLUGIN_PATH=$PWD/install/lib/EICrecon/plugins:/usr/local/plugins
prmon --json-summary rec_dis_${{matrix.beam}}_minQ2=${{matrix.minq2}}_${{ matrix.detector_config }}.prmon.json -- \
$PWD/install/bin/eicrecon $JANA_OPTIONS -Ppodio:output_file=rec_dis_${{matrix.beam}}_minQ2=${{matrix.minq2}}_${{ matrix.detector_config }}.edm4eic.root sim_dis_${{matrix.beam}}_minQ2=${{matrix.minq2}}_${{ matrix.detector_config }}.edm4hep.root -Pacts:WriteObj=true -Pacts:WritePly=true -Pplugins=janadot,janatop $(<${{ github.workspace }}/.github/janadot.groups)
$PWD/install/bin/eicrecon ${{env.JANA_OPTIONS}} -Ppodio:output_file=rec_dis_${{matrix.beam}}_minQ2=${{matrix.minq2}}_${{ matrix.detector_config }}.edm4eic.root sim_dis_${{matrix.beam}}_minQ2=${{matrix.minq2}}_${{ matrix.detector_config }}.edm4hep.root -Pacts:WriteObj=true -Pacts:WritePly=true -Pplugins=janadot,janatop $(<${{ github.workspace }}/.github/janadot.groups)
- uses: actions/upload-artifact@v4
with:
name: rec_dis_${{matrix.beam}}_minQ2=${{matrix.minq2}}_${{ matrix.detector_config }}.edm4eic.root
Expand Down
5 changes: 4 additions & 1 deletion src/algorithms/fardetectors/MatrixTransferStatic.cc
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,10 @@ void eicrecon::MatrixTransferStatic::process(const MatrixTransferStatic::Input&
}
}
if (not matrix_found) {
error("MatrixTransferStatic:: No valid matrix found to match beam momentum!! Skipping!!");
if (m_cfg.requireMatchingMatrix) {
critical("No matrix found with matching beam momentum");
throw std::runtime_error("No matrix found with matching beam momentum");
}
return;
}

Expand Down
1 change: 1 addition & 0 deletions src/algorithms/fardetectors/MatrixTransferStaticConfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ struct MatrixTransferStaticConfig {
std::string readout{""};

bool requireBeamProton{true};
bool requireMatchingMatrix{true};
};

} // namespace eicrecon
2 changes: 2 additions & 0 deletions src/factories/fardetectors/MatrixTransferStatic_factory.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,8 @@ class MatrixTransferStatic_factory
ParameterRef<std::string> readout{this, "readout", config().readout};

ParameterRef<bool> requireBeamProton{this, "requireBeamProton", config().requireBeamProton};
ParameterRef<bool> requireMatchingMatrix{this, "requireMatchingMatrix",
config().requireMatchingMatrix};

Service<AlgorithmsInit_service> m_algorithmsInit{this};

Expand Down
Loading