Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Basic implementation of event pooling in O2DPG workflow #1760

Merged
merged 20 commits into from
Oct 31, 2024
Merged
Changes from 2 commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
a3e0e9a
Created flag for .root Kinematics input file.
jackal1-66 Oct 7, 2024
9512661
Runner edited to allow eventpool on events generation
jackal1-66 Oct 9, 2024
c36bbfd
Fix for timeframe getter in kine-input
jackal1-66 Oct 9, 2024
d1a177c
Moved kine-input flag in workflow creation step
jackal1-66 Oct 17, 2024
4df70b6
Merge branch 'AliceO2Group:master' into eventpool1
jackal1-66 Oct 17, 2024
f77c3ac
Added rng seed flag
jackal1-66 Oct 18, 2024
27211ef
Merge branch 'eventpool1' of https://github.com/jackal1-66/O2DPG into…
jackal1-66 Oct 18, 2024
a0d7a3a
Merge branch 'AliceO2Group:master' into eventpool1
jackal1-66 Oct 18, 2024
b28d9fb
Added flag for random Phi rotation in event pool
jackal1-66 Oct 18, 2024
a6aff46
Added bypass for Alien paths
jackal1-66 Oct 21, 2024
726adf9
Merge branch 'AliceO2Group:master' into eventpool1
jackal1-66 Oct 28, 2024
fd69bfb
Removed kine-input flag and reorganised workflow for eventpool genera…
jackal1-66 Oct 28, 2024
6ef2c87
Merge branch 'AliceO2Group:master' into eventpool1
jackal1-66 Oct 29, 2024
3f0d313
Merge branch 'AliceO2Group:master' into eventpool
jackal1-66 Oct 29, 2024
94c6e9c
Created example script for eventpool creation and usage
jackal1-66 Oct 29, 2024
c11fb13
Merge branch 'eventpool1' of https://github.com/jackal1-66/O2DPG into…
jackal1-66 Oct 29, 2024
1d1e2f8
Include alien path option
jackal1-66 Oct 29, 2024
eaca573
Merge pull request #1 from jackal1-66/eventpool1
jackal1-66 Oct 29, 2024
3373bec
Removed remaining piece of unused test evtpool implementation
jackal1-66 Oct 29, 2024
fd3589c
Changed location of root_merger utility script
jackal1-66 Oct 30, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions MC/bin/o2_dpg_workflow_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@
parser.add_argument('--cpu-limit', help='Set CPU limit (core count)', default=8, type=float)
parser.add_argument('--cgroup', help='Execute pipeline under a given cgroup (e.g., 8coregrid) emulating resource constraints. This m\
ust exist and the tasks file must be writable to with the current user.')
parser.add_argument('--kine-input', help='Use pre-existent event generation.', default="", type=str)
jackal1-66 marked this conversation as resolved.
Show resolved Hide resolved

# run control, webhooks
parser.add_argument('--stdout-on-failure', action='store_true', help='Print log files of failing tasks to stdout,')
Expand Down Expand Up @@ -880,6 +881,19 @@ def __init__(self, workflowfile, args, jmax=100):
exit (0)
print ('Workflow is empty. Nothing to do')
exit (0)

# Gets the .root kinematic file path and passes it to the event simulation step
# the string appended to the filename is to take account of the current timeframe
# and to skip events accordingly
if args.kine_input:
kine_fn = args.kine_input
if os.path.isfile(kine_fn):
for stage in self.workflowspec['stages']:
if "sgngen" in stage['name']:
stage['cmd'] = stage['cmd'][:-1] + " --kine-input " + kine_fn + ':' + str(stage['timeframe']) + stage['cmd'][-1]
else:
print("Input kinematic file does not exist.")
exit(2)

# construct the DAG, compute task weights
workflow = build_dag_properties(self.workflowspec)
Expand Down