This is a "Hello, World" application in Monte Carlo methods. It stresses random number generation along with some other math required for implementation of the Acceptance-Rejection technique.
For details please refer to Wikipedia
python -m mcpi_demo [options]
Demo can be invoked in several ways:
- Cloning Github repo and running
python mcpi.py [options]
- Cloning Github repo and running
python -m mcpi_demo [options]
- Installing conda package and invoking executable
conda install -c pycoddiy/label/dev mcpi-demo
mcpi [options]
The following options are allowed:
--variant [numpy, numba, dpnp, numba-dpex]
(defaultnumpy
): Implementation variant--batch-size
: Number of trial points in the batch--n-batches
: Number of batches
The Monte Carlo Pi demo is also supplemented with the Juoyter Notebook, where step by step we illustrate the idea of the algorithm.