Skip to content

Commit

Permalink
Merge pull request #761 from djhoese/bugfix-mersi2-sensor-name
Browse files Browse the repository at this point in the history
Fix mersi2_l1b reader setting sensor as a set object
  • Loading branch information
djhoese authored May 10, 2019
2 parents 1bfbac6 + c3c717f commit 6c439fb
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions satpy/readers/mersi2_l1b.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,13 +54,13 @@ def end_time(self):
return self._strptime('/attr/Observing Ending Date', '/attr/Observing Ending Time')

@property
def sensor_names(self):
def sensor_name(self):
"""Map sensor name to Satpy 'standard' sensor names."""
file_sensor = self['/attr/Sensor Identification Code']
sensor = {
'MERSI': 'mersi2',
}.get(file_sensor, file_sensor)
return {sensor} # set
return sensor

def _get_coefficients(self, cal_key, cal_index):
coeffs = self[cal_key][cal_index]
Expand Down Expand Up @@ -161,7 +161,7 @@ def get_dataset(self, dataset_id, ds_info):

data.attrs.update({
'platform_name': self['/attr/Satellite Name'],
'sensor': self.sensor_names,
'sensor': self.sensor_name,
})

return data

0 comments on commit 6c439fb

Please sign in to comment.