package randii

All checked builds pass
  1. Overview
  2. Docs
A pure OCaml port of the Random123 counter based random number generator from DEShaw Research

Install

dune-project
 Dependency

Authors

Maintainers

Sources

1.0.0.tar.gz
md5=1f8f3a98495497cece0131f11c0297e7
sha512=4377b604e5debe94ba98e980ffdbb92e936306460b7db65eee2d1d5493f0abc12f54982527d49351b8461e3208ac158aed79a932575872956e849a432d058e85

Description

Currently implements the Threefry 2&4 digit 32&64 bit random number generators

Added to opam-repository:

README

randii

OCaml port of Random123 - a counter based random number generator.

This library is a pure OCaml port of the Random123 Threefry algorithms as described in Parallel Random Numbers: As Easy as 1, 2, 3, Salmon, Moraes, Dror & Shaw, SC11, Seattle, Washington, USA, 2011, ACM and originally implemented here.

In terms of number representations this library depends only on ocaml-integers with an additional dependency on zarith if one wants to run the test suite.

Testing

There is a simple CLI tool for basic testing, please see

$ randii --help

for more information.

The test suite uses Known Answer Tests from the test suite of the original implementation - specifically the Threefry data in kat_vectors and old_kat_vectors.

There is also an executable for running the Threefry implementations through the SmallCrush battery of tests via OCaml testu01:

$ dune exec -- u01/smallcrush.exe

WARNING it takes a while to run.

TODOs

  • basic arithmetic for ctr_t type,
  • make dependence on testu01 a with-test dep

Dependencies (7)

  1. testu01 >= "1.2.3-0.2"
  2. dune >= "3.0" & > "1.5"
  3. integers >= "0.4.0"
  4. fmt >= "0.9.0"
  5. cmdliner >= "1.1.1"
  6. logs >= "0.7.0"
  7. ocaml >= "4.08"

Dev Dependencies (4)

  1. odoc with-doc
  2. bisect_ppx with-test & >= "2.6.0"
  3. zarith with-test & >= "1.12"
  4. alcotest with-test

Optional Dependencies

None

Used by

None

Conflicts

None

Build status

Results of building randii with each compiler on check.ci.ocaml.org, run of against opam-repository 8a77e58. All results for this package.

Each result links to its build log. To keep crawlers from overloading the site, build logs require a GitHub sign-in (see ocurrent/opam-health-check). On your first log, GitHub asks you to “Authorize opam-health-check”, the OCurrent app that runs these checks; it sees only your public profile, not your repositories. The sign-in lasts 30 days.

Version OCaml 4.11 OCaml 4.14 OCaml 5.2 OCaml 5.4 OCaml 5.5
1.0.0 (this version) good good good good good
  • good Package successfully built
  • partial One of the dependencies failed to build
  • bad Package failed to build
  • n/a Package is not available in this environment
  • internal Internal failure