Skip to content

Commit 20b653b

Browse files
authored
fix: orient the edge between alpha and beta as an undirected edge.
Signed-off-by: Zhiyi Huang <[email protected]>
1 parent 65f6ad3 commit 20b653b

File tree

1 file changed

+3
-0
lines changed
  • causallearn/search/ConstraintBased

1 file changed

+3
-0
lines changed

causallearn/search/ConstraintBased/FCI.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -499,6 +499,9 @@ def orient_on_path_helper(path, node_A, node_B):
499499
changeFlag = True
500500
if verbose:
501501
print("Find uncovered circle path between A and B: " + graph.get_edge(node_A, node_B).__str__())
502+
edge = graph.get_edge(node_A, node_B)
503+
graph.remove_edge(edge)
504+
graph.add_edge(Edge(node_A, node_B, Endpoint.TAIL, Endpoint.TAIL))
502505
orient_on_path_helper(path, node_A, node_B)
503506

504507
return changeFlag

0 commit comments

Comments
 (0)