nrnb / GoogleSummerOfCode

Main documentation site for NRNB GSoC project ideas and resources
114 stars 38 forks source link

Interactive Systems Biology Analyses using COPASI's R or Python APIs #167

Closed cannin closed 2 years ago

cannin commented 3 years ago

Background

COPASI (http://copasi.org/) is a software application for simulation and analysis of biochemical networks and their dynamics. While the primary interaction with COPASI is over a graphical user interface, where models can be easily constructed and analyzed, all functionality is available from a variety of programming languages thanks to SWIG. These automatically generated SWIG wrappers, do however still resemble the underlying C++ abstractions, and so are hard to use (and to document). CoRC provides a high-level API for Copasi’s computational backend in the R programming environment. This allows the scripting of sophisticated systems biology workflows in R for reproducible research or for batch-processing of more demanding calculations on compute clusters. The CoRC interface is designed for both simplicity and flexibility and simulation and analysis results are immediately available in native R data structures, such as tibbles, for further (statistical) analysis or visualization.

You can find more information about CoRC on Github (https://jpahle.github.io/CoRC, including tutorials and examples) and in our publication in Bioinformatics ( https://doi.org/10.1093/bioinformatics/btab033).

Similarly, the basiCO project (http://basico.readthedocs.io/) aims to do the same for the python language. Instead of having to know about internal COPASI data structures, users would be able to use native data frames to perform operations.

Goal

The goal is to improve the usability of the COPASI R (CoRC) or Python (basico) interfaces by enhancing or exposing further functionality that is available in the C++ API but would still be too cumbersome to use in the scripting language.

CoRC (R)

CoRC already supports a number of tasks and analyses available in Copasi. We would like to extend this in different ways, for instance, by implementing more complex analyses and supporting researchers with automated/scripted systems biology workflows.

BasiCO (Python)

Basico currently supports basic model editing, time course simulations, steady state calculations and parameter estimation tasks. COPASI however exposes a multitude of other analysis tasks, that would be helpful to be exposed with a simple interface extrapolating from what is there at current. Creating additional interactive notebooks would be beneficial as well.

Difficulty Level 2

An existing R or Python version is available, and so only those would have to be modified, enhanced or augmented.

An understanding of the additional analysis tasks that COPASI (which has many features) offers would help in guiding contributions to these interfaces.

Skills

Public Repository

Potential Mentors

Augustin Luna Frank Bergman; @fbergmann Juergen Pahle; @jpahle

thepritam commented 3 years ago

Can I please work on this issue @cannin . I am familiar with the skills tools for this issue.

shaliniiit commented 3 years ago

@cannin I have gone through the code and the issue and feel like its a good fit for me having worked on similar projects in other universities like Penn State and CMU. I'd be happy to start working. Please look up my resume: https://drive.google.com/file/d/1pcqymg8_DTuCQTTV8cUyEfISpvD63Jlq/view?usp=sharing

cannin commented 3 years ago

@thepritam @shaliniiit thanks for the interest. @fbergmann the other potential mentor will be posting more details in the next few days to give additional guidance; watch for updates here.

thepritam commented 3 years ago

@cannin Thank you for your response and will do it accordingly.

sh15h4nk commented 3 years ago

Hello there, I'm a student, looking to work on with this project idea from the GSOC'21. I have an experience with python API, I wanted to contribute to this issue. Can someone help me with the start up guide to this issue or the project. I'm basically new to open source. Halp Plox! and how do i contact the mentors?

fbergmann commented 3 years ago

@sh15h4nk glad to see that you are interested in the project. To get started i suggest that you fork the basico project, by clicking the 'fork' button on the https://github.com/copasi/basico, and then clone the newly created repo (using for example github desktop https://desktop.github.com/). Once the files are on your machine, create a new virtual environment, and install the dependencies into it (by running pip install -r requirements.txt) at that point you should be ready to run the notebooks in docs/notebooks. Please let me know if you have any questions / issues with this.

thepritam commented 3 years ago

@fbergmann

@thepritam @shaliniiit thanks for the interest. @fbergmann the other potential mentor will be posting more details in the next few days to give additional guidance; watch for updates here.

Hello @fbergmann , I am interested to work on this given issue and I have worked previously different api based systems. Please guide me to start working on this issue. Thanks

fbergmann commented 3 years ago

hello @thepritam, great! I would also invite you to fork the project, clone it, and set it up for your locally. Then i would like you to work through the documentation here https://basico.readthedocs.io/en/latest/ (that is automatically generated from the documentation in the ./docs/ folder. Once you have done, I would like you to make a pull request that slightly improves the documentation (fixing a typo, changing a paragraph something like that). This will help make you familiar with the process. Please let me know if you need help on any step.

sh15h4nk commented 3 years ago

@sh15h4nk glad to see that you are interested in the project. To get started i suggest that you fork the basico project, by clicking the 'fork' button on the https://github.com/copasi/basico, and then clone the newly created repo (using for example github desktop https://desktop.github.com/). Once the files are on your machine, create a new virtual environment, and install the dependencies into it (by running pip install -r requirements.txt) at that point you should be ready to run the notebooks in docs/notebooks. Please let me know if you have any questions / issues with this.

@fbergmann I have successfully setup the project on my local machine, Do I actually need to work the whole project on notebooks?. And what do I do next?

fbergmann commented 3 years ago

@sh15h4nk great! And no, I would hope that any new functionality would be added to the primary API (in the ./basico/ folder), and from there would be available for notebook users, and script users alike. I see the notebooks as a great way, to encode examples and for documentation. So it would be necessary to alter then / add new ones at times. The next step would be to make a minor modification, run the tests (using python -m pytest from the main directory) to ensure, everything is still working. And make a pull request back to the main repository, that shows that you are setup and ready to go.

sh15h4nk commented 3 years ago

@sh15h4nk great! And no, I would hope that any new functionality would be added to the primary API (in the ./basico/ folder), and from there would be available for notebook users, and script users alike. I see the notebooks as a great way, to encode examples and for documentation. So it would be necessary to alter then / add new ones at times. The next step would be to make a minor modification, run the tests (using python -m pytest from the main directory) to ensure, everything is still working. And make a pull request back to the main repository, that shows that you are setup and ready to go.

minor modification in sense?

cannin commented 3 years ago

@sh15h4nk The main work would be left for the summer as you will describe in your proposal (https://nrnb.org/gsoc.html). For now, it make be sufficient to change some small string even if the Pull Request is not accepted. If there is anything that has prevented you from exploring the code (or where the instructions could have been improved) that is a Pull Request that you could also make.

sh15h4nk commented 3 years ago

Yeh, Got it . How often this organization select new student, like I'm very new to the open source but I have a quiet experience in developing a Python API. I just need an opportunity to learn, explore and contribute. @cannin Help me Out.

cannin commented 3 years ago

@sh15h4nk NRNB has been selected the majority of years in the past ~10 years and in some cases, we manage to publish the work in academic journals (https://academic.oup.com/bioinformatics/article/28/6/889/309721 2012).

sh15h4nk commented 3 years ago

@sh15h4nk NRNB has been selected the majority of years in the past ~10 years and in some cases, we manage to publish the work in academic journals (https://academic.oup.com/bioinformatics/article/28/6/889/309721 2012).

Like, Is there any Opportunity for a student, who is very new to the Open Source. Like I don't know much about the Biology. But I have a knowledge and experience with programming and Python API. Is that enough to learn and contribute .What can you say about my selection. Could I get a chance or Do I need to lookup into other tech related organization? @cannin

sh15h4nk commented 3 years ago

@sh15h4nk great! And no, I would hope that any new functionality would be added to the primary API (in the ./basico/ folder), and from there would be available for notebook users, and script users alike. I see the notebooks as a great way, to encode examples and for documentation. So it would be necessary to alter then / add new ones at times. The next step would be to make a minor modification, run the tests (using python -m pytest from the main directory) to ensure, everything is still working. And make a pull request back to the main repository, that shows that you are setup and ready to go.

I have made a pull request to the repo, what next !

cannin commented 3 years ago

@sh15h4nk Most of my previous students have been from computer science areas. For GSOC, I tend to look for good programmers that understand the task even if they do not understand the research. Some projects are easier to build upon with basic project knowledge. Here the task is to make additional COPASI desktop tool functionality available via the Python package. Separately, you should understand how to navigate tools like git/GitHub, but you do not need a long previous experience in an open source community.

The main component of the application is the proposal: https://nrnb.org/gsoc.html to help us understand you know what the task is and that you have a feasible plan.

sh15h4nk commented 3 years ago

@sh15h4nk Most of my previous students have been from computer science areas. For GSOC, I tend to look for good programmers that understand the task even if they do not understand the research. Some projects are easier to build upon with basic project knowledge. Here the task is to make additional COPASI desktop tool functionality available via the Python package. Separately, you should understand how to navigate tools like git/GitHub, but you do not need a long previous experience in an open source community.

The main component of the application is the proposal: https://nrnb.org/gsoc.html to help us understand you know what the task is and that you have a feasible plan.

Interactive system in sense like an application (.exe ) GUI or an command line tool and what would be the features of the system like loading and creating module etc. Or like any significant features of the application

sh15h4nk commented 3 years ago

What is the exact system to work on is it an api or an application

fbergmann commented 3 years ago

@sh15h4nk the target audience for basico, (and cork) are scientists and students that would interactively script with these apis. So they would use Jupyter Notebooks / Jupyter Lab / Spider / PyCharms for basico and RStudio for CoRC to construct / explore models, and analyze them. This is usually an iterative approach, wherein many different things are tried out.

sh15h4nk commented 3 years ago

So the main goal is to write scripts what Interact with the apis out and give back the response to the user on the notebook

fbergmann commented 3 years ago

indeed, as the underlying (c++ api) requires too much knowledge of the underlying architecture, basico / corc provide high level abstractions on top that hide the complexity, making it easy to handle.

sh15h4nk commented 3 years ago

So for this we will working on the other repo (new interactive system) or will be upgrading an existing one? Or will be doing modification on the basico api ? and giving the user to use the function or the modules ?

fbergmann commented 3 years ago

You'd be working on a fork of basico (or corc if that is what you choose), and add new functionality to the modules on that one, work on documentation and examples. With the goal that it will be then merged back into the main repository. This all should just work without the underlying C++ code of COPASI to be modified.

jpahle commented 3 years ago

Hi All, it's great that there is already quite some interest in our R/Python Copasi APIs. Frank has been active answering your questions. I just wanted to add that I will also be available as a mentor. I would also like to emphasize that there are opportunities to work on the Python API (basiCO) but also on our R API (CoRC) or, in fact, both.

khanspers commented 2 years ago

Cleanup in preparation for GSoC 2022.