Fundamentals · PixInsight · WBPP 3.1.x

WeightedBatchPreprocessing (WBPP)

WeightedBatchPreprocessing (WBPP) is the script that turns lights, darks, flats and bias frames into calibrated, registered and integrated master lights. It groups the data automatically by filter, exposure and binning.

Purpose

TaskResult
calibrate and stack subsone master light per filter, or one colour master for OSC
align several filtersall masters registered to the same reference image
create an astrometric solutionbasis for , and annotation
WhyWBPP rather than individual processes?

The script chains all steps with consistent settings. Errors from manual intermediate steps disappear, and the pipeline is reproducible.

Principle

StageEffect
Calibrationbias, dark and flat remove offset, dark current, hot pixels, vignetting and dust
Cosmetic correctionremoves remaining hot and cold pixels before registration smears them into trails
Debayering (OSC only)reconstructs a colour image from the Bayer pattern
Weightingfavours subs with good seeing and transparency
Registrationaligns all images pixel-exactly to a reference image
Local normalizationevens out brightness and gradient differences between subs
Integration with rejectionaverages the images, removes outliers such as satellites and aircraft

Parameters

Organised by the tabs of WBPP 3.1.x; the position of individual options may differ between versions.

Bias / Darks / Flats / Lights tabs

Load files with +Bias, +Darks, +Flats, +Lights or +Directory.

TabCheckWhy
Biasmaster bias or individual frames recognisedflats are calibrated with bias because they are too short for their own dark
Darksexposure matching the lights, same temperatureonly a matching dark removes dark current and hot pixels correctly
Flatsone group per filter; filter keyword correctvignetting and dust differ per filter
Lightsgrouping, exposure and filter plausiblewrong grouping leads to wrong calibration

Calibration tab

Flat groups: bias (or dark flats) assigned.

Light groups:

SectionSettingWhy
Calibration Settingsdark Auto; Optimize Master Dark off when exposure and temperature matchdark optimisation scales the dark and can create artefacts with CMOS sensors
Output Pedestal Settingsautomaticprevents negative values or clipping after dark subtraction
Cosmetic Correctionenabled (auto-detect hot/cold)see Principle
CFA Settingsmono: off. OSC: see

Check: in the light table dark ✓ and flat ✓, flat with the matching filter.

Post-Calibration tab

SectionSettingWhy
Subframe WeightingPSF Signal Weightweights by the signal-to-noise ratio of the stars
Image Registrationdefault; with several filters one common reference imageall masters must align pixel-exactly, otherwise colour fringes
Astrometric Solutionenabledbasis for SPCC, MGC and annotation
Local Normalizationenabledimproves rejection and weighting
Image Integrationrejection Generalized Extreme Studentized Deviate (from about 50 subs per filter)robust outlier detection for large stacks
Drizzleoptional 2× only when undersampled (image scale above about 2″/px), then the same for all filtersdrizzle changes the geometry; mixed scales cannot be combined
Autocropenabledcrops registration borders that disturb gradient correction and statistics

Pipeline tab and right panel

  • Pipeline: check that all required steps are active.
  • Registration Reference Image: mode auto, or manually the best frame of the strongest filter – it defines the geometry of all masters.
  • Global Options: Generate rejection maps enabled; Preserve white balance at default (off).
  • Output Directory: project folder. Start with Run.

Typical applications

Monochrome camera with several filters

One flat and one light group per filter; CFA off; one common registration reference. Result: aligned masters per filter (e.g. L, R, G, B, Ha or Ha, OIII, SII).

Colour camera (OSC)

GroupSetting
FlatsCFA images enabled → Apply to all flat frames
LightsCFA images enabled, mosaic pattern Auto, debayer method VNG → Apply to all light frames
Drizzle (optional)Bayer drizzle 1×; 2× only when undersampled
  • Why VNG: interpolates edge-adaptively and produces fewer colour artefacts at stars than bilinear or SuperPixel at full resolution.
  • Why Bayer drizzle: reconstructs the colour channels directly from the subs instead of interpolating missing colour values – sharper stars, less colour noise; needs many dithered subs.
  • The integrated image may look greenish at first. This is expected and is corrected by . Older WBPP versions offered Separate CFA flat scaling factors for this; in 3.x it is no longer a separate checkbox.
  • Check: light table dark ✓, flat ✓; flat table bias ✓, CFA images Yes. Result: one colour master.

Reading rejection maps

The rejection maps are stored in the large master light (without “autocrop”) as additional images (rejection_low, rejection_high, possibly slope); opening it shows several windows.

  • Narrow lines in rejection_high: satellites successfully removed.
  • Artefacts in the master without a counterpart in the rejection map were present in all subs (e.g. stray light from a star outside the field). Rejection cannot remove them → crop (DynamicCrop).

What a good result looks like

Typical errors

ObservationCauseRemedy
Dust donuts, vignetting in the masterflat missing or wrong filtercheck flat assignment
Hot pixel trailscosmetic correction off, dark not matchingenable cosmetic correction, matching dark
Colour fringes when combiningfilters registered to different referencesone common reference image
Green cast (OSC)expected after debayeringcolour calibration with SPCC
Streaks in the master, not in the rejection mapstray light in all subscrop before gradient correction
Masters cannot be combineddrizzle applied to one filter onlysame drizzle for all filters

When to use it – and when not

Good forBetter another tool
standard preprocessing of mono and OSC dataremoving borders and stray light → DynamicCrop (afterwards)
a reproducible pipeline across several nightsgradients in the master → (afterwards)
Used in

HaLRGB workflow · MultiscaleGradientCorrection (MGC) · Narrowband workflow (HOO/SHO) · OSC workflow with a quad band-pass filter · SpectrophotometricColorCalibration (SPCC)