Project

General

Profile

Actions

Bug #1764

closed

pixel counts not always proportional to the square of binning value

Added by Jim Pulokas over 12 years ago. Updated almost 7 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Leginon subsystem
Start date:
04/27/2012
Due date:
% Done:

0%

Estimated time:
Affected Version:
Appion/Leginon 2.1.0
Show in known bugs:
No
Workaround:

Description

In leginon/calibrationclient.py, the calculation of dose in method pixel_totaldose_from_imagedata assumes that a pixel value should be divided by binning^2 in order to effectively "unbin" the pixel. This does not work in two cases:
1) Eagle camera through TIA: the gain of the camera appears to be different depending on the binning
2) Direct Electron: currently in de.py, we do binning in software using numextension.bin(), this is actually an average and not a sum.

Two possible solutions to think about:
1) standardize the meaning of binning in pyscope so that you always get what you expect: a sum of the pixels that you would have gotten if you did not bin. For Eagle, this means calibrating the artificial gain that is applied to the image and reversing it before returning the image. For DE, this means using a sum function instead of the bin function (which actually does average) or maybe DE12 is now capable of hardware binning and we just use that.


Related issues 1 (0 open1 closed)

Related to Leginon - Bug #2342: Dose measurement does not work correctly on binned image on Tietz F416ClosedJim Pulokas04/26/2013

Actions
Actions

Also available in: Atom PDF