First time here? Checkout the FAQ!
x
0 votes
ago by (350 points)
Not sure if this should be a bug report or just a question. I would love to know if there already exists a way around this problem I am having.

I can successfully use the prepacing_lats and associated options to initilize a simulation from a set of prescribed activation times. However, if I do so in a mesh that uses 1) the monodomain and 2) gregions that prescribe some tissue as scar (modeled as extracellular bath and therefore removed from the intracellular grid) I run into indexing issues. Specifically here is my pipeline:

1) Have a generated model
2) Generate a set of prescribed activation times across this model. These activation times are defined across every node of the model.
3) pass the model and activation times to openCARP as well as, on occasion, a retagfile to dynamically change some of the elements to scar tissue. openCARP will then generate an intracellular domain grid (which does not include the scar elements). This present a problem because now the activation times, which were defined on the whole mesh, no longer match up. This leads to an incorrect LAT-based initilization (it still proceeds but with a garbage activation sequence).

The preferred behavior would be for the provided prepacing_lats to be atuomatically clipped by the same process that generates the intracellular grid. I could of course generate the LAT map myself based on what will be the at runtime intracellular grid, but this is clunky especially if I have a combination of pre-defined scar elements and dynamic retagging of scar elements. It seems like openCARP should be able to do this as it already handles re-formatting all of the other node indicies for things like pacing sites, element tags, etc, to match the simulation grid even when they are input and defined in the context of the full mesh.

For context here is an example of what a job call would look like. The $runScript is just a simple carputils tools.carpexample job that parses my inputs and sets up the openCARP call with formatting for things like simulation time and setting up the dynamic retagging. In this case assume the tag 999 corresponds to scar tissue and that the mesh may or may not already have some scar tissue in it.

python3 -u $runScipt \
    --np $SLURM_NTASKS \
    --ParFile $parFile \
    --planFile $planFile\
    --build $build\
    --mesh $mesh \
    --outdir $outdir\
    --ID $outdir\
    --overwrite-behaviour "overwrite" \
    --CARP-opts "-gridout_i 2"\
    --CARP-opts "-prepacing_lats $prepaceFile"\
    --CARP-opts "-prepacing_beats 2"\
    --CARP-opts "-prepacing_bcl 250"\
    --addedTime 1000\
    --numStims 0\
    --RetagFile $retagFile\
    --ReTagVal 999\

Please log in or register to answer this question.

Welcome to openCARP Q&A. Ask questions and receive answers from other members of the community. For best support, please use appropriate TAGS!
architecture, carputils, documentation, experiments, installation-containers-packages, limpet, slimfem, website, governance
...