Denoise
The Denoise node is an efficient tool for removing noise or grain from your footage. It uses spatial or temporal filtering to remove noise without losing image quality.
Inputs and Controls
Connection Type |
Connection Name |
Function |
Input |
Motion |
An optional input for attaching pre-calculated motion vectors, such as those created by VectorGenerator. Denoise can generate motion vectors internally, but connecting this input may produce significantly faster results. |
Noise |
An optional input for attaching a separate noise file. If you’re working with complex footage that doesn’t have a convenient area for analyzing noise, you can use the Noise input to analyze noise from another image and apply the results to your footage. |
|
Source |
The image sequence to denoise. |
Control (UI) |
Knob (Scripting) |
Default Value |
Function |
Denoise Tab |
|||
Local GPU |
gpuName |
N/A |
Displays the GPU used for rendering when Use GPU if available is enabled. Local GPU displays Not available when: • Use CPU is selected as the default blink device in the Preferences. • no suitable GPU was found on your system. • it was not possible to create a context for processing on the selected GPU, such as when there is not enough free memory available on the GPU. You can select a different GPU, if available, by navigating to the Preferences and selecting an alternative from the default blink device dropdown. Note: Selecting a different GPU requires you to restart Nuke before the change takes effect. |
Use GPU if available |
useGPUIfAvailable |
enabled |
When enabled, rendering occurs on the Local GPU specified, if available, rather than the CPU. Note: Enabling this option with no local GPU allows the script to run on the GPU whenever the script is opened on a machine that does have a GPU available.
|
Source |
type |
Digital |
Choose Film or Digital according to what type of footage you’re working with. |
Noise Model |
model |
Modulated |
Choose what type of noise you’re dealing with: • Constant - try this if you’re working on film footage with lots of detail and not too much noise in dark regions, or digital footage with lots of detail and not too much noise in light regions. • Modulated - for most cases, this is a good option. |
Lift Blacks |
lift_blacks |
disabled |
When enabled, blacks in the image are lifted toward white. This can be particularly useful if your image contains a lot of sub-blacks, areas of black with a value less than 0. |
Profile |
profile |
Constant |
Choose the denoise profile to use: • Constant - let Denoise look at the analysis region and remove the same amount of noise across all intensities. Constant is nearly always a good choice, but if you find that your denoise results are too smooth and adjusting DenoiseAmount and RollOff doesn’t help, you should try setting this to Automatic. • Automatic - let Denoise estimate a noise profile automatically based on the entire ProfileFrame. This way, Denoise removes different amounts of noise from the shadow, midtone, and highlight areas of the Source image. When you first switch to automatic profiling, Denoise uses the current frame to calculate the profile. If you’d like to use a different frame, you need to set Profile Frame on the Profile tab to that frame and click the Recalculate Profile button. Denoise always bases the noise profile on your Source footage, even if you’ve attached another clip to the Noise input. You can use the TuneProfile controls to tweak both Constant and Automatic profiles. |
Output |
output |
Result |
Whether to output the denoised image or the noise that was removed: • Result - output the denoised Source image. • Noise - output the noise that was removed from the Source image. Only noise should be visible in this image. If you can see a lot of picture detail, it means the current settings are making Denoise work too hard and remove too much of the image, which leads to a soft result. |
Denoise Amount |
amount |
1 |
Sets the overall amount of noise to remove. Increase this to remove more noise, or decrease to keep more detail. A value of 0 removes no noise. |
Roll Off |
rolloff |
2 |
Sets the smoothness of the denoise thresholding. A value of 1 equals hard thresholding. Any other value produces soft thresholding between the Denoise Amount and the Roll Off multiplied by Denoise Amount. |
Smoothness |
smoothness |
1 |
Sets the smoothness of the denoised image. This affects the underlying image rather than the noise detected. In most cases, the default value of 1 works fine. However, you can try using this control if you’re not getting the correct smoothness level by adjusting the Denoise Amount. |
Luminance Blend |
lumablend |
0.7 |
Blends the denoised luminance with the image’s original luminance, bringing back some of the image detail in the result. You might want to have this set to 1 when you’re working on denoising the footage, but for the final result, you’ll want to decrease it. |
Preserve Edges |
preserve_edges |
disabled |
When enabled, Denoise attempts to sharpen the image at edges to prevent over-smoothing, though this can emphasize noise in some cases. |
Temporal Processing |
|||
Enable |
enable_temporal |
disabled |
When enabled, uses frames either side of the current frame to perform temporal frame blending, which may produce a better denoise result. Note: The Motion input must be connected to enable Temporal Processing. The number of frames used either side of the current frame is determined by the Temporal Frame Offset control. When disabled, uses only the current frame to produce the denoise result. |
Frame Blending |
frame_blending |
0.1 |
Sets the variance allowed between regions in blended frames. Higher values attempt to blend more regions, but can lose image detail. Note: This control is only available when Temporal Processing is enabled. |
Frames to Blend |
frames |
1 |
Sets the number of frames, on either side of the current frame, used to calculate the denoise effect. Note: This control is only available when Temporal Processing is enabled. |
Noise Analysis |
|||
Lock Noise Analysis |
lockNoiseAnalysis |
disabled |
When enabled, no analysis is performed. This is activated by default if you use the Import button to read a noise profile from an external file. |
Analysis Region |
analysisRegion |
N/A |
Enter the coordinates for the region from which you want to analyze noise. You can adjust the following: • x - the distance (in pixels) between the left edge of the image and the left side of the analysis box. • y - the distance (in pixels) between the bottom edge of the image and the bottom edge of the analysis box. • r - the distance (in pixels) between the left edge of the image and the right side of the analysis box. • t - the distance (in pixels) between the bottom edge of the image and the top edge of the analysis box. • w - the width of the analysis box. This is only available if you click the wh button. • h - the height of the analysis box. This is only available if you click the wh button. You can also use the analysis box in the Viewer to position the analysis region. This should be a flat area free from image detail, so no textures, edges, or shadows. The minimum size for the analysis region is 80x80 pixels. If the analysis region is too small, Denoise doesn’t analyze the footage or remove any noise. By default, whenever the analysis box is altered, the internal analysis of the noise in that region reoccurs. |
Analysis Frame |
analysisFrame |
1 |
The frame at which to analyze the noise in the analysis region. This field is automatically updated if you scrub to a new frame in the Viewer and reposition the analysis box. |
Analyze Noise |
analyze |
N/A |
Click this button to analyze the noise in your footage. This can be useful if you scrub to a new frame, don't move the analysis box, and want to reanalyze the noise from the new frame. |
Analysis File |
analysisFile |
N/A |
The name and location of an external analysis file. Click the Export button to save the analysis profile in this file, or Import to read the analysis profile from this file. The analysis file can be any binary file - for example a plain text file (.txt). |
Import |
import |
N/A |
Reads an analysis profile from an external analysis file (specified in Analysis File). This disables any controls that are read from the analysis file. To re-enable them, you can uncheck Lock Noise Analysis. |
Export |
export |
N/A |
Saves an analysis profile to an external analysis file (specified in Analysis File). Note: If you’ve set Profile to Constant, only the controls that affect the analysis are saved in this file. By contrast, if you’ve set Profile to Automatic, both the analysis profile and the automatically calculated noise profile are exported. |
Tune Frequencies |
|||
Process High Frequencies |
processHigh |
enabled |
Enable this if you want to remove noise from high frequencies (fine detail). |
High Gain |
highAmount |
1 |
Scales the threshold for fine noise removal. Increase this value to remove more fine noise, or decrease it to keep more detail and fine noise. A value of 0 means no fine noise is removed, whereas 1 is the estimated threshold. |
Process Medium Frequencies |
processMedium |
enabled |
Enable this if you want to remove noise from medium frequencies. |
Medium Gain |
mediumAmount |
1 |
Scales the threshold for medium noise removal. Increase this value to remove more medium noise, or decrease it to keep more detail and medium noise. A value of 0 means no medium noise is removed, whereas 1 is the estimated threshold. |
Process Low Frequencies |
processLow |
enabled |
Enable this if you want to remove noise from low frequencies (coarse detail). Normally, most of the noise occurs in the high and medium frequencies, so often you can disable the low frequency altogether. |
Low Gain |
lowAmount |
1 |
Scales the threshold for low noise removal. Increase this value to remove more low noise, or decrease it to keep more detail and low noise. A value of 0 means no low noise is removed, whereas 1 is the estimated threshold. |
Process Very Low Frequencies |
processVeryLow |
disabled |
Enable this if you want to remove noise from very low frequencies (very coarse detail). Normally, most of the noise occurs in the high and medium frequencies, so often you can disable the very low frequency altogether. |
Very Low Gain |
veryLowAmount |
1 |
Scales the threshold for very low noise removal. Increase this value to remove more very low noise, or decrease it to keep more detail and very low noise. A value of 0 means no very low noise is removed, whereas 1 is the estimated threshold. |
Tune Channels |
|||
Luminance Gain |
lumaAmount |
1 |
Scales the denoising threshold for the luminance channel. Increase this value to remove more noise, or decrease it to keep more detail and noise. |
Chrominance Gain |
chromaAmount |
5 |
Scales the denoising threshold for the chrominance channel. Increase this value to remove more noise, or decrease it to keep more detail and noise. |
Profile Tab |
|||
curve editor |
profileCurve |
N/A |
The noise profile curve. The x axis represents image intensity, from dark areas on the left to lighter areas on the right. The y axis represents the relative amount of noise removed. You can adjust the curve manually by dragging the points on the curve to a new location. To add more points to the curve, Ctrl/Cmd+Alt+click on the curve. If you are not happy with your changes, click Reset Profile to reset the curve to its original shape. |
reset |
N/A |
N/A |
Resets any changes you’ve made to the noise curve. This does not affect changes made using the Low Gain, Mid Gain, and High Gain controls. This button has the same functionality as the Reset Profile button below. |
Tune Profile |
tuneProfile |
disabled |
Enable this to tune the noise profile by adjusting Low Gain, Mid Gain, or High Gain. This works in both the Constant and Automatic profiling mode. |
Low Gain |
lowGain |
1 |
Scales the denoising threshold in the low light areas of the Source image. For example, a value of 2 multiplies the threshold by 2. Everything below the threshold is considered noise and removed, while everything above the threshold is kept. This control is only available when Tune Profile is enabled. |
Mid Gain |
midGain |
1 |
Scales the denoising threshold in the midtone areas of the Source image. For example, a value of 2 multiplies the threshold by 2. Everything below the threshold is considered noise and removed, while everything above the threshold is kept. This control is only available when Tune Profile is enabled. |
High Gain |
highGain |
1 |
Scales the denoising threshold in the highlight areas of the Source image. For example, a value of 2 multiplies the threshold by 2. Everything below the threshold is considered noise and removed, while everything above the threshold is kept. This control is only available when Tune Profile is enabled. |
Profile Frame |
profileFrame |
1 |
The frame at which to estimate the noise profile when Profile is set to Automatic. This control is read only. If you want to change the profile frame, you need to scrub to a new frame in the Viewer and click Recalculate Profile. |
Recalculate Profile |
reprofile |
N/A |
If you’ve set Profile to Automatic, Denoise first uses the current frame to calculate the profile. If you’d like to use a different frame, you need to scrub to that frame and click this button. |
Step-by-Step Guides
Video Tutorials
NUKEX 6.3 Denoise Tutorial: part 1 from Foundry on Vimeo.
Welcome to the first of two tutorials on the Denoise node for Foundry’s NukeX. This tutorial will take you through the basics of Denoise and will quickly get you started. So, here’s some noisy footage. I will show you how to use Denoise to remove the noise from this footage without losing the detail. Let me just pause on a frame and bring up a Denoise node. The Denoise node can be found under the Filter menu, and it has two possible inputs: a source clip and a noise clip. I am going to go ahead and connect the source clip to the clip we want to denoise. Denoise works by estimating the noise levels within an analysis region and then removing anything below the estimated noise levels in the rest of the clip.
The first thing we need to do is find a suitable analysis region. A suitable analysis region is a region that’s flat, free from any detail, shadows, or highlights. If I zoom out on this clip, you can see there is a large blue screen area. This is ideal for sampling the noise. If you do not have a blue screen or a green screen, try to find as flat a region as possible. Or, alternatively, you can connect a separate clip to the noise clip and analyze the noise from there. I am going to move this box to the blue area over here, but before I do that, I am going to change the Analysis Mode from Pen Up to Analysis Button - that means I can move this, rescale it, and it won’t analyze it until I press Analyze Noise. OK, it has finished analyzing the noise, so we can now compute our result.
OK, so this is the Denoise result. I will go ahead and zoom in so we can compare that to the original. You can see it is quite a good result straight out of the box, but it is perhaps a little bit soft. I will now go through the parameters you can tune in order to change the output. OK, so the first parameter you can tune is the Source. This can either be Film or Digital, and alters the noise levels across intensity values. Setting the Source type to whatever the footage was captured on works best for most footage, but for some footage, you might need to switch this around. Essentially, setting the Source type to Digital will keep the noise levels constant, whereas setting it to film will preserve more noise or detail in the dark regions and will remove more noise or detail in the bright regions.
The next parameter to tune is the Noise Model. This can either be Constant or Modulated. It also alters the noise levels across intensity values, but does so in a way that is almost the opposite to the source type. By default, this is set to Modulated, which works well for most footage. For film footage, setting the Noise Model to Modulated will remove more noise in the dark regions. For digital footage, it will remove more noise in the bright regions. For example, if you have film footage with little noise in the dark regions and lots of detail you would like to preserve, you might want to try setting this to Constant. This footage has a lot of detail in the hair, so I’m going to try and set this to Constant and see what happens. You can see that this is actually better for this footage. It has kept the background flat, but brought out a lot more detail.
The next parameter is the Profile. This can either be Constant or Automatic. I will go through Automatic profiling in the next tutorial, so for now I will leave this Constant. The parameters described so far all affect the noise analysis, and changing any of these will force the analysis to be recomputed.
I will now go through the parameters you can tune in order to change the output after the analysis. Before I start doing anything, I am going to set the Luminance Blend to 1. By default, it is set to 0.7, which means the output contains 0.7 of the denoise luminance and 0.3 of the original luminance. Setting this to 1 allows you to see what the Denoise actually does, but you probably want to bring this back down for the final output.
The next thing I’m going to do is bring up the Sharpen to some excessive amount. Sharpening emphasizes any detail being kept, so by increasing it, it is easier to visualize this. To control the detail being kept, I need to tune the Denoise Amount and Roll Off in combination. Anything below the Denoise Amount will be removed, anything between the Denoise Amount and the Roll Off will be softly thresholded, and anything above the Roll Off will be kept. In order to increase the level of detail, I can decrease the Denoise Amount. If there is too much noise left in the output, I can increase the Denoise Amount. Equally, I can increase the Roll Off or decrease it. Increasing the Roll Off gives a much smoother output, so if you think your result is too soft, you can decrease the Roll Off. If you think it’s too sharp, then you can increase the Roll Off.
OK, so when you are happy with the detail being kept and the noise being removed, put the Sharpen back down again. You could leave a little bit in there if you wish. The next parameter to tune is the Smoothness. The Denoise Amount and the Roll Off are just the threshold; the Smoothness allows you to control the smoothness of the underlying image. For example, if your output is a bit blotchy, or if it’s too smooth, then you might want to increase or decrease the Smoothness. To illustrate this, I am going to increase the Denoise Amount to a very large number, so there are no details being kept. What we are left with is the underlying image. So, regardless of what we do, we are not going to be able to sharpen or smooth this anymore. If the output at this stage is blotchy, you have to tune the Smoothness. I will just show you what this does. So, if I increase it, it will all go smoother and it will sharpen as I decrease it. OK, so when I am happy with the Smoothness of the underlying image, I can bring the threshold back down again. Finally, I’m going to blend back some of the Luminance Blend. The Chrominance Blend works by the same principle, but you probably never want to tune this. So let’s compare this denoise result with the original. I have shown you how to use Denoise to remove the noise, while preserving the detail. Let’s play through and see the result.
OK, so I have taken you through some of the basics of Denoise. In the next tutorial, I will look at profiling and explain how you can tune the noise levels for different intensities, frequencies, and channels. I will also look at how you can import and export the noise analysis.
NUKEX 6.3 Denoise Tutorial: part 2 from Foundry on Vimeo.
Welcome to the second of two tutorials on the Denoise node for Foundry’s NukeX. In the first tutorial, I took you through the basics of Denoise. In this tutorial, I will go through profiling and tuning of noise levels for different luminance values, frequencies, and color channels. So again, I have this footage I want to denoise, but this time I will take you through more advanced ways of using the tool.
The first thing I will explore is profiling. The noise Profile specifies this threshold across different intensities. By setting the Profile to Constant, it is, of course, constant across all intensities, but even so, we can go in and tune it. To tune the profile, open up the Tune Profile tab, select Tune Profile, and you can now tune the low light, midtone, and highlight regions. To visualize your profile, you can go into the Noise Analysis tab and press Plot Profile. You can then see how the profile changes as you tune it. If you are not quite sure how to tune the profile, you can deselect Tune Profile and set the Profile to Automatic. This will compute an automatic profile for the frame you are looking at. If you want to change the frame, you have to go down to Profile Frame, change it to another frame, and then press Recalculate Profile. This is the frame computed for 230 - you can see that it is quite flat. This is probably because there is not enough variation in this frame to build a good profile. You can still go in and tune it, but let’s see if we can obtain a better profile from a different clip.
I am going to bring in a different clip, shot with the same camera, and show you how to compute the profile, export it, and import it again. I will copy this node and select the original clip as the noise clip and the new clip as the source clip. I will then press Analyze Noise, not moving the region or anything. So, we will analyze the noise from exactly the same region as the original sequence. OK, I will then Recalculate Profile. So, this is the profile for the new clip. Let’s just view the full frame of the clip. You can see the noise levels are less in the shadows and highlights and more in the midtones. Let’s save this profile in Analysis File, so just put in a file name - it could be anything - and Export Profile. I can then remove this clip, remove this node, and go back to the original Denoise node, put in my profile name, and import it. You can see the profile has been imported and it looks exactly like it did before. When you import a profile, all parameters relevant to it will be locked. To unlock it, go into the Noise Analysis tab and change it to anything other than Lock Analysis, in this case, Analysis Button. I am going to copy this node again, so we can compare the results obtained with the Automatic profile and the Constant profile. Let me set this Profile to Constant and remove Plot Profile and the other Plot Profile. Let’s zoom in again. So, this is the original, this is the result using the Constant profile, and this is the result using the Automatic profile.
You can see that the Automatic profile has maybe a bit too much noise. So, let’s go in and tweak it a bit: Denoise Amount moved up from 1 to 1.42. We now have a flat background, but we also have more detail. Let’s compare that. So, you can see that the Automatic profile has kept a lot more detail, this hair sticking out, more detail around here as well. You can also tune the noise levels for different frequencies. Most of the noise is in the low to mid frequencies, so sometimes you can disable the low and very low frequencies. Go into Tune Frequencies and try disabling these. If disabling these does not introduce any more noise, then you can leave them disabled, otherwise you can try tuning them a bit.
Finally, you can also tune the noise levels for the luminance and the chrominance. The human eye is not very sensitive to color variations, so by default the Chrominance Gain is set to 5 times the estimated noise level. You might, however, want to reduce this to preserve the original color (2.05). This is our final result, compared to the original, and compared to the result we obtained after the first tutorial. So, I have taken you through profiling and the advanced tuning of Denoise. Thanks for watching the second tutorial on the Denoise node for Foundry’s NukeX.