Skip to main content

Inference code for fast generation of vertex quality variables

Project description

Fast Vertexing Variables at LHCb - Inference Library

Full documentation is avalibale here.

Description

This tool provides a quick approximation of the LHCb reconstruction process. Built on top of RapidSim, the run function automatically communicates with RapidSim to generate kinematic information which is then smeared before predictions of high-level vertexing variables are generated.

The software utilizes Variational Autoencoders (VAEs) to estimate these variables. These VAEs are trained on output from the LHCb simulation software.

Generated tuples can be integrated with other tools such as TriggerCalib and PIDCalib2, completing the full chain of estimation of reconstruction efficiencies and mass shapes for background studies at LHCb.

Disclaimer

This tool is not designed to replace the full simulation software. It is designed to quickly return reasonable estimates of mass shapes and efficiencies.

Environment Setup

RaidSim is required to use the full functionalty of this library. The environment variables $RAPIDSIM_ROOT and $EVTGEN_ROOT that are used by the code to access the install.

  • RAPIDSIM_ROOT: The root directory for RapidSim.
  • EVTGEN_ROOT (optional): The root directory for EVTGEN, if applicable.

Example Usage

run()

The run() function is the primary method to execute FastVertexing. It handles several key operations in the vertexing and event simulation process:

from fast_vertex_quality_inference import run

run(
    events=1000,
    decay="B+ -> { D0b -> K+ e- anti-nue } pi+",
    naming_scheme="B_plus -> { NA -> K_plus e_minus NA } e_plus",
    decay_models="PHSP -> { ISGW2 -> PHSP PHSP PHSP } PHSP",
    mass_hypotheses={"e_plus": "e+"},
    intermediate_particle={"Jpsi": ["e_minus", "e_plus"]},
)

run_from_tuple()

The run_from_tuple() function only executes the vertexing network on an existing tuple and can be used without a RapidSim installation.

from fast_vertex_quality_inference import run_from_tuple

run_from_tuple(
    file="decay_tree.root",
    mother_particle="MOTHER",
    daughter_particles=["DAUGHTER1", "DAUGHTER2", "DAUGHTER3"],
    fully_reco=False,
    nPositive_missing_particles=0,
    nNegative_missing_particles=0,
    mass_hypotheses={"DAUGHTER2": "e+"},
    intermediate_particle={"INTERMEDIATE": ["DAUGHTER2", "DAUGHTER3"]},
    branch_naming_structure={"true_momenta_component": "{particle}_TRUE_P{dim}"},
)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fast_vertex_quality_inference-1.0.14.tar.gz (41.0 MB view details)

Uploaded Source

Built Distribution

File details

Details for the file fast_vertex_quality_inference-1.0.14.tar.gz.

File metadata

File hashes

Hashes for fast_vertex_quality_inference-1.0.14.tar.gz
Algorithm Hash digest
SHA256 ef0b793f510580c933561bdef094c2aa2f42763dae3c6a939694d5aafe47b81c
MD5 079457d983d90fad876e4e9ac8dffb5b
BLAKE2b-256 84ec19880abaef25737f72c1732edd8eec28cd1d7d7936a2e228c45e56c16717

See more details on using hashes here.

File details

Details for the file fast_vertex_quality_inference-1.0.14-py3-none-any.whl.

File metadata

File hashes

Hashes for fast_vertex_quality_inference-1.0.14-py3-none-any.whl
Algorithm Hash digest
SHA256 d2893b1b014bf4264db2e264dbf319c3e151a0cc37086b0f0ecfc632aa9f831c
MD5 5052e4cefaf3a7439e4b140a107ef5fa
BLAKE2b-256 024f44da99aeb8df49d5eec0a9248922e7bc9b8509673179549f90f047fbe9cc

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page