Core
Core functionality for PhysiCellModelManager.jl.
Public API
PhysiCellModelManager.getMonadIDs
— MethodgetMonadIDs()
Return a vector of all monad IDs in the database.
Alternate forms take a monad, sampling, or trial object (or an array of any combination of them) and return the corresponding monad IDs.
Examples
getMonadIDs() # all monad IDs in the database
getMonadIDs(monad) # just a vector with the monad ID, i.e. [monad.id]
getMonadIDs(sampling) # all monad IDs in a sampling
getMonadIDs(trial) # all monad IDs in a trial
getMonadIDs([trial1, trial2]) # all monad IDs between trial1 and trial2
PhysiCellModelManager.getSimulationIDs
— MethodgetSimulationIDs(args...)
Deprecated alias for simulationIDs
. Use simulationIDs
instead.
PhysiCellModelManager.initializeModelManager
— MethodinitializeModelManager()
initializeModelManager(path_to_project_dir::AbstractString)
initializeModelManager(path_to_physicell::AbstractString, path_to_data::AbstractString)
Initialize the PhysiCellModelManager.jl project model manager, identifying the data folder, PhysiCell folder, and loading the central database.
If no arguments are provided, it assumes that the PhysiCell and data directories are in the current working directory.
Arguments
path_to_project_dir::AbstractString
: Path to the project directory as either an absolute or relative path. This folder must contain thePhysiCell
anddata
directories.path_to_physicell::AbstractString
: Path to the PhysiCell directory as either an absolute or relative path.path_to_data::AbstractString
: Path to the data directory as either an absolute or relative path.
PhysiCellModelManager.setNumberOfParallelSims
— MethodsetNumberOfParallelSims(n::Int)
Set the maximum number of parallel simulations to n
.
PhysiCellModelManager.simulationIDs
— MethodsimulationIDs()
Return a vector of all simulation IDs in the database.
Alternate forms take a simulation, monad, sampling, or trial object (or an array of any combination of them) and return the corresponding simulation IDs.
Examples
simulationIDs() # all simulation IDs in the database
simulationIDs(simulation) # just a vector with the simulation ID, i.e. [simulation.id]
simulationIDs(monad) # all simulation IDs in a monad
simulationIDs(sampling) # all simulation IDs in a sampling
simulationIDs(trial) # all simulation IDs in a trial
simulationIDs([trial1, trial2]) # all simulation IDs between trial1 and trial2
Private API
PhysiCellModelManager.baseToExecutable
— FunctionbaseToExecutable(s::String)
Convert a string to an executable name based on the operating system. If the operating system is Windows, append ".exe" to the string.
PhysiCellModelManager.constituentsType
— MethodconstituentsType(T::Type{<:AbstractTrial})
constituentsType(T::AbstractTrial)
Return the type of the constituents of T
. Used in the readConstituentIDs
function.
PhysiCellModelManager.constituentsTypeFilename
— MethodconstituentsTypeFilename(T::Type{<:AbstractTrial})
constituentsTypeFilename(T::AbstractTrial)
Return the filename of the constituents of T
. Used in the readConstituentIDs
function.
PhysiCellModelManager.lowerClassString
— MethodlowerClassString(T::AbstractTrial)
lowerClassString(T::Type{<:AbstractTrial})
Return the lowercase string representation of the type of T
, excluding the module name. Without this, it may return, e.g., Main.PhysiCellModelManager.Sampling.
Examples
lowerClassString(Simulation) # "simulation"
lowerClassString(Simulation(1)) # "simulation"
PhysiCellModelManager.pcmmLogo
— MethodpcmmLogo()
Return a string representation of the awesome PhysiCellModelManager.jl logo.
PhysiCellModelManager.readConstituentIDs
— MethodreadConstituentIDs(T::AbstractTrial)
Read a CSV file containing constituent IDs from T
and return them as a vector of integers.
For a trial, this is the sampling IDs. For a sampling, this is the monad IDs. For a monad, this is the simulation IDs.
Examples
ids = readConstituentIDs(Sampling(1)) # read the IDs of the monads in sampling 1
ids = readConstituentIDs(Sampling, 1) # identical to above but does not need to create the Sampling object
ids = readConstituentIDs(Monad, 1) # read the IDs of the simulations in monad 1
ids = readConstituentIDs(Trial, 1) # read the IDs of the samplings in trial 1
PhysiCellModelManager.samplingSimulationIDs
— MethodsamplingSimulationIDs(sampling_id::Int)
Internal function to get the simulation IDs for a given sampling ID. Users should use simulationIDs
instead.
PhysiCellModelManager.setMarchFlag
— MethodsetMarchFlag(flag::String)
Set the march flag to flag
. Used for compiling the PhysiCell code.
PhysiCellModelManager.trialFolder
— MethodtrialFolder(T::Type{<:AbstractTrial})
Return the path to the folder for the AbstractTrial
object, T
.
Examples
simulation = Simulation(1)
trialFolder(Simulation)
# output
"abs/path/to/data/outputs/simulations/1"
PhysiCellModelManager.trialFolder
— MethodtrialFolder(T::Type{<:AbstractTrial}, id::Int)
Return the path to the folder for a given subtype of AbstractTrial
and ID.
Examples
trialFolder(Simulation, 1)
# output
"abs/path/to/data/outputs/simulations/1"
PhysiCellModelManager.trialMonads
— MethodtrialMonads(trial_id::Int)
Internal function to get the monad IDs for a given trial ID. Users should use getMonadIDs
instead.
PhysiCellModelManager.trialSimulationIDs
— MethodtrialSimulationIDs(trial_id::Int)
Internal function to get the simulation IDs for a given trial ID. Users should use simulationIDs
instead.