Skip to main content

NumPy-based Python interface to Intel (R) MKL Random Number Generation functionality

Project description

mkl_random -- a NumPy-based Python interface to Intel® oneAPI Math Kernel Library (OneMKL) Random Number Generation functionality

Conda package using conda-forge

mkl_random started as a part of Intel® Distribution for Python optimizations to NumPy.

Per NumPy's community suggestions, voiced in https://github.com/numpy/numpy/pull/8209, it is being released as a stand-alone package.

Prebuilt mkl_random can be installed into conda environment from Intel's channel using:

  conda install -c https://software.repos.intel.com/python/conda mkl_random

or from conda forge channel:

   conda install -c conda-forge mkl_random

To install mkl_random PyPI package please use following command:

   python -m pip install -i https://software.repos.intel.com/python/pypi --extra-index-url https://pypi.org/simple mkl_random

If command above installs NumPy package from the Pypi, please use following command to install Intel optimized NumPy wheel package from Intel Pypi Cloud:

   python -m pip install -i https://software.repos.intel.com/python/pypi --extra-index-url https://pypi.org/simple mkl_random numpy==<numpy_version>

Where <numpy_version> should be the latest version from https://software.repos.intel.com/python/conda/


mkl_random is not fixed-seed backward compatible drop-in replacement for numpy.random, meaning that it implements sampling from the same distributions as numpy.random.

For distributions directly supported in Intel® OneMKL, method keyword is supported:

   mkl_random.standard_normal(size=(10**5, 10**3), method='BoxMuller')

Additionally, mkl_random exposes different basic random number generation algorithms available in MKL. For example to use SFMT19937 use

   mkl_random.RandomState(77777, brng='SFMT19937')

For generator families, such that MT2203 and Wichmann-Hill, a particular member of the family can be chosen by specifying brng=('WH', 3), etc.

The list of supported by mkl_random.RandomState constructor brng keywords is as follows:

  • 'MT19937'
  • 'SFMT19937'
  • 'WH' or ('WH', id)
  • 'MT2203' or ('MT2203', id)
  • 'MCG31'
  • 'R250'
  • 'MRG32K3A'
  • 'MCG59'
  • 'PHILOX4X32X10'
  • 'NONDETERM'
  • 'ARS5'

To build mkl_random from sources on Linux:

  • install a recent version of MKL, if necessary;
  • execute source /path_to_oneapi/mkl/latest/env/vars.sh;
  • execute python -m pip install .

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

mkl_random-1.4.0-0-cp314-cp314-win_amd64.whl (354.9 kB view details)

Uploaded CPython 3.14Windows x86-64

