From 1aa24f83a1254cf00a513c95f90f97eed21a2231 Mon Sep 17 00:00:00 2001
From: Chao Peng <cpeng@anl.gov>
Date: Wed, 5 May 2021 09:58:52 -0500
Subject: [PATCH] add python module

---
 benchmarks/sampling_ecal/requirements.txt              | 1 +
 benchmarks/sampling_ecal/run_emcal_barrel_electrons.sh | 3 +++
 2 files changed, 4 insertions(+)
 create mode 100644 benchmarks/sampling_ecal/requirements.txt

diff --git a/benchmarks/sampling_ecal/requirements.txt b/benchmarks/sampling_ecal/requirements.txt
new file mode 100644
index 00000000..7a4ab2e2
--- /dev/null
+++ b/benchmarks/sampling_ecal/requirements.txt
@@ -0,0 +1 @@
+imageio >= 2.9.0
diff --git a/benchmarks/sampling_ecal/run_emcal_barrel_electrons.sh b/benchmarks/sampling_ecal/run_emcal_barrel_electrons.sh
index 8418b361..8293dbd3 100644
--- a/benchmarks/sampling_ecal/run_emcal_barrel_electrons.sh
+++ b/benchmarks/sampling_ecal/run_emcal_barrel_electrons.sh
@@ -70,6 +70,9 @@ if [[ "$?" -ne "0" ]] ; then
   exit 1
 fi
 
+# check required python modules
+python -m pip install -r benchmarks/sampling_ecal/requirements.txt
+
 # Run analysis script
 python ${CB_EMCAL_SCRIPT_DIR}/draw_cluster_layers.py \
     ${CB_EMCAL_REC_FILE} -e 0 --topo-size=1.0 --compact=${CB_EMCAL_COMPACT_PATH} -o results
-- 
GitLab