-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #100 from drbergman/librr-macros
inputs.toml and support libRR intracellulars
- Loading branch information
Showing
64 changed files
with
2,169 additions
and
1,914 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
name = "pcvct" | ||
uuid = "3c374bc7-7384-4f83-8ca0-87b8c727e6ff" | ||
authors = ["Daniel Bergman <[email protected]> and contributors"] | ||
version = "0.0.15" | ||
version = "0.0.16" | ||
|
||
[deps] | ||
AutoHashEquals = "15f4f7f2-30c1-5605-9d31-71845cf9641f" | ||
CSV = "336ed68f-0bac-5ca0-87d4-7b16caf5d00b" | ||
DataFrames = "a93c6f00-e57d-5684-b7b6-d8193f3e46c0" | ||
Dates = "ade2ca70-3891-5945-98fb-dc099432e06a" | ||
|
@@ -28,9 +29,11 @@ RecipesBase = "3cdcf5f2-1ef4-517c-9805-6587b60abb01" | |
SQLite = "0aa819cd-b072-5ff4-a722-6bc24af294d9" | ||
Sobol = "ed01d8cd-4d21-5b2a-85b4-cc3bdc58bad4" | ||
Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2" | ||
TOML = "fa267f1f-6049-4f14-aa54-33bafae1ed76" | ||
Tables = "bd369af6-aec1-5ad0-b16a-f7cc5008161c" | ||
|
||
[compat] | ||
AutoHashEquals = "2.2.0" | ||
CSV = "0.10" | ||
DataFrames = "1" | ||
Distributions = "0.25" | ||
|
@@ -53,6 +56,7 @@ RecipesBase = "1.3.4" | |
SQLite = "1" | ||
Sobol = "1" | ||
Statistics = "1" | ||
TOML = "1.0.3" | ||
Tables = "1" | ||
julia = "1.6.7" | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
```@meta | ||
CollapsedDocStrings = true | ||
``` | ||
|
||
# VCTComponents | ||
|
||
Allows for combining PhysiCell input components into whole inputs. | ||
|
||
Currently, only supports this for intracellular ODE (libRoadRunner) models. | ||
|
||
```@autodocs | ||
Modules = [pcvct] | ||
Pages = ["VCTComponents.jl"] | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
# Developer guide | ||
|
||
## Style guide | ||
- Use `#!` for comments that are informative | ||
- This helps find code lines commented out in development. | ||
- Using the regexp `^(\s+)?# .+\n` seems to work well for finding commented out code lines. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
# Intracellular inputs | ||
|
||
pcvct currently only supports ODE intracellular models using libRoadRunner. | ||
It uses a specialized format to achieve this, creating the SBML files needed by libRoadRunner at PhysiCell runtime. | ||
Briefly, the `intracellular.xml` file defines a mapping between cell definitions and intracellular models. | ||
See the template provided [here](https://github.com/drbergman/PhysiCell/blob/my-physicell/sample_projects_intracellular/combined/template-combined/config/sample_combined_sbmls.xml). | ||
|
||
To facilitate creation of such files, and to make it easy to mix-and-match intracellular models, users can place the SBML files that define the ODEs into `data/components/roadrunner` and then simply reference those to construct the specialized XMLs needed. | ||
For example, place the `Toy_Metabolic_Model.xml` from [sample_projects_intracellular/ode/ode_energy/config/](https://github.com/drbergman/PhysiCell/blob/my-physicell/sample_projects_intracellular/ode/ode_energy/config) into `data/components/roadrunner` and assemble the XML as follows | ||
|
||
```julia | ||
cell_type = "default" # name of the cell type using this intracellular model | ||
component = PhysiCellComponent("roadrunner", "Toy_Metabolic_Model.xml") # pass in the type of the component and the name of the file to use | ||
cell_type_to_component = Dict{String, PhysiCellComponent}(cell_type => component) # add other entries to this Dict for other cell types using an intracellular model | ||
intracellular_folder = assembleIntracellular!(cell_type_to_component; name="toy_metabolic") # will return "toy_metabolic" or "toy_metabolic_n" | ||
``` | ||
|
||
This creates a folder at `data/inputs/intracellulars/` with the name stored in `intracellular_folder`. | ||
Also, the `!` in `assembleIntracellular!` references how the components in the `cell_type_to_component` `Dict` are updated to match those in `data/inputs/intracellulars/$(intracellular_folder)/intracellular.xml`. | ||
Use these IDs to make variations on the components by using | ||
|
||
```julia | ||
xml_path = ["intracellulars", "intracellular:ID:$(component.id)", ...] | ||
``` | ||
|
||
where the `...` is the path starting with the root of the XML file (`sbml` for SBML files). | ||
|
||
Finally, pass this folder into `InputFolders` to use this input in simulation runs: | ||
```julia | ||
inputs = InputFolders(...; ..., intracellular=intracellular_folder, ...) | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.