YueJiang-nj / CVPR2020-SDFDiff

SDFDiff: Differentiable Rendering of Signed Distance Fields for 3D Shape Optimization
275 stars 19 forks source link

Questions about your paper #6

Open skmhrk1209 opened 3 years ago

skmhrk1209 commented 3 years ago

Hi @YueJiang-nj , thank you for sharing the code of your nice work. I have a question about your approximation of an intersection point.

In my understanding, the core idea of your paper is that for computing an intersection point, constructing the computation graph through all the ray marching iterations is not needed . So, you approximate the intersection point using trilinear interpolation between the eight local samples.

Is a simple approximation of an intersection point like p=s+SDF(s)v problematic? Why did you use the eight local samples some of which are not on the ray?

The notation follows your paper.

Thank you.

YueJiang-nj commented 3 years ago
  1. Is a simple approximation of an intersection point like p=s+SDF(s)v problematic?

SDF(s) is the closest distance to the object. But for intersection, we want to find the intersection point on the ray. For example, if your current position has distance 1 cm to the surface, but you are parallel to the closest surface which is not along the ray. Then SDF(s) = 1 cm, but moving 1 cm along the ray will not let you reach the surface.

  1. Why did you use the eight local samples some of which are not on the ray?

That's because we are using voxel-based SDF grid. So only the grid point values are known. For each point in the grid but is not exactly the grid point, the value can only be known by being trilinear interpolated from the surrounded grid point values. i.e., the 8 grid points around it on the little cube the point is in.

skmhrk1209 commented 3 years ago
  1. I mean,
    
    # --- ray marching ---

maybe the same as "renderer_kernel.cu"

with torch.no_grad(): while not converged: p += SDF(p) * v

make only the last step differentiable

with torch.enable_grad(): p += SDF(p) * v


But I think this is impossible when using voxel-based SDF.

2. I had forgotten your network output is discrete SDF voxel. I got it now.

Thank you.
YueJiang-nj commented 3 years ago

I think it is the same as what I did. We are also using: while not converged: p += SDF(p) * v

lishixuan001 commented 2 years ago

Hi Yue,

Can the result be directly loaded into Autodesk 3D to reduce the work of 3D modeling? Or at least is it possible (in a validated way) for any other related works?