Skip to content
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

Addition of HEPMC3 and GENIE Reweight to docker image #105

Open
wants to merge 11 commits into
base: main
Choose a base branch
from

Conversation

wesketchum
Copy link
Contributor

This PR includes the addition of the HEPMC3 package, addition of Pythia8 for future interfaces to GENIE, updates to GENIE to include interfaces to HEPMC3, and the inclusion of the GENIE Reweight package.

What new packages does this PR add to the development container?

  • New: HEPMC3 v3.3.0
  • New: Pythia8 v8.310
  • Update: GENIE v3.2 -> v3.4 (HEPMC flavor from my own repo)
  • Update LHAPDF v6.5.3 -> v6.5.4
  • New: GENIE Reweight v1.2.4

Check List

  • I successfully built the container using docker
# outline of container build instructions
cd docker
git checkout wketchum_HEPMC3
docker build . -t ldmx/local:hepmc
  • I was able to build ldmx-sw using this new container build
# outline of build instructions
ldmx-container-pull local hepmc
cd ldmx-sw
mkdir build
cd build
ldmx cmake ..
ldmx make install
  • [] I was able to test run a small simulation and reconstruction inside this container
# outline of test instructions
cd $LDMX_BASE/ldmx-sw/build
ldmx ctest
cd ..
for c in `ls ldmx-sw/*/test/*.py`; ldmx fire $c; done

Following the above instructions, I saw two errors. Will include in following message.

  • I was able to successfully use the new packages. Explain what you did to test them below:
    Executed updated GENIE simulation and reweighting (from branch wketchum/Genie_Generator_HepMC3Refactor in ldmx-sw) and verified all appears to be working well.

@wesketchum
Copy link
Contributor Author

Saw two errors from running ctest:

bash-5.2$ ldmx ctest --rerun-failed --output-on-failure
Test project /Users/wketchum/ldmx-sw_15May2024/build
    Start 6: Hcal
1/2 Test #6: Hcal .............................***Failed   13.21 sec
Filters: [Hcal]
Randomness seeded to: 3705149731

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
run_test is a Catch2 v3.3.1 host application.
Run with -? for options

-------------------------------------------------------------------------------
Hcal Geometry test
-------------------------------------------------------------------------------
/Users/wketchum/ldmx-sw_15May2024/Hcal/test/HcalGeometryTest.cxx:48
...............................................................................

/Users/wketchum/ldmx-sw_15May2024/Hcal/test/HcalGeometryTest.cxx:55: FAILED:
  {Unknown expression after the reported line}
due to a fatal error condition:
  SIGSEGV - Segmentation violation signal

===============================================================================
test cases:    2 |    1 passed | 1 failed
assertions: 6003 | 6002 passed | 1 failed


 *** Break *** segmentation violation



===========================================================
There was a crash.
This is the entire stack trace of all threads:
===========================================================
#0  0x00007fc3b42ea3ea in __GI___wait4 (pid=27, stat_loc=stat_loc
entry=0x7fff259e9818, options=options
entry=0, usage=usage
entry=0x0) at ../sysdeps/unix/sysv/linux/wait4.c:30
#1  0x00007fc3b42ea3ab in __GI___waitpid (pid=<optimized out>, stat_loc=stat_loc
entry=0x7fff259e9818, options=options
entry=0) at ./posix/waitpid.c:38
#2  0x00007fc3b4250bdb in do_system (line=<optimized out>) at ../sysdeps/posix/system.c:171
#3  0x00007fc3b610a334 in TUnixSystem::StackTrace() () from /usr/local/lib/libCore.so
#4  0x00007fc3b6107665 in TUnixSystem::DispatchSignals(ESignals) () from /usr/local/lib/libCore.so
#5  <signal handler called>
#6  0x00007fc3b32bb2a2 in simcore::g4user::SteppingAction::UserSteppingAction(G4Step const*) () from /Users/wketchum/ldmx-sw/install/lib/libSimCore_G4User.so
#7  0x00007fc3aa3cc08d in G4SteppingManager::Stepping (this=0x556205ed3b30) at /src/source/tracking/src/G4SteppingManager.cc:243
#8  0x00007fc3aa3d61bc in G4TrackingManager::ProcessOneTrack (this=0x55620650be90, apValueG4Track=apValueG4Track
entry=0x55620aaaf1f0) at /src/source/tracking/src/G4TrackingManager.cc:126
#9  0x00007fc3aa40fd29 in G4EventManager::DoProcessing (this=0x55620650bdf0, anEvent=<optimized out>) at /src/source/event/src/G4EventManager.cc:184
#10 0x00007fc3aa49ecab in G4RunManager::ProcessOneEvent (this=0x556204e1bcf0, i_event=1) at /src/source/run/src/G4RunManager.cc:399
#11 0x00007fc3aacd7dc3 in simcore::Simulator::produce(framework::Event&) () from /Users/wketchum/ldmx-sw_15May2024/install/lib/libSimCore.so
#12 0x00007fc3b5d50ee9 in framework::Process::process(int, int, framework::Event&) const () from /Users/wketchum/ldmx-sw/install/lib/libFramework.so
#13 0x00007fc3b5d5372d in framework::Process::run() () from /Users/wketchum/ldmx-sw/install/lib/libFramework.so
#14 0x00005561e5acb1e6 in CATCH2_INTERNAL_TEST_0() ()
#15 0x00005561e5b2d16c in Catch::TestInvokerAsFunction::invoke() const ()
#16 0x00005561e5b21e71 in Catch::TestCaseHandle::invoke() const ()
#17 0x00005561e5b20f62 in Catch::RunContext::invokeActiveTestCase() ()
#18 0x00005561e5b20c76 in Catch::RunContext::runCurrentTest(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&) ()
#19 0x00005561e5b1f251 in Catch::RunContext::runTest(Catch::TestCaseHandle const&) ()
#20 0x00005561e5acd53b in Catch::(anonymous namespace)::TestGroup::execute() ()
#21 0x00005561e5acea40 in Catch::Session::runInternal() ()
#22 0x00005561e5ace542 in Catch::Session::run() ()
#23 0x00005561e5acc03d in int Catch::Session::run<char>(int, char const* const*) ()
#24 0x00005561e5acbf25 in main ()
===========================================================


The lines below might hint at the cause of the crash.
You may get help by asking at the ROOT forum https://root.cern.ch/forum
Only if you are really convinced it is a bug in ROOT then please submit a
report at https://root.cern.ch/bugs Please post the ENTIRE stack trace
from above as an attachment in addition to anything else
that might help us fixing this issue.
===========================================================
#6  0x00007fc3b32bb2a2 in simcore::g4user::SteppingAction::UserSteppingAction(G4Step const*) () from /Users/wketchum/ldmx-sw/install/lib/libSimCore_G4User.so
#7  0x00007fc3aa3cc08d in G4SteppingManager::Stepping (this=0x556205ed3b30) at /src/source/tracking/src/G4SteppingManager.cc:243
#8  0x00007fc3aa3d61bc in G4TrackingManager::ProcessOneTrack (this=0x55620650be90, apValueG4Track=apValueG4Track
entry=0x55620aaaf1f0) at /src/source/tracking/src/G4TrackingManager.cc:126
#9  0x00007fc3aa40fd29 in G4EventManager::DoProcessing (this=0x55620650bdf0, anEvent=<optimized out>) at /src/source/event/src/G4EventManager.cc:184
#10 0x00007fc3aa49ecab in G4RunManager::ProcessOneEvent (this=0x556204e1bcf0, i_event=1) at /src/source/run/src/G4RunManager.cc:399
#11 0x00007fc3aacd7dc3 in simcore::Simulator::produce(framework::Event&) () from /Users/wketchum/ldmx-sw_15May2024/install/lib/libSimCore.so
#12 0x00007fc3b5d50ee9 in framework::Process::process(int, int, framework::Event&) const () from /Users/wketchum/ldmx-sw/install/lib/libFramework.so
#13 0x00007fc3b5d5372d in framework::Process::run() () from /Users/wketchum/ldmx-sw/install/lib/libFramework.so
#14 0x00005561e5acb1e6 in CATCH2_INTERNAL_TEST_0() ()
#15 0x00005561e5b2d16c in Catch::TestInvokerAsFunction::invoke() const ()
#16 0x00005561e5b21e71 in Catch::TestCaseHandle::invoke() const ()
#17 0x00005561e5b20f62 in Catch::RunContext::invokeActiveTestCase() ()
#18 0x00005561e5b20c76 in Catch::RunContext::runCurrentTest(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >&) ()
#19 0x00005561e5b1f251 in Catch::RunContext::runTest(Catch::TestCaseHandle const&) ()
#20 0x00005561e5acd53b in Catch::(anonymous namespace)::TestGroup::execute() ()
#21 0x00005561e5acea40 in Catch::Session::runInternal() ()
#22 0x00005561e5ace542 in Catch::Session::run() ()
#23 0x00005561e5acc03d in int Catch::Session::run<char>(int, char const* const*) ()
#24 0x00005561e5acbf25 in main ()
===========================================================



    Start 7: Run_SimCore_basic.py
