We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 30a5f3f + 170b20c commit 0a700feCopy full SHA for 0a700fe
doc/source/conf.py
@@ -28,6 +28,10 @@
28
import tomli as tomllib
29
30
# Check for external Sphinx extensions we depend on
31
+try:
32
+ import numpy as np
33
+except ImportError:
34
+ raise RuntimeError('Need to install "numpy" package for doc build')
35
try:
36
import numpydoc
37
except ImportError:
@@ -45,6 +49,11 @@
45
49
'Need nibabel on Python PATH; consider "make htmldoc" from nibabel root directory'
46
50
)
47
51
52
+from packaging.version import Version
53
+
54
+if Version(np.__version__) >= Version('1.22'):
55
+ np.set_printoptions(legacy='1.21')
56
48
57
# -- General configuration ----------------------------------------------------
58
59
# We load the nibabel release info into a dict by explicit execution
0 commit comments