nmwsharp / diffusion-net

Pytorch implementation of DiffusionNet for fast and robust learning on 3D surfaces like meshes or point clouds.
https://arxiv.org/abs/2012.00888
MIT License
398 stars 50 forks source link

DiffusionNet for Regression? #13

Open latmarat opened 2 years ago

latmarat commented 2 years ago

Hi, very interesting work! I am wondering if diffusion-net can be adapted for regression tasks, i.e. predicting scalars in triangles of a surface mesh? Thanks!

nmwsharp commented 2 years ago

Yes, for sure!

You can see an example of this here, predicting values on faces. https://github.com/nmwsharp/diffusion-net/blob/master/experiments/human_segmentation_original/human_segmentation_original.py#L69-L75.

You can pass outputs_at='faces' to construct a network which outputs a value per-face. You will also need to pass in the face listing (as an Fx3 array of integers) when you invoke the newtork.

To do regression (as opposed to e.g. classification/segmentation), you can just not use any last activation from the network to output values on R^n, by omitting the last_activation argument when you build the network (by default this sets last_activation=None).

mikkelmedm commented 1 year ago

Hi, thanks for this awesome work! So if I wanted to predict a plane with a specific location and a certain angle intersecting the input mesh, would the network be easily configurable for that task? I.e. a simlpe regression task of rotation and translation. Or is it bound to output values 'per-face' or 'per-vertices'? Thanks again :)