Skip to content
Snippets Groups Projects
Commit 2fd58c74 authored by Johannes Schumann's avatar Johannes Schumann
Browse files

Add xsec to w2list

parent fb0cf69b
No related branches found
No related tags found
1 merge request!8W2list
Pipeline #19508 passed
......@@ -126,7 +126,7 @@ PARTICLE_MC_STATUS = {
W2LIST_LOOKUP = {
"PS": 0,
"EG": 1,
"XSEC_MEAN": 2,
"XSEC": 2,
"COLUMN_DEPTH": 3,
"P_EARTH": 4,
"WATER_INT_LEN": 5,
......@@ -137,8 +137,6 @@ W2LIST_LOOKUP = {
"CC": 10,
"DISTAMAX": 11,
"WATERXSEC": 12,
"XSEC": 13,
"DXSEC": 14,
"TARGETA": 15,
"TARGETZ": 16,
"VERINCAN": 17,
......@@ -491,7 +489,7 @@ def write_detector_file(gibuu_output,
evt.w.push_back(-1.0) #w3 (= w2*flux)
# Event Information (w2list)
evt.w2list.resize(W2LIST_LENGTH)
evt.w2list[W2LIST_LOOKUP["XSEC"]] = event.xsec
evt.w2list[W2LIST_LOOKUP["TARGETA"]] = gibuu_output.A
evt.w2list[W2LIST_LOOKUP["TARGETZ"]] = gibuu_output.Z
evt.w2list[W2LIST_LOOKUP["BX"]] = bjorkenx[mc_event_id]
......
......@@ -117,6 +117,8 @@ class TestAANET(unittest.TestCase):
np.testing.assert_allclose(evt.mc_tracks.pos_y, -122.54421157)
np.testing.assert_allclose(evt.mc_tracks.pos_z, 208.57726764)
usr = evt.mc_tracks.usr[0]
# XSEC
np.testing.assert_almost_equal(evt.w2list[2], 40.62418521597373)
# Bx
np.testing.assert_almost_equal(evt.w2list[7], 0.35479262672400624)
# By
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment