You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: pymc/__init__.py
+33-1Lines changed: 33 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -13,7 +13,7 @@
13
13
# limitations under the License.
14
14
15
15
# pylint: disable=wildcard-import
16
-
__version__="4.0"
16
+
__version__="4.0.0"
17
17
18
18
importlogging
19
19
importmultiprocessingasmp
@@ -27,6 +27,38 @@
27
27
handler=logging.StreamHandler()
28
28
_log.addHandler(handler)
29
29
30
+
31
+
def_check_install_compatibilitites():
32
+
try:
33
+
importtheano
34
+
35
+
print(
36
+
"!"*60
37
+
+f"\nYour Python environment has Theano(-PyMC) {theano.__version__} installed, "
38
+
+f"but you are importing PyMC {__version__} which uses Aesara as its backend."
39
+
+f"\nFor PyMC {__version__} to work as expected you should uninstall Theano(-PyMC)."
40
+
+"\nSee https://github.com/pymc-devs/pymc3/wiki for installation instructions.\n"
41
+
+"!"*60
42
+
)
43
+
exceptImportError:
44
+
pass
45
+
46
+
try:
47
+
importpymc3
48
+
49
+
print(
50
+
"!"*60
51
+
+f"\nYou are importing PyMC {__version__}, but your environment also has"
52
+
+f" the legacy version PyMC3 {pymc3.__version__} installed."
53
+
+f"\nFor PyMC {__version__} to work as expected you should uninstall PyMC3."
54
+
+"\nSee https://github.com/pymc-devs/pymc3/wiki for installation instructions.\n"
55
+
+"!"*60
56
+
)
57
+
exceptImportError:
58
+
pass
59
+
60
+
61
+
_check_install_compatibilitites()
30
62
_log.info(
31
63
"You are running the v4 development version of PyMC which currently still lacks key features. You probably want to use the stable v3 instead which you can either install via conda or find on the v3 GitHub branch: https://github.com/pymc-devs/pymc/tree/v3"
0 commit comments