def set_header_and_band_attrs(scene): """Set and delete some attributes.""" irch = scene['4'] nimg = set_header_and_band_attrs_defaults(scene, BANDNAMES, PPS_TAGNAMES, REFL_BANDS, irch) scene.attrs['source'] = "avhrr2pps.py" scene.attrs['orbit_number'] = 00000 return nimg
def set_header_and_band_attrs(scene): """Set and delete some attributes.""" irch = scene['24'] nimg = set_header_and_band_attrs_defaults(scene, BANDNAMES, PPS_TAGNAMES, REFL_BANDS, irch) scene.attrs['source'] = "mersi22pps.py" return nimg
def set_header_and_band_attrs(scene): """Set and delete some attributes.""" nimg = 0 # name of first dataset is image0 # Set some header attributes: irch = scene['vii_10690'] scene.attrs['source'] = "metimage2pps.py" nimg = set_header_and_band_attrs_defaults(scene, BANDNAMES, PPS_TAGNAMES, REFL_BANDS, irch) for band in REFL_BANDS: print("Is this correct, it was in testdata3.") scene[band].attrs['sun_zenith_angle_correction_applied'] = 'True' return nimg
def set_header_and_band_attrs(scene, orbit_n=0): """Set and delete some attributes.""" irch = scene['31'] nimg = set_header_and_band_attrs_defaults(scene, BANDNAMES, PPS_TAGNAMES, REFL_BANDS, irch, orbit_n=orbit_n) scene.attrs['source'] = "modis2pps.py" return nimg
def set_header_and_band_attrs(scene): """Set and delete some attributes.""" irch = scene['M15'] nimg = set_header_and_band_attrs_defaults(scene, BANDNAMES, PPS_TAGNAMES, REFL_BANDS, irch) scene.attrs['source'] = "viirs2pps.py" if 'I04' in scene: # If highresolution we should have I04, scene.attrs['number_of_scans'] = scene['I04'].values.shape[0]/scene['I04'].attrs['rows_per_scan'] else: # else use 11um. scene.attrs['number_of_scans'] = scene['M15'].values.shape[0]/scene['M15'].attrs['rows_per_scan'] for band in REFL_BANDS: if band not in scene: continue # For VIIRS data sun_zenith_angle_correction_applied is applied always! scene[band].attrs['sun_zenith_angle_correction_applied'] = 'True' return nimg
def set_header_and_band_attrs(scene): """Set and delete some attributes.""" irch = scene['brightness_temperature_channel_4'] for attr in RENAME_AND_MOVE_TO_HEADER: if attr in irch.attrs: scene.attrs[RENAME_AND_MOVE_TO_HEADER[attr]] = irch.attrs.pop(attr) nimg = set_header_and_band_attrs_defaults(scene, BANDNAMES, PPS_TAGNAMES, REFL_BANDS, irch) scene.attrs['source'] = "eumgacfdr2pps.py" scene.attrs['is_gac'] = 'True' scene.attrs['orbit_number'] = 99999 for band in BANDNAMES: if band not in scene: continue if band in REFL_BANDS: scene[band].attrs['sun_earth_distance_correction_applied'] = 'True' del scene[band].encoding['coordinates'] return nimg
def set_header_and_band_attrs(scene, orbit_n=99999): """Set and delete some attributes.""" irch = scene['4'] nimg = set_header_and_band_attrs_defaults(scene, BANDNAMES, PPS_TAGNAMES, REFL_BANDS, irch, orbit_n=orbit_n) scene.attrs['source'] = "gac2pps.py" scene.attrs['is_gac'] = 'True' for band in BANDNAMES: if band not in scene: continue if band in REFL_BANDS: # For GAC data sun_earth_distance_correction is applied always! # The sun_earth_distance_correction_factor is not provided by pygac <= 1.2.1 / satpy <= 0.18.1 scene[band].attrs['sun_earth_distance_correction_applied'] = 'True' return nimg