=5" conda activate pymc_env Now, a simple pymc code like: import pymc as pm import numpy as np RANDOM_SEED = 8927 rng = np.random.default_rng(RANDOM_SEED) with pm.Model() as model: mu = pm.Normal("mu", mu=0, sigma=1) obs = pm.Normal("obs", mu=mu, sigma=1, observed=rng.standard_normal(100)) idata = pm.sample(2000) gives me t...">

Problems with installation of pymc after xcode update on mac (original) (raw)

Hello,

After updating xcode on my macbook pro m2, pymc stopped working. I tried with a fresh install:

   conda create -c conda-forge -n pymc_env "pymc>=5"
   conda activate pymc_env

Now, a simple pymc code like:

import pymc as pm
import numpy as np

RANDOM_SEED = 8927
rng = np.random.default_rng(RANDOM_SEED)

with pm.Model() as model:
    mu = pm.Normal("mu", mu=0, sigma=1)
    obs = pm.Normal("obs", mu=mu, sigma=1, observed=rng.standard_normal(100))

    idata = pm.sample(2000)

gives me the following warning + error:

WARNING (pytensor.tensor.blas): Using NumPy C-API based implementation for BLAS functions.

ERROR (pytensor.graph.rewriting.basic): Rewrite failure due to: constant_folding ERROR (pytensor.graph.rewriting.basic): node: ExpandDims{axis=0}(1) ERROR (pytensor.graph.rewriting.basic): TRACEBACK: ERROR (pytensor.graph.rewriting.basic): Traceback (most recent call last): File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/graph/rewriting/basic.py”, line 1909, in process_node replacements = node_rewriter.transform(fgraph, node) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/graph/rewriting/basic.py”, line 1081, in transform return self.fn(fgraph, node) ^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/tensor/rewriting/basic.py”, line 1122, in constant_folding thunk = node.op.make_thunk(node, storage_map, compute_map, no_recycling=) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/link/c/op.py”, line 119, in make_thunk

clang++: error: unable to execute command: Abort trap: 6 clang++: error: linker command failed due to signal (use -v to see invocation)

Output is truncated. View as a scrollable element or open in a text editor. Adjust cell output settings…

You can find the C code in this temporary file: /var/folders/w7/h67z1rn941j1p0m51k08d9xc0000gp/T/pytensor_compilation_error_mh9wt315

ERROR (pytensor.graph.rewriting.basic): Rewrite failure due to: constant_folding ERROR (pytensor.graph.rewriting.basic): node: ExpandDims{axis=0}(1) ERROR (pytensor.graph.rewriting.basic): TRACEBACK: ERROR (pytensor.graph.rewriting.basic): Traceback (most recent call last): File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/graph/rewriting/basic.py”, line 1909, in process_node replacements = node_rewriter.transform(fgraph, node) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/graph/rewriting/basic.py”, line 1081, in transform return self.fn(fgraph, node) ^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/tensor/rewriting/basic.py”, line 1122, in constant_folding thunk = node.op.make_thunk(node, storage_map, compute_map, no_recycling=) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/link/c/op.py”, line 119, in make_thunk return self.make_c_thunk(node, storage_map, compute_map, no_recycling)

clang++: error: unable to execute command: Abort trap: 6 clang++: error: linker command failed due to signal (use -v to see invocation)

Output is truncated. View as a scrollable element or open in a text editor. Adjust cell output settings…

You can find the C code in this temporary file: /var/folders/w7/h67z1rn941j1p0m51k08d9xc0000gp/T/pytensor_compilation_error_xrwrb7xq

ERROR (pytensor.graph.rewriting.basic): Rewrite failure due to: constant_folding ERROR (pytensor.graph.rewriting.basic): node: ExpandDims{axis=0}(1) ERROR (pytensor.graph.rewriting.basic): TRACEBACK: ERROR (pytensor.graph.rewriting.basic): Traceback (most recent call last): File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/graph/rewriting/basic.py”, line 1909, in process_node replacements = node_rewriter.transform(fgraph, node) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/graph/rewriting/basic.py”, line 1081, in transform return self.fn(fgraph, node) ^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/tensor/rewriting/basic.py”, line 1122, in constant_folding thunk = node.op.make_thunk(node, storage_map, compute_map, no_recycling=) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/link/c/op.py”, line 119, in make_thunk return self.make_c_thunk(node, storage_map, compute_map, no_recycling)

clang++: error: unable to execute command: Abort trap: 6 clang++: error: linker command failed due to signal (use -v to see invocation)

Output is truncated. View as a scrollable element or open in a text editor. Adjust cell output settings…

You can find the C code in this temporary file: /var/folders/w7/h67z1rn941j1p0m51k08d9xc0000gp/T/pytensor_compilation_error_ofeuhbkn

ERROR (pytensor.graph.rewriting.basic): Rewrite failure due to: constant_folding ERROR (pytensor.graph.rewriting.basic): node: ExpandDims{axis=0}(1) ERROR (pytensor.graph.rewriting.basic): TRACEBACK: ERROR (pytensor.graph.rewriting.basic): Traceback (most recent call last): File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/graph/rewriting/basic.py”, line 1909, in process_node replacements = node_rewriter.transform(fgraph, node) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/graph/rewriting/basic.py”, line 1081, in transform return self.fn(fgraph, node) ^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/tensor/rewriting/basic.py”, line 1122, in constant_folding thunk = node.op.make_thunk(node, storage_map, compute_map, no_recycling=) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/link/c/op.py”, line 119, in make_thunk return self.make_c_thunk(node, storage_map, compute_map, no_recycling)

clang++: error: unable to execute command: Abort trap: 6 clang++: error: linker command failed due to signal (use -v to see invocation)

Output is truncated. View as a scrollable element or open in a text editor. Adjust cell output settings…

You can find the C code in this temporary file: /var/folders/w7/h67z1rn941j1p0m51k08d9xc0000gp/T/pytensor_compilation_error_f8nj0p8b

ERROR (pytensor.graph.rewriting.basic): Rewrite failure due to: constant_folding ERROR (pytensor.graph.rewriting.basic): node: ExpandDims{axis=0}(1) ERROR (pytensor.graph.rewriting.basic): TRACEBACK: ERROR (pytensor.graph.rewriting.basic): Traceback (most recent call last): File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/graph/rewriting/basic.py”, line 1909, in process_node replacements = node_rewriter.transform(fgraph, node) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/graph/rewriting/basic.py”, line 1081, in transform return self.fn(fgraph, node) ^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/tensor/rewriting/basic.py”, line 1122, in constant_folding thunk = node.op.make_thunk(node, storage_map, compute_map, no_recycling=) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/link/c/op.py”, line 119, in make_thunk return self.make_c_thunk(node, storage_map, compute_map, no_recycling)

clang++: error: unable to execute command: Abort trap: 6 clang++: error: linker command failed due to signal (use -v to see invocation)

Output is truncated. View as a scrollable element or open in a text editor. Adjust cell output settings…

You can find the C code in this temporary file: /var/folders/w7/h67z1rn941j1p0m51k08d9xc0000gp/T/pytensor_compilation_error_lg28oyur

ERROR (pytensor.graph.rewriting.basic): Rewrite failure due to: constant_folding ERROR (pytensor.graph.rewriting.basic): node: ExpandDims{axis=0}(1) ERROR (pytensor.graph.rewriting.basic): TRACEBACK: ERROR (pytensor.graph.rewriting.basic): Traceback (most recent call last): File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/graph/rewriting/basic.py”, line 1909, in process_node replacements = node_rewriter.transform(fgraph, node) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/graph/rewriting/basic.py”, line 1081, in transform return self.fn(fgraph, node) ^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/tensor/rewriting/basic.py”, line 1122, in constant_folding thunk = node.op.make_thunk(node, storage_map, compute_map, no_recycling=) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/link/c/op.py”, line 119, in make_thunk return self.make_c_thunk(node, storage_map, compute_map, no_recycling)

clang++: error: unable to execute command: Abort trap: 6 clang++: error: linker command failed due to signal (use -v to see invocation)

Output is truncated. View as a scrollable element or open in a text editor. Adjust cell output settings…

You can find the C code in this temporary file: /var/folders/w7/h67z1rn941j1p0m51k08d9xc0000gp/T/pytensor_compilation_error_pcx2r6_r

ERROR (pytensor.graph.rewriting.basic): Rewrite failure due to: constant_folding ERROR (pytensor.graph.rewriting.basic): node: Cast{float64}(0) ERROR (pytensor.graph.rewriting.basic): TRACEBACK: ERROR (pytensor.graph.rewriting.basic): Traceback (most recent call last): File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/graph/rewriting/basic.py”, line 1909, in process_node replacements = node_rewriter.transform(fgraph, node) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/graph/rewriting/basic.py”, line 1081, in transform return self.fn(fgraph, node) ^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/tensor/rewriting/basic.py”, line 1122, in constant_folding thunk = node.op.make_thunk(node, storage_map, compute_map, no_recycling=) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File “/Users/marco.forgione/anaconda3/envs/pymc_env/lib/python3.12/site-packages/pytensor/link/c/op.py”, line 119, in make_thunk return self.make_c_thunk(node, storage_map, compute_map, no_recycling)

clang++: error: unable to execute command: Abort trap: 6 clang++: error: linker command failed due to signal (use -v to see invocation)