- Timestamp:
- 05/02/07 10:20:06 (14 years ago)
- Location:
- TI02-CSML/trunk/csml
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
TI02-CSML/trunk/csml/API/ops_GridSeriesFeature.py
r2095 r2105 52 52 else: 53 53 print 'crs not supported' 54 55 56 57 54 58 55 ##Get names of variables in file and relate them to the subset selection 59 56 selection={} 60 57 for gridOrd in self.value.gridSeriesDomain.coordTransformTable.gridOrdinates: 61 58 selection[gridOrd.gridAxesSpanned.CONTENT]=kwargs[gridOrd.coordAxisLabel.CONTENT] 62 59 63 60 64 61 strTimes, axisorder, fulldata=csml.API.genSubset.getTheData(self, selection, times, timeName) 65 62 66 63 67 64 #Okay, got the data now. Need to write CSML feature and NetCDF files. … … 83 80 84 81 #create a stand alone gridseries feature containing this coverage 85 subsettedFeature=csmlWrap.createGridSeriesFeature(value=cvg, datasetID="A",featureID="B",description="C")82 subsettedFeature=csmlWrap.createGridSeriesFeature(value=cvg,featureID=self.id,description=self.description) 86 83 87 84 -
TI02-CSML/trunk/csml/csmllibs/csmlfeaturetypes.py
r2060 r2105 163 163 if len(dimNames) <= 2: 164 164 #it's an axis or bounds not a feature, try next variable 165 return None #(should this be None, None, None ?)165 return None, None, None 166 166 unitlist=[] 167 167 for dim in dimNames: -
TI02-CSML/trunk/csml/csmllibs/csmlfeaturewrap.py
r2073 r2105 51 51 pass 52 52 53 def createGridSeriesFeature(self,value, parameter=None, datasetID=None,featureID=None,description=None):53 def createGridSeriesFeature(self,value, parameter=None,featureID=None,description=None): 54 54 feat=csml.parser.GridSeriesFeature() 55 55 if featureID: … … 58 58 feat.id='No ID' 59 59 if description: 60 feat.description= csml.parser.csString(description)60 feat.description=description 61 61 else: 62 feat.description= csml.parser.csString('No Description')62 feat.description='No Description' 63 63 feat.value=value 64 64 #feat.parameter=parameter -
TI02-CSML/trunk/csml/parser.py
r2073 r2105 580 580 csElement.__init__(self,**kwargs) 581 581 582 class TimeSeries Domain(AbstractGML, csElement):582 class TimeSeries(AbstractGML, csElement): 583 583 def __init__(self, **kwargs): 584 584 AbstractGML.__init__(self,**kwargs) … … 590 590 def __init__(self, **kwargs): 591 591 AbstractDiscreteCoverage.__init__(self,**kwargs) 592 children={'pointSeriesDomain':[CSML('TimeSeries Domain'),'TimeSeriesDomain' ,CSML('pointSeriesDomain') ], 'rangeSet':[GML('rangeSet'), 'RangeSet'],'coverageFunction':[GML('coverageFunction'),'csString']}592 children={'pointSeriesDomain':[CSML('TimeSeries'),'TimeSeries' ,CSML('pointSeriesDomain') ], 'rangeSet':[GML('rangeSet'), 'RangeSet'],'coverageFunction':[GML('coverageFunction'),'csString']} 593 593 addchildren(self,children) 594 594 csElement.__init__(self,**kwargs) … … 868 868 869 869 870 class Dataset( AbstractGML,csElement):870 class Dataset(csElement): 871 871 ''' Dataset class, needed as root of tree''' 872 872 def __init__(self, **kwargs): 873 AbstractGML.__init__(self,**kwargs) 873 a=[CSML('id')] 874 addatts(self,a) 874 875 children = {'featureCollection':[CSML('CSMLFeatureCollection') ,'CSMLFeatureCollection'],'storageDescriptor':[CSML('CSMLStorageDescriptor'), 'CSMLStorageDescriptor']} 875 876 addchildren(self,children)
Note: See TracChangeset
for help on using the changeset viewer.