Hi Qianqian,
I hope this message finds you well. I'm having an issue converting a multi-level brain MRI volume to a mesh. The volume is a 256x256x256 array, with the levels
hi Melissa,
the quickest way to get a mesh from a multi-labeled volume is to call v2m with the cgalmesh option. please run this example script
https://github.com/fangq/iso2mesh/blob/master/sample/demo_cgalmesher.m#L17
the advantage of this approach is that cgal 3d mesher is very robust and fast. The output mesh are correctly labeled with the matching volume segmentation labels. We also provides multiple options to control the density of each region, see another example
https://github.com/fangq/iso2mesh/blob/master/sample/demo_label_sizing.m
while I am aware that the CGAL team has been continuously improving this direct volumetric meshing method, the output mesh from this embedded cgalmesher in iso2mesh has shown various imperfections, especially when compared to a surface-based meshing pipeline
as described in our brain2mesh paper, as highlighted in the Fig. 5 and the last paragraph of Section 3.1 of this paper
this is not surprising because cgalmesher is not given any multi-layered topology of the brain tissues and can not apply surface-based smoothing to optimize the mesh.
if you want to try brain2mesh, you may first call label2tpm function to convert your input to a tissue probabilistic map (TPM) and then pass it to brain2mesh
https://github.com/fangq/brain2mesh/blob/master/label2tpm.m
https://github.com/fangq/brain2mesh
bain2mesh may not be as robust as cgalmesh, but after some manual tuning, the output mesh can be quite good.
Qianqian
5=white matter4=grey matter3=CSF2=skull1=scalp
Very similar to your Colin27 volume. Running the following code gives me only two layers of mesh:
opt=2;[node,elem,face]=vol2mesh(vol,1:size(vol,1),1:size(vol,2),1:size(vol,3),opt,100,1:5);
whereas running this code (below) gives me the necessary mesh layers, but I am unable to distinguish between them (i.e. there is no 5th dimension of elem) in order to input different optical properties for each layer into MMC:
[node,elem,regions,holes]=v2s(vol,1:5,2);
I have looked through all your examples in brain2mesh, iso2mesh, etc. but I am unable to figure out what is wrong with my code above. Would you be able to give me any feedback, or post your volume to mesh script for e.g. the Colin27 brain template?
Thank you so much! Any help would be appreciated.
Melissa
--
You received this message because you are subscribed to the Google Groups "mmc-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mmc-users+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/mmc-users/630bb475-7824-4642-bfa5-cfb64949b3dbn%40googlegroups.com.