docs: def run(self):
          """Load climate data and convert to indicator objects
          """
          import numpy as np
  
          # get all NUTS region IDs, for linking values to region objects
          query = self.session.query(models.NUTS2Region.key,
                                     models.NUTS2Region.id)
          region_ids = self.client.df_query(query).set_index('key')['id'].to_dict()
  
          # load climate data and NUTS2 polygons
          data = next(self.requires()).load()
          nuts = NUTS2GeoJSONInputFile().load()
  
          # generated indicator IDs, keyed by season
          indicator_ids = dict()
  
          # climate data by season
          t_data = dict()
  
          # create new indicator objects for summer and winter, create averaged climate data
          for season, suffix in CLIMATE_SEASON_SUFFIXES.items():
              # noinspection PyUnresolvedReferences
              indicator = models.ClimateIndicator(description=self.description + suffix)
              self.session.add(indicator)
  
              # commit, to get indicator ID filled
              self.session.commit()
              indicator_ids[season] = indicator.id
  
              # select winter or summer data by month index, average over time range
              if season == 'summer':
                  t_data[season] = np.ma.average(data['data'][3:9, :, :], axis=0)
              else:
                  # noinspection PyTypeChecker
                  t_data[season] = np.ma.average(0.5 * (data['data'][0:3, :, :] + data['data'][9:12, :, :]), axis=0)
  
          # container for output objects, for bulk saving
          objects = []
  
          # start value for manual object id generation
          current_value_id = models.ClimateValue.get_max_id(self.session)
  
          # for each region, get a mask, average climate variable over the mask and store the indicator value;
          # loop over features first, then over seasons, because mask generation is expensive
          for feature in nuts:
  
              # draw region mask (doesn't matter for which season we take the map shape)
              mask = geojson_polygon_to_mask(feature=feature,
                                             shape=t_data['summer'].shape,
                                             lat_idx=data['lat_idx'],
                                             lon_idx=data['lon_idx'])
  
              # create indicator values for summer and winter
              for season in list(CLIMATE_SEASON_SUFFIXES.keys()):
                  # weighted average from region mask
                  value = np.ma.average(t_data[season], weights=mask)
  
                  # region ID must be cast to int (DBs don't like numpy dtypes from pandas)
                  region_id = region_ids.get(feature.properties['NUTS_ID'], None)
                  if region_id is not None:
                      region_id = int(region_id)
  
                  # append an indicator value, manually generate object IDs for bulk saving
                  current_value_id += 1
                  objects.append(models.ClimateValue(id=current_value_id,
                                                     value=value,
                                                     region_id=region_id,
                                                     indicator_id=indicator_ids[season]))
  
                  # # print some debugging output
                  # print self.variable_name + ' ' + season, feature.properties['NUTS_ID'], value
  
                  # # generate some plots for debugging
                  # from matplotlib import pyplot as plt
                  # plt.subplot(211)
                  # plt.imshow(0.02 * t_data + mask * t_data, interpolation='none')
                  # plt.subplot(212)
                  # plt.imshow(t_data, interpolation='none')
                  # plt.savefig('/tmp/' + feature.properties['NUTS_ID'] + '.png')
  
          # bulk-save all objects
          self.session.bulk_save_objects(objects)
          self.session.commit()
  
          self.done()