LabCanvas
Image analysisPublished Last updated

Bleach correction in ImageJ and Fiji: simple ratio, exponential fit or histogram matching?

Fiji’s Bleach Correction (Image › Adjust): simple ratio, exponential fit and histogram matching tested on a known time-lapse, and when each is valid.

ImageJ plot of a cell whose true signal rises 50% during a bleaching time-lapse, after each bleach correction method: the simple ratio and exponential fit with a reference region follow the truth, the whole-frame ratio falls short, histogram matching stays flat
ImageJ plot of a cell whose true signal rises 50% during a bleaching time-lapse, after each bleach correction method: the simple ratio and exponential fit with a reference region follow the truth, the whole-frame ratio falls short, histogram matching stays flat.
Contents

To correct photobleaching in Fiji, choose Image › Adjust › Bleach Correction on an 8- or 16-bit time-lapse and pick one of three methods. Simple Ratio scales each frame by the mean of frame 1 divided by that frame's mean; Exponential Fit fits y=ae−bx+c to the frame means and scales each frame by the fitted decay; Histogram Matching reshapes each frame's histogram to match frame 1's. For intensity quantification, use Simple Ratio or Exponential Fit, subtract the camera background first, and draw an ROI on a region that only bleaches. Histogram Matching is for segmentation and display: it removes real changes in brightness along with the bleaching.

We tested all three on a synthetic time-lapse whose truth is known: every cell bleaches to 23% over 60 frames, and one cell also truly gets 50% brighter in the second half.

Method (camera background subtracted first)Steady cell, frame 60 ÷ frame 1Rising cell, frame 60 ÷ frame 1
True signal1.0001.500
No correction0.2290.344
Simple Ratio, whole frame0.8541.279
Simple Ratio, ROI on a steady cell1.0001.498
Exponential Fit, ROI on a steady cell1.0021.501
Histogram Matching0.9881.016
ImageJ plot of the rising cell relative to frame 1 after each bleach correction method, against the true signal
ImageJ 1.54f, the rising cell’s mean relative to frame 1 after Bleach Correction built from the plugin’s source. Truth black, dotted, under the blue and cyan lines: 1 until frame 31, then up to 1.5. No correction grey falls to 0.34; Simple Ratio on the whole frame orange reaches 1.28; Simple Ratio and Exponential Fit with an ROI on a steady cell blue, cyan follow the truth; Histogram Matching red stays near 1.

How do I correct bleaching in Fiji? Step by step

The command is the CorrectBleach plugin by Kota Miura, which comes with Fiji (Miura et al. 2020). Plain ImageJ 1.x does not include it.

  1. Check the stack: Image › Properties… should list your time points as Frames. For a 3D time-lapse, the plugin averages each time point over its z-slices, so slices and frames must be right. Run it on one channel at a time (Image › Color › Split Channels): it reads only slices and frames.
  2. Subtract the camera background. Measure the mean of an empty region, then Process › Math › Subtract… that value with Process all slices ticked. (Simple Ratio can do this for you in its Background Intensity field; Exponential Fit cannot.)
  3. Draw a reference ROI on a region whose real signal should not change during the movie: a cell that does not respond, the whole cell in a localisation experiment, or a reference structure. Without an ROI the plugin uses the whole frame.
  4. Image › Adjust › Bleach Correction and choose the Correction Method: Simple Ratio, Exponential Fit or Histogram Matching.
  5. For Simple Ratio, a second dialog asks for the Background Intensity: 0 if you subtracted it in step 2, otherwise the camera background value. For Exponential Fit, a plot of the fit opens and the Log window gets the fitted parameters a, b and c with R2.
  6. The corrected movie opens as a new window (its name starts with DUP_); the original is not changed. Measure on the corrected copy.
Fiji Bleach Correction dialog with the Correction Method list, next to a 16-bit time-lapse with an oval ROI on a cell
Image › Adjust › Bleach Correction here built from the plugin’s source and run in ImageJ 1.54f: the Correction Method list 1 and the citation DOI; the oval ROI on a steady cell 2 is the reference region used by Simple Ratio and Exponential Fit.

What each method does

Simple Ratio. The plugin subtracts the Background Intensity from every pixel, measures the mean in the ROI (or the whole frame) in every frame, and multiplies frame t by

ratiot=mean1meant

It follows the measured decay exactly, frame by frame, including the noise of the reference mean. In a 3D time-lapse, the mean of each time point is taken over all its slices.

Exponential Fit. The plugin fits an exponential with offset to the mean of the ROI (or the whole frame) against the frame number x, counted from 0:

f(x)=ae−bx+c

and multiplies frame x by f(0)/f(x). The fit smooths out frame-to-frame noise in the reference, and the Log reports the decay rate b per frame: on our sample, with the background subtracted and an ROI on a steady cell, b=0.024997, so 1/b=40.0 frames, the true bleaching time constant. It does not subtract any background, and it needs the movie to decay: if the last frame is not darker than the first, it stops with "This sequence seems to be not decaying".

Histogram Matching. The plugin matches the histogram of every frame to the histogram of frame 1 (for a 3D time-lapse, the histogram of the whole time point). It ignores any ROI. The result looks evenly bright throughout, which helps thresholding and segmentation, and the noise does not grow towards the end as it does with the two scaling methods. But any real change in brightness is matched away with the bleaching, so it is not for measuring intensities: the plugin's own source says so.

Which method is valid for quantification?

MethodKeeps relative intensitiesUse it forWatch out for
Simple RatioYes, with the right referenceMeasuring intensities over time; short or irregular bleaching curvesNoise in the reference mean is copied into every frame; the reference must not change for real
Exponential FitYes, with the right referenceMeasuring intensities when the bleaching is a smooth exponentialBackground must be subtracted first; a decay that is not exponential is corrected wrongly
Histogram MatchingNoSegmentation, tracking and displayReal brightness changes disappear; never report intensities from it

The reference region is what makes the scaling methods valid. In our test:

  • Whole frame as reference: the rising cell came out 1.279 instead of 1.500 and the steady cell 0.854 instead of 1.000. The real rise of one cell lifted the frame mean, so every frame was scaled up too little; the background in the frame, which does not bleach, did the same.
  • A steady cell as reference: both cells came out right (1.498 and 1.000 with Simple Ratio, 1.501 and 1.002 with Exponential Fit).

The background matters as much. Without subtracting the camera offset of 100, Simple Ratio with Background Intensity 0 lifted the steady cell only to 524.6 at frame 60 (1,099.1 at frame 1), and Exponential Fit with an ROI on the steady cell corrected the cell but multiplied the offset with it: the empty background rose from 99.5 to 333.6.

Pitfalls

  • Camera offset left in. The scaling methods multiply every pixel, offset included. Subtract the background first (or set Background Intensity for Simple Ratio).
  • A reference that changes for real. If your treatment changes the whole field, a whole-frame or responding-cell reference corrects your result away. Choose a region that only bleaches, and say which.
  • Multichannel stacks. Correct each channel on its own: channels bleach at different rates, and the plugin only reads slices and frames.
  • Clipping and rounding. The plugin works on 8- and 16-bit stacks and writes the result in the same type, so corrected values are rounded, and subtracting a background in 16-bit sets negative noise to 0.
  • Noise grows with the correction. A frame scaled up 4 times has its noise scaled up 4 times. Late, dim frames stay noisy after correction, and no method creates signal that bleached away.
  • Correcting where you should normalise. FRAP and calcium imaging have their own corrections (double normalisation, ΔF/F0); see FRAP analysis and ΔF/F₀.
  • Drift. The ROI is fixed; if the field moves, correct drift first (drift correction).

Reporting it

A methods sentence to copy:

Photobleaching was corrected in [Fiji (ImageJ 1.54f)] with Bleach Correction (Miura et al., 2020), [Simple Ratio / Exponential Fit] method, after subtraction of the camera background ([100] counts), using [a non-responding cell / the whole cell] as the reference region; [each channel was corrected separately].

Say which method, the reference region and how the background was handled, and show an uncorrected trace in the supplement, so readers can see how much correction was applied.

In LabCanvas: bleaching inside the assays

LabCanvas Image Analysis has no bleach correction command that rescales a whole movie. Where bleaching matters for a result, the assays handle it in the measurement instead:

  1. FRAP: the FRAP recovery assay measures a Reference (whole cell) region in every frame and divides by it (double normalisation), which corrects the bleaching caused by imaging, then fits the recovery for the mobile fraction and half-time.
  2. Calcium: the Calcium traces (ΔF/F₀) assay divides each cell's trace by its own baseline F₀ (a low percentile or the first frames).
  3. Drift first: Process › Align corrects drift before you measure in fixed regions.
FRAP recovery in LabCanvas Image Analysis
FRAP recovery: Mobile fraction 0.8, recovery half-time 2.77 s, fit R² 0.9999.

Measuring is free with a LabCanvas account (downloading files is part of LabCanvas Pro), and the assays are checked in more than 8,900 automated tests. For a corrected copy of a whole movie, use Fiji's Bleach Correction as above. ImageJ and Fiji are independent open-source projects; LabCanvas is not affiliated with them.

References

  • Miura K, et al. (2020). Bleach correction ImageJ plugin for compensating the photobleaching of time-lapse sequences. F1000Research 9, 1494. doi:10.12688/f1000research.27171.1
  • Schindelin J, Arganda-Carreras I, Frise E, et al. (2012). Fiji: an open-source platform for biological-image analysis. Nature Methods 9, 676–682. doi:10.1038/nmeth.2019

Frequently asked questions

How do I correct photobleaching in Fiji?

Subtract the camera background first (Process › Math › Subtract on all frames), draw an ROI on a region whose real signal does not change, then choose Image › Adjust › Bleach Correction and pick Simple Ratio or Exponential Fit. The corrected copy opens in a new window. The command works on 8- and 16-bit stacks.

Which bleach correction method should I use for quantification?

Simple Ratio or Exponential Fit, with the background subtracted and an ROI on a reference region that only bleaches. Both restored a real 50% rise to 1.498 and 1.501 times its start in our test. Do not use Histogram Matching for intensities: it reduced the same rise to 1.016.

What is the difference between simple ratio and exponential fit?

Simple Ratio multiplies each frame by the mean of frame 1 divided by that frame’s mean, so it follows the measured curve frame by frame, noise included. Exponential Fit fits y = a·e^(−bx) + c to the means and multiplies each frame by the fitted value at frame 1 divided by the fitted value at that frame, which is smoother but assumes the bleaching really is a single exponential.

Why is histogram matching not good for intensity measurements?

It changes every frame so that its histogram matches frame 1’s. Any real change in brightness is matched away along with the bleaching: in our test a cell that truly got 50% brighter came out 1.6% brighter. The plugin’s own source says it is for segmentation, not intensity measurements.

Why does Bleach Correction say the sequence is not decaying?

The Exponential Fit method stops when the mean of the last frame is not lower than the first: there is no decay to fit. Check that you picked the right channel and frames, that the ROI is on a bleaching region, and that the movie is not dominated by background.

Should I correct bleaching before FRAP or calcium analysis?

Not with this command. FRAP corrects bleaching during imaging with a reference region in double normalisation, and calcium imaging divides by a baseline F₀; a global correction applied first can distort both. See our FRAP and ΔF/F₀ guides.

bleach correction ImageJphotobleaching correction Fijisimple ratioexponential fithistogram matchingtime-lapsefluorescence quantificationCorrectBleach

Try it in LabCanvas

Every app is free to start in your browser. Create an account and begin.

Start Image Analysis free in your browser