Comments (8)
Good day @carrascomj !
I am happy to see you are interested in pyTFA. This is definitely a functionality we have considered, and it would considerably expand the usability of pyTFA. However, we don't really have anyone that could work on it at the moment, so your effort is very welcome !
For the implementation, if you decide to write a standalone module we will gladly link to it, and if instead you would like to contribute directly to the code we can work with pull requests :)
Very cool notebook also, thank you for sharing it. And indeed, yes, pH and Ionic strength are extremely important for the models to be accurate. I am happy to see you could reproduce our results !
It's been a while since I have used eQuilibrator, so maybe things changed, but also it is important to make sure we recover the ΔGr'°, and not the ΔGr'm.
from pytfa.
Nice! I will fork the project and will try to implement it in the package.
Just a quick question: as the eQuilibrator-API provides calculation of Confidence intervals, would it be meaningful to use them as the error for ΔGr'?
from pytfa.
Yes, we use the errors as bounds for the ΔGr'°, so we can directly integrate them!
from pytfa.
Hello! After this PR is merged to equilibrator_api, I should be able to open mine for pytfa.
Meanwhile, I have stumbled upon some decisions to take:
- The logic is implemented as a new method
.prepare_equilibrator()
. I had to arrange the.__init__()
to make it possible for the user to initialize theThermoModel
without specifying athermo_data
argument. Other possibility would be to implement it as an external function instead of a method. Here, the problem is that the API exposes the thermodynamics information of the reactions, not the formation energies, so the preparation of the model requires some tweaking of theThermoModel
in the process. - Lazy loading of eQuilibrator. The eQuilibrator package always takes time to load, so I thought it would be interesting to just load it when the user tries to prepare the model with eQuilibrator.
- equilibrator_api as extra dependency? Right now, I have implemented it so it's only installed with
pip install pytfa[equilibrator]
- Minimally refactored the assessment of reaction compartment to utils.py, since both "preparations" of reactions call it.
- Added some tests to the related methods.
from pytfa.
Good day Jorge,
Wow, that was fast! Ok, regarding your points:
- I initially thought to have it as an external function, but I actually like your method. I was also wondering, maybe we can simply generate a thermo_data object, and feed this as a standard thermo_data dict ?
- Yes I think this is a must
- If you mean as an optional dependency, yes, I think it makes the most sense. Then I can simply add in the readme and docs this info
- I'll need more details here but yes I understand why this can be necessary
- Thanks! This is also a must, and yet so many people forget about this haha!
Thank your for being so on top of this
Cheers,
Pierre
from pytfa.
Hi! After talking about it on the equilibrator_api side, I will try to implement it by reconstructing the thermo_data
structure with formation energies from eQuilibrator, which might provide a cleaner integration, as an external function.
However, using raw formation energies from eQuilibrator may yield very high uncertainties. If they turned to be too high to be informative, I will need to go back to the proposed alternative .prepare_equilibrator()
method, relying on reaction data.
from pytfa.
Good day Jorge,
I see your point. In the current TFA we usually have formation energies decomposed by groups from the group contribution method. This allows to reduce the error when calculating the Gibbs energy of reaction by only accounting for the elements that change during the transformation. If we can get the components from the CCM from eQuilibrator, given a metabolite, maybe we can do the same?
from pytfa.
Hello Pierre,
As explained in the PR, eQuilibrator uses the Component Contribution method instead of group contributions. Thus, major profound changes would be needed in the package to accommodate this information from eQuilibrator. The solution from the eQuilibrator prepared tmodel varies from but it is more similar to the cobra model than using the .thermodb
file.
I have used the total summation of fluxes to quickly compare them:
cobrapy -> 143.13836864239119
thermo_data from equilibrator -> 188.8536839871894
thermo_data from .thermodb -> 1190.6526819344149
from pytfa.
Related Issues (20)
- metabolomics integration HOT 3
- Unable to open Matlab models HOT 2
- KeyError and potential solution in sampling tutorial HOT 4
- SEED identifiers in thermo DB
- deltaGerr automatically sets to 2.0 after loading thermo model HOT 2
- tutorial_basics lots of warnings when mytfa.prepare() HOT 2
- Thermo DB as SQLite HOT 1
- tutorial_basic.py ERROR - Relaxation could not complete (no DeltaG relaxation found) HOT 7
- Get new delta G values after adding metabolomics data HOT 1
- Use displacement or not? HOT 1
- Relaxation of log concentration error HOT 1
- Problem with pytfa.relax_dgo due to sympy HOT 2
- CPLEX binaries should not be mandatory for Docker build HOT 6
- KeyError on .convert() HOT 2
- Problem with installation HOT 2
- Comma missing in constraint definition
- Problem with building Docker container HOT 1
- equilibrator-cache replaced quilt with zenodo
- Permission denied when running the docker image HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pytfa.