extend Steps ntuple and switch Docker to Geant4 submodule source
Add 15 new columns to the Steps ntuple: edep, step_length, parent_id, process name, layer_id, material, pre-step momentum direction, and B/E field components (in T and V/m) at the pre-step point. Replace wget Geant4 tarball download in all three Dockerfiles with ADD of the lib/geant4 submodule source; narrow submodule init to lib/pybind11 only so builds no longer require network access for Geant4. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
+19
-16
@@ -50,22 +50,24 @@ RUN mkdir dawn-source \
|
||||
&& make clean && make guiclean && make && make install \
|
||||
&& cd - && rm -rf "dawn-source"
|
||||
|
||||
## main package
|
||||
## main package — build Geant4 from submodule source
|
||||
ADD minicalosim/lib/geant4 /tmp/geant4-src
|
||||
|
||||
RUN cd && wget -q https://gitlab.cern.ch/geant4/geant4/-/archive/v11.1.2/geant4-v11.1.2.tar.gz && \
|
||||
tar -xzf geant4-v11.1.2.tar.gz -C /tmp && \
|
||||
mkdir /tmp/geant4-v11.1.2-build && \
|
||||
cd /tmp/geant4-v11.1.2-build && \
|
||||
cmake -DCMAKE_INSTALL_PREFIX=/opt/geant4-v11.1.2 -DCMAKE_RULE_MESSAGES=OFF -DGEANT4_INSTALL_DATA=ON \
|
||||
-DGEANT4_USE_GDML=ON -DGEANT4_USE_OPENGL_X11=ON \
|
||||
-DGEANT4_BUILD_MULTITHREADED=ON \
|
||||
-DGEANT4_BUILD_TLS_MODEL=global-dynamic \
|
||||
-DGEANT4_USE_RAYTRACER_X11=ON /tmp/geant4-v11.1.2 >/dev/null && \
|
||||
make -j4 >/dev/null && \
|
||||
make install >/dev/null
|
||||
|
||||
RUN rm -rf /tmp/geant4-v11.1.2 && \
|
||||
rm -rf /tmp/geant4-v11.1.2-build
|
||||
RUN cmake \
|
||||
-S /tmp/geant4-src \
|
||||
-B /tmp/geant4-build \
|
||||
-DCMAKE_INSTALL_PREFIX=/opt/geant4-v11.1.2 \
|
||||
-DCMAKE_RULE_MESSAGES=OFF \
|
||||
-DGEANT4_INSTALL_DATA=ON \
|
||||
-DGEANT4_USE_GDML=ON \
|
||||
-DGEANT4_USE_OPENGL_X11=ON \
|
||||
-DGEANT4_BUILD_MULTITHREADED=ON \
|
||||
-DGEANT4_BUILD_TLS_MODEL=global-dynamic \
|
||||
-DGEANT4_USE_RAYTRACER_X11=ON \
|
||||
>/dev/null && \
|
||||
cmake --build /tmp/geant4-build --parallel $(nproc) >/dev/null && \
|
||||
cmake --install /tmp/geant4-build >/dev/null && \
|
||||
rm -rf /tmp/geant4-src /tmp/geant4-build
|
||||
|
||||
|
||||
RUN python3 -m pip install geant4-pybind
|
||||
@@ -94,7 +96,8 @@ ARG USER
|
||||
ADD minicalosim /root/minicalosim
|
||||
|
||||
RUN cd /root/minicalosim && git checkout $COMMIT && \
|
||||
mkdir -p build && cd build && rm -rf * && cmake ../ && make -j4 &&\
|
||||
git submodule update --init lib/pybind11 && \
|
||||
mkdir -p build && cd build && rm -rf * && cmake ../ && make -j$(nproc) &&\
|
||||
cp minicalo* ../bind/G4Calo.py /usr/local/lib/python3.8/dist-packages/
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user