From 7cb9685b9c6f3f17ad92abc57a942491e851047f Mon Sep 17 00:00:00 2001 From: Dmitry Kalinkin Date: Tue, 26 Dec 2023 17:22:59 -0500 Subject: [PATCH] Use workflow.source_path --- benchmarks/barrel_ecal/Snakefile | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/benchmarks/barrel_ecal/Snakefile b/benchmarks/barrel_ecal/Snakefile index c148c443..4888ebfe 100644 --- a/benchmarks/barrel_ecal/Snakefile +++ b/benchmarks/barrel_ecal/Snakefile @@ -3,7 +3,7 @@ DETECTOR_PATH = os.environ["DETECTOR_PATH"] rule emcal_barrel_particles_gen: input: - script="benchmarks/barrel_ecal/scripts/emcal_barrel_particles_gen.cxx", + script=workflow.source_path("benchmarks/barrel_ecal/scripts/emcal_barrel_particles_gen.cxx"), params: JUGGLER_N_EVENTS = 100, output: @@ -67,7 +67,7 @@ ln {input} {output} rule emcal_barrel_particles_analysis: input: - script="benchmarks/barrel_ecal/scripts/emcal_barrel_particles_analysis.cxx", + script=workflow.source_path("benchmarks/barrel_ecal/scripts/emcal_barrel_particles_analysis.cxx"), sim="{DETECTOR_CONFIG}/sim_output/sim_emcal_barrel_{PARTICLE}.edm4hep.root", wildcard_constraints: PARTICLE="(electron|photon|piplus|piminus)", # avoid clash with "pions" @@ -94,7 +94,7 @@ root -l -b -q '../{input.script}+("{wildcards.PARTICLE}", true)' rule emcal_barrel_pions_analysis: input: - script="benchmarks/barrel_ecal/scripts/emcal_barrel_pions_analysis.cxx", + script=workflow.source_path("benchmarks/barrel_ecal/scripts/emcal_barrel_pions_analysis.cxx"), sim="{DETECTOR_CONFIG}/sim_output/sim_emcal_barrel_piplus_energies5.0_5.0.edm4hep.root", output: expand( @@ -111,7 +111,7 @@ root -l -b -q '../{input.script}+("../{input.sim}")' rule emcal_barrel_pi0_analysis: input: - script="benchmarks/barrel_ecal/scripts/emcal_barrel_pi0_analysis.cxx", + script=workflow.source_path("benchmarks/barrel_ecal/scripts/emcal_barrel_pi0_analysis.cxx"), sim="{DETECTOR_CONFIG}/sim_output/sim_emcal_barrel_pi0_energies5.0_5.0.edm4hep.root", fsam="{DETECTOR_CONFIG}/results/emcal_barrel_electron_calibration.json", output: @@ -143,7 +143,7 @@ rule emcal_energy_scan: rule emcal_barrel_particles_energy_scan_analysis: input: - script="benchmarks/barrel_ecal/scripts/emcal_barrel_energy_scan_analysis.cxx", + script=workflow.source_path("benchmarks/barrel_ecal/scripts/emcal_barrel_energy_scan_analysis.cxx"), scan_points="{DETECTOR_CONFIG}/sim_output/emcal_barrel_energy_scan_points_{PARTICLE}.txt", output: "{DETECTOR_CONFIG}/results/energy_scan/emcal_barrel_{PARTICLE}_fsam_scan.png", @@ -162,7 +162,7 @@ root -l -b -q '../{input.script}+("{wildcards.PARTICLE}")' rule emcal_barrel_pion_rejection_analysis: input: - script="benchmarks/barrel_ecal/scripts/emcal_barrel_pion_rejection_analysis.cxx", + script=workflow.source_path("benchmarks/barrel_ecal/scripts/emcal_barrel_pion_rejection_analysis.cxx"), electron="{DETECTOR_CONFIG}/sim_output/sim_emcal_barrel_electron_energies1.0_18.0.edm4hep.root", piminus="{DETECTOR_CONFIG}/sim_output/sim_emcal_barrel_piminus_energies1.0_18.0.edm4hep.root", output: