Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add MET09 IODC service mode #2278

Merged
merged 5 commits into from
Dec 19, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions satpy/etc/areas.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ msg_seviri_iodc_3km:
with 3 km resolution
projection:
proj: geos
lon_0: 41.5
lon_0: 45.5
a: 6378169.0
b: 6356583.8
h: 35785831.0
Expand All @@ -103,7 +103,7 @@ msg_seviri_iodc_1km:
with 1 km resolution
projection:
proj: geos
lon_0: 41.5
lon_0: 45.5
a: 6378169.0
b: 6356583.8
h: 35785831.0
Expand Down Expand Up @@ -155,7 +155,7 @@ msg_seviri_iodc_9km:
with 9 km resolution
projection:
proj: geos
lon_0: 41.5
lon_0: 45.5
a: 6378169.0
b: 6356583.8
h: 35785831.0
Expand Down Expand Up @@ -206,7 +206,7 @@ msg_seviri_iodc_9km_ext:
with 9 km resolution (extended outside original 3km grid)
projection:
proj: geos
lon_0: 41.5
lon_0: 45.5
a: 6378169.0
b: 6356583.8
h: 35785831.0
Expand Down Expand Up @@ -257,7 +257,7 @@ msg_seviri_iodc_48km:
with 48 km resolution
projection:
proj: geos
lon_0: 41.5
lon_0: 45.5
a: 6378169.0
b: 6356583.8
h: 35785831.0
Expand Down
3 changes: 2 additions & 1 deletion satpy/readers/eum_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,8 @@ def get_service_mode(instrument_name, ssp_lon):
"""Get information about service mode for a given instrument and subsatellite longitude."""
service_modes = {'seviri': {'0.0': {'service_name': 'fes', 'service_desc': 'Full Earth Scanning service'},
'9.5': {'service_name': 'rss', 'service_desc': 'Rapid Scanning Service'},
'41.5': {'service_name': 'iodc', 'service_desc': 'Indian Ocean Data Coverage service'}
'41.5': {'service_name': 'iodc', 'service_desc': 'Indian Ocean Data Coverage service'},
'45.5': {'service_name': 'iodc', 'service_desc': 'Indian Ocean Data Coverage service'}
},
'fci': {'0.0': {'service_name': 'fdss', 'service_desc': 'Full Disk Scanning Service'},
'9.5': {'service_name': 'rss', 'service_desc': 'Rapid Scanning Service'},
Expand Down
13 changes: 11 additions & 2 deletions satpy/tests/reader_tests/test_eum_base.py
Original file line number Diff line number Diff line change
Expand Up @@ -141,15 +141,24 @@ def test_get_seviri_service_mode_rss(self):
self.assertEqual(res['service_name'], name)
self.assertEqual(res['service_desc'], desc)

def test_get_seviri_service_mode_iodc(self):
"""Test fetching of SEVIRI service mode information for IODC."""
def test_get_seviri_service_mode_iodc_E0415(self):
"""Test fetching of SEVIRI service mode information for IODC at 41.5 degrees East."""
ssp_lon = 41.5
name = 'iodc'
desc = 'Indian Ocean Data Coverage service'
res = get_service_mode('seviri', ssp_lon)
self.assertEqual(res['service_name'], name)
self.assertEqual(res['service_desc'], desc)

def test_get_seviri_service_mode_iodc_E0455(self):
"""Test fetching of SEVIRI service mode information for IODC at 45.5 degrees East."""
ssp_lon = 45.5
name = 'iodc'
desc = 'Indian Ocean Data Coverage service'
res = get_service_mode('seviri', ssp_lon)
self.assertEqual(res['service_name'], name)
self.assertEqual(res['service_desc'], desc)

def test_get_fci_service_mode_fdss(self):
"""Test fetching of FCI service mode information for FDSS."""
ssp_lon = 0.0
Expand Down
26 changes: 13 additions & 13 deletions satpy/tests/reader_tests/test_seviri_l2_bufr.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,14 @@
FILETYPE_INFO = {'file_type': 'seviri_l2_bufr_asr'}

FILENAME_INFO = {'start_time': '20191112000000',
'spacecraft': 'MSG1'}
'spacecraft': 'MSG2'}
FILENAME_INFO2 = {'start_time': '20191112000000',
'spacecraft': 'MSG1',
'spacecraft': 'MSG2',
'server': 'TESTSERVER'}
MPEF_PRODUCT_HEADER = {
'NominalTime': datetime(2019, 11, 6, 18, 0),
'SpacecraftName': '08',
'RectificationLongitude': 'E0415'
'SpacecraftName': '09',
'RectificationLongitude': 'E0455'
}

DATASET_INFO = {
Expand All @@ -63,8 +63,8 @@


DATASET_ATTRS = {
'platform_name': 'MET08',
'ssp_lon': 41.5,
'platform_name': 'MET09',
'ssp_lon': 45.5,
'seg_size': 16
}

Expand All @@ -76,7 +76,7 @@
'h': 35785831., 'proj': 'geos', 'units': 'm'},
232,
232,
(-5570248.6866, -5567248.2834, 5567248.2834, 5570248.6866)
(-5570248.6867, -5567248.2834, 5567248.2834, 5570248.6867)
)

AREA_DEF_FES = geometry.AreaDefinition(
Expand All @@ -87,7 +87,7 @@
'h': 35785831., 'proj': 'geos', 'units': 'm'},
232,
232,
(-5570248.6866, -5567248.2834, 5567248.2834, 5570248.6866)
(-5570248.6867, -5567248.2834, 5567248.2834, 5570248.6867)
)

AREA_DEF_EXT = geometry.AreaDefinition(
Expand All @@ -99,13 +99,13 @@
'h': 35785831., 'proj': 'geos', 'units': 'm'},
1238,
1238,
(-5571748.888268564, -5571748.888155806, 5571748.888155806, 5571748.888268564)
(-5571748.8883, -5571748.8882, 5571748.8882, 5571748.8883)
)

TEST_FILES = [
'ASRBUFRProd_20191106130000Z_00_OMPEFS01_MET08_FES_E0000',
'MSG1-SEVI-MSGASRE-0101-0101-20191106130000.000000000Z-20191106131702-1362128.bfr',
'MSG1-SEVI-MSGASRE-0101-0101-20191106101500.000000000Z-20191106103218-1362148'
'ASRBUFRProd_20191106130000Z_00_OMPEFS02_MET09_FES_E0000',
'MSG2-SEVI-MSGASRE-0101-0101-20191106130000.000000000Z-20191106131702-1362128.bfr',
'MSG2-SEVI-MSGASRE-0101-0101-20191106101500.000000000Z-20191106103218-1362148'
]

# Test data
Expand All @@ -127,7 +127,7 @@ def __init__(self, filename, with_adef=False, rect_lon='default'):
ec.codes_set(self.buf1, 'unpack', 1)
# write the bufr test data twice as we want to read in and then concatenate the data in the reader
# 55 id corresponds to METEOSAT 8`
ec.codes_set(self.buf1, 'satelliteIdentifier', 55)
ec.codes_set(self.buf1, 'satelliteIdentifier', 56)
ec.codes_set_array(self.buf1, 'latitude', LAT)
ec.codes_set_array(self.buf1, 'latitude', LAT)
ec.codes_set_array(self.buf1, 'longitude', LON)
Expand Down