本文整理汇总了Python中netCDF4.Dataset.instituion方法的典型用法代码示例。如果您正苦于以下问题:Python Dataset.instituion方法的具体用法?Python Dataset.instituion怎么用?Python Dataset.instituion使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类netCDF4.Dataset
的用法示例。
在下文中一共展示了Dataset.instituion方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: netcdfSIT
# 需要导入模块: from netCDF4 import Dataset [as 别名]
# 或者: from netCDF4.Dataset import instituion [as 别名]
def netcdfSIT(lats,lons,var):
directory = '/home/zlabe/Surtsey/seaice_obs/Thk/March/'
name = 'icesatG_regrid_March_20032008.nc'
filename = directory + name
ncfile = Dataset(filename,'w',format='NETCDF4')
ncfile.description = 'Sea ice thickness processed by NASA-G and now' \
'regridded on an EASE2.0 100 km grid for the' \
'period of March 2003-2008'
### Dimensions
ncfile.createDimension('years',var.shape[0])
ncfile.createDimension('lat',var.shape[1])
ncfile.createDimension('lon',var.shape[2])
### Variables
years = ncfile.createVariable('years','f4',('years'))
latitude = ncfile.createVariable('lat','f4',('lat','lat'))
longitude = ncfile.createVariable('lon','f4',('lon','lon'))
varns = ncfile.createVariable('sit','f4',('years','lat','lon'))
### Units
varns.units = 'meters'
ncfile.title = 'ICESat-G'
ncfile.instituion = 'Dept. ESS at University of California, Irvine'
ncfile.source = 'NASA-G'
ncfile.references = 'Donghui Yi, H. Zwally'
### Data
years[:] = list(xrange(var.shape[0]))
latitude[:] = lats
longitude[:] = lons
varns[:] = var
ncfile.close()
print 'Completed: Created netCDF4 File!'
示例2: netcdfPiomas
# 需要导入模块: from netCDF4 import Dataset [as 别名]
# 或者: from netCDF4.Dataset import instituion [as 别名]
def netcdfPiomas(lats,lons,var,directory):
name = 'piomas_regrid_March_19792015.nc'
filename = directory + name
ncfile = Dataset(filename,'w',format='NETCDF4')
ncfile.description = 'PIOMAS Sea ice thickness reanalysis from 1979-2015 ' \
'interpolated on a 180x180 grid (latxlon)' \
'of NSIDC EASE100'
### Dimensions
ncfile.createDimension('years',var.shape[0])
ncfile.createDimension('lat',var.shape[1])
ncfile.createDimension('lon',var.shape[2])
### Variables
years = ncfile.createVariable('years','f4',('years'))
latitude = ncfile.createVariable('lat','f4',('lat','lat'))
longitude = ncfile.createVariable('lon','f4',('lon','lon'))
varns = ncfile.createVariable('thick','f4',('years','lat','lon'))
### Metrics
varns.units = 'meters'
ncfile.title = 'PIOMAS March SIT'
ncfile.instituion = 'Dept. ESS at University of California, Irvine'
ncfile.source = 'University of Washington'
ncfile.references = '[Zhang and Rothrock, 2003]'
### Data
years[:] = list(xrange(var.shape[0]))
latitude[:] = lats
longitude[:] = lons
varns[:] = var
ncfile.close()
print 'Completed: Created netCDF4 File!'
示例3: netcdfSIT
# 需要导入模块: from netCDF4 import Dataset [as 别名]
# 或者: from netCDF4.Dataset import instituion [as 别名]
def netcdfSIT(lats,lons,var,varmean):
directory = '/home/zlabe/Surtsey/seaice_obs/Thk/March/'
name = 'sub_regrid_March_19861994.nc'
filename = directory + name
ncfile = Dataset(filename,'w',format='NETCDF4')
ncfile.description = 'Sea ice thickness processed by submarine' \
'data although record is spotty throughout' \
'1986-1994 reference period. Mean thickness' \
'over the period is also included.'
### Dimensions
ncfile.createDimension('years',var.shape[0])
ncfile.createDimension('lat',var.shape[1])
ncfile.createDimension('lon',var.shape[2])
### Variables
years = ncfile.createVariable('years','f4',('years'))
latitude = ncfile.createVariable('lat','f4',('lat','lat'))
longitude = ncfile.createVariable('lon','f4',('lon','lon'))
varns = ncfile.createVariable('sit','f4',('years','lat','lon'))
varnsmean = ncfile.createVariable('meansit','f4',('lat','lon'))
### Units
varns.units = 'meters'
varnsmean.units = 'meters'
ncfile.title = 'Submarine Data'
ncfile.instituion = 'Dept. ESS at University of California, Irvine'
ncfile.source = 'NSIDC, J. Maslanik & A.P. Barrett'
ncfile.created_by = 'Zachary Labe ([email protected])'
# ncfile.references = ''
### Data
years[:] = list(xrange(var.shape[0]))
latitude[:] = lats
longitude[:] = lons
varns[:] = var
varnsmean[:] = varmean
ncfile.close()
print 'Completed: Created netCDF4 File!'
示例4: netcdfSIT
# 需要导入模块: from netCDF4 import Dataset [as 别名]
# 或者: from netCDF4.Dataset import instituion [as 别名]
def netcdfSIT(lats,lons,var,varmean):
directory = '/home/zlabe/Surtsey/seaice_obs/Thk/March/'
name = 'icebridge_regrid_March_20092014.nc'
filename = directory + name
ncfile = Dataset(filename,'w',format='NETCDF4')
ncfile.description = 'Sea ice thickness processed by iceBridge onto' \
'EASE2.0 100km grids for spring 2009-2014.' \
'Mean thickness also included for period over' \
'2009-2014.'
### Dimensions
ncfile.createDimension('years',var.shape[0])
ncfile.createDimension('lat',var.shape[1])
ncfile.createDimension('lon',var.shape[2])
### Variables
years = ncfile.createVariable('years','f4',('years'))
latitude = ncfile.createVariable('lat','f4',('lat','lat'))
longitude = ncfile.createVariable('lon','f4',('lon','lon'))
varns = ncfile.createVariable('sit','f4',('years','lat','lon'))
varnsmean = ncfile.createVariable('meansit','f4',('lat','lon'))
### Units
varns.units = 'meters'
varnsmean.units = 'meters'
ncfile.title = 'IceBridge'
ncfile.instituion = 'Dept. ESS at University of California, Irvine'
ncfile.source = 'NSIDC, Andrew P. Barrett'
# ncfile.references = ''
### Data
years[:] = list(xrange(var.shape[0]))
latitude[:] = lats
longitude[:] = lons
varns[:] = var
varnsmean[:] = varmean
ncfile.close()
print 'Completed: Created netCDF4 File!'
示例5: netcdfSatelliteG
# 需要导入模块: from netCDF4 import Dataset [as 别名]
# 或者: from netCDF4.Dataset import instituion [as 别名]
def netcdfSatelliteG(lats,lons,var,directory):
name = 'satelliteG_regrid_March_20032015.nc'
filename = directory + name
ncfile = Dataset(filename,'w',format='NETCDF4')
ncfile.description = 'Satellite data for ICESat-G (2003-2008) and' \
'CryoSat-2 (2011-2015) that have been regridded' \
'on 180x180 EASE2.0 100km grids. Years 2009-2010 are' \
'available in the data but have been filled with' \
'nan values to be inclusive. Shape is therefore' \
'[13,180,180]'
### Dimensions
ncfile.createDimension('years',var.shape[0])
ncfile.createDimension('lat',var.shape[1])
ncfile.createDimension('lon',var.shape[2])
### Variables
years = ncfile.createVariable('years','f4',('years'))
latitude = ncfile.createVariable('lat','f4',('lat','lat'))
longitude = ncfile.createVariable('lon','f4',('lon','lon'))
varns = ncfile.createVariable('thick','f4',('years','lat','lon'))
### Metrics
varns.units = 'meters'
ncfile.title = 'ICESat_G/CryoSat March SIT'
ncfile.instituion = 'Dept. ESS at University of California, Irvine'
ncfile.source = 'NASA-G/ESA Products'
ncfile.references = 'Donghui Yi, H. Zwally, S. Laxon'
### Data
years[:] = list(xrange(var.shape[0]))
latitude[:] = lats
longitude[:] = lons
varns[:] = var
ncfile.close()
print 'Completed: Created netCDF4 File!'