-
Notifications
You must be signed in to change notification settings - Fork 217
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
WIP: Fix to model summary methods #268
Conversation
This fix resolves opencobra#267, in which models that do not conform to the standard boundary reaction format would cause the `model_summary` method to fail. Now the summary method will print the ID of the first metabolite and raise a warning if a boundary reaction exchanges more than one species.
Good catch -- I'll work on that. |
Awesome. If you need help with anything you know where to find me :) |
While I'm at it we might as well get to #266, #238, and #240. How would we feel about exporting table formatting to a third party? It might make the code a bit more extendable / maintainable. tabulate looks promising, but I'm certainly happy to look at others if you have suggestions. (Or if we want to avoid additional dependencies) |
I agree. This kind of formatting usually has hundreds of edge cases one has to consider ("what happens if the name of the reaction is super long", etc.). I like how it's done now with converting everything to a pandas data frame and then writing some formatting for that data frame. |
pardon the premature merge, the bug fix was already good, please open new pr for the additional issues you mentioned. Anyway, tabulate looks like good option, prettytable is another but tabulate directly takes pandas df so maybe the better option. |
Yikes, as @cdiener mentioned there was still an issue with assigning input and output fluxes.. |
ouch, yes mea culpa :( This also reminds me I think it would be good to start doing merges to devel first, and only upon release to master.. |
I think there is no problem here. The bug I reported initially was already fixed here and the rest can be in another pull req. I think bug fix pull requests are fine in master, otherwise master would just be a glorified tag for the latest release :) |
Sounds great. Regardless, it shouldn't be too long until I have a newer implementation ready. |
This fix resolves #267, in which models that do not conform to the
standard boundary reaction format would cause the
model_summary
methodto fail. Now the summary method will print the ID of the first
metabolite and raise a warning if a boundary reaction exchanges more
than one species.