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

insert_muon: use spaces

parent 8bb6a921
No related branches found
No related tags found
No related merge requests found
rule insert_muon_generate: rule insert_muon_generate:
input: input:
script="benchmarks/insert_muon/analysis/gen_particles.cxx", script="benchmarks/insert_muon/analysis/gen_particles.cxx",
params: params:
NEVENTS_GEN=5000, NEVENTS_GEN=5000,
th_max=7.0, th_max=7.0,
th_min=1.7 th_min=1.7
output: output:
GEN_FILE="sim_output/insert_muon/mu-_{P}GeV.hepmc" GEN_FILE="sim_output/insert_muon/mu-_{P}GeV.hepmc"
shell: shell:
""" """
root -l -b -q '{input.script}({params.NEVENTS_GEN},"{output.GEN_FILE}", "mu-", {params.th_min}, {params.th_max}, 0., 360., {wildcards.P})' root -l -b -q '{input.script}({params.NEVENTS_GEN},"{output.GEN_FILE}", "mu-", {params.th_min}, {params.th_max}, 0., 360., {wildcards.P})'
""" """
rule insert_muon_simulate: rule insert_muon_simulate:
input: input:
GEN_FILE="sim_output/insert_muon/mu-_{P}GeV.hepmc", GEN_FILE="sim_output/insert_muon/mu-_{P}GeV.hepmc",
warmup="warmup/{DETECTOR_CONFIG}.edm4hep.root", warmup="warmup/{DETECTOR_CONFIG}.edm4hep.root",
params: params:
PHYSICS_LIST="FTFP_BERT" PHYSICS_LIST="FTFP_BERT"
output: output:
SIM_FILE="sim_output/insert_muon/{DETECTOR_CONFIG}_sim_mu-_{P}GeV_{INDEX}.edm4hep.root" SIM_FILE="sim_output/insert_muon/{DETECTOR_CONFIG}_sim_mu-_{P}GeV_{INDEX}.edm4hep.root"
shell: shell:
""" """
NEVENTS_SIM=1000 NEVENTS_SIM=1000
# Running simulation # Running simulation
npsim \ npsim \
...@@ -34,28 +34,28 @@ npsim \ ...@@ -34,28 +34,28 @@ npsim \
""" """
rule insert_muon_recon: rule insert_muon_recon:
input: input:
SIM_FILE="sim_output/insert_muon/{DETECTOR_CONFIG}_sim_mu-_{P}GeV_{INDEX}.edm4hep.root" SIM_FILE="sim_output/insert_muon/{DETECTOR_CONFIG}_sim_mu-_{P}GeV_{INDEX}.edm4hep.root"
output: output:
REC_FILE="sim_output/insert_muon/{DETECTOR_CONFIG}_rec_mu-_{P}GeV_{INDEX}.edm4hep.root" REC_FILE="sim_output/insert_muon/{DETECTOR_CONFIG}_rec_mu-_{P}GeV_{INDEX}.edm4hep.root"
shell: shell:
""" """
NEVENTS_REC=1000 NEVENTS_REC=1000
eicrecon {input.SIM_FILE} -Ppodio:output_file={output.REC_FILE} -Pdd4hep:xml_files=$DETECTOR_PATH/{wildcards.DETECTOR_CONFIG}.xml -Ppodio:output_collections=MCParticles,HcalEndcapPInsertRecHits,HcalEndcapPInsertClusters,HcalEndcapPInsertSubcellHits,EcalEndcapPInsertRecHits,EcalEndcapPInsertClusters -Pjana:nevents=$NEVENTS_REC eicrecon {input.SIM_FILE} -Ppodio:output_file={output.REC_FILE} -Pdd4hep:xml_files=$DETECTOR_PATH/{wildcards.DETECTOR_CONFIG}.xml -Ppodio:output_collections=MCParticles,HcalEndcapPInsertRecHits,HcalEndcapPInsertClusters,HcalEndcapPInsertSubcellHits,EcalEndcapPInsertRecHits,EcalEndcapPInsertClusters -Pjana:nevents=$NEVENTS_REC
""" """
rule insert_muon_analysis: rule insert_muon_analysis:
input: input:
expand("sim_output/insert_muon/{DETECTOR_CONFIG}_sim_mu-_{P}GeV_{INDEX}.edm4hep.root", expand("sim_output/insert_muon/{DETECTOR_CONFIG}_sim_mu-_{P}GeV_{INDEX}.edm4hep.root",
P=[50], P=[50],
DETECTOR_CONFIG=["{DETECTOR_CONFIG}"], DETECTOR_CONFIG=["{DETECTOR_CONFIG}"],
INDEX=range(5), INDEX=range(5),
), ),
script="benchmarks/insert_muon/analysis/muon_plots.py", script="benchmarks/insert_muon/analysis/muon_plots.py",
output: output:
results_dir=directory("results/{DETECTOR_CONFIG}/insert_muon"), results_dir=directory("results/{DETECTOR_CONFIG}/insert_muon"),
shell: shell:
""" """
mkdir -p {output.results_dir} mkdir -p {output.results_dir}
python {input.script} {output.results_dir} python {input.script} {output.results_dir}
""" """
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