REDROOM
PHP 8.2.30
Path:
Logout
Edit File
Size: 1.12 KB
Close
/proc/thread-self/root/opt/cloudlinux/venv/lib/python3.11/site-packages/numpy/_pyinstaller/pyinstaller-smoke.py
Text
Base64
"""A crude *bit of everything* smoke test to verify PyInstaller compatibility. PyInstaller typically goes wrong by forgetting to package modules, extension modules or shared libraries. This script should aim to touch as many of those as possible in an attempt to trip a ModuleNotFoundError or a DLL load failure due to an uncollected resource. Missing resources are unlikely to lead to arithmetic errors so there's generally no need to verify any calculation's output - merely that it made it to the end OK. This script should not explicitly import any of numpy's submodules as that gives PyInstaller undue hints that those submodules exist and should be collected (accessing implicitly loaded submodules is OK). """ import numpy as np a = np.arange(1., 10.).reshape((3, 3)) % 5 np.linalg.det(a) a @ a a @ a.T np.linalg.inv(a) np.sin(np.exp(a)) np.linalg.svd(a) np.linalg.eigh(a) np.unique(np.random.randint(0, 10, 100)) np.sort(np.random.uniform(0, 10, 100)) np.fft.fft(np.exp(2j * np.pi * np.arange(8) / 8)) np.ma.masked_array(np.arange(10), np.random.rand(10) < .5).sum() np.polynomial.Legendre([7, 8, 9]).roots() print("I made it!")
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 1 × Files: 4
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
__pycache__
DIR
-
drwxr-xr-x
2026-02-06 08:01:08
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
hook-numpy.py
1.38 KB
lrw-r--r--
2026-01-20 13:01:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
pyinstaller-smoke.py
1.12 KB
lrw-r--r--
2026-01-20 13:01:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
test_pyinstaller.py
1.11 KB
lrw-r--r--
2026-01-20 13:01:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
__init__.py
0 B
lrw-r--r--
2026-01-20 13:01:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).