Skip to content

Functionalise#883

Merged
VCLanNguyen merged 8 commits intofeature/frameshift_refactor_v10_11_01from
feature/frameshift_refactor_v10_11_01_hlay_functions
Nov 24, 2025
Merged

Functionalise#883
VCLanNguyen merged 8 commits intofeature/frameshift_refactor_v10_11_01from
feature/frameshift_refactor_v10_11_01_hlay_functions

Conversation

@henrylay97
Copy link
Member

@henrylay97 henrylay97 commented Nov 24, 2025

Description

This is an internal PR within the team working on refactoring the timing reference frames for data, release managers can ignore. We will make a final PR once the main branch is ready.

In this PR I've refactored the frame shift module a little:

  • Moved everything into the sbnd::timing namespace so we don't have to specify it for all the objects etc.
  • Added functions to split up most of the produce() function and make things a little more readable.
  • Created helper function for finding the closest timestamp in a vector to provided reference timestamp, as this was being done many times.
  • Created helper function for formatting a uint64_t timestamp into seconds and nanoseconds for print statements, as this was also being done many times.
  • I've reduced the duplication in the final logic, a lot of it was the same for beam and offbeam.
  • I've made the indentation consistent and removed unused fcl parameters.
  • I've added a fcl parameter (that defaults to false) for whether to produce the TTree.
  • I've made sure we are using pre-defined default values and enumerations provided in the relevant sbnobj files.

This goes with SBNSoftware/sbnobj#156

@VCLanNguyen VCLanNguyen merged commit ce18cbd into feature/frameshift_refactor_v10_11_01 Nov 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Comments