Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f1c1d48
commit 73e2245
Showing
1 changed file
with
60 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
New function `np.show_runtime` | ||
------------------------------ | ||
|
||
A new function ``np.show_runtime`` has been added to display the runtime | ||
information of the machine in addition to ``np.show_config`` which displays | ||
the build-related information. | ||
This function returns a list of dictionaries as follows:: | ||
|
||
>>> np.show_runtime() | ||
[{'simd_extensions': {'baseline': ['SSE', 'SSE2', 'SSE3'], | ||
'found': ['SSSE3', | ||
'SSE41', | ||
'POPCNT', | ||
'SSE42', | ||
'AVX', | ||
'F16C', | ||
'FMA3', | ||
'AVX2'], | ||
'not_found': ['AVX512F', | ||
'AVX512CD', | ||
'AVX512_KNL', | ||
'AVX512_KNM', | ||
'AVX512_SKX', | ||
'AVX512_CLX', | ||
'AVX512_CNL', | ||
'AVX512_ICL']}}, | ||
{'architecture': 'Zen', | ||
'filepath': '/usr/lib/x86_64-linux-gnu/openblas-pthread/libopenblasp-r0.3.20.so', | ||
'internal_api': 'openblas', | ||
'num_threads': 12, | ||
'prefix': 'libopenblas', | ||
'threading_layer': 'pthreads', | ||
'user_api': 'blas', | ||
'version': '0.3.20'}] | ||
|
||
Note that this function requires `threadpoolctl`_ to function properly. | ||
It would result in the following warning if not installed:: | ||
|
||
>>> np.show_runtime() | ||
WARNING: `threadpoolctl` not found in system! Install it by `pip install threadpoolctl`. Once installed, try `np.show_runtime` again for more detailed build information | ||
[{'simd_extensions': {'baseline': ['SSE', 'SSE2', 'SSE3'], | ||
'found': ['SSSE3', | ||
'SSE41', | ||
'POPCNT', | ||
'SSE42', | ||
'AVX', | ||
'F16C', | ||
'FMA3', | ||
'AVX2'], | ||
'not_found': ['AVX512F', | ||
'AVX512CD', | ||
'AVX512_KNL', | ||
'AVX512_KNM', | ||
'AVX512_SKX', | ||
'AVX512_CLX', | ||
'AVX512_CNL', | ||
'AVX512_ICL']}}] | ||
|
||
|
||
.. _threadpoolctl: https://pypi.org/project/threadpoolctl/ |