Runner

Run simulations, monads, samplings, and trials in the PhysiCellModelManager.jl framework.

Public API

Base.runMethod
run(T::AbstractTrial[; force_recompile::Bool=false, prune_options::PruneOptions=PruneOptions()])`

Run the given simulation, monad, sampling, or trial.

Call the appropriate functions to run the simulations and return the number of successful simulations. Also print out messages to the console to inform the user about the progress and results of the simulations.

Arguments

  • T::AbstractTrial: The trial, sampling, monad, or simulation to run.
  • force_recompile::Bool=false: If true, forces a recompilation of all files by removing all .o files in the PhysiCell directory.
  • prune_options::PruneOptions=PruneOptions(): Options for pruning simulations.
source
PhysiCellModelManager.runAbstractTrialMethod
runAbstractTrial(T::AbstractTrial; force_recompile::Bool=false, prune_options::PruneOptions=PruneOptions())

Deprecated alias for run, but only with this particular signature. Does not work on Cmd objects as Base.run is built for. Also, does not work with running sensitivity samplings.

source

Private API

PhysiCellModelManager.PCMMOutputType
PCMMOutput{T<:AbstractTrial}

A struct to hold the output of the PhysiCellModelManager.jl run, including the AbstractTrial object, the number of scheduled simulations, and the number of successful simulations.

Fields

  • trial::T: The trial, sampling, monad, or simulation that was run.
  • n_scheduled::Int: The number of simulations that were scheduled to run.
  • n_success::Int: The number of simulations that were successfully completed.
source
PhysiCellModelManager.SimulationProcessType
SimulationProcess

A struct to hold the simulation process and its associated monad ID. Users should not need to interact with this struct directly.

Fields

  • simulation::Simulation: The simulation object.
  • monad_id::Int: The ID of the associated monad.
  • process::Union{Nothing,Base.Process}: The process associated with the simulation. If the simulation process fails, e.g. if the command cannot be constructed, this will be nothing.
source
PhysiCellModelManager.collectSimulationTasksMethod
collectSimulationTasks(T::AbstractTrial[; force_recompile::Bool=false])

Collect the simulation tasks for the given trial, sampling, monad, or simulation.

Arguments

  • T::AbstractTrial: The trial, sampling, monad, or simulation to collect tasks for.

Keyword Arguments

  • force_recompile::Bool=false: If true, forces a recompilation of all files by removing all .o files in the PhysiCell directory.
  • do_full_setup::Bool=true: If true, performs a full setup of the simulation, including compiling code and preparing input files. Only used for AbstractMonad objects.
source
PhysiCellModelManager.prepareHPCCommandMethod
prepareHPCCommand(cmd::Cmd, simulation_id::Int)

Prepare the command to run a simulation on an HPC system using sbatch. This function adds the necessary flags to the command and returns it as a Cmd object.

source
PhysiCellModelManager.prepareSimulationCommandMethod
prepareSimulationCommand(simulation::Simulation, monad_id::Int, do_full_setup::Bool, force_recompile::Bool)

Internal function to prepare the command to run a simulation, including preparing input files and compiling the custom code if necessary.

source
PhysiCellModelManager.resolveSimulationMethod
resolveSimulation(simulation_process::SimulationProcess, prune_options::PruneOptions)

Resolve the simulation process by checking its exit code and updating the database accordingly.

source
PhysiCellModelManager.simulationFailedToRunMethod
simulationFailedToRun(simulation::Simulation, monad_id::Int)

Set the status code of the simulation to "Failed" and erase the simulation ID from the simulations.csv file for the monad it belongs to.

source