The%20hep_random%20Library - PowerPoint PPT Presentation

About This Presentation
Title:

The%20hep_random%20Library

Description:

Engines (random number 'generators') and distributions ... A fully compliant implementation of the proposed standard random library ... – PowerPoint PPT presentation

Number of Views:11
Avg rating:3.0/5.0
Slides: 11
Provided by: markfi2
Learn more at: http://cd-docdb.fnal.gov
Category:

less

Transcript and Presenter's Notes

Title: The%20hep_random%20Library


1
The hep_random Library
  • A component of the coming C standard and of LHC
    MathCore

2
The standard random library
  • Proposed for inclusion in C standard
  • Has made it into TR1
  • Engines (random number generators) and
    distributions
  • Early package in Boost written by Jens Maurer
  • Significant conceptual revamping with heavy input
    from FNAL
  • Based on CLHEP Random experience

3
What is hep_random
  • A fully compliant implementation of the proposed
    standard random library
  • With those tweaks we are relatively sure will be
    accepted by the standards committee
  • Suitable as a reference implementation
  • The standard does not like to incorporate
    completely groundbreaking art
  • Users of hep_random will find transition to
    stdrandom trivial
  • Namespace will change

4
What are the advantages in having this in the
standard library
  • Avoid any temptation for each physics group to
    roll your own
  • Engines can have subtle traps that lead to
    incorrect physics results!
  • Weight of the compiler vendors and world of
    developers behind improvements
  • We are good
  • They are often better
  • No issue of portability
  • (except for non-compliant compilers)
  • Let compiler vendors do the maintenance

5
Nature of the random library
  • Concepts mostly the same as for CLHEP
  • Engines
  • Distributions
  • Some features that are clearly remnants of
    Fortran-style programming are gone
  • Designed to easily be extended
  • New distributions new engines
  • Heavily templated for maximal user control

6
In what ways does hep_random differ from
CLHEP/Random?
  • They are much more similar than different!
  • Better model of expressing sharing/not sharing of
    engines
  • Engine used is always explicit in distribution
    invocation
  • Slightly different set of engines and
    distributions
  • We will be providing an extension that supplies
    all the missing ones, for the HEP community
  • A significant new distribution that allows for
    variates from a general user-supplied pdf function

7
Where are we now?
  • We have the proposed final wording of the library
    specification in a proposal to J16
  • Some final tweaks will appear, but mostly
  • We were able to say with honesty that the issues
    one discovers by implementing the standard have
    been explored
  • We have our reference implementation just about
    completed
  • Some alternate algorithms for some distributions
    have to be tested and vetted or excised
  • We are in serious Users Guide writing mode

8
Forward From Here
  • Two possible paths
  • Submit it to Boost
  • Create a Boost-independent version

9
The Boost Path
  • Submit hep_random for inclusion in Boost
  • Our code already uses Boost
  • All the experiments we work with already use
    Boost
  • This is the best way of gaining widespread
    visibility
  • Which also means people helping to improve the
    library
  • Will need to modify code and prepare build files
    for Boost build
  • This is the path requiring the least work

10
The Non-Boost Path
  • Modify the code, removing Boost dependencies
  • Package it suitable for any/all of
  • MathCore (thus LHC expts, and ROOT)
  • Geant4
  • CLHEP (as an underlying implementation)
  • Requires more work than submission to Boost
    requires
  • Magnitude of the task depends upon how well these
    groups can agree on things, and how much of their
    own styles each group insists upon
Write a Comment
User Comments (0)
About PowerShow.com