#!/usr/bin/env python # encoding: utf-8 """ Glance config file to compare sfc emissivity output from Geocat to output from FWAIT Created by Graeme Martin 20101119. Copyright (c) 2010 University of Wisconsin SSEC. All rights reserved. """ import glance.filters as filters # general settings to control how reports are created settings = {} settings['useThreadsToControlMemory'] = True settings['shouldIncludeImages'] = True settings['useSharedRangeForOriginal'] = True settings['doFork'] = False # info on the latitude and longitude variables that will be used lat_lon_info = {} lat_lon_info['longitude'] = 'imager_prof_retr_msg_Lon_reduced' lat_lon_info['latitude'] = 'imager_prof_retr_msg_Lat_reduced' lat_lon_info['longitude_alt_name_in_b'] = 'Longitude' lat_lon_info['latitude_alt_name_in_b'] = 'Latitude' lat_lon_info['lon_lat_epsilon'] = 0.0001 # Need to define a different filter for each missing value in the dataset being filtered. #numClrPixelsFilter_m999f = (lambda data, filterData: filters.filter_based_on_additional_data_set_min_max_bounds( \ # data, filterData, missingValue=-999.0, minOkFilterValue=9, maxOkFilterValue=9)) #numClrPixelsFilter_m128i = (lambda data, filterData: filters.filter_based_on_additional_data_set_min_max_bounds( \ # data, filterData, missingValue=-128, minOkFilterValue=9, maxOkFilterValue=9)) # per variable defaults defaultValues = { 'epsilon': None, 'epsilon_failure_tolerance': None, 'nonfinite_data_tolerance': None, # 'missing_value_alt_in_b': -999.0 # glance should be able to get from variable attributes } # a list of all the variables to analyze # setOfVariables = {} setOfVariables['overall quality flag'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_Quality_Flag', 'alternate_name_in_B': 'QualityFlag', } setOfVariables['retrieval quality flag'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_Quality_Flag_Rtvl', 'alternate_name_in_B': 'QualityFlagRtvl', } setOfVariables['bt11 quality flag'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_Quality_Flag_BT11', 'alternate_name_in_B': 'QualityFlagBT11', } setOfVariables['number of iterations'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_Num_Iteration', 'alternate_name_in_B': 'NumIter', } setOfVariables['rmse bt next'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_RMSE_BrtTemp_Next', 'alternate_name_in_B': 'RMSEBT', } setOfVariables['number of clear pixels'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_Num_Clr_Pix', 'alternate_name_in_B': 'NumClrPix', } setOfVariables['quality information'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_Quality_Information', 'alternate_name_in_B': 'QualityInfo', } # for some reason glance doesn't like the profile variables. """ setOfVariables['msg temperature profile'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_Tprof', 'alternate_name_in_B': 'TempProf', } setOfVariables['msg water profile'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_Wprof', 'alternate_name_in_B': 'RHProf', } """ # can't filter any of the sounding output because the res is reduced! setOfVariables['msg land surface temperature'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_Lst', 'alternate_name_in_B': 'LST', } setOfVariables['msg lifted index'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_LI', 'alternate_name_in_B': 'LI', } setOfVariables['msg cape'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_CAPE', 'alternate_name_in_B': 'CAPE', } setOfVariables['msg total totals index'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_TT', 'alternate_name_in_B': 'TT', } setOfVariables['msg k index'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_KI', 'alternate_name_in_B': 'KI', } setOfVariables['msg showalter index'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_SI', 'alternate_name_in_B': 'SI', } setOfVariables['msg total precipitable water'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_TPW', 'alternate_name_in_B': 'TPW', } setOfVariables['msg total precipitable water high'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_TPW_High', 'alternate_name_in_B': 'PWHigh', } setOfVariables['msg total precipitable water mid'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_TPW_Mid', 'alternate_name_in_B': 'PWMid', } setOfVariables['msg total precipitable water low'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_TPW_Low', 'alternate_name_in_B': 'PWLow', } setOfVariables['reduced resolution longitude'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_Lon_reduced', 'alternate_name_in_B': 'Longitude', } setOfVariables['reduced resolution latitude'] = { # this entry should correspond to the name in the data file 'variable_name': 'imager_prof_retr_msg_Lat_reduced', 'alternate_name_in_B': 'Latitude', }