Changeset 713

Show
Ignore:
Timestamp:
01/20/11 18:11:24 (2 years ago)
Author:
jjr8
Message:

Incremented build number and fixed:
* #452: Batched versions of Convert ArcGIS Raster to Lines tool are missing the Background Value and Minimum Dangle Length parameters
* #453: AVHRR Pathfinder V5 SST tools fail with: the Python pydap.client.open_url function failed with: Exception: Unable to parse token
* #454: AVHRR Pathfinder V5 SST tools have yearly nighttime data for 2005 but not for 2006

Location:
MGET/Branches/Jason/PythonPackage/src/GeoEco
Files:
5 modified

Legend:

Unmodified
Added
Removed
  • MGET/Branches/Jason/PythonPackage/src/GeoEco/AggregatedModules/pydap/parsers/das.py

    r602 r713  
    104104                value = self.consume(r'".*?[^\\]"|[^;,]+') 
    105105            else: 
    106                 try: 
    107                     value = self.consume('"') 
    108                 except: 
    109                     value = self.consume('[^; "]+') 
     106                if self.buffer[0] == '"': 
     107                    value = self.buffer[0]                          # It is a strong enclosed by double quotes. First consume the leading double-quote. 
     108                    self.buffer = self.buffer[1:] 
     109                     
     110                    while not self.buffer.startswith('";\n'):       # Consume all characters leading up to a sequence of double-quote, semicolon, newline. 
     111                        value += self.buffer[0] 
     112                        self.buffer = self.buffer[1:] 
     113                         
     114                    value += self.buffer[0]                         # Consume trailing double-quote. 
     115                    self.buffer = self.buffer[1:] 
    110116                else: 
    111                     value += self.consume('[^"]*') 
    112                     value += self.consume('"') 
     117                    value = self.consume('[^;"]+')         # It is a strong not enclosed by double quotes. Consume it all up to a semicolon. 
    113118             
    114119            if type_.lower() in ['string', 'url']: 
  • MGET/Branches/Jason/PythonPackage/src/GeoEco/DataManagement/ArcGISRasters.py

    r558 r713  
    34623462    outputParamExpressionDescriptions=[_OutputFeatureClassParamExpressionDescription], 
    34633463    outputParamDefaultExpressions=[u'os.path.join(outputWorkspace, inputRaster[len(workspaceToSearch)+1:])'], 
    3464     constantParamNames=[u'simplify', u'field', u'projectedCoordinateSystem', u'geographicTransformation', u'resamplingTechnique', u'projectedCellSize', u'registrationPoint', u'clippingDataset', u'clippingRectangle', u'mapAlgebraExpression'], 
     3464    constantParamNames=[u'backgroundValue', u'minDangleLength', u'simplify', u'field', u'projectedCoordinateSystem', u'geographicTransformation', u'resamplingTechnique', u'projectedCellSize', u'registrationPoint', u'clippingDataset', u'clippingRectangle', u'mapAlgebraExpression'], 
    34653465    processListMethodName=u'ToLinesList', 
    34663466    processListMethodShortDescription=_(u'Converts a list of ArcGIS rasters to lines that outline groups of adjacent raster cells having the same value.'), 
  • MGET/Branches/Jason/PythonPackage/src/GeoEco/DataProducts/NOAA/NODC.py

    r707 r713  
    152152        # Otherwise, get the oldest dataset from each catalog. 
    153153 
    154         if expression is None: 
    155             version50InterimExpression = 'Year IN (' + ', '.join(self._Version50InterimYears) + ')' 
    156         else: 
    157             version50InterimExpression = '(' + expression + ') AND Year IN (' + ', '.join(self._Version50InterimYears) + ')' 
     154        version50InterimExpression = '(' + expression + ') AND Year IN (' + ', '.join(self._Version50InterimYears) + ') AND (TemporalResolution <> \'yearly\' OR Year <> 2005)'     # NODC says there is no yearly data available for 2005, but they nonethless have an interim NOAA-17 file available on their server. We want to ignore it. 
    158155 
    159156        datasets = [] 
     
    256253        # Otherwise, get the newest dataset from each catalog. 
    257254 
    258         if expression is None: 
    259             version50InterimExpression = 'Year IN (' + ', '.join(self._Version50InterimYears) + ')' 
    260         else: 
    261             version50InterimExpression = '(' + expression + ') AND Year IN (' + ', '.join(self._Version50InterimYears) + ')' 
     255        version50InterimExpression = '(' + expression + ') AND Year IN (' + ', '.join(self._Version50InterimYears) + ') AND (TemporalResolution <> \'yearly\' OR Year <> 2005)'      # NODC says there is no yearly data available for 2005, but they nonethless have an interim NOAA-17 file available on their server. We want to ignore it. 
    262256 
    263257        datasets = [] 
     
    460454                       self._TemporalResolution == u'5day' and (version == u'5.0' and d.month == 1 and d.day <= 6 or version == u'5.1' and (d.month > 1 or d.month == 1 and d.day > 6)) or \ 
    461455                       self._TemporalResolution == u'8day' and (version == u'5.0' and d.month == 1 and d.day == 1 or version == u'5.1' and (d.month > 1 or d.month == 1 and d.day > 1)) or\ 
    462                        self._TemporalResolution == u'monthly' and version == u'5.1': 
     456                       self._TemporalResolution == u'monthly' and version == u'5.1':        # TODO: Check this logic for nighttime 
    463457                         
    464458                        dataset.Close() 
     
    473467                # NOAA-17 is in an opposite orbit unlike all the other 
    474468                # data in the Pathfinder V5 time series." 
    475  
    476                 elif d.year == 2005 and self._TemporalResolution == u'yearly': 
    477                     dataset.Close() 
    478                     continue 
     469                # 
     470                # Note that, according our definition, NOAA's yearly 
     471                # nighttime 2005 file actually begins on December 31, 
     472                # 2004 at 12:00:00. Therefore we have to check that 
     473                # d.year == 2004 if observationTime == u'nighttime'. 
     474 
     475                elif self._TemporalResolution == u'yearly': 
     476                    observationTime = dataset.GetQueryableAttributeValue(u'ObservationTime') 
     477                    if observationTime == u'daytime' and d.year == 2005 or observationTime == u'nighttime' and d.year == 2004: 
     478                        dataset.Close() 
     479                        continue 
    479480 
    480481                # If we got to here, the dataset is ok. Add it to the 
  • MGET/Branches/Jason/PythonPackage/src/GeoEco/Datasets/Virtual.py

    r696 r713  
    318318                data[t] = self._CachedDatasets[i].UnscaledData.__getitem__(tuple(sliceList[1:])) 
    319319            elif self._CachedOldestGrid.UnscaledNoDataValue is not None: 
    320                 self._LogWarning(_(u'There is no data in %(dn)s for the time slice %(ts)s.') % {u'dn': self._Collection.DisplayName, u'ts': tCoords[t].strftime('%Y-%m-%d %H:%M:%S')}) 
     320                if tCornerCoordType == 'min': 
     321                    self._LogWarning(_(u'There is no data in %(dn)s for the time slice that starts on %(ts)s.') % {u'dn': self._Collection.DisplayName, u'ts': tCoords[t].strftime('%Y-%m-%d %H:%M:%S')}) 
     322                elif tCornerCoordType == 'center': 
     323                    self._LogWarning(_(u'There is no data in %(dn)s for the time slice %(ts)s.') % {u'dn': self._Collection.DisplayName, u'ts': tCoords[t].strftime('%Y-%m-%d %H:%M:%S')}) 
     324                else: 
     325                    self._LogWarning(_(u'There is no data in %(dn)s for the time slice that ends on %(ts)s.') % {u'dn': self._Collection.DisplayName, u'ts': tCoords[t].strftime('%Y-%m-%d %H:%M:%S')}) 
    321326                data[t] += self._CachedOldestGrid.UnscaledNoDataValue 
    322327            else: 
    323                 self._LogWarning(_(u'There is no data in %(dn)s for the time slice %(ts)s but the datasets in this collection do not have a NoData value defined. The values of this time slice will be set to 0.') % {u'dn': self._Collection.DisplayName, u'ts': tCoords[t].strftime('%Y-%m-%d %H:%M:%S')}) 
     328                if tCornerCoordType == 'min': 
     329                    self._LogWarning(_(u'There is no data in %(dn)s for the time slice that starts on %(ts)s but the datasets in this collection do not have a NoData value defined. The values of this time slice will be set to 0.') % {u'dn': self._Collection.DisplayName, u'ts': tCoords[t].strftime('%Y-%m-%d %H:%M:%S')}) 
     330                elif tCornerCoordType == 'center': 
     331                    self._LogWarning(_(u'There is no data in %(dn)s for the time slice %(ts)s but the datasets in this collection do not have a NoData value defined. The values of this time slice will be set to 0.') % {u'dn': self._Collection.DisplayName, u'ts': tCoords[t].strftime('%Y-%m-%d %H:%M:%S')}) 
     332                else: 
     333                    self._LogWarning(_(u'There is no data in %(dn)s for the time slice that ends on %(ts)s but the datasets in this collection do not have a NoData value defined. The values of this time slice will be set to 0.') % {u'dn': self._Collection.DisplayName, u'ts': tCoords[t].strftime('%Y-%m-%d %H:%M:%S')}) 
    324334 
    325335            t += 1 
  • MGET/Branches/Jason/PythonPackage/src/GeoEco/__init__.py

    r688 r713  
    1 __version__ = u'0.8a21' 
     1__version__ = u'0.8a22'