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

Better graphviz support for bipartite graphs #888

Open
slwu89 opened this issue Feb 17, 2024 · 1 comment
Open

Better graphviz support for bipartite graphs #888

slwu89 opened this issue Feb 17, 2024 · 1 comment

Comments

@slwu89
Copy link
Member

slwu89 commented Feb 17, 2024

Hi @epatters, following up here from the zulip conversation. Before working on PropertyBipartiteGraph and to_graphviz for it, I wanted to ask if you can help explain the design considerations behind the existing PropertyGraph machinery and its interaction with the other graph acsets/to_graphviz system, so that I can replicate as much as possible those designs for the bipartite one. And if there are any essential desiderata for the bipartite one. Thanks!

@slwu89
Copy link
Member Author

slwu89 commented Feb 29, 2024

@epatters while looking at this I noticed an apparent oddity, in the BipartiteGraphs module the methods to remove vertices and edges are typed for AbstractBipartiteGraph as opposed to the rest of the getters/setters which are typed for HasBipartiteGraph, see https://github.com/AlgebraicJulia/Catlab.jl/blob/main/src/graphs/BipartiteGraphs.jl#L254-L288

This is relevant because in my current design I follow the version for basic graph property graph. That is, the type of the acset graph in the struct PropertyGraph should be a subtype of HasGraph. If I do something similar for bipartite graphs and make the type of the bipartite acset in BipartitePropertyGraph be a subtype of HasBipartiteGraph, the methods for remove vertices won't "forward" properly, as the type class is too wide for those ones.

I suspect that the intention was to have those methods in the BipartiteGraphs module actually take HasBipartiteGraph as the type of the first argument, but want to confirm with you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants