Feature #19374
RootOutput filename variable for Run/Subrun start timestamp
Description
In artdaq, we commonly use filenames of the form artdaqdemo_r%06r_sr%02s_%to_%#_dl1.root. However, in recent art versions, this causes automatically-opened files to keep index 1 while incrementing the timestamp field instead:
artdaqdemo_r000007_sr01_20180314T143646_1_dl1.root
artdaqdemo_r000007_sr01_20180314T143655_1_dl1.root
artdaqdemo_r000007_sr01_20180314T143705_1_dl1.root
artdaqdemo_r000007_sr01_20180314T143715_1_dl1.root
artdaqdemo_r000007_sr01_20180314T143725_1_dl1.root
We would like a timestamp variable which tracks the start of the run time, so that these would become something like:
artdaqdemo_r000007_sr01_20180314T143646_1_dl1.root
artdaqdemo_r000007_sr01_20180314T143646_2_dl1.root
artdaqdemo_r000007_sr01_20180314T143646_3_dl1.root
artdaqdemo_r000007_sr01_20180314T143646_4_dl1.root
artdaqdemo_r000007_sr01_20180314T143646_5_dl1.root
History
#1 Updated by Kyle Knoepfel almost 3 years ago
- Status changed from New to Feedback
There are a couple different ways we could do this:
- Use the timestamp in the
(Sub)RunPrincipal
, or - Capture the time whenever the output module's
begin(Sub)Run
functions are called.
We argue 1 is probably the best-defined option. Did you have any other possibilities in mind?
#2 Updated by Eric Flumerfelt almost 3 years ago
Kyle Knoepfel wrote:
There are a couple different ways we could do this:
- Use the timestamp in the
(Sub)RunPrincipal
, or- Capture the time whenever the output module's
begin(Sub)Run
functions are called.We argue 1 is probably the best-defined option. Did you have any other possibilities in mind?
I would tend to agree with your analysis. Ideally, the Principal, the file name, and the SAM metadata would all always be in agreement...
#3 Updated by Kyle Knoepfel over 2 years ago
- Target version set to Vega
#4 Updated by Kyle Knoepfel over 2 years ago
- Status changed from Feedback to Accepted
#5 Updated by Kyle Knoepfel over 2 years ago
- Estimated time set to 16.00 h
#6 Updated by Kyle Knoepfel over 2 years ago
- Category set to Infrastructure
- Status changed from Accepted to Resolved
- Assignee set to Kyle Knoepfel
- % Done changed from 0 to 100
- SSI Package art added
The following file-renaming patterns have added:
Specifier | Meaning |
%ts |
Start time of SubRun with lowest ID |
%tS |
Start time of SubRun with highest ID |
%tr |
Start time of Run with lowest ID |
%tR |
Start time of Run with highest ID |
The time recorded corresponds to the time at which the output module begins processing the beginning of the (sub)run. |
#7 Updated by Kyle Knoepfel over 2 years ago
- Target version changed from Vega to 3.01.00
#8 Updated by Kyle Knoepfel over 2 years ago
- Target version changed from 3.01.00 to 3.02.00
#9 Updated by Kyle Knoepfel almost 2 years ago
- Status changed from Resolved to Closed