Skip to content

Commit

Permalink
feat: added model info source
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexPatrie committed Mar 15, 2024
1 parent 87273f9 commit 90e2651
Showing 1 changed file with 157 additions and 58 deletions.
215 changes: 157 additions & 58 deletions notebooks/biobuilder_api_demo.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -12,67 +12,12 @@
},
{
"cell_type": "code",
"execution_count": 1,
"execution_count": null,
"id": "initial_id",
"metadata": {
"ExecuteTime": {
"end_time": "2024-03-15T20:13:23.826982Z",
"start_time": "2024-03-15T20:13:23.204096Z"
},
"collapsed": true
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"True\n"
]
},
{
"data": {
"text/plain": [
"{'name': 'Reppas2015 - tumor control via alternating immunostimulating and immunosuppressive phases',\n",
" 'description': 'The paper describes a model of tumor control via alternating immunostimulating and immunosuppressive phases. \\r\\nCreated by COPASI 4.25 (Build 207) \\r\\n\\r\\nThis model is described in the article: \\r\\nIn silico tumor control induced via alternating immunostimulating and immunosuppressive phases\\r\\nAI Reppas, JCL Alfonso, and H Hatzikirou\\r\\nVirulence 7:2, 174--186\\r\\n\\r\\nAbstract: \\r\\nDespite recent advances in the field of Oncoimmunology, the success potential of immunomodulatory therapies against cancer remains to be elucidated. One of the reasons is the lack of understanding on the complex interplay between tumor growth dynamics and the associated immune system responses. Toward this goal, we consider a mathematical model of vascularized tumor growth and the corresponding effector cell recruitment dynamics. Bifurcation analysis allows for the exploration of model’s dynamic behavior and the determination of these parameter regimes that result in immune-mediated tumor control. In this work, we focus on a particular tumor evasion regime that involves tumor and effector cell concentration oscillations of slowly increasing and decreasing amplitude, respectively. Considering a temporal multiscale analysis, we derive an analytically tractable mapping of model solutions onto a weakly negatively damped harmonic oscillator. Based on our analysis, we propose a theory-driven intervention strategy involving immunostimulating and immunosuppressive phases to induce long-term tumor control.\\r\\n\\r\\nTo cite BioModels Database, please use: BioModels Database: An enhanced, curated and annotated resource for published quantitative kinetic models . \\r\\nTo the extent possible under law, all copyright and related or neighbouring rights to this encoded model have been dedicated to the public domain worldwide. \\r\\nPlease refer to CC0 Public Domain Dedication for more information.',\n",
" 'format': {'name': 'SBML', 'version': 'L3V1'},\n",
" 'publication': {'journal': 'Virulence',\n",
" 'title': 'In silico tumor control induced via alternating immunostimulating and immunosuppressive phases.',\n",
" 'affiliation': 'a Center for Advancing Electronics; Technische Universität Dresden ; Dresden , Germany.',\n",
" 'synopsis': \"Despite recent advances in the field of Oncoimmunology, the success potential of immunomodulatory therapies against cancer remains to be elucidated. One of the reasons is the lack of understanding on the complex interplay between tumor growth dynamics and the associated immune system responses. Toward this goal, we consider a mathematical model of vascularized tumor growth and the corresponding effector cell recruitment dynamics. Bifurcation analysis allows for the exploration of model's dynamic behavior and the determination of these parameter regimes that result in immune-mediated tumor control. In this work, we focus on a particular tumor evasion regime that involves tumor and effector cell concentration oscillations of slowly increasing and decreasing amplitude, respectively. Considering a temporal multiscale analysis, we derive an analytically tractable mapping of model solutions onto a weakly negatively damped harmonic oscillator. Based on our analysis, we propose a theory-driven intervention strategy involving immunostimulating and immunosuppressive phases to induce long-term tumor control.\",\n",
" 'year': 2016,\n",
" 'month': '1',\n",
" 'volume': '7',\n",
" 'issue': '2',\n",
" 'pages': '174-186',\n",
" 'link': 'http://identifiers.org/pubmed/26305801',\n",
" 'authors': [{'name': 'Reppas AI'},\n",
" {'name': 'Alfonso JC'},\n",
" {'name': 'Hatzikirou H', 'orcid': '0000-0002-1270-7885'}]},\n",
" 'files': {'main': [{'name': 'Reppas2015.xml', 'fileSize': '62675'}],\n",
" 'additional': [{'name': 'Reppas2015.sedml',\n",
" 'fileSize': '2191',\n",
" 'description': 'Auto-generated SEDML file'},\n",
" {'name': 'Reppas2015.cps',\n",
" 'fileSize': '81326',\n",
" 'description': 'CPS file of the model in COPASI'}]},\n",
" 'history': {'revisions': [{'version': 2,\n",
" 'submitted': 1562858737000,\n",
" 'submitter': 'Jinghao Men',\n",
" 'comment': 'Edited model metadata online.'},\n",
" {'version': 3,\n",
" 'submitted': 1562858822000,\n",
" 'submitter': 'Jinghao Men',\n",
" 'comment': 'Automatically added model identifier BIOMD0000000749'}]},\n",
" 'firstPublished': 1562858819000,\n",
" 'submissionId': 'MODEL1907110002',\n",
" 'publicationId': 'BIOMD0000000749'}"
]
},
"execution_count": 1,
"metadata": {},
"output_type": "execute_result"
}
],
"outputs": [],
"source": [
"import sys\n",
"\n",
Expand Down Expand Up @@ -160,6 +105,135 @@
"pp(simple_tc_model)"
]
},
{
"cell_type": "code",
"execution_count": 27,
"id": "1519914d8b9a85ce",
"metadata": {
"ExecuteTime": {
"end_time": "2024-03-15T20:22:06.411220Z",
"start_time": "2024-03-15T20:22:06.408264Z"
},
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"{ 'description': 'The paper describes a model of tumor control via alternating '\n",
" 'immunostimulating and immunosuppressive phases. \\r\\n'\n",
" 'Created by COPASI 4.25 (Build 207) \\r\\n'\n",
" '\\r\\n'\n",
" 'This model is described in the article: \\r\\n'\n",
" 'In silico tumor control induced via alternating '\n",
" 'immunostimulating and immunosuppressive phases\\r\\n'\n",
" 'AI Reppas, JCL Alfonso, and H Hatzikirou\\r\\n'\n",
" 'Virulence 7:2, 174--186\\r\\n'\n",
" '\\r\\n'\n",
" 'Abstract: \\r\\n'\n",
" 'Despite recent advances in the field of Oncoimmunology, the '\n",
" 'success potential of immunomodulatory therapies against '\n",
" 'cancer remains to be elucidated. One of the reasons is the '\n",
" 'lack of understanding on the complex interplay between tumor '\n",
" 'growth dynamics and the associated immune system responses. '\n",
" 'Toward this goal, we consider a mathematical model of '\n",
" 'vascularized tumor growth and the corresponding effector '\n",
" 'cell recruitment dynamics. Bifurcation analysis allows for '\n",
" 'the exploration of model’s dynamic behavior and the '\n",
" 'determination of these parameter regimes that result in '\n",
" 'immune-mediated tumor control. In this work, we focus on a '\n",
" 'particular tumor evasion regime that involves tumor and '\n",
" 'effector cell concentration oscillations of slowly '\n",
" 'increasing and decreasing amplitude, respectively. '\n",
" 'Considering a temporal multiscale analysis, we derive an '\n",
" 'analytically tractable mapping of model solutions onto a '\n",
" 'weakly negatively damped harmonic oscillator. Based on our '\n",
" 'analysis, we propose a theory-driven intervention strategy '\n",
" 'involving immunostimulating and immunosuppressive phases to '\n",
" 'induce long-term tumor control.\\r\\n'\n",
" '\\r\\n'\n",
" 'To cite BioModels Database, please use: BioModels Database: '\n",
" 'An enhanced, curated and annotated resource for published '\n",
" 'quantitative kinetic models . \\r\\n'\n",
" 'To the extent possible under law, all copyright and related '\n",
" 'or neighbouring rights to this encoded model have been '\n",
" 'dedicated to the public domain worldwide. \\r\\n'\n",
" 'Please refer to CC0 Public Domain Dedication for more '\n",
" 'information.',\n",
" 'files': { 'additional': [ { 'description': 'CPS file of the model in COPASI',\n",
" 'fileSize': '81326',\n",
" 'name': 'Reppas2015.cps'},\n",
" { 'description': 'Auto-generated SEDML file',\n",
" 'fileSize': '2191',\n",
" 'name': 'Reppas2015.sedml'}],\n",
" 'main': [{'fileSize': '62675', 'name': 'Reppas2015.xml'}]},\n",
" 'firstPublished': 1562858819000,\n",
" 'format': {'name': 'SBML', 'version': 'L3V1'},\n",
" 'history': { 'revisions': [ { 'comment': 'Edited model metadata online.',\n",
" 'submitted': 1562858737000,\n",
" 'submitter': 'Jinghao Men',\n",
" 'version': 2},\n",
" { 'comment': 'Automatically added model '\n",
" 'identifier BIOMD0000000749',\n",
" 'submitted': 1562858822000,\n",
" 'submitter': 'Jinghao Men',\n",
" 'version': 3}]},\n",
" 'name': 'Reppas2015 - tumor control via alternating immunostimulating and '\n",
" 'immunosuppressive phases',\n",
" 'publication': { 'affiliation': 'a Center for Advancing Electronics; '\n",
" 'Technische Universität Dresden ; Dresden , '\n",
" 'Germany.',\n",
" 'authors': [ {'name': 'Reppas AI'},\n",
" {'name': 'Alfonso JC'},\n",
" { 'name': 'Hatzikirou H',\n",
" 'orcid': '0000-0002-1270-7885'}],\n",
" 'issue': '2',\n",
" 'journal': 'Virulence',\n",
" 'link': 'http://identifiers.org/pubmed/26305801',\n",
" 'month': '1',\n",
" 'pages': '174-186',\n",
" 'synopsis': 'Despite recent advances in the field of '\n",
" 'Oncoimmunology, the success potential of '\n",
" 'immunomodulatory therapies against cancer '\n",
" 'remains to be elucidated. One of the reasons '\n",
" 'is the lack of understanding on the complex '\n",
" 'interplay between tumor growth dynamics and '\n",
" 'the associated immune system responses. Toward '\n",
" 'this goal, we consider a mathematical model of '\n",
" 'vascularized tumor growth and the '\n",
" 'corresponding effector cell recruitment '\n",
" 'dynamics. Bifurcation analysis allows for the '\n",
" \"exploration of model's dynamic behavior and \"\n",
" 'the determination of these parameter regimes '\n",
" 'that result in immune-mediated tumor control. '\n",
" 'In this work, we focus on a particular tumor '\n",
" 'evasion regime that involves tumor and '\n",
" 'effector cell concentration oscillations of '\n",
" 'slowly increasing and decreasing amplitude, '\n",
" 'respectively. Considering a temporal '\n",
" 'multiscale analysis, we derive an analytically '\n",
" 'tractable mapping of model solutions onto a '\n",
" 'weakly negatively damped harmonic oscillator. '\n",
" 'Based on our analysis, we propose a '\n",
" 'theory-driven intervention strategy involving '\n",
" 'immunostimulating and immunosuppressive phases '\n",
" 'to induce long-term tumor control.',\n",
" 'title': 'In silico tumor control induced via alternating '\n",
" 'immunostimulating and immunosuppressive phases.',\n",
" 'volume': '7',\n",
" 'year': 2016},\n",
" 'publicationId': 'BIOMD0000000749',\n",
" 'submissionId': 'MODEL1907110002'}\n"
]
}
],
"source": [
"# 1b. view model info for model source:\n",
"\n",
"pp(simple_tc_model.source_info)"
]
},
{
"cell_type": "code",
"execution_count": 4,
Expand All @@ -173,7 +247,7 @@
},
"outputs": [],
"source": [
"# 1b. define a TimeCourse process instance using the above object as a parameter. The other parameter is method. See BasiCO documentation for more details on solvers\n",
"# 1c. define a TimeCourse process instance using the above object as a parameter. The other parameter is method. See BasiCO documentation for more details on solvers\n",
"\n",
"simple_tc_process = sed.TimeCourseProcess(model=simple_tc_model, method='lsoda')"
]
Expand Down Expand Up @@ -814,6 +888,31 @@
"#### **_Experiment 2_**: Load an SBML model from a specified model filepath and add Model changes to the composite before adding it to the bigraph. Here, we expect the user to be familiar enough with the model file they are passing to make individual species/parameter/reaction changes for specific species types. In the Caravagna model, for example, the species involved are T, E, I. Let's change the initial concentration for some of these as an example of model changes:"
]
},
{
"cell_type": "code",
"execution_count": 26,
"id": "89739e0302d6b89a",
"metadata": {
"ExecuteTime": {
"end_time": "2024-03-15T20:21:00.668323Z",
"start_time": "2024-03-15T20:21:00.664979Z"
},
"collapsed": false
},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"True\n"
]
}
],
"source": [
"caravagna_model_filepath = '../biosimulator_processes/model_files/Caravagna2010.xml'\n",
"print(os.path.exists(caravagna_model_filepath))"
]
},
{
"cell_type": "code",
"execution_count": 16,
Expand Down

0 comments on commit 90e2651

Please sign in to comment.