Closed tomeichlersmith closed 1 year ago
@cbravo135 is there a way to have different input files for the different steps in a job.
I am thinking that an alignment iteration could be one job where step (1) has the input detector, step (2) has the full list of input slcio
files dispatched over slurm to the cluster, step (3) uses the bin files generated by step (2) when all those files are done, and step (4) uses the res
file from step(3). It looks like that capability may already exists, but I'm not familiar enough with hps-mc to know for sure.
zoomed with @cbravo135
Generally idea is two hps-mc jobs and one manual task:
1a - don't want to have hps-mc compiling
Merge 1b + 2 ==> part of running tracking requires identifying the detector and making sure it is compiled/built. Run a separate job per input file so that it can be submitted to batch
Merge 3 + 4 This is where the main update is required - need to write an hps-mc component for pede
@tomeichlersmith Maybe we can get together and think about where to put the new component(s). Most tools are in tools.py
but the file is super bloated already. So it might be worth creating a new file mille_tools.py
or however you'd want to name it.
That's a good point @sarahgaiser - I will put the PEDE component in a new file.
Perhaps this brings up the larger question of factorizing the files in hpsmc
. We could put each component into its own file and then import them all into a common namespace using a thoughtful __init___.py
. This would allow them all to exist in the same module (from a user point of view) but would be easier to maintain (from a developer point of view). This kind of refactoring is something that is larger than the scope of this issue though.
Yeah this totally shouldn't be part of this issue. However, to make future cleanup easier we should start having these separate files for new things.
I'll go ahead and create an issue for the refactoring of hpsmc
-> https://github.com/JeffersonLab/hps-mc/issues/343
An "iteration" of alignment consists of four steps.
construct
a detector from a compact.xml with the defined alignment parameterstracking
and the GBL alignment driver with hps-java with this new detector to calculate track parameters and their derivativespede
to determine new alignment parameters from these updated track parameter derivativesapply
these updated parameters to a new version/iteration of the detectorStep (2) can already be done with hps-mc so I'm going to look into doing the other steps within hps-mc or at least shipped with hps-mc so that a full alignment "iteration" can be accomplished. The other steps already have python code written for them but that code has a different structure and is in a different repo. Good place to start though.