Skip to content

Commit

Permalink
udpated cancer biorobots
Browse files Browse the repository at this point in the history
  • Loading branch information
MathCancer committed Feb 22, 2023
1 parent e0ba190 commit 7e17661
Show file tree
Hide file tree
Showing 34 changed files with 5,885 additions and 406 deletions.
4 changes: 4 additions & 0 deletions ALL_CITATIONS.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Using PhysiCell version 1.10.4
Please cite DOI: 10.1371/journal.pcbi.1005991
Project website: http://PhysiCell.MathCancer.org

210 changes: 26 additions & 184 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,17 @@ endif
ARCH := native # best auto-tuning
# ARCH := core2 # a reasonably safe default for most CPUs since 2007
# ARCH := corei7
# ARCH := corei7-avx # earlier i7
# ARCH := core-avx-i # i7 ivy bridge or newer
# ARCH := core-avx2 # i7 with Haswell or newer
# ARCH := nehalem
# ARCH := westmere
# ARCH := sandybridge # circa 2011
# ARCH := ivybridge # circa 2012
# ARCH := haswell # circa 2013
# ARCH := broadwell # circa 2014
# ARCH := skylake # circa 2015
# ARCH := bonnell
# ARCH := silvermont
# ARCH := skylake-avx512
# ARCH := nocona #64-bit pentium 4 or later
Expand Down Expand Up @@ -49,194 +58,24 @@ PhysiCell_pugixml.o PhysiCell_settings.o PhysiCell_geometry.o

# put your custom objects here (they should be in the custom_modules directory)

PhysiCell_custom_module_OBJECTS := .o
PhysiCell_custom_module_OBJECTS := custom.o

pugixml_OBJECTS := pugixml.o

PhysiCell_OBJECTS := $(BioFVM_OBJECTS) $(pugixml_OBJECTS) $(PhysiCell_core_OBJECTS) $(PhysiCell_module_OBJECTS)
ALL_OBJECTS := $(PhysiCell_OBJECTS) $(PhysiCell_custom_module_OBJECTS)

EXAMPLES := ./examples/PhysiCell_test_mechanics_1.cpp ./examples/PhysiCell_test_mechanics_2.cpp \
./examples/PhysiCell_test_DCIS.cpp ./examples/PhysiCell_test_HDS.cpp \
./examples/PhysiCell_test_cell_cycle.cpp ./examples/PhysiCell_test_volume.cpp
# compile the project

all:
make heterogeneity-sample
make
all: main.cpp $(ALL_OBJECTS)
$(COMPILE_COMMAND) -o $(PROGRAM_NAME) $(ALL_OBJECTS) main.cpp
make name

name:
@echo ""
@echo "Executable name is" $(PROGRAM_NAME)
@echo ""

# sample projects
list-projects:
@echo "Sample projects: template biorobots-sample cancer-biorobots-sample cancer-immune-sample"
@echo " celltypes3-sample heterogeneity-sample pred-prey-farmer virus-macrophage-sample"
@echo " worm-sample interaction-sample"
@echo ""
@echo "Sample intracellular projects: ode-energy-sample physiboss-cell-lines-sample cancer-metabolism-sample"
@echo ""

