Skip to content

Commit

Permalink
File changes on NFsim issue
Browse files Browse the repository at this point in the history
  • Loading branch information
jrfaeder committed Feb 22, 2024
1 parent b12a011 commit f9e3464
Show file tree
Hide file tree
Showing 23 changed files with 2,169 additions and 0 deletions.
Binary file modified .DS_Store
Binary file not shown.
Binary file modified Issues/.DS_Store
Binary file not shown.
3 changes: 3 additions & 0 deletions Issues/nfsim_indrani/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
!*.gdat
!*.net
BioModel*
22 changes: 22 additions & 0 deletions Issues/nfsim_indrani/deleteMolecules.bngl
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
begin parameters
d 1
kdeg_Ste2_PO4 1
end parameters

begin molecule types
CELL()
Ste2(Pheromone_site,Gpa1_site,Sst2_site,Yck_site,S338_S339~none~PO4)
Pheromone(Ste2_site)
end molecule types

begin seed species
Pheromone(Ste2_site!1).Ste2(Pheromone_site!1,Gpa1_site,Sst2_site,Yck_site,S338_S339~PO4) 1
end seed species

begin reaction rules
# Ste2(S338_S339~PO4) -> CELL() kdeg_Ste2_PO4 DeleteMolecules
Ste2(S338_S339~PO4) -> CELL() 100 DeleteMolecules
end reaction rules

#writeModel({suffix=>"test",evaluate_expressions=>1})
generate_network({overwrite=>1})
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
begin parameters
d 1
kdeg_Ste2_PO4 1
end parameters

begin molecule types
CELL()
Ste2(Pheromone_site,Gpa1_site,Sst2_site,Yck_site,S338_S339~none~PO4)
Pheromone(Ste2_site)
end molecule types

begin seed species
Pheromone(Ste2_site!1).Ste2(Pheromone_site!1,Gpa1_site,Sst2_site,Yck_site,S338_S339~PO4) 1
end seed species

begin reaction rules
# Ste2(S338_S339~PO4) -> CELL() kdeg_Ste2_PO4 DeleteMolecules
Ste2(S338_S339~PO4) -> CELL() 100 DeleteMolecules
end reaction rules

writeModel({suffix=>"test",evaluate_expressions=>1})
generate_network({overwrite=>1})
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
begin parameters
d 1
kdeg_Ste2_PO4 1
end parameters

begin molecule types
CELL()
Ste2(Pheromone_site,Gpa1_site,Sst2_site,Yck_site,S338_S339~none~PO4)
Pheromone(Ste2_site)
end molecule types

begin seed species
Pheromone(Ste2_site!1).Ste2(Pheromone_site!1,Gpa1_site,Sst2_site,Yck_site,S338_S339~PO4) 1
end seed species

begin reaction rules
# Ste2(S338_S339~PO4) -> CELL() kdeg_Ste2_PO4 DeleteMolecules
Ste2(S338_S339~PO4) -> CELL() 100 DeleteMolecules
end reaction rules

writeModel({suffix=>"test",evaluate_expressions=>1})
generate_network({overwrite=>1})
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Created by BioNetGen 2.9.0
begin parameters
1 d 1 # Constant
2 kdeg_Ste2_PO4 1 # Constant
3 _rateLaw1 100 # Constant
end parameters
begin species
1 Pheromone(Ste2_site!1).Ste2(Gpa1_site,Pheromone_site!1,S338_S339~PO4,Sst2_site,Yck_site) 1
2 CELL() 0
3 Pheromone(Ste2_site) 0
end species
begin reactions
1 1 2,3 _rateLaw1 #_R1
end reactions
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Created by BioNetGen 2.9.0

begin model
begin parameters
d 1
kdeg_Ste2_PO4 1
_rateLaw1 100
end parameters
begin molecule types
CELL()
Pheromone(Ste2_site)
Ste2(Pheromone_site,Gpa1_site,Sst2_site,Yck_site,S338_S339~none~PO4)
end molecule types
begin species
Pheromone(Ste2_site!1).Ste2(Gpa1_site,Pheromone_site!1,S338_S339~PO4,Sst2_site,Yck_site) 1
end species
begin reaction rules
_R1: Ste2(S338_S339~PO4) -> CELL() _rateLaw1 DeleteMolecules
end reaction rules
end model
25 changes: 25 additions & 0 deletions Issues/nfsim_indrani/deleteMolecules_changed.bngl
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
begin model

begin parameters
d 1
kdeg_Ste2_PO4 1
_rateLaw1 100
end parameters

begin molecule types
CELL()
Pheromone(Ste2_site)
Ste2(Pheromone_site,Gpa1_site,Sst2_site,Yck_site,S338_S339~none~PO4)
end molecule types

begin species
Pheromone(Ste2_site!1).Ste2(Gpa1_site,Pheromone_site!1,S338_S339~PO4,Sst2_site,Yck_site) 1
end species

begin reaction rules
_R1: Ste2(S338_S339~PO4) -> CELL() _rateLaw1 DeleteMolecules
end reaction rules

end model

generate_network({overwrite=>1})
1,196 changes: 1,196 additions & 0 deletions Issues/nfsim_indrani/run_nf.ipynb

Large diffs are not rendered by default.

86 changes: 86 additions & 0 deletions Issues/nfsim_indrani/run_pybng.ipynb
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"metadata": {},
"outputs": [],
"source": [
"import bionetgen"
]
},
{
"cell_type": "code",
"execution_count": 34,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"\n",
"begin reaction rules\n",
" dZeta: Zeta() -> dead() kdl DeleteMolecules\n",
"end reaction rules\n",
"\n"
]
}
],
"source": [
"#mname=\"deleteMolecules\"\n",
"#mname=\"test_deleteMolecules\"\n",
"mname= \"test_deleteMolecules_simple\"\n",
"model= bionetgen.bngmodel(mname+\".bngl\")\n",
"#with open(mname+\"_pybng.bngl\", \"w\") as f:\n",
"# f.write(str(model)) # writes the changed model to new_model file\n",
"print(model.rules)\n",
"#ret = bionetgen.run(\"Model_ZAP70_SYK.bngl\", out=\"HPC\",suppress=False)"
]
},
{
"cell_type": "code",
"execution_count": 35,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"DeleteMolecules\n"
]
}
],
"source": [
"print(model.rules[model.rules[0]].rule_mod.type)"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "base",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.9.7"
}
},
"nbformat": 4,
"nbformat_minor": 2
}
8 changes: 8 additions & 0 deletions Issues/nfsim_indrani/run_pybng.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import bionetgen

#mname="deleteMolecules"
mname="test_deleteMolecules"
model= bionetgen.bngmodel(mname+".bngl")
#with open(mname+"_pybng.bngl", "w") as f:
# f.write(str(model)) # writes the changed model to new_model file
print(model.rules)
31 changes: 31 additions & 0 deletions Issues/nfsim_indrani/test_deleteMolecules.bngl
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
begin model



begin parameters
kdl 0.03 #CBL degrades ZAP/SYK
end parameters

begin molecule types
A(State~UZAP~PZAP~SHP~uSYK~pSYK,CBL)
Zeta(receptor,ITAM1~U~PP,ITAM2~U~PP,ITAM3~U~PP,ITAM4~U~PP,ITAM5~U~PP,ITAM6~U~PP)
CBL(site)
dead()
end molecule types

begin seed species
A(State~UZAP,CBL) 1
Zeta(receptor,ITAM1~U,ITAM2~U,ITAM3~U,ITAM4~U,ITAM5~U,ITAM6~U) 1
CBL(site) 1
end seed species

begin reaction rules
CBL_degrade_ITAM1: Zeta(ITAM1!1).A(State!1,CBL!3).CBL(site!3) -> dead() kdl DeleteMolecules
end reaction rules

end model

writeModel({suffix=>"changed",evaluate_expressions=>1,overwrite=>1})
writeXML()
#simulate_nf({t_end=>270,n_steps=>1000})

Loading

0 comments on commit f9e3464

Please sign in to comment.