-
Notifications
You must be signed in to change notification settings - Fork 11
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
visualization of the chemical mechanism #2
Comments
In the prior commit, we had removed the old code but did not commit the new code to zero the C array. Now fixed. Signed-off-by: Bob Yantosca <[email protected]>
I just wanted to confirm this is still under the |
The atomic composition is indeed the only reason why I haven't started |
I was inspired by this idea so here's a step towards graphviz compatibility: obin1@37ef030. This addition creates a DOT language file of the mechanism, which once removing the automatically generated header can be used with graphviz like Explicitly including atomic composition could be useful, but I'm not sure it'd be essential for this, isn't stoichiometry already (hopefully) implied in the .eqn file? If we only want to plot a subset/induced subgraph of the reaction mechanism, maybe the specific submechanism could be chosen when writing the files by some sort of mask (could existing tools, like families, be expanded to make this possible)? I know that @emyli19 is working on Python tools to visualize subsets of mechanisms, but this might also be a useful tool directly in KPP. Would people still be interested in something like this? |
Hello @obin1, it's great to see your interest in graphs and mechanism
In my graphs, reactions are always represented as edges, whereas you are
You have implemented your additions directly into the KPP C code. My
Indeed, graphviz (dot) is probably the most widely used format for
With ever-increasing complexity of atmospheric chemical mechanisms, I |
Thanks for binning these topics @RolfSander, I took a while to gather some thoughts, here they are
|
Thanks for your comments. A few replies: 1 Graph type I agree that the bipartite graph is a cleaner way to store all the 2 Technical approach I don't think that KPP is the right tool to perform any complex https://en.wikipedia.org/wiki/GraphML http://graphml.graphdrawing.org/ Note that both networkx and graph-tool are able to read and write in 3 Software I quickly checked the wikipedia page of networkx. It looks like a very |
To follow up on these:
|
|
A manuscript describing my mechanism explorer software is now open for https://doi.org/10.5194/egusphere-2023-1577 If you have any comments or suggestions, feel free to post a public My code takes KPP *.spc and *.eqn files as input and generates a |
Hi @RolfSander, we were actually just looking at this last week! Looks like a really useful tool, especially the interactive visualization. Our projects are still using bipartite graphs, either in DOT format for reciprocal reactions or the biadjacency matrix for mass balancing in ML applications. I am using KPP to generate these formulations, so we are definitely interested in use of MEXPLORER. I would first like to clean up the way this is done, including adding the Section 2.3.2 is quite relevant to what we are working on: @emyli is quantifying cycles in GEOS-Chem in a bipartite context. I am curious how this is done in a unipartite context in MEXPLORER -- are parallel edges merged for calculation of the net reaction between species? |
Thanks :-) Let me know if you want to try it and have any questions about the
Great! I think the best way to proceed would be to create a separate
For the visualization, I merge parallel edges that go in the same https://graph-tool.skewed.de/static/doc/autosummary/graph_tool.topology.label_components.html The subgraphs with two or more vertices indicate which species belong to |
Great, I started a new branch! I was working in one of the flux/family branches, but will move the code to the new branch to isolate the graph generation. |
Automatic visualization of the chemical mechanism with graphviz.
The text was updated successfully, but these errors were encountered: