Skip to content

Commit

Permalink
Change to get_edges_with_flag where appropriate
Browse files Browse the repository at this point in the history
  • Loading branch information
cmalinmayor committed Sep 8, 2023
1 parent ee98eeb commit 65f4552
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions src/traccuracy/metrics/_ctc.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,19 +50,15 @@ def compute(self):
}
edge_error_counts = {
"ws": len(
self.data.pred_graph.get_edges_with_attribute(
EdgeAttr.WRONG_SEMANTIC, lambda x: x
self.data.pred_graph.get_edges_with_flag(
EdgeAttr.WRONG_SEMANTIC
)
),
"fp": len(
self.data.pred_graph.get_edges_with_attribute(
EdgeAttr.FALSE_POS, lambda x: x
)
self.data.pred_graph.get_edges_with_flag(EdgeAttr.FALSE_POS)
),
"fn": len(
self.data.gt_graph.get_edges_with_attribute(
EdgeAttr.FALSE_NEG, lambda x: x
)
self.data.gt_graph.get_edges_with_flag(EdgeAttr.FALSE_NEG)
),
}
error_sum = get_weighted_error_sum(
Expand Down

0 comments on commit 65f4552

Please sign in to comment.