Recent submissions

Comment · 3 years ago
Comment · 5 years ago
If you’re looking for some great content that is completely unrelated, I’d recommend either Keenan Crane’s Discrete Differential Geometry course (https://www.cs.cmu.edu/~kmcrane/Projects/DDG/ and https://brickisland.net/DDGSpring2021/) or Peter Shirley’s Ray Tracing in a Weekend Series (https://raytracing.github.io/). The former is a little more math heavy/in-depth, whereas the latter is a little more abbreviated. Both are super fun and expose you to some really exciting and powerful ideas from Computer Graphics.
Comment · 5 years ago
Thanks again for the insights here and in the other thread!

> In the implicit paradigm, it's not necessary to evaluate the smoke ahead of time since sphere tracing can reduce to marching adaptively when we are within smoke.

Makes sense. The SDF is separate from the density grid for the cloud/smoke. We need both, one to detect the boundary (SDF) and another to actually render the volume (density grid).

In offline rendering we usually just have some primitive (sphere, cube etc) that acts as the boundary but that obviously isn't as adaptive and doesn't let you easily reveal arbitrary slices of a volume.

Comment · 5 years ago
Thanks for the insights! I come from a mostly rendering background, so my understanding is definitely biased from always thinking of SDFs in the context of surface rendering or reconstruction :-)
Comment · 5 years ago
Comment · 5 years ago
> Meshes and bezier patches are boundary representations with no information of the volume they enclose

Pedantic on my part, but SDF is still just a surface/boundary representation at the end of the day. It may have additional benefits that you point out such as quickly computing if you're inside/outside or being able to more easily deform the shape (through any number of procedures including slicing), but you'd probably use a density grid instead of a SDF if you're dealing with anything volumetric, such as clouds or smoke.

> You don't. I didn't notice render times, but "interactive frame rates" would be lacking.

Yeah definitely, poor wording on my part.

> Most SDF primitives and their compositions are not analytic (from use of abs, fract, etc). Differentiation by finite differences is most common. Few are using automatic differentiation. I don't quite follow how back prop would produce the surface gradient, but I doubt it would be faster than these methods.

I don't think we're talking about the same thing, I'm not referring to the surface gradient when I say differentiable rendering.

Both differentiable rendering with an SDF (i.e. SDFDiff https://arxiv.org/pdf/1912.07109.pdf) and with a neural SDF(DIST http://b1ueber2y.me/projects/DIST-Renderer/) use automatic differentiation to compute the gradient of the rendering/image-generating process. Section 3.4 in the DIST paper discusses where back prop comes into all of this. Basically your surface is defined by the weights of some neural net (i.e. a neural SDF) and you need to know the gradient of your image with respect to those weights.

For a variety of reasons, these surface representations are easier to handle than triangle meshes which break certain desirable properties for differentiation and require extra care as a result (see edge sampling https://people.csail.mit.edu/tzumao/diffrt/ for an early example of the challenges of doing differentiable rendering with a triangle mesh).

Comment · 5 years ago
Meshes are actually extremely fast for querying distance to a surface. Even in scenes with lots of geometry, using an acceleration structure like a BVH can be extremely fast. You can even do ray tracing in real time on a GPU now (at least for direct lighting, certainly not for global illumination).

By contrast, SDFs require you to do lots of expensive lookups as you slowly march along a ray until you happen to bump into a surface.

Comment · 5 years ago
I don't think the point is compression, SDFs even when represented with a neural net have a much larger memory footprint and are significantly more expensive to render.

The main benefit of a SDF are that you don't have topological issues to worry about, which makes them great for reconstruction problems where a surface is evolving over time.

Comment · 5 years ago
I believe Occupancy Networks is using octrees for surface extraction (i.e. construct a voxel grid given your SDF). See figure 2 in the Occupancy Networks Paper.

On the other-hand, octrees are used in this paper to store variable resolution feature volumes (i.e. to improve the representation of the SDF). See figure 3 in Neural Geometric Detail Paper.

Comment · 5 years ago
My understanding of this paper (please comment/correct based on your understanding):

* Instead of using a single latent feature per each implicit surface, the authors propose using a "volume" of latent features per each surface. This allows for the NNs to better capture the geometric detail while remaining relatively shallow. The result is a more accurate and faster to compute neural SDF. Contrary to the claim of another comment, the neural SDF alone is not the interesting part of this paper--the prior works points to at least three other papers that have explored the idea of representing an SDF with a neural net: Park et al.'s DeepSDF https://arxiv.org/pdf/1901.05103.pdf, Mescheder et al's Occupancy Networks http://www.cvlibs.net/publications/Mescheder2019CVPR.pdf, and Chen et al's Learning Implicit Fields https://arxiv.org/pdf/1812.02822.pdf All very interesting papers.

* When I say a "volume" of latent features I specifically mean a voxel-grid where the corners of each voxel are latent features and any position X has a corresponding feature Z which is simply the trilinear interpolation of the features on the corners of the voxel. As the authors mention, they try to keep this sparse by leaving any voxel that does not contain the surface "empty".

The authors use an octree to create L different feature volumes. As L becomes larger, the resolution of the feature volume increases which means that more fine grained details can be encoded as features.

Finally, the authors describe a rendering procedure that makes use of their LOD model (still need to read this part more thoroughly).

Some additional thoughts:

Why are SDFs useful at all?

One comment suggests this is a form of "compression" but meshes have a far smaller memory footprint and are computationally less expensive to render. Ray tracing is extremely fast, largely due to the fact that as a primitive operation in graphics so much time and energy has been invested into understanding how to make it faster with various acceleration structures, like BVHs.

So are SDFs actually useful?

Yes. Triangle or polygon meshes are great when you have them, but are terribly challenging to work with for reconstruction tasks. For instance, you effectively have to pause occasionally during reconstruction to fix your mesh up so that it isn't complete garbage (triangles with small angles, self-intersections, extremely lopsided side lengths, etc). SDFs support arbitrary topology painlessly, which is why they show up so much in reconstruction/computer vision.

So why do we need neural nets to represent them?

I think the primary reason you use a neural network to represent a signed distance function is because it's a more efficient representation than storing the SDF in some sort of grid structure (maybe someone else has more thoughts on this?). As a side benefit, it can simplify any sort of differentiable rendering since the surface itself already is represented in a manner that is naturally differentiable via back-propagation.

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton