PDS_VERSION_ID      = PDS3
LABEL_REVISION_NOTE = "2017-02-22 CT: first version
                       2018-11-02 CG: fixed line length
                       2019-12-16 CT: added correction for filter dependant 
                                      boresight shifts;
                                      updated WAC distortion parameters to 
                                      achieve better disotrion correction;
                                      updated NAC and WAC distortion parameters
                                      to maintein the boresight on center of 
                                      the CCD;
                       2020-07-15 CT: added correction for temperature 
                                      dependent boresight shift
                       2021-10-07 GK: added correction with LUT" 

/* FILE CHARACTERISTICS */
RECORD_TYPE         = STREAM
FILE_NAME           = "NAC_FM_DISTORTION_V02.TXT"
DESCRIPTION         = "NAC FM Distortion correction parameters 
                       Original correction file: 2008-09-09 
                       with fitted parametrs: 2014-10-20
                       methods: POLY3 = 3-rd order 2D polynomial
                       n_pars = (poly_order+1)**2
                       parameters start with 00!
                       
                       The filter shifts are in pixels in CCD coordinates.
                       
                       General information about the calibration can be found
                       in OSIRIS_CAL_PIPELINE_V??.PDF and about the data in
                       GEOMETRIC_DIST_COR_V??.PDF (latest version)."

/*   IMAGE IDENTIFICATION   */
PRODUCT_ID                      = NAC_FM_DISTORTION
ROSETTA:DATA_VERSION_ID         = "RO-RIS-MPAE-TN-081 2/-"
DATA_SET_ID  = "RO-C-OSINAC-4-PRL-67P-M01-STRLIGHT-V2.0"

/*   MISSION IDENTIFICATION   */
INSTRUMENT_HOST_NAME            = "ROSETTA-ORBITER"

/*   INSTRUMENT DESCRIPTION   */


/*   TIME IDENTIFICATION   */
PRODUCT_CREATION_TIME           = 2021-10-07
ROSETTA:START_VALID_PERIOD      = 2004-03-02T01:00:00
ROSETTA:START_VALID_PERIOD_SCLK = "1/0036809986.59225"
ROSETTA:END_VALID_PERIOD        = 2016-09-30T23:00:00
ROSETTA:END_VALID_PERIOD_SCLK   = "1/0433897110.29268"

OBJECT      = NAC_FM_DISTORTION_DOCUMENT
  INTERCHANGE_FORMAT  = ASCII
  DOCUMENT_FORMAT     = TEXT
  DOCUMENT_TOPIC_TYPE = "SENSOR CALIBRATION"
  DOCUMENT_NAME       = "NAC_FM_DISTORTION_V02.TXT"
  PUBLICATION_DATE    = 2021-10-07
END_OBJECT  = NAC_FM_DISTORTION_DOCUMENT

END

/* CVS VERSION */ 
CVS_VERSION_LOG                   = "
$Log: NAC_FM_DISTORTION_V02.TXT,v $
Revision 1.4  2021/11/26 14:01:40  guettlerc
cloned from OsiCalliope

Revision 1.13  2021/11/26 12:46:18  guettlerc
merge LUT resampling from distortion V03 into V02, remove V03
update OSICALLIOPE_V09.TXT accordingly

Revision 1.12  2021/09/14 11:01:55  guettlerc
added filter shift for NAC31 (email Gabor 10/09/2021 15:02)

Revision 1.11  2021/07/21 09:11:17  guettlerc
fixed line length for cvs history

Revision 1.10  2020/07/15 09:54:43  tubiana
Updated LABEL_REVISION_NOTE, DESCRIPTION, ROSETTA:DATA_VERSION_ID,
PRODUCT_CREATION_TIME and PUBLICATION_DATE

Revision 1.9  2020/07/15 09:16:42  tubiana
corrected LABEL_REVISION_NOTE

Revision 1.8  2020/05/13 08:55:48  pc\kovacs
Modified temperature correction factors, including starfield and ZetaCas

Revision 1.7  2020/04/27 12:31:15  tubiana
Removed comments to BORESIGHT_X_FACTOR_B and BORESIGHT_Y_FACTOR_B

Revision 1.6  2020/04/26 13:05:19  pc\kovacs
Removed constant value for new SPICE calculations

Revision 1.5  2020/04/24 09:07:52  pc\kovacs
Modified temperature shift parameters.
Base temperature is 290K for NAC, 300K for WAC for closer ADC2 temperature
average value.

Revision 1.4  2020/04/21 19:05:14  pc\kovacs
Modified temperature shift factors, fixed general '0.5 px' shift

Revision 1.3  2019/12/16 14:51:32  tubiana
Merged V02 and V03 into V02
Added temperature dependent boresight shift
Updated label revision note and publication date

Revision 1.2  2019/12/13 11:48:05  hall
Merged from GK_OCA_2_11b

Revision 1.1.2.4  2019/10/16 12:08:30  kovacs
Modified distortion correction parameters, to keep the 1024, 1024 center pixel
unchanged by the calibration step.

Revision 1.1.2.3  2019/10/14 14:27:16  tubiana
Updated LABEL_REVISION_NOTE
Added info about filter shifts
Updated ROSETTA:DATA_VERSION_ID
Updated PRODUCT_CREATION_TIME and PUBLICATION_DATE

Revision 1.1.2.2  2019/10/01 08:37:23  kovacs
Modified shiftg factors (2019-09-05)

Revision 1.1.2.1  2019/08/28 11:38:09  kovacs
Added filter shift handling
Compiled with: MPS_CALLIB_1_18_1
added config:  OSICALLIOPE_V09.TXT, NAC_FM_DISTORTION_V02.TXT,
WAC_FM_DISTORTION_V02.TXT
"

DIST_X_METHOD= POLY3
DIST_X_NPARS= 16

DIST_X_PAR00= -10.099597
DIST_X_PAR01= 0.000906443
DIST_X_PAR02= -5.26902e-07
DIST_X_PAR03= -3.32516e-12
DIST_X_PAR04= 1.01413
DIST_X_PAR05= -2.39320e-07
DIST_X_PAR06= 1.19823e-10
DIST_X_PAR07= -2.01772e-16
DIST_X_PAR08= -4.71201e-06
DIST_X_PAR09= 8.98608e-12
DIST_X_PAR10= -7.17827e-16
DIST_X_PAR11= 2.23917e-19
DIST_X_PAR12= 2.91214e-10
DIST_X_PAR13= -1.94627e-16
DIST_X_PAR14= 2.20615e-19
DIST_X_PAR15= -6.87882e-23



DIST_Y_METHOD= POLY3
DIST_Y_NPARS= 16

DIST_Y_PAR00= 3.624624
DIST_Y_PAR01= 0.997063
DIST_Y_PAR02= -5.93490e-07
DIST_Y_PAR03= 1.99967e-10
DIST_Y_PAR04= 0.00321866
DIST_Y_PAR05= -3.38901e-06
DIST_Y_PAR06= 1.88602e-12
DIST_Y_PAR07= -1.95971e-17
DIST_Y_PAR08= -6.41550e-08
DIST_Y_PAR09= 1.16434e-10
DIST_Y_PAR10= -1.12755e-16
DIST_Y_PAR11= 3.01745e-20
DIST_Y_PAR12= -1.06652e-11
DIST_Y_PAR13= -4.15382e-17
DIST_Y_PAR14= 3.98303e-20
DIST_Y_PAR15= -1.09102e-23

PIXEL_LUT_NF = "NAC_FM_DISTORTION_LUT_NF_V01.DCD"
PIXEL_LUT_EF = "NAC_FM_DISTORTION_LUT_EF_V01.DCD"

/* filter shift */

FSHIFT_15 = ( 4.16, -1.29)
FSHIFT_16 = ( 3.88, -1.11)
FSHIFT_22 = ( 0.00,  0.00)
FSHIFT_23 = (-1.03, -0.36)
FSHIFT_24 = (-0.44, -0.64)
FSHIFT_26 = (-0.85, -0.45)
FSHIFT_27 = (-0.64, -0.12)
FSHIFT_28 = (-0.80, -0.42)
FSHIFT_31 = (10.08, -0.73)
FSHIFT_32 = ( 4.13, -0.57)
FSHIFT_33 = ( 3.28, -0.83)
FSHIFT_35 = ( 3.86, -1.27)
FSHIFT_36 = ( 3.61, -1.16)
FSHIFT_37 = ( 3.40, -0.41)
FSHIFT_38 = ( 3.51, -0.93)
FSHIFT_41 = ( 4.49, -1.06)
FSHIFT_51 = ( 4.40, -1.14)
FSHIFT_58 = (-1.14, -0.79)
FSHIFT_61 = ( 3.57, -1.01)
FSHIFT_71 = ( 3.74, -0.98)
FSHIFT_81 = (10.08, -1.40)
FSHIFT_82 = ( 5.33, -0.68)
FSHIFT_83 = ( 4.50, -1.12)
FSHIFT_84 = ( 5.32, -1.29)
FSHIFT_86 = ( 5.29, -1.23)
FSHIFT_87 = ( 4.68, -0.72)
FSHIFT_88 = ( 4.82, -1.18)


/* Boresight shift temperature factors */

BORESIGHT_BASE_TEMP   = 290.0
BORESIGHT_X_FACTOR_A  = 0.297
BORESIGHT_X_FACTOR_B  = 0.0
BORESIGHT_Y_FACTOR_A  = 0.583
BORESIGHT_Y_FACTOR_B  = 0.0