Stalling in MMCLAB based on source position

7 views
Skip to first unread message

Ife E

unread,
Apr 22, 2026, 7:21:55 AM (2 days ago) Apr 22
to mcx-users
Dear Prof. Fang,

We've been running into an interesting issue with MMCLAB v2025.10

We have been running simulations to generate ground truth data for DOT. Our maximum SDS is quite high (approx. 5 cm) so we have been simulating a large number of photons  (1e10). For these larger photon counts we have found MMCLAB is more likely to stall. 

Based on GPU usage (and the sound of my cooling fans!) it seems like the simulations finish or pause but don't pass back control to MATLAB so we need to restart the IDE. 

Initially we found shifting the offending source locations very slightly before resuming the simulation prevented this issue. As we repeat simulations for different optical properties different sources would begin to stall and we haven't found a correlation between them. Now we randomly set the shift direction of all the sources before simulating and have more success but every so often run into this issue.

All our generated meshes are verified with meshcheckrepair and we pass the cfg output from mmclab(cfg,'prep') to the simulation as well just in case. We also have cases to check that the source position does not overlap with any element vertices. Weirdly for our initial simulations at lower photon counts it seemed like this happened less frequently.

Not a critical issue for us at the moment but we thought it was interesting behaviour to highlight, and couldn't find any related problems on the forums.

All the best,
Ife


Reply all
Reply to author
Forward
0 new messages