2/2 Test #7: Run_SimCore_basic.py .............***Failed   10.36 sec
---- LDMXSW: Loading configuration --------
---- LDMXSW: Configuration load complete  --------
---- LDMXSW: Starting event processing --------
[ RunManager ]: Parallel worlds physics list has been registered.
[ RunManager ]: Parallel worlds have been enabled.
[ DetectorConstruction ] 0 debug: Attaching Tagger_TrackerSD to Tagger_active_Sensor_vol
[ DetectorConstruction ] 0 debug: Attaching Recoil_TrackerSD to Recoil_l14_active_Sensor_vol
[ DetectorConstruction ] 0 debug: Attaching Recoil_TrackerSD to Recoil_l56_active_Sensor_vol
[ DetectorConstruction ] 0 debug: Attaching hcal_sd to back_hcal_scintYVolume
[ DetectorConstruction ] 0 debug: Attaching hcal_sd to back_hcal_scintXVolume
[ DetectorConstruction ] 0 debug: Attaching hcal_sd to side_hcal_scintX_0Volume
[ DetectorConstruction ] 0 debug: Attaching hcal_sd to side_hcal_scintY_0Volume
[ DetectorConstruction ] 0 debug: Attaching hcal_sd to side_hcal_scintX_1Volume
[ DetectorConstruction ] 0 debug: Attaching hcal_sd to side_hcal_scintY_1Volume
[ DetectorConstruction ] 0 debug: Attaching hcal_sd to side_hcal_scintX_2Volume
[ DetectorConstruction ] 0 debug: Attaching hcal_sd to side_hcal_scintY_2Volume
[ DetectorConstruction ] 0 debug: Attaching hcal_sd to side_hcal_scintX_3Volume
[ DetectorConstruction ] 0 debug: Attaching hcal_sd to side_hcal_scintY_3Volume
[ DetectorConstruction ] 0 debug: Attaching hcal_sd to side_hcal_scintZXVolume
[ DetectorConstruction ] 0 debug: Attaching hcal_sd to side_hcal_scintZYVolume
[ DetectorConstruction ] 0 debug: Attaching ecal_sd to Si_volume
[ DetectorConstruction ] 0 debug: Attaching trig_scint_Target_sd to target
[ DetectorConstruction ] 0 debug: Attaching trig_scint_Pad1_sd to trigger_pad1_bar_volume
[ DetectorConstruction ] 0 debug: Attaching trig_scint_Pad2_sd to trigger_pad2_bar_volume
[ DetectorConstruction ] 0 debug: Attaching trig_scint_Pad3_sd to trigger_pad3_bar_volume
[ DetectorConstruction ] 0 debug: Attaching ecal_sp to sp_ecal_front_back
[ DetectorConstruction ] 0 debug: Attaching ecal_sp to sp_ecal_top_bot
[ DetectorConstruction ] 0 debug: Attaching ecal_sp to sp_ecal_left_right
[ DetectorConstruction ] 0 debug: Attaching ecal_sp to sp_ecal_front_back
[ DetectorConstruction ] 0 debug: Attaching ecal_sp to sp_ecal_top_bot
[ DetectorConstruction ] 0 debug: Attaching ecal_sp to sp_ecal_left_right
[ DetectorConstruction ] 0 debug: Attaching hcal_sp to sp_hcal_front_back
[ DetectorConstruction ] 0 debug: Attaching hcal_sp to sp_hcal_top_bot
[ DetectorConstruction ] 0 debug: Attaching hcal_sp to sp_hcal_left_right
[ DetectorConstruction ] 0 debug: Attaching hcal_sp to sp_hcal_front_back
[ DetectorConstruction ] 0 debug: Attaching hcal_sp to sp_hcal_top_bot
[ DetectorConstruction ] 0 debug: Attaching hcal_sp to sp_hcal_left_right
[ DetectorConstruction ] 0 debug: Attaching target_sp to sp_target
[ DetectorConstruction ] 0 debug: Attaching target_sp to sp_target
[ DetectorConstruction ] 0 debug: Attaching target_sp to sp_target
[ DetectorConstruction ] 0 debug: Attaching trigScint_sp to sp_trigScint
[ DetectorConstruction ] 0 debug: Attaching trigScint_sp to sp_trigScint
[ DetectorConstruction ] 0 debug: Attaching trigScint_sp to sp_trigScint
[ DetectorConstruction ] 0 debug: Attaching trigScint_sp to sp_trigScint
[ DetectorConstruction ] 0 debug: Attaching trigScint_sp to sp_trigScint
[ DetectorConstruction ] 0 debug: Attaching trigScint_sp to sp_trigScint
[ DetectorConstruction ] 0 debug: Attaching tracker_sp to sp_recoil
[ DetectorConstruction ] 0 debug: Attaching tracker_sp to sp_recoil
[ DetectorConstruction ] 0 debug: Attaching tracker_sp to sp_recoil
[ DetectorConstruction ] 0 debug: Attaching tracker_sp to sp_recoil
[ DetectorConstruction ] 0 debug: Attaching tracker_sp to sp_recoil
[ DetectorConstruction ] 0 debug: Attaching tracker_sp to sp_recoil
[ DetectorConstruction ] 0 debug: Attaching magnet_sp to sp_magnet_gap_top_bot
[ DetectorConstruction ] 0 debug: Attaching magnet_sp to sp_magnet_gap_left_right
[ DetectorConstruction ] 0 debug: Attaching magnet_sp to sp_magnet_gap_top_bot
[ DetectorConstruction ] 0 debug: Attaching magnet_sp to sp_magnet_gap_left_right
[ ParallelWorld ] 0 debug: Adding : sp_target_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_target_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_trigScint_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_trigScint_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_trigScint_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_trigScint_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_trigScint_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_trigScint_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_recoil_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_recoil_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_recoil_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_recoil_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_recoil_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_recoil_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_magnet_gap_top_bot_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_magnet_gap_left_right_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_magnet_gap_top_bot_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_magnet_gap_left_right_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_ecal_front_back_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_ecal_top_bot_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_ecal_left_right_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_ecal_front_back_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_ecal_top_bot_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_ecal_left_right_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_hcal_front_back_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_hcal_top_bot_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_hcal_left_right_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_hcal_front_back_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_hcal_top_bot_PV to parallel world.
[ ParallelWorld ] 0 debug: Adding : sp_hcal_left_right_PV to parallel world.
[ Process ] 1  info: Processing 1 Run 9001 Event 1  (2024-10-16 08:22:07.802771000+0000)

 *** Break *** segmentation violation



