public abstract class AbstractPinholeShift extends PropertyContainer implements PinholeShift, Initializable
PinholeShift interface that provides static
pinhole positions via a KEY_PINHOLE property. Returns zero on
getFlux() and getFwhm(), indicating that it cannot calculate
these values.| Modifier and Type | Class and Description |
|---|---|
static class |
AbstractPinholeShift.Background
Reads the image on the command line and calculates backgrounds.
|
static class |
AbstractPinholeShift.Evaluate
From reconstructed shift, we make a quantitative analysis.
|
static class |
AbstractPinholeShift.Reconstruct
Tests an algorithm with given properties.
|
| Modifier and Type | Field and Description |
|---|---|
private static double |
DEFADNOISE
Default noise from a perfect A/D converter.
|
private static Rectangle |
DEFAPPLICABLE
The default view, centered at pinhole.
|
private static double |
DEFSIGMACLIP
Default clipping in the sigma range.
|
private static int |
DEFSKYTHICK
The default sky thickness.
|
static String |
KEY_ADNOISE
Noise introduced by the A/D convert.
|
static String |
KEY_APPLICABLE
If only part of the image should be used, this points to the window.
|
static String |
KEY_GAIN
Gain of the CCD
|
static String |
KEY_PINHOLE
This key points to a pinhole property.
|
static String |
KEY_SIGMACLIP
For fitting, only pixels higher than this sigma above sky.
|
static String |
KEY_SKYTHICK
For background frames, the thickness in pixel.
|
KEY_LISTSEPARATOR, KEY_MAPKEYVALUECHAR, KEY_MAPSEPARATORCONFIG, KEY_CLASS| Modifier | Constructor and Description |
|---|---|
protected |
AbstractPinholeShift(Map<String,String> prop)
Throws an illegal argument exception, if the pinhole is not set.
|
| Modifier and Type | Method and Description |
|---|---|
protected static Vector2D |
backgroundFrameMean(MImageHDU hdu,
Rectangle box,
int thick)
Background is mean of frame, RMS is standard deviation, no clipping.
|
protected static Vector2D |
backgroundFrameMedian(MImageHDU hdu,
Rectangle box,
int thick)
Background is mean of frame, RMS is standard deviation, no clipping.
|
protected static Vector2D |
backgroundMean(MImageHDU hdu,
Rectangle box)
Background is mean of frame, RMS is standard deviation, no clipping.
|
protected static Vector2D |
backgroundMedian(MImageHDU hdu,
Rectangle box)
Background is mean of frame, RMS is standard deviation, no clipping.
|
Number[] |
getAduSignal(MImageHDU hdu)
Gets the measured ADU of the star.First, we call the abstract
PinholeShift.getBackground(fits.hdu.MImageHDU) method, then we use sigma-clipping to get all
pixel that have a signal. |
Rectangle |
getApplicableWindow()
If this class has a property named
KEY_APPLICABLE and that
property can be parsed into a MyRectangle, this method returns
the applicable window on the fits frame. |
double |
getFlux()
Returns zero.
|
double |
getFwhm()
Returns zero.
|
Point2D |
getPinholePosition()
Returns the fixed pinhole position parsed from the properties.
|
double |
getSignalToNoise(MImageHDU hdu)
Estimates the S/N of the fiber-view image.
|
void |
init()
Parses the pinhole position.
|
augment, augment, augment, augment, augment, clone, defaultBoolean, defaultChar, defaultDouble, defaultFloat, defaultInt, defaultLong, defaultObject, defaultObject, defaultProperties, defaultProperty, getAsBoolean, getAsChar, getAsDouble, getAsEnums, getAsFloat, getAsInt, getAsList, getAsLong, getAsMap, getAsMap, getAsObject, getAsObject, getProperties, getProperty, has, initProperties, isNew, parseObject, parseObject, reload, reload, removeProperty, requires, rescanned, setObject, setProperties, setProperty, stringProperties, toStringequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetBackground, initFiberView, solveFiberViewpublic static final String KEY_PINHOLE
public static final String KEY_APPLICABLE
public static final String KEY_SKYTHICK
public static final String KEY_SIGMACLIP
public static final String KEY_GAIN
public static final String KEY_ADNOISE
private static final Rectangle DEFAPPLICABLE
private static final int DEFSKYTHICK
private static final double DEFSIGMACLIP
private static final double DEFADNOISE
public void init()
init in interface Initializablepublic Point2D getPinholePosition()
MyPoint2D.getPinholePosition in interface PinholeShiftprotected static Vector2D backgroundMean(MImageHDU hdu, Rectangle box) throws BasicFitsException
BasicFitsExceptionprotected static Vector2D backgroundMedian(MImageHDU hdu, Rectangle box) throws BasicFitsException
BasicFitsExceptionprotected static Vector2D backgroundFrameMean(MImageHDU hdu, Rectangle box, int thick) throws BasicFitsException
BasicFitsExceptionprotected static Vector2D backgroundFrameMedian(MImageHDU hdu, Rectangle box, int thick) throws BasicFitsException
BasicFitsExceptionpublic Number[] getAduSignal(MImageHDU hdu)
PinholeShift.getBackground(fits.hdu.MImageHDU) method, then we use sigma-clipping to get all
pixel that have a signal. The number of pixels with signal and the ADU
sum are returned.public double getSignalToNoise(MImageHDU hdu)
PinholeShift.getBackground(fits.hdu.MImageHDU) method, then we use sigma-clipping to get all
pixel that have a signal. The ADU-signal is multiplied by an estimated
gain of the CCD to get the photon-signal, the noise is estimated by the
sum of the photon-signal and the number of signal pixel times (1+npix/nB)
times (sigma^2*gain +gain^2*0.289).getSignalToNoise in interface PinholeShiftpublic double getFlux()
getFlux in interface PinholeShiftpublic double getFwhm()
getFwhm in interface PinholeShiftpublic Rectangle getApplicableWindow()
KEY_APPLICABLE and that
property can be parsed into a MyRectangle, this method returns
the applicable window on the fits frame.