Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unreachable code in ColoredHyperGraph, ColoredHyperGraphView, and CombinatorialComplex #291

Closed
3 of 5 tasks
gurug-dev opened this issue Oct 24, 2023 · 0 comments · Fixed by #383
Closed
3 of 5 tasks
Assignees
Labels
bug Something isn't working
Milestone

Comments

@gurug-dev
Copy link
Contributor

gurug-dev commented Oct 24, 2023

What/Where?

  • CHG - degree_matrix, line 1125: incidence_matrix will never be 0,0 shape due to compute_set_incidence
  • CHG - laplacian_matrix, line 1163: adjacency_matrix will never be 0,0 shape due to compute_set_incidence
  • CHG/CCC - _remove_hyperedge the case -> isinstance(hyperedge, Hashable) and not isinstance(hyperedge, Iterable) is not valid as previous check if hyperedge not in self.cells filters out any object not already present in self.cells and self.cells can only contain hashable and iterable elements like frozenset, etc
  • CHGView - __contains__ : elif isinstance(hyperedge_elements, HyperEdge) case is unreachable as hyperedge_elements is unpacked earlier if it is HyperEdge object.
  • CCC - _CCC_condition method is not well defined, CCC._node_membership is an empty set for a defined CCC.
    combinatorial_complex = CombinatorialComplex([[1, 2, 3], [2, 3, 4]], ranks=2)
    combinatorial_complex._CCC_condition([None], 2)  # doesn't throw an error.
@ffl096 ffl096 added this to the 0.1.0 milestone Jul 3, 2024
@ffl096 ffl096 added the bug Something isn't working label Jul 3, 2024
@ffl096 ffl096 mentioned this issue Jul 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants