CCDTest_TDI_Linearity

Description :

This function allows to compute CCD linearity using two image files, a flat field file and an image file, where the CCD was exposed to light during readout process (this is why this is called TDI method). The light exposition occurs when 5% of the CCD has been readout. 
It outputs the detector non linearity figures (Rms and p-p) as well as two plots showing linearity residuals and linearity curve.

Please refers to this link to know more about this function.

Minimum version : 3.00

Syntax :

CCDTEST_TDI_LINEARITY  X1  Y1  X2  Y2  Offset  FluxMin  Filter  ImageTDI$  ImageFlat$  Title$  DoPlots_Lin  DoPlots_Res  FirstLineY  RMSLinearity  P_PLinearity

Variables :

Parameters Inputs / Outputs Type Description
X1 Input Integer First image column to process, please avoid prescan
Y1 Input Integer Last image column to process, please avoid overscan
Y1 Input Integer First row to process, this row must be illuminated
Y2 Input Integer Last row to process at the top of the image, this row must be illuminated
Offset Input Floating point Offset value in the area in the bottom that has not received any light, must be accurate.
FluxMin Input Floating point This is the minimum light flux that will be used to compute the lowest light level of linearity, and thus will set the FirstLineY to be used.
Filter Input Floating point If 0 no low pass filter is applied to the image, if 4 high low pass filter is performed to the data, allowing to be less sensitive to noise. 
ImageTDI$ Input String chars Full qualified path and filename of the TDI image
ImageFlat$ Input String chars Full qualified path and filename of the flat field image file
Title$ Input String chars Provides a Title for the two plots, usually the CCD's name.
DoPlots_Lin Input Boolean (0 or 1) If 1 displays a plot showing linearity plot
DoPlots_Res Input Boolean (0 or 1) If 1 displays a plot showing linearity residuals
FirstLineY Output Integer This returns the first valid row that has been used during computation
RMSLinearity Output Floating point Gives the RMS linearity computed throughout the first row and the last valid row
P_PLinearity Output Floating point Gives the peak to peak linearity computed throughout the first row and the last valid row

Image type that can be used by this function :

Image name Monochrome / RGB Integer coding / Floating point / Complex CPA / FITS file format
Img Yes / No Yes / Yes / No Yes / Yes

 

Script sample :

PathTDI$="C:\Prism\ESO\TDI-1-WO.cpa"
PathFlat$="C:\Prism\ESO\Flat-1-WO.cpa"

X1=28
X2=536

// Light starts here
Y1=200 
// and endshere
Y2=2045

Title$="TEST"

DoPlot_res=1
DoPlot_lin=1

OffsetADU=1010
FluxMinADU=50
LinA_FitFilter=3

CCDTEST_TDI_LINEARITY X1 Y1 X2 Y2 OffsetADU FluxMinADU LinA_FitFilter PathTDI$ PathFlat$ Title$ DoPlot_res DoPlot_lin FirstLineY RMSLinearity PPLinearity

Print "FirstLineY = " FirstLineY
Print "RMSLinearity = " RMSLinearity
Print "PPLinearity = " PPLinearity