public class CalibratorMsg extends Object implements Calibrator
At the time this module was written the McIDAS documentation for the MSG Instrument did not reflect that calibration data is now stored by band in the calibration block.
Current understanding is that an MSG ASCII calibration block should be
prefixed by the string MSGT followed by the following 6 values for the
Inverse Planck Funciton corresponding to each band:
| Name | Calculation | Units |
|---|---|---|
| C1W3 | C1 * W^3 | |
| C1 = 2.0e5 * P * C^2 | radiance/(cm^-1)^3) | |
| W = 1.0e2 * (band wave numbers) | (cm^-1) | |
| C2W | C2 * W | |
| C2 = P * C / B | K/(cm^-1) | |
| W = 1.0e2 * (band wave numbers) | (cm^-1) | |
| ALPHA | gain adjustment | |
| BETA | bias adjustment | |
| GAIN | gain | |
| OFFSET | offset | |
Each string value is 17 characters with 10 decimal places (fortran E17.10),
and should be parseable using Double.parseDouble. After
converting cal block from ints to a string calibration values for the first
band, including the header should look like:
MSGT 0.0000000000E+00 0.0000000000E+00 0.0000000000E+00 0.0000000000E+00 0.2312809974E-01-0.1179533087E+01
Calibrator.CalibratorFY2| Modifier and Type | Field and Description |
|---|---|
boolean |
isPreCalibrated |
CAL_ALB, CAL_BRIT, CAL_MAX, CAL_MIN, CAL_NONE, CAL_RAD, CAL_RAW, CAL_REFL, CAL_TEMP, SENSOR_FY2D, SENSOR_FY2E, SENSOR_FY2F, SENSOR_FY2G, SENSOR_FY2H, SENSOR_GOES10_IMGR, SENSOR_GOES10_SNDR, SENSOR_GOES12_IMGR, SENSOR_GOES12_SNDR, SENSOR_GOES13_IMGR, SENSOR_GOES13_SNDR, SENSOR_GOES14_IMGR, SENSOR_GOES14_SNDR, SENSOR_GOES15_IMGR, SENSOR_GOES15_SNDR, SENSOR_GOES16_IMGR, SENSOR_GOES16_SNDR, SENSOR_GOES8_IMGR, SENSOR_GOES8_SNDR, SENSOR_GOES9_IMGR, SENSOR_GOES9_SNDR, SENSOR_MSG10_IMGR, SENSOR_MSG8_IMGR, SENSOR_MSG9_IMGR| Constructor and Description |
|---|
CalibratorMsg(double[][] coefs) |
CalibratorMsg(int[] cal)
Construct this object according to the calibration data provided.
|
| Modifier and Type | Method and Description |
|---|---|
float[] |
calibrate(float[] input,
int band,
int calTypeOut)
Calibrate an array of pixels from the current calibration type according
to the parameters provided.
|
float |
calibrate(float inputPixel,
int band,
int calTypeOut)
Calibrate a pixel from the current calibration type according to the
parameters provided.
|
int[] |
calibratedList(int band,
boolean isPreCal) |
String |
calibratedUnit(int calType) |
float |
calibrateFromRaw(float inputPixel,
int band,
int calTypeOut)
Calibrate a pixel from RAW data according to the parameters provided.
|
float[] |
convertBritToTemp(float[] inputData)
convert a gray scale value to brightness temperature
|
float |
convertBritToTemp(int inVal)
convert a gray scale value to brightness temperature
|
boolean |
getIsPreCalibrated()
return isPrecalibrated value
|
void |
initMsg(int[] cal) |
int |
setCalType(int calType)
Set the input data calibration type.
|
void |
setIsPreCalibrated(boolean isPrecalibrated)
set isPrecalibrated value
|
public CalibratorMsg(int[] cal)
throws CalibratorException
cal - calibration block from an MSG AREA file.CalibratorException - on invalid calibration block.public CalibratorMsg(double[][] coefs)
throws CalibratorException
coefs - CalibratorExceptionpublic void initMsg(int[] cal)
throws CalibratorException
CalibratorExceptionpublic int setCalType(int calType)
setCalType in interface CalibratorcalType - calibration type from Calibratorpublic float[] calibrate(float[] input,
int band,
int calTypeOut)
calibrate in interface Calibratorinput - pixel array to calibrate.band - channel for which to perform calibration.calTypeOut - Calibration type constant.Float.NaN if the
calibration type cannot be performed for the specified band.public float calibrate(float inputPixel,
int band,
int calTypeOut)
calibrate in interface CalibratorinputPixel - pixel value to calibrate.band - channel for which to perform calibration.calTypeOut - Calibration type constant.Float.NaN if the
calibration type cannot be performed for the specified band.public int[] calibratedList(int band,
boolean isPreCal)
calibratedList in interface Calibratorpublic float calibrateFromRaw(float inputPixel,
int band,
int calTypeOut)
inputPixel - pixel value to calibrate.band - channel for which to perform calibration.calTypeOut - Calibration type constant.Float.NaN if the
calibration type cannot be performed for the specified band.public String calibratedUnit(int calType)
calibratedUnit in interface Calibratorpublic float convertBritToTemp(int inVal)
convertBritToTemp in interface CalibratorinVal - input data valuepublic float[] convertBritToTemp(float[] inputData)
convertBritToTemp in interface CalibratorinputData - input data arraypublic boolean getIsPreCalibrated()
getIsPreCalibrated in interface Calibratorpublic void setIsPreCalibrated(boolean isPrecalibrated)
setIsPreCalibrated in interface CalibratorCopyright © 1996–2023 The SSEC Visualization Project. All rights reserved.