===========================================================
There was a crash.
This is the entire stack trace of all threads:
===========================================================
#0  0x00007f46d94ea3ea in __GI___wait4 (pid=180, stat_loc=stat_loc
entry=0x7ffd32229998, options=options
entry=0, usage=usage
entry=0x0) at ../sysdeps/unix/sysv/linux/wait4.c:30
#1  0x00007f46d94ea3ab in __GI___waitpid (pid=<optimized out>, stat_loc=stat_loc
entry=0x7ffd32229998, options=options
entry=0) at ./posix/waitpid.c:38
#2  0x00007f46d9450bdb in do_system (line=<optimized out>) at ../sysdeps/posix/system.c:171
#3  0x00007f46d9f0a334 in TUnixSystem::StackTrace() () from /usr/local/lib/libCore.so
#4  0x00007f46d9f07665 in TUnixSystem::DispatchSignals(ESignals) () from /usr/local/lib/libCore.so
#5  <signal handler called>
#6  0x00007f46d781d2a2 in simcore::g4user::SteppingAction::UserSteppingAction(G4Step const*) () from /Users/wketchum/ldmx-sw/install/lib/libSimCore_G4User.so
#7  0x00007f46d5b4008d in G4SteppingManager::Stepping (this=0x55b8b9d16600) at /src/source/tracking/src/G4SteppingManager.cc:243
#8  0x00007f46d5b4a1bc in G4TrackingManager::ProcessOneTrack (this=0x55b8b9d165c0, apValueG4Track=apValueG4Track
entry=0x55b8c26d86a0) at /src/source/tracking/src/G4TrackingManager.cc:126
#9  0x00007f46d5b83d29 in G4EventManager::DoProcessing (this=0x55b8b9d16520, anEvent=<optimized out>) at /src/source/event/src/G4EventManager.cc:184
#10 0x00007f46d5c12cab in G4RunManager::ProcessOneEvent (this=0x55b8b97889d0, i_event=1) at /src/source/run/src/G4RunManager.cc:399
#11 0x00007f46d6304dc3 in simcore::Simulator::produce(framework::Event&) () from /Users/wketchum/ldmx-sw_15May2024/install/lib/libSimCore.so
#12 0x00007f46da40bee9 in framework::Process::process(int, int, framework::Event&) const () from /Users/wketchum/ldmx-sw/install/lib/libFramework.so
#13 0x00007f46da40e72d in framework::Process::run() () from /Users/wketchum/ldmx-sw/install/lib/libFramework.so
#14 0x000055b88cc0d0bd in main ()
===========================================================


The lines below might hint at the cause of the crash.
You may get help by asking at the ROOT forum https://root.cern.ch/forum
Only if you are really convinced it is a bug in ROOT then please submit a
report at https://root.cern.ch/bugs Please post the ENTIRE stack trace
from above as an attachment in addition to anything else
that might help us fixing this issue.
===========================================================
#6  0x00007f46d781d2a2 in simcore::g4user::SteppingAction::UserSteppingAction(G4Step const*) () from /Users/wketchum/ldmx-sw/install/lib/libSimCore_G4User.so
#7  0x00007f46d5b4008d in G4SteppingManager::Stepping (this=0x55b8b9d16600) at /src/source/tracking/src/G4SteppingManager.cc:243
#8  0x00007f46d5b4a1bc in G4TrackingManager::ProcessOneTrack (this=0x55b8b9d165c0, apValueG4Track=apValueG4Track
entry=0x55b8c26d86a0) at /src/source/tracking/src/G4TrackingManager.cc:126
#9  0x00007f46d5b83d29 in G4EventManager::DoProcessing (this=0x55b8b9d16520, anEvent=<optimized out>) at /src/source/event/src/G4EventManager.cc:184
#10 0x00007f46d5c12cab in G4RunManager::ProcessOneEvent (this=0x55b8b97889d0, i_event=1) at /src/source/run/src/G4RunManager.cc:399
#11 0x00007f46d6304dc3 in simcore::Simulator::produce(framework::Event&) () from /Users/wketchum/ldmx-sw_15May2024/install/lib/libSimCore.so
#12 0x00007f46da40bee9 in framework::Process::process(int, int, framework::Event&) const () from /Users/wketchum/ldmx-sw/install/lib/libFramework.so
#13 0x00007f46da40e72d in framework::Process::run() () from /Users/wketchum/ldmx-sw/install/lib/libFramework.so
#14 0x000055b88cc0d0bd in main ()
===========================================================




0% tests passed, 2 tests failed out of 2

Total Test time (real) =  23.61 sec

The following tests FAILED:
	  6 - Hcal (Failed)
	  7 - Run_SimCore_basic.py (Failed)
Errors while running CTest

Copy link
Member

@tomeichlersmith tomeichlersmith left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I do not know why there is a seg fault on the first event. I'm curious if it happens outside of ctest and if it does, then I'd do a Debug build of ldmx-sw and run the config in gdb to try to find the culprit.

Besides my question on Pythia6, I feel obliged to point out the OS update in the pipeline: #103 This would presumably require re-development of these changes, although that OS update also requires updates to ldmx-sw.

@@ -214,6 +247,7 @@ RUN mkdir src &&\
-Dxrootd=OFF \
-Dgsl_shared=ON \
-Dmathmore=ON \
-Dpythia8=ON \
-Dpythia6=ON \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we remove Pythia6? Is it still necessary?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately still necessary :/ I know the GENIE team is working on it, but I think the Pythia6 dependency is buried deep, and they've not fully extricated it yet. I will double-check to be sure, but unfortunately it's a case where it looks like we need both.

@wesketchum
Copy link
Contributor Author

Thanks @tomeichlersmith. I haven't had the chance to investigate the test failure in more detail yet, but will do so. Good to verify that they should not be failing.

I'll review the OS updates as well and work to make sure we have the right plan for that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants