Question on Voxel size definition

21 views
Skip to first unread message

Weizhe Fan

unread,
Mar 22, 2026, 6:51:36 PM (13 days ago) Mar 22
to mcx-users
Hi Dr. Fang,

Thank you for making such a powerful tool. I have a question below and would appreciate your help.

I'd like to simulate a very thin layer in MCX, so I first tried defining the voxel size as 0.02mm and see whether the simulation can run. I also change values the tissue region, detector, source and so on, to corresponding voxel unit. Then I ran the simulation, but got the error 'MCX ERROR(-1):invalid argument in unit mcx_core.cu:1981'. 

Can I ask is it because MCX does not support such small voxel size, or is it because there are just too many voxels in total (I have 3000^3=2.7e10)?

I have also attached my setting here. Thank you for your time!
屏幕截图 2026-03-22 163513.png屏幕截图 2026-03-22 163657.png

Regards,
Weizhe

Qianqian Fang

unread,
Mar 23, 2026, 5:45:43 PM (12 days ago) Mar 23
to mcx-...@googlegroups.com, Weizhe Fan

just for the purpose of storing the fluence output, mcx needs to allocates 8-byte per voxel per time gate. based on your domain size, you will need at least 54GB of memory for storing fluence alone, not mention other buffers needed for the simulation. 

the question is - does your GPU have 54GB of graphics memory? similarly, what is the size of your host/CPU memory?


please also read the following FAQ item for new mcx users


especially the section "Brute-force is never a good solution."


for the output memory requirements, please also read this section in the README



On 3/22/26 16:40, Weizhe Fan wrote:

You don't often get email from fweiz...@gmail.com. Learn why this is important

--
You received this message because you are subscribed to the Google Groups "mcx-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mcx-users+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/mcx-users/84074911-3375-44d5-b922-482f423c9cebn%40googlegroups.com.

Qianqian Fang

unread,
Mar 23, 2026, 5:48:31 PM (12 days ago) Mar 23
to mcx-...@googlegroups.com, Weizhe Fan

sorry, I miscalculated - you will need 216 GB GPU memory = 3000^3*8 bytes, which is not physically possible.

Weizhe Fan

unread,
Mar 23, 2026, 7:39:23 PM (12 days ago) Mar 23
to Qianqian Fang, mcx-...@googlegroups.com
Thank you for the information. I need to design my simulation in a better way.

Qianqian Fang <q.f...@neu.edu> 于2026年3月23日周一 17:48写道:
Reply all
Reply to author
Forward
0 new messages