PRO VIIRS_GEO_READ, FILE, LAT, LON, ZEN ;- Read a VIIRS GEO HDF5 file (M band) ;- Check arguments if (n_elements(file) eq 0) then message, 'Argument FILE is undefined' ;- Parse the filename result = strsplit(file_basename(file), '_', /extract) product = result[0] satname = result[1] date = result[2] begtime = result[3] endtime = result[4] ;- Open the file file_id = h5f_open(file) ;- Set the group name group_name = '/All_Data/VIIRS-MOD-GEO-TC_All' ;- Read the latitude data dataset_name = 'Latitude' data_id = h5d_open(file_id, group_name + '/' + dataset_name) lat = h5d_read(data_id) h5d_close, data_id ;- Read the longitude data dataset_name = 'Longitude' data_id = h5d_open(file_id, group_name + '/' + dataset_name) lon = h5d_read(data_id) h5d_close, data_id ;- Read the solar zenith angle data dataset_name = 'SolarZenithAngle' data_id = h5d_open(file_id, group_name + '/' + dataset_name) zen = h5d_read(data_id) h5d_close, data_id ;- Close the file h5f_close, file_id END