Skip to content
Snippets Groups Projects
Commit db96a68c authored by Dmitry Kalinkin's avatar Dmitry Kalinkin
Browse files

zdc_lyso: namespace prefix for Snakemake rules

parent 07804284
Branches
No related tags found
No related merge requests found
import os import os
rule ecal_lyso_sim_hepmc: rule zdc_lyso_sim_hepmc:
input: input:
script = "benchmarks/zdc_lyso/gen_particles.cxx", script = "benchmarks/zdc_lyso/gen_particles.cxx",
output: output:
...@@ -16,7 +16,7 @@ root -l -b -q '{input.script}({params.num_events}, "{output.hepmcfile}", "{wildc ...@@ -16,7 +16,7 @@ root -l -b -q '{input.script}({params.num_events}, "{output.hepmcfile}", "{wildc
""" """
rule ecal_lyso_sim: rule zdc_lyso_sim:
input: input:
hepmcfile="data/{PARTICLE}_{BEAM_ENERGY}GeV_theta_{THETA_MIN}deg_thru_{THETA_MAX}deg.hepmc", hepmcfile="data/{PARTICLE}_{BEAM_ENERGY}GeV_theta_{THETA_MIN}deg_thru_{THETA_MAX}deg.hepmc",
warmup="warmup/{DETECTOR_CONFIG}.edm4hep.root", warmup="warmup/{DETECTOR_CONFIG}.edm4hep.root",
...@@ -38,7 +38,7 @@ npsim \ ...@@ -38,7 +38,7 @@ npsim \
""" """
rule ecal_lyso_reco: rule zdc_lyso_reco:
input: input:
"sim_output/zdc_lyso/{DETECTOR_CONFIG}_{PARTICLE}_{BEAM_ENERGY}GeV_theta_{THETA_MIN}deg_thru_{THETA_MAX}deg.edm4hep.root", "sim_output/zdc_lyso/{DETECTOR_CONFIG}_{PARTICLE}_{BEAM_ENERGY}GeV_theta_{THETA_MIN}deg_thru_{THETA_MAX}deg.edm4hep.root",
output: output:
...@@ -52,7 +52,7 @@ mv podio_output.root {output} ...@@ -52,7 +52,7 @@ mv podio_output.root {output}
""" """
rule zdc_analysis: rule zdc_lyso_analysis:
input: input:
expand("sim_output/zdc_lyso/{{DETECTOR_CONFIG}}_{PARTICLE}_{BEAM_ENERGY}GeV_theta_{THETA_MIN}deg_thru_{THETA_MAX}deg.eicrecon.tree.edm4eic.root", expand("sim_output/zdc_lyso/{{DETECTOR_CONFIG}}_{PARTICLE}_{BEAM_ENERGY}GeV_theta_{THETA_MIN}deg_thru_{THETA_MAX}deg.eicrecon.tree.edm4eic.root",
PARTICLE=["gamma"], PARTICLE=["gamma"],
...@@ -69,7 +69,7 @@ python {input.script} ...@@ -69,7 +69,7 @@ python {input.script}
# Examples of invocation # Examples of invocation
rule create_all_hepmc: rule zdc_lyso_hepmc:
input: input:
expand("data/{PARTICLE}_{BEAM_ENERGY}GeV_theta_{THETA_MIN}deg_thru_{THETA_MAX}deg.hepmc", expand("data/{PARTICLE}_{BEAM_ENERGY}GeV_theta_{THETA_MIN}deg_thru_{THETA_MAX}deg.hepmc",
PARTICLE=["gamma"], PARTICLE=["gamma"],
...@@ -78,7 +78,7 @@ rule create_all_hepmc: ...@@ -78,7 +78,7 @@ rule create_all_hepmc:
THETA_MAX=["0.3"]) THETA_MAX=["0.3"])
rule run_all_locally: rule zdc_lyso_local:
input: input:
"results/" + os.environ["DETECTOR_CONFIG"] + "/zdc_lyso/plots.pdf", "results/" + os.environ["DETECTOR_CONFIG"] + "/zdc_lyso/plots.pdf",
message: message:
......
...@@ -2,7 +2,7 @@ sim:zdc_lyso: ...@@ -2,7 +2,7 @@ sim:zdc_lyso:
extends: .det_benchmark extends: .det_benchmark
stage: simulate stage: simulate
script: script:
- snakemake --cores 1 run_all_locally - snakemake --cores 1 zdc_lyso_local
retry: retry:
max: 2 max: 2
when: when:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment