Starting on a denoiser algorithm

Project Page Next project post Post History

I've been searching recently on ways to improve speed performance in render engines. When I started this project, that I wanted things to be as physically correct as possible. I was also thinking about efficiency, so long as it was correct. I'm still pursuing this agenda. However, the world isn't perfect, and neither are cameras. Cameras produce noise in their images, it's just apart of the capture cycle. Nothing is perfect.

It had me wondering then, if it was possible to add a sort of denoiser to the engine. I went digging and found a paper, which briefly mentioned a denoiser algorithm. I thought then, if a big production render engine is doing this, maybe I can as well.

Digging a little further, I found one that is meant to be similar to what they use in RenderMan. RenderMan is Pixar's render engine (as in Pixar Animation Studios - Finding Nemo etc.!). Their render engine is available to use in a number of software packages. Though I don't want to use RenderMan. As good as it is, it's not mine.

Looking a little further, I found an open source denoiser called IntelĀ® Open Image Denoise. I've read a little on it, though am deciding not to use it. While I'm sure it's very good, it's mostly because I'm trying to make everything my own. Which is kinda silly, given the abundance of open source material. But here I am. Doing my thing.

I scoured the net and found some examples that used an algorithm similar to the Pixar and Intel one. I then spent some time trying to manufacture it in my own way. And I've managed to get something working, sort of.

Let's start with a render. Below is an example render from Hyperion.

Hyperion render unfiltered (no denoising).

The render above is pretty low quality. And sorry about it being a little dark, I forgot to adjust the ISO! But what we do have is lots of noise. This is deliberate, because we're trying to minimise it's impact. It's also a way of seeing how much denoisers can be pushed. I'm afraid to say, my current algorithm doesn't go very far! Here's an example of the render above, as run through the denoiser:

The denoised Hyperion render. It's dark, blurry and difficult to see.

Well, it's doing something. Maybe it's OK for a first try? After all, it has denoised the image! It's also made it unusable.

I'm not sure what the issue is. Maybe it's a parameter I'm not understanding. Or it's searching too widely for information to denoise with. Or I'm simply starting with an image that's too noisey? In any case, it's something for me to play with.

What I'm really getting at here is: I want to know if I can reduce render times by using a denoiser on the image. My understanding, from my limited reading, is that they work best when used at the point of diminishing returns on the render passes. This may explain why my initial tests are so poor, maybe I do need to let it render a little further, and have a better quality image to begin with.

That said, I'm not terribly fussy about the engine being slow. I'd rather it was physically correct, than fast and cutting corners. But denoising is something that's used in photography and video editing frequently. So I don't see why I shouldn't experiment with it. Even if my code is naively and poorly conceived!!

Hopefully more on this in the future.