ranahanocka / MeshCNN

Convolutional Neural Network for 3D meshes in PyTorch
MIT License
1.61k stars 320 forks source link

How to get final segmentation plots? #11

Closed fatemehteimury closed 5 years ago

fatemehteimury commented 5 years ago

Hi Rana, I really appreciate you for sharing such a nice code and your mesh pooling idea is really great. I used your segmentation code for my own dataset and I expected to get a vector that represents which edge belongs to which segment or final segmentation plot you provide in the Github.

Besides, what I get is in the checkpoints, human seg I get some obj files that shows how mesh-pool decimate faces (gray plots you provide in the Github which I can see through view.sh) I supposed these plots should be allocated to classification. It would be so nice if you help me to find my answer.

Best regards, Fatemeh

ranahanocka commented 5 years ago

Hi @fatemehteimury ,

Thanks for the kind words :+1:

Did you try running the example for segmentation? I just re-ran it, exactly as I wrote in the wiki:

bash ./scripts/human_seg/get_data.sh
bash ./scripts/human_seg/train.sh
bash ./scripts/human_seg/get_pretrained.sh
bash ./scripts/human_seg/test.sh
bash ./scripts/human_seg/view.sh

and when I run view.sh I get this image

Basically, what happened here, is when you run test.py, it calls the test method in mesh_classifier.py , which runs the forward pass on the network and then exports the segmentation IDs per edge by writing the lines out in the test .obj files (see this line).

So after you ran test, when you pass this .obj to the viewer, it will plot the predicted edge segmentation colors.

fatemehteimury commented 5 years ago

Dear Rana, Thanks for your kind response. Best regards, Fatemeh