Hacker News new | past | comments | ask | show | jobs | submit login
Variations on symmetric nearest neighbour smoothing (observablehq.com)
92 points by jashkenas on Jan 19, 2020 | hide | past | favorite | 12 comments



After some googling this kind of looks like "inverse distance weighted interpolation." Is that at all similar? Seems well trodden ground

https://pro.arcgis.com/en/pro-app/help/analysis/geostatistic...

https://en.wikipedia.org/wiki/Inverse_distance_weighting


This is a neat article with some good experimentation, but... This is essentially someone seeing the precursor to the bilateral filter for the first time without ever having heard of a bilateral filter before.

A bilateral filter weights surrounding pixels by how close in value they are. This ends up creating a smoothing effect from soft clustering. Take a look at the 'rolling guidance filter' for an effect when used iteratively.


Really simple filters can yield very impressive results on images.

This makes me think of deep learning "style transfer" effects. They're nice but so are artistic filters that long predate these things and are tremendously simpler.


> They're nice but so are artistic filters that long predate these things and are tremendously simpler.

CNN are also tremendously simple. They just iterate many filters, but each one of them is much simpler than the bilateral filter.


Everything a computer does is simple if you are reductionist about it


It seems to create aliasing artefacts at edges. I wonder if this can be suppressed by scaling up the image and the filter radius and then scaling back down?


Look up bilateral filters and the various papers related to minimizing sharp segmentation.


Indeed, a bilateral filter is this approach of selection but segmenting on signal statistics of the surrounding image rather than just value. (Usually variance for denoising, contrast for non-blocking sharpening, L2 metric like PSNR for deblocking, luminance for chroma artifact reduction after upscaling.)


Can you link some papers that take about this? Segmenting on statistics isn't typical in the many papers I've read.


I implemented this in ShaderToy if anyone wants to see it run in real-time:

https://www.shadertoy.com/view/WlGGzt


Fascinating. Couldn't help but think that the result looks a lot like some recent game shaders, for grass and landscape, like seen in the witness. Maybe Jonathan can chime in.


I was just thinking, "this would be a great screen-space shader effect". It's at once both painterly and pixelly.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: