causy
Advanced tools
@@ -145,5 +145,2 @@ import enum | ||
| if len(unapplied_actions_y_z) > 0 or len(unapplied_actions_x_z) > 0: | ||
| logger.warning( | ||
| f"Orientation conflict detected in ColliderTest stage when orienting the edge between {x.name} and {y.name}. The conflict is resolved using the strategy {self.conflict_resolution_strategy}, but orientation conflicts indicate assumption violations and can severely affect the accuracy of the results.", | ||
| ) | ||
| if ( | ||
@@ -153,4 +150,22 @@ ColliderTestConflictResolutionStrategies.KEEP_FIRST | ||
| ): | ||
| # We keep the first edge that was removed | ||
| continue | ||
| # We prioritize the first edge that was removed, we do nothing | ||
| if len(unapplied_actions_y_z) > 0: | ||
| results.append( | ||
| TestResult( | ||
| u=z, | ||
| v=y, | ||
| action=TestResultAction.DO_NOTHING, | ||
| data={"orientation_conflict": True}, | ||
| ) | ||
| ) | ||
| if len(unapplied_actions_x_z) > 0: | ||
| results.append( | ||
| TestResult( | ||
| u=z, | ||
| v=x, | ||
| action=TestResultAction.DO_NOTHING, | ||
| data={"orientation_conflict": True}, | ||
| ) | ||
| ) | ||
| elif ( | ||
@@ -242,3 +257,8 @@ ColliderTestConflictResolutionStrategies.KEEP_LAST | ||
| if breakflag is True: | ||
| continue | ||
| return TestResult( | ||
| u=y, | ||
| v=z, | ||
| action=TestResultAction.DO_NOTHING, | ||
| data={"orientation_conflict": True}, | ||
| ) | ||
| return TestResult( | ||
@@ -256,3 +276,11 @@ u=y, | ||
| if graph.only_directed_edge_exists(graph.nodes[node], x): | ||
| continue | ||
| breakflag = True | ||
| break | ||
| if breakflag is True: | ||
| return TestResult( | ||
| u=x, | ||
| v=z, | ||
| action=TestResultAction.DO_NOTHING, | ||
| data={"orientation_conflict": True}, | ||
| ) | ||
| return TestResult( | ||
@@ -259,0 +287,0 @@ u=x, |
+1
-1
| Metadata-Version: 2.1 | ||
| Name: causy | ||
| Version: 0.1.38 | ||
| Version: 0.1.39 | ||
| Summary: Causal discovery made easy. | ||
@@ -5,0 +5,0 @@ License: MIT |
Alert delta unavailable
Currently unable to show alert delta for PyPI packages.
4465413
0.02%20949
0.12%