Skip to content
Snippets Groups Projects

Implement the NTuple::Writer and NTuple::GenericWriter algorithms for thread-safe NTuple writing

Merged Silia Taider requested to merge staider/Gaudi:NTupleWriter into master

Overview

The NTuple writer is a Gaudi algorithm for writing data of any type from N locations in the event store to a TTree. It allows users to write data from various locations within the event store into a ROOT TTree structure dynamically creating branches leveraging ROOT's dynamic typing and I/O capabilities to support a range of data types based on either runtime or compile-time configurations.

Key Components

  • NTuple::GenericWriter: This class represents an algorithm that dynamically creates branches based on runtime information. It is intended for scenarios where the exact configuration of the TTree branches is determined when configuring the Gaudi application itself. It allows users to specify N input data types and their corresponding locations in the event store to construct matching TTree branches.
  • NTuple::Writer: This class represents a compile-time configured algorithm, inheriting from Gaudi::Functional::Consumer. It requires a transformation function to convert input data into a specific output format allowing it to deal with an arbitrary number of inputs and to also write to the file an arbitrary number of outputs. It relies on templates to define the structure and data transformations at compile time.

Workflow

  • Initialization: Sets up the ROOT file and creates a TTree, initializing branches for each specified input.
  • Execution: Fills the TTree with data from the event store.
  • Finalization: Writes the filled TTree to the ROOT file and closes the file.

Key Features

  • Supports dynamic branch creation based on runtime information.
  • Offers compile-time optimized branch creation for predefined structures.
  • Introduces a data transformation feature for more flexibility and control over what to write.
  • Customizable configurations for file names and branch names.

Coverage

The merge request includes both pytest and Boost frameworks for unit and integration tests.

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Silia Taider added 1 commit

    added 1 commit

    Compare with previous version

  • Silia Taider resolved all threads

    resolved all threads

  • Silia Taider added 1 commit

    added 1 commit

    Compare with previous version

  • Marco Clemencic resolved all threads

    resolved all threads

  • Sebastien Ponce approved this merge request

    approved this merge request

  • Silia Taider added 4 commits

    added 4 commits

    • 507a0c99 - Implement the NTuple::GenericWriter algorithm
    • 301c7b5c - Add tests for the NTuple::GenericWriter algorithm
    • dd1418dc - Implement the NTuple::Writer algorithm
    • a86b0848 - Add tests for the NTuple::Writer algorithm

    Compare with previous version

  • Silia Taider reset approvals from @sponce by pushing to the branch

    reset approvals from @sponce by pushing to the branch

  • Silia Taider added 2 commits

    added 2 commits

    • 1804b20c - Move NTuple::GenericWriter tests to GaudiTestSuite
    • c5ac4382 - Move NTuple::Writer tests to GaudiTestSuite

    Compare with previous version

  • Silia Taider added 3 commits

    added 3 commits

    • 9c4d57be - Delete unnecessary testing algorithms
    • 56efac0f - Add NTUpleWriter testing algorithms
    • 9d1b4cd2 - Update GenericNTupleWriter tests

    Compare with previous version

  • Silia Taider added 2 commits

    added 2 commits

    • 99443e43 - Add NTUpleWriter testing algorithms
    • ea778fc8 - Update GenericNTupleWriter tests

    Compare with previous version

  • Marco Clemencic changed milestone to %v38r2

    changed milestone to %v38r2

  • Edited by Software for LHCb
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Please register or sign in to reply
    Loading