Please visit Jefferson Lab Event Policies and Guidance before planning your next event:
May 8 – 12, 2023
Norfolk Waterside Marriott
US/Eastern timezone

A new portable random number generator wrapper library

Not scheduled
Hampton Roads Ballroom and Foyer Area (Norfolk Waterside Marriott)

Hampton Roads Ballroom and Foyer Area

Norfolk Waterside Marriott

235 East Main Street Norfolk, VA 23510
Poster Poster Poster Session


Wang, Tianle (Brookhaven National Lab)


Random number generator is an important component of many scientific projects. Many of those projects are written using programming models (like OpenMP and SYCL) to target different architectures. However, some of the programming models do not provide a random number generator. In this talk we are going to introduce our random number generator wrapper. It is a header-only library that supports three distributions of random numbers: uniform, normal, and poisson. On GPU backend, it wraps the curand and rocrand library, and supports many different random number engines. It also wraps random123, a counter-based random number generator, on both CPU and GPU. With this library, we can generate random numbers with a few lines of code, and target both GPU and multi-thread CPU with the same code. We investigate the reproducibility and performance of this wrapper on different architectures with different engines. We will also show the applications of this RNG header library in the Wire-Cell Toolkit library for its LArTPC detector simulation module.

Consider for long presentation No

Primary author

Wang, Tianle (Brookhaven National Lab)


Mohammad Atif, FNU (Brookhaven National Laboratory) Dong, Zhihua (Brookhaven National Laboratory) Lin, Meifeng (Brookhaven National Laboratory)

Presentation materials

There are no materials yet.

Peer reviewing