Skip to content

Commit dfd018e

Browse files
cschefflermichaelosthege
authored andcommitted
Fix model graph node name to remove RV from end only and not the start
1 parent ab40dcc commit dfd018e

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

pymc/model_graph.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,8 +135,10 @@ def _make_node(self, var_name, graph, *, formatting: str = "plain"):
135135
style = "filled"
136136
else:
137137
shape = "ellipse"
138-
syle = None
139-
symbol = v.owner.op.__class__.__name__.strip("RV")
138+
style = None
139+
symbol = v.owner.op.__class__.__name__
140+
if symbol.endswith("RV"):
141+
symbol = symbol[:-2]
140142
label = f"{var_name}\n~\n{symbol}"
141143
else:
142144
shape = "box"

0 commit comments

Comments
 (0)