mkl_random-1.4.0-0-cp314-cp314-manylinux_2_28_x86_64.whl (450.4 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.28+ x86-64

mkl_random-1.4.0-0-cp313-cp313-win_amd64.whl (356.0 kB view details)

Uploaded CPython 3.13Windows x86-64

mkl_random-1.4.0-0-cp313-cp313-manylinux_2_28_x86_64.whl (448.0 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.28+ x86-64

mkl_random-1.4.0-0-cp312-cp312-win_amd64.whl (354.6 kB view details)

Uploaded CPython 3.12Windows x86-64

mkl_random-1.4.0-0-cp312-cp312-manylinux_2_28_x86_64.whl (448.6 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.28+ x86-64

mkl_random-1.4.0-0-cp311-cp311-win_amd64.whl (374.4 kB view details)

Uploaded CPython 3.11Windows x86-64

mkl_random-1.4.0-0-cp311-cp311-manylinux_2_28_x86_64.whl (454.9 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.28+ x86-64

mkl_random-1.4.0-0-cp310-cp310-win_amd64.whl (374.0 kB view details)

Uploaded CPython 3.10Windows x86-64

mkl_random-1.4.0-0-cp310-cp310-manylinux_2_28_x86_64.whl (456.8 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.28+ x86-64

File details

Details for the file mkl_random-1.4.0-0-cp314-cp314-win_amd64.whl.

File metadata

File hashes

Hashes for mkl_random-1.4.0-0-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 ad0c0f05e5a3eaf9d5bef961acb1fd2e93cd3eee89677034fbcbedc849222387
MD5 5e798edd9922a19cf8bf007784ab7f7e
BLAKE2b-256 5d9aab287a4d93ffe44cf484dbc91183d367e8a76648fe686bbd693a6e1042ff

See more details on using hashes here.

File details

Details for the file mkl_random-1.4.0-0-cp314-cp314-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for mkl_random-1.4.0-0-cp314-cp314-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 b8721cc49ee435b22066050dd6d2713b03a8b2d45c6400a85d953174928adfc3
MD5 93cc4e19664a8cd1d2ef580672aebad9
BLAKE2b-256 d04aff6fc4c05c5197316f01a2eaf0d2cb89a9e102af46d6856ea23013964ba6

See more details on using hashes here.

File details

Details for the file mkl_random-1.4.0-0-cp313-cp313-win_amd64.whl.

File metadata

File hashes

Hashes for mkl_random-1.4.0-0-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 e36c8be54ea45dbae92d7a17b03baae131d0e0c52f8120affd105827612e5672
MD5 1dd40af2975adb09ddddfac8f8f8501f
BLAKE2b-256 2b4636118a2fb1ffae6d25191089f0b7521e214fea23f71eb61c60482f3a90ac

See more details on using hashes here.

File details

Details for the file mkl_random-1.4.0-0-cp313-cp313-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for mkl_random-1.4.0-0-cp313-cp313-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 eeec54c5eb0b3b15bc2c7ed6ccabf0ac9c3eb6ae34595b20d5b33f51260e8106
MD5 1f70356b95ac4b5442ebd1e6f246d040
BLAKE2b-256 8fdb24699401666c52494ec181764c6cf531c97aa66205f1691b9041eb227bec

See more details on using hashes here.

File details

Details for the file mkl_random-1.4.0-0-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for mkl_random-1.4.0-0-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 2055511706b2395567bab1f3a244403d226f7d9310624cac09e9526531e46ce3
MD5 35181badff6013cda2ce80dbb7299646
BLAKE2b-256 77b0951cd7147c85981461e27fcbdbc3a4e02ebb34408a915f5207623d7963be

See more details on using hashes here.

File details

Details for the file mkl_random-1.4.0-0-cp312-cp312-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for mkl_random-1.4.0-0-cp312-cp312-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 cb57bf447cc3d3946b309fa1c1a028d013aab45b39a0829bfe11b53be8de93d0
MD5 201cdf00f488525931512854618ecc67
BLAKE2b-256 dfc9e7b293e76f2d1c85f6701168b875812331fd5efc0c5f779abc4b952f85a4

See more details on using hashes here.

File details

Details for the file mkl_random-1.4.0-0-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for mkl_random-1.4.0-0-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 4115e3d368a091a759dd0d632b8813e14f56c31f1f5ba90fcd4e97899a4f27b2
MD5 e196892df3c1317b6bf5aa46265bbae0
BLAKE2b-256 1b91ae6d094a4e5a47604464eb04d1f4f2b2018ad3654861e905c721ba69b3bf

See more details on using hashes here.

File details

Details for the file mkl_random-1.4.0-0-cp311-cp311-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for mkl_random-1.4.0-0-cp311-cp311-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 cb83c4ec72f811ff6901888b5ab3a457e2b7bb7d7a6e2e39f02fb22bdb98abd1
MD5 cbe9b70d6acf9a2dc5b1b3436a3164bd
BLAKE2b-256 03da69cbcce652003aca80b90e023e3b38ba8f9503ef5d570761ecb8675509fc

See more details on using hashes here.

File details

Details for the file mkl_random-1.4.0-0-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for mkl_random-1.4.0-0-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 5ad744b2c3425a3f4fde3bb504ccead2a7b8d830e367b3cd03e869877a2f2a32
MD5 362eeb853f585cafea0f5bdaf6f2c2ae
BLAKE2b-256 e50e834839e653e56c59bd528e644dfcc0429022c886b1f733e96bbddf2d35b4

See more details on using hashes here.

File details

Details for the file mkl_random-1.4.0-0-cp310-cp310-manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for mkl_random-1.4.0-0-cp310-cp310-manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 06a8723f18501ae2b2e3f6d246ed8a51de2cf16cc49049dc78d21d22a12f9c85
MD5 3e01fae06f93a7ff6ddfd319b8f9d5ee
BLAKE2b-256 cbfead90df4714c256af88f7167214618c164cc6725ed3646c54b8337f7eb985

See more details on using hashes here.

Supported by

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