MER_RRC_2P version 0

MER_RRC_2P_v0

This definition is based on version 5/B of product specification PO-RS-MDA-GS-2009 Vol11

root type

binary record
idfield namedefinition
0mph
ascii record "MPH"size: 1247
1sph
ascii record "MER_RR__2P_SPH"size: 1542
2dsd
ascii array[dim_0]
dim_0: $num_dsd
ascii record "DSD"size: 280
3Quality_ADS
binary array[dim_0]
Level 2 Summary Quality ADS (SQ ADS)

dim_0: $num_dsr[0]
binary record "MER_RR__2P_ADSR_sq_meris_rec_data"size: 32
4Scaling_Factor_GADS
binary array[dim_0]
Level 2 GADS Scaling Factor and Offsets

dim_0: $num_dsr[1]
binary record "MER_RRC_2P_GADS_sfgi_meris_rec_data"size: 76
5Tie_points_ADS
binary array[dim_0]
Level 2 ADS Tie Points Location and Aux. Data (L ADS)

dim_0: $num_dsr[2]
binary record "MER_RR__1P_ADSR_tie_pt_meris_rec_data"
6Cloud_Type_OT
binary array[dim_0]
Level 2 MDS Cloud Optical Thickness

dim_0: $num_dsr[3]
binary record "MER_RR__2P_MDSR_19_meris_rec_data_v1"
7Cloud_Top_Pressure
binary array[dim_0]
Level 2 MDS Cloud Top Pressure

dim_0: $num_dsr[4]
binary record "MER_RR__2P_MDSR_15_meris_rec_data"
8Vapour_Content
binary array[dim_0]
Level 2 MDS Total Water vapour

dim_0: $num_dsr[5]
binary record "MER_RR__2P_MDSR_14_meris_rec_data"
9Flags
binary array[dim_0]
Level 2 MDS Flag

dim_0: $num_dsr[6]
binary record "MER_RR__2P_MDSR_20_meris_rec_data"

detection rule

This product definition is applicable if a product matches the following rule:

bytes(/,0,8) == "PRODUCT=" and
bytes(/,9,10) == "MER_RRC_2P"

product variables

namesizeinitialisation
sceneRasterWidth$sceneRasterWidth = int(/sph/line_length)
tiePointGridWidth$tiePointGridWidth = int(/sph/line_length) / int(/sph/samples_per_tie_pt) + if(int(/sph/line_length) % int(/sph/samples_per_tie_pt) == 0, 0, 1)
num_dsd$num_dsd = int(/mph/num_dsd)
num_ds$num_ds = 7
ds_to_dsd_index[$num_ds]$ds_to_dsd_index[0] = index(/dsd, str(./ds_name) == "Quality ADS                 ");
$ds_to_dsd_index[1] = index(/dsd, str(./ds_name) == "Scaling Factor GADS         ");
$ds_to_dsd_index[2] = index(/dsd, str(./ds_name) == "Tie points ADS              ");
$ds_to_dsd_index[3] = index(/dsd, str(./ds_name) == "MDS Cloud Type, OT          ");
$ds_to_dsd_index[4] = index(/dsd, str(./ds_name) == "MDS Cloud Top Pressure      ");
$ds_to_dsd_index[5] = index(/dsd, str(./ds_name) == "MDS Vapour Content          ");
$ds_to_dsd_index[6] = index(/dsd, str(./ds_name) == "MDS Flags                   ")
ds_available[$num_ds]for i = 0 to $num_ds - 1 do
$ds_available[i] = if($ds_to_dsd_index[i] != -1 and !(bytes(/dsd[$ds_to_dsd_index[i]]/filename,8) == "NOT USED"), 1, 0)
ds_offset[$num_ds]for i = 0 to $num_ds - 1 do
$ds_offset[i] = 8 * int(/dsd[$ds_to_dsd_index[i]]/ds_offset)
num_dsr[$num_ds]for i = 0 to $num_ds - 1 do
$num_dsr[i] = int(/dsd[$ds_to_dsd_index[i]]/num_dsr)