Skip to content

Commit b9c4f20

Browse files
ricardoV94michaelosthege
authored andcommitted
Suppress optimizer verbose from MergeOptimizer when compiling inner fgraph C code of Composite
Otherwise, it will show up everytime a Composite has been cached by th C backend
1 parent 2db3760 commit b9c4f20

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

pytensor/scalar/basic.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -4236,7 +4236,8 @@ def fgraph(self):
42364236
# the fgraph to be set to the variable as we need to pickle
42374237
# them for the cache of c module to work.
42384238
fgraph = FunctionGraph(self.inputs, self.outputs)
4239-
MergeOptimizer().rewrite(fgraph)
4239+
with config.change_flags(optimizer_verbose=False):
4240+
MergeOptimizer().rewrite(fgraph)
42404241
for node in fgraph.apply_nodes:
42414242
if not isinstance(node.op, ScalarOp):
42424243
raise TypeError(

0 commit comments

Comments
 (0)