template:
cp ./sample_projects/template/custom_modules/* ./custom_modules/
touch main.cpp && cp main.cpp main-backup.cpp
cp ./sample_projects/template/main.cpp ./main.cpp
cp Makefile Makefile-backup
cp ./sample_projects/template/Makefile .
cp ./config/PhysiCell_settings.xml ./config/PhysiCell_settings-backup.xml
cp ./sample_projects/template/config/* ./config/

# sample projects

# ---- non-intracellular projects
biorobots-sample:
cp ./sample_projects/biorobots/custom_modules/* ./custom_modules/
touch main.cpp && cp main.cpp main-backup.cpp
cp ./sample_projects/biorobots/main.cpp ./main.cpp
cp Makefile Makefile-backup
cp ./sample_projects/biorobots/Makefile .
cp ./config/PhysiCell_settings.xml ./config/PhysiCell_settings-backup.xml
cp ./sample_projects/biorobots/config/* ./config/

cancer-biorobots-sample:
cp ./sample_projects/cancer_biorobots/custom_modules/* ./custom_modules/
touch main.cpp && cp main.cpp main-backup.cpp
cp ./sample_projects/cancer_biorobots/main-cancer_biorobots.cpp ./main.cpp
cp Makefile Makefile-backup
cp ./sample_projects/cancer_biorobots/Makefile .
cp ./config/PhysiCell_settings.xml ./config/PhysiCell_settings-backup.xml
cp ./sample_projects/cancer_biorobots/config/* ./config/

cancer-immune-sample:
cp ./sample_projects/cancer_immune/custom_modules/* ./custom_modules/
touch main.cpp && cp main.cpp main-backup.cpp
cp ./sample_projects/cancer_immune/main-cancer_immune_3D.cpp ./main.cpp
cp Makefile Makefile-backup
cp ./sample_projects/cancer_immune/Makefile .
cp ./config/PhysiCell_settings.xml ./config/PhysiCell_settings-backup.xml
cp ./sample_projects/cancer_immune/config/* ./config/

celltypes3-sample:
cp ./sample_projects/celltypes3/custom_modules/* ./custom_modules/
touch main.cpp && cp main.cpp main-backup.cpp
cp ./sample_projects/celltypes3/main.cpp ./main.cpp
cp Makefile Makefile-backup
cp ./sample_projects/celltypes3/Makefile .
cp ./config/PhysiCell_settings.xml ./config/PhysiCell_settings-backup.xml
cp ./sample_projects/celltypes3/config/* ./config/

heterogeneity-sample:
cp ./sample_projects/heterogeneity/custom_modules/* ./custom_modules/
touch main.cpp && cp main.cpp main-backup.cpp
cp ./sample_projects/heterogeneity/main.cpp ./main.cpp
cp Makefile Makefile-backup
cp ./sample_projects/heterogeneity/Makefile .
cp ./config/PhysiCell_settings.xml ./config/PhysiCell_settings-backup.xml
cp ./sample_projects/heterogeneity/config/* ./config/

pred-prey-farmer:
cp ./sample_projects/pred_prey_farmer/custom_modules/* ./custom_modules/
touch main.cpp && cp main.cpp main-backup.cpp
cp ./sample_projects/pred_prey_farmer/main.cpp ./main.cpp
cp Makefile Makefile-backup
cp ./sample_projects/pred_prey_farmer/Makefile .
cp ./config/PhysiCell_settings.xml ./config/PhysiCell_settings-backup.xml
cp ./sample_projects/pred_prey_farmer/config/* ./config/

virus-macrophage-sample:
cp ./sample_projects/virus_macrophage/custom_modules/* ./custom_modules/
touch main.cpp && cp main.cpp main-backup.cpp
cp ./sample_projects/virus_macrophage/main.cpp ./main.cpp
cp Makefile Makefile-backup
cp ./sample_projects/virus_macrophage/Makefile .
cp ./config/PhysiCell_settings.xml ./config/PhysiCell_settings-backup.xml
cp ./sample_projects/virus_macrophage/config/* ./config/

worm-sample:
cp ./sample_projects/worm/custom_modules/* ./custom_modules/
touch main.cpp && cp main.cpp main-backup.cpp
cp ./sample_projects/worm/main.cpp ./main.cpp
cp Makefile Makefile-backup
cp ./sample_projects/worm/Makefile .
cp ./config/PhysiCell_settings.xml ./config/PhysiCell_settings-backup.xml
cp ./sample_projects/worm/config/* ./config/

interaction-sample:
cp ./sample_projects/interactions/custom_modules/* ./custom_modules/
touch main.cpp && cp main.cpp main-backup.cpp
cp ./sample_projects/interactions/main.cpp ./main.cpp
cp Makefile Makefile-backup
cp ./sample_projects/interactions/Makefile .
cp ./config/PhysiCell_settings.xml ./config/PhysiCell_settings-backup.xml
cp ./sample_projects/interactions/config/* ./config/

# ---- intracellular projects
ode-energy-sample:
cp ./sample_projects_intracellular/ode/ode_energy/custom_modules/* ./custom_modules/
touch main.cpp && cp main.cpp main-backup.cpp
cp ./sample_projects_intracellular/ode/ode_energy/main.cpp ./main.cpp
cp Makefile Makefile-backup
cp ./sample_projects_intracellular/ode/ode_energy/Makefile .
cp ./config/PhysiCell_settings.xml ./config/PhysiCell_settings-backup.xml
cp ./sample_projects_intracellular/ode/ode_energy/config/* ./config/

physiboss-cell-lines-sample:
cp ./sample_projects_intracellular/boolean/physiboss_cell_lines/custom_modules/* ./custom_modules/
touch main.cpp && cp main.cpp main-backup.cpp
cp ./sample_projects_intracellular/boolean/physiboss_cell_lines/main.cpp ./main.cpp
cp Makefile Makefile-backup
cp ./sample_projects_intracellular/boolean/physiboss_cell_lines/Makefile .
cp ./config/PhysiCell_settings.xml ./config/PhysiCell_settings-backup.xml
cp ./sample_projects_intracellular/boolean/physiboss_cell_lines/config/* ./config/

ecoli-acetic-switch-sample:
cp ./sample_projects_intracellular/fba/ecoli_acetic_switch/custom_modules/* ./custom_modules/
touch main.cpp && cp main.cpp main-backup.cpp
cp ./sample_projects_intracellular/fba/ecoli_acetic_switch/main_ecoli_acetic_switch.cpp ./main.cpp
cp Makefile Makefile-backup
cp ./sample_projects_intracellular/fba/ecoli_acetic_switch/Makefile ./
cp ./config/PhysiCell_settings.xml ./config/PhysiCell_settings-backup.xml
cp ./sample_projects_intracellular/fba/ecoli_acetic_switch/config/* ./config/

cancer-metabolism-sample:
cp ./sample_projects_intracellular/fba/cancer_metabolism/custom_modules/* ./custom_modules/
touch main.cpp && cp main.cpp main-backup.cpp
cp ./sample_projects_intracellular/fba/cancer_metabolism/main.cpp ./main.cpp
cp Makefile Makefile-backup
cp ./sample_projects_intracellular/fba/cancer_metabolism/Makefile ./
cp ./config/PhysiCell_settings.xml ./config/PhysiCell_settings-backup.xml
cp ./sample_projects_intracellular/fba/cancer_metabolism/config/* ./config/


# early examples for convergence testing

physicell_test_mech1: $(PhysiCell_OBJECTS) ./examples/PhysiCell_test_mechanics_1.cpp
$(COMPILE_COMMAND) -o test_mech1 $(PhysiCell_OBJECTS) ./examples/PhysiCell_test_mechanics_1.cpp

physicell_test_mech2: $(PhysiCell_OBJECTS) ./examples/PhysiCell_test_mechanics_2.cpp
$(COMPILE_COMMAND) -o test_mech2 $(PhysiCell_OBJECTS) ./examples/PhysiCell_test_mechanics_2.cpp

physicell_test_DCIS: $(PhysiCell_OBJECTS) ./examples/PhysiCell_test_DCIS.cpp
$(COMPILE_COMMAND) -o test_DCIS $(PhysiCell_OBJECTS) ./examples/PhysiCell_test_DCIS.cpp

physicell_test_HDS: $(PhysiCell_OBJECTS) ./examples/PhysiCell_test_HDS.cpp
$(COMPILE_COMMAND) -o test_HDS $(PhysiCell_OBJECTS) ./examples/PhysiCell_test_HDS.cpp

physicell_test_cell_cycle: $(PhysiCell_OBJECTS) ./examples/PhysiCell_test_cell_cycle.cpp
$(COMPILE_COMMAND) -o test_cycle $(PhysiCell_OBJECTS) ./examples/PhysiCell_test_cell_cycle.cpp

PhysiCell_test_volume: $(PhysiCell_OBJECTS) ./examples/PhysiCell_test_volume.cpp
$(COMPILE_COMMAND) -o test_volume $(PhysiCell_OBJECTS) ./examples/PhysiCell_test_volume.cpp

examples: $(PhysiCell_OBJECTS)
$(COMPILE_COMMAND) -o ./examples/test_mech1 ./examples/PhysiCell_test_mechanics_1.cpp $(PhysiCell_OBJECTS)
$(COMPILE_COMMAND) -o ./examples/test_mech2 ./examples/PhysiCell_test_mechanics_2.cpp $(PhysiCell_OBJECTS)
$(COMPILE_COMMAND) -o ./examples/test_DCIS ./examples/PhysiCell_test_DCIS.cpp $(PhysiCell_OBJECTS)
$(COMPILE_COMMAND) -o ./examples/test_HDS ./examples/PhysiCell_test_HDS.cpp $(PhysiCell_OBJECTS)
$(COMPILE_COMMAND) -o ./examples/test_cycle ./examples/PhysiCell_test_cell_cycle.cpp $(PhysiCell_OBJECTS)
$(COMPILE_COMMAND) -o ./examples/test_volume ./examples/PhysiCell_test_volume.cpp $(PhysiCell_OBJECTS)

# PhysiCell core components

PhysiCell_phenotype.o: ./core/PhysiCell_phenotype.cpp
Expand Down Expand Up @@ -311,25 +150,28 @@ PhysiCell_MultiCellDS.o: ./modules/PhysiCell_MultiCellDS.cpp

PhysiCell_various_outputs.o: ./modules/PhysiCell_various_outputs.cpp
$(COMPILE_COMMAND) -c ./modules/PhysiCell_various_outputs.cpp

PhysiCell_pugixml.o: ./modules/PhysiCell_pugixml.cpp
$(COMPILE_COMMAND) -c ./modules/PhysiCell_pugixml.cpp

PhysiCell_settings.o: ./modules/PhysiCell_settings.cpp
$(COMPILE_COMMAND) -c ./modules/PhysiCell_settings.cpp
$(COMPILE_COMMAND) -c ./modules/PhysiCell_settings.cpp

PhysiCell_basic_signaling.o: ./core/PhysiCell_basic_signaling.cpp
$(COMPILE_COMMAND) -c ./core/PhysiCell_basic_signaling.cpp

$(COMPILE_COMMAND) -c ./core/PhysiCell_basic_signaling.cpp
PhysiCell_geometry.o: ./modules/PhysiCell_geometry.cpp
$(COMPILE_COMMAND) -c ./modules/PhysiCell_geometry.cpp

# user-defined PhysiCell modules

custom.o: ./custom_modules/custom.cpp
$(COMPILE_COMMAND) -c ./custom_modules/custom.cpp

# cleanup

reset:
rm -f *.cpp PhysiCell_cell.o
rm -f *.cpp
cp ./sample_projects/Makefile-default Makefile
rm -f ./custom_modules/*
touch ./custom_modules/empty.txt
Expand All @@ -338,7 +180,7 @@ reset:
rm ALL_CITATIONS.txt
cp ./config/PhysiCell_settings-backup.xml ./config/PhysiCell_settings.xml
touch ./config/empty.csv
rm ./config/*.csv
rm -f ./config/*.csv

clean:
rm -f *.o
Expand All @@ -348,9 +190,9 @@ data-cleanup:
rm -rf ./output
mkdir ./output
touch ./output/empty.txt

# archival

checkpoint:
zip -r $$(date +%b_%d_%Y_%H%M).zip Makefile *.cpp *.h config/*.xml custom_modules/*

Expand Down
Loading

0 comments on commit 7e17661

Please sign in to comment.