Skip to content

mrzimu/uproot-custom-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Example of uproot-custom usage

This project demonstrates how to use the uproot-custom package to customize branch data reading. You can use this project as a template to create your own downstream projects that leverage uproot-custom for reading custom ROOT data structures.

Introduction

It implements 2 factory-reader pairs to read TOverrideStreamer and TObjWithObjArray objects from demo ROOT files. The class definitions and the program generating demo file is located at ./gen-demo-data.

Project structure

A typical downstream project using uproot-custom will have the following structure:

my_project/
    ├── pyproject.toml
    ├── my_module/
    │   └── Python source files...
    └── cpp/
        └── C++ source files...
  • pyproject.toml file is required to specify the project metadata and build system requirements.
  • my_module directory contains the Python source files, which is the entry point for users to do import my_module.
  • cpp directory contains the C++ source files that implement custom data reading logic.

Tip

The name of this example project is my-reader, and the Python module name is my_reader. See Python Packaging User Guide to learn more about pyproject.toml.

Installation

To install this package, run:

cd /path/to/this/project
pip install .

You can also install it in editable mode for development:

cd /path/to/this/project
pip install -e .

About

Example project that illustrates how to use uproot-custom.

Resources

Stars

Watchers

Forks

Packages

No packages published