Multiscale Sharpen separates the image into layers of detail of about 1, 2, 4 and 8 pixels and gives each layer a gain of its own, so we sharpen the size of detail we want and no other. Each layer's noise is measured on that layer, so one threshold keeps the grain out at every scale, and a deringing hold keeps the stars from wearing dark collars. It works on linear and stretched images alike.

Categories
  • Sharpening
  • Multiscale
Keywords
  • sharpening
  • multiscale
  • starlet
  • wavelets
  • detail layers
  • scales
  • noise threshold
  • deringing
  • dark rings
  • local contrast
  • stretched data
  • linear data
  • DeepSharp

1Introduction

Multiscale Sharpen is the least exotic of the sharpening processes, and the one most of us reach for first. The image is split with the starlet transform into four layers, each holding the detail at about one size, 1, 2, 4 and 8 pixels, plus a coarse residual holding everything broader. Giving a layer a gain sharpens that size and no other. The residual is never touched: it carries the image's brightness, not its detail. With every gain at 1 the image comes back exactly as it was.

Two things make it more than an ordinary wavelet sharpening. Each layer's noise is measured from its own coefficients, so the Threshold means the same on every layer and on every image: a detail must clear that many of its layer's noise sigmas before it is sharpened at all. And Deringing keeps a gain from deepening the ring of negative detail that surrounds every bright star.

Multiscale Sharpen is DeepSharp's Multiscale method. DeepSharp's PixInsight module puts its seven methods on seven tabs of one process; in DSPX each is a process of its own in Process > Sharpening, and they share DeepSharp's engine and its results.

The Orion Nebula before and after Multiscale Sharpen
Multiscale Sharpen. Left, the Orion Nebula in a stretched wide field of Orion; right, with layer 2 at 2.5 and layer 3 at 2, the other settings at their defaults. The nebula's fine structure and the small stars are sharper, and the bright stars wear no dark collar.

2Quick Start

  1. Open the image and choose Process > Sharpening > Multiscale Sharpen.
  2. Raise Layer 2 (2 px) to about 1.5: on most well sampled images it is the most useful layer.
  3. Preview the visible area at 1:1, then try Layer 3 (4 px) the same way.
  4. Leave Threshold at 3 on a noisy image, and Deringing at 1.
  5. Click Apply.

3Interface & Parameters

The panel has three sections: Layers, a gain for each size of detail; Noise and ringing; and Output. Each folds away with the arrow beside its title. Under them are the Preview box, the image the process applies to, the buttons and the system bar along the bottom.

The Multiscale Sharpen panel
The Multiscale Sharpen panel with its default settings, which leave the image as it is.

3.1Layers

Each layer's gain runs from 0 to 5: 1, the default, leaves the layer as it is, 0 removes it, above 1 sharpens it.

Layer 1 (1 px): The finest detail, single pixels. On an astronomical image this layer is mostly noise and star cores, so a gain here sharpens stars and grain together; the threshold is what makes it usable at all.

Layer 2 (2 px): Small stars, the edges of knots, fine nebular texture. Usually the most useful layer to lift on a well sampled image.

Layer 3 (4 px): Nebular texture, dust structure, the inner parts of a galaxy's arms.

Layer 4 (8 px): Whole structures rather than texture. A gain here reads as local contrast more than as sharpening.

3.2Noise and Ringing

Threshold: How many of a layer's own noise sigmas a detail must clear before it is sharpened, from 0 to 10; 3 by default. Below the threshold nothing is added. Above it, the detail is first reduced by the threshold and then given its gain, so there is no step where the coefficients cross it. At 0 the gains apply to the noise as well.

Deringing: How much of the gain is withheld from whatever would go darker, from 0 to 1; 1 by default. Just outside a bright star the detail at every size is negative, which is simply what a bright core looks like from outside, so a gain applied evenly deepens that ring as surely as it lifts the core, and the star ends up wearing a black collar. At 1 a gain may brighten but never deepen; at 0 it works both ways, and rings. It does not apply to a layer turned down: removing a layer is meant to work both ways.

3.3Output

Output: Where the result goes.

3.4Apply, Preview and Instance

Preview: Shows the result on the image without changing it, computed at full resolution on The visible area, on A region we draw on the image with Draw Region, or on The whole image, which Apply then reuses instead of running again. A preview never starts by itself: it is computed when we click Preview, with its progress and Stop. On a part of the image it is close, not exact: each layer's noise is measured on the part. Before, in the image's banner, or the backslash key held, shows the image as it is.

Applies to: The image Multiscale Sharpen works on, chosen in a list of the open images. It shows the image in front, and follows it as we bring other images to the front. Picking another image in the list makes the panel work on that one, its preview included, without bringing it to the front; the pick stays while we work on other images, and Follow Active, the small button that appears beside the list, makes the panel follow the image in front again. An image that a tool or a run is working on is listed, but cannot be picked.

Apply: Sharpens the image named in Applies to, as Output says, channel by channel for a color image.

Instance: Shows the process as the panel has it now, as text: the settings as a DSPX process (.dsproc) or as a PixInsight process icon (.xpsm), chosen under Format. The icon is a DeepSharp icon with its method set to Multiscale, which DeepSharp's PixInsight module opens on that tab. Copy puts the text on the clipboard; Save... saves it as a file and puts it on the Process Shelf.

Reset: Puts every setting back to its default.

The system bar along the bottom of the panel has the same commands as small icons: at the left, drag to apply and Apply; at the right, Instance, Help (this page) and Reset. Drag to apply, the first icon, carries the process with its settings: dropped on an image's window, it sharpens that image, whatever image the panel works on; dropped on the Process Shelf, it is kept there as a row of its own. With Edit > Preferences > Layout > Hide classic buttons, the bar alone has them.

4One Layer at a Time

The four layers look nothing alike once lifted. Layer 1 brings out the grain and the star cores; layer 2 the small stars and the fine edges; layer 3 the texture of the nebula; layer 4 its large shapes, as local contrast. The quickest way to learn which layer carries the detail we are after is to raise one, look, and put it back: on most images it is one or two layers, not all four.

The same part of the image with layer 1 raised and with layer 4 raised
Two layers, two effects. Left, Layer 1 (1 px) at 4: the finest detail, the small stars above all, sharpened where it clears the threshold. Right, Layer 4 (8 px) at 3: the larger structures and the bright stars lifted, more like local contrast than sharpening.

5Example

An image before Multiscale Sharpen The same image after Multiscale Sharpen
An image before and after Multiscale Sharpen.

6Usage Tips and Tricks

One layer at a time. Every gain at 1 leaves the image as it was, so raise a single layer, preview, and put it back before trying the next.

Keep the threshold up on noisy data. A threshold of 3 lets almost no grain through; lower it only on clean images, when faint detail is being left out.

Turn a layer down to soften. A gain below 1 removes that size of detail: layer 1 at 0.5 is a gentle noise reduction of the finest scale.

Small sizes for texture, large for structure. 1 and 2 pixels for texture and small stars, 4 and 8 for structure.

Through a mask. With a star mask from Deep Star Mask, inverted, the stars are left alone while the nebula is sharpened.

GPU. In DSPX mode the whole method runs on the graphics card when the image is a quarter of a megapixel or more: the luminance, the four starlet layers, each layer's noise, the gains and the threshold, the deringing, the level put back, and the scaling of the channels. A 24 MP color image runs about sixteen times faster than on the processor. An image with a NaN or an infinite sample stays on the processor. The result agrees with the processor's to a few millionths of the range, and the Log reports the same noise and shares of pixels. Choose CPU only in Edit > Preferences > Performance / AI to keep it on the processor, and see The Processor and the GPU.

Deep Sharpen: a trained network undoes the measured blur of a linear image.

Deconvolution: Richardson-Lucy against the measured blur of a linear image.

Texture Sharpen: sharpens the faint texture and quiets the sky in one pass. Better than Multiscale Sharpen on a noisy image.

Flow Sharpen: sharpens across the structure, never along it.

Clarity: local contrast that cannot form a rim along an edge.

Filament Sharpen: finds long thin structure, enhances it or makes a mask of it.

Wavelets: DSPX's general multiscale process, with more layers, noise reduction per layer and a choice of transforms.

Unsharp Mask: the classic sharpening by a blurred copy, with one size.