We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
import cdms2 import vcs f=cdms2.open(vcs.sample_data+"/clt.nc") s=f("clt") u=f("u") s.regrid(u)
gives:
/Users/doutriaux1/anaconda2/envs/cdat8/lib/python2.7/site-packages/cdms2/avariable.py:1146: Warning: avariable.regrid: We chose regridTool = esmf for you among the following choices: Tools -> 'regrid2' (old behavior) 'esmf' (conserve, patch, linear) or 'libcf' (linear) warnings.warn(message, Warning) /Users/doutriaux1/anaconda2/envs/cdat8/lib/python2.7/site-packages/cdms2/avariable.py:1153: Warning: avariable.regrid: We chose regridMethod = linear for you among the following choices: 'conserve' or 'linear' or 'patch' warnings.warn(message, Warning) --------------------------------------------------------------------------- AttributeError Traceback (most recent call last) <ipython-input-8-5f18d310af48> in <module>() ----> 1 s.regrid(u) /Users/doutriaux1/anaconda2/envs/cdat8/lib/python2.7/site-packages/cdms2/avariable.pyc in regrid(self, togrid, missing, order, mask, **keywords) 1179 dstGridMask=None, 1180 dstGridAreas=None, -> 1181 **keywords) 1182 # now interpolate 1183 return ro(self, **keywords) /Users/doutriaux1/anaconda2/envs/cdat8/lib/python2.7/site-packages/cdms2/mvCdmsRegrid.pyc in __init__(self, srcGrid, dstGrid, dtype, regridMethod, regridTool, srcGridMask, srcGridAreas, dstGridMask, dstGridAreas, **args) 353 354 srcCoords = _getCoordList(srcGrid) --> 355 dstCoords = _getCoordList(dstGrid) 356 357 regridTool = str(regridTool) # force string if unicode or byte /Users/doutriaux1/anaconda2/envs/cdat8/lib/python2.7/site-packages/cdms2/mvCdmsRegrid.pyc in _getCoordList(grid) 227 228 # have axes, need to convert to curvilinear grid --> 229 cgrid = grid.toCurveGrid() 230 231 lats = cgrid.getLatitude() AttributeError: 'TransientVariable' object has no attribute 'toCurveGrid'
The text was updated successfully, but these errors were encountered:
You cannot pass a transient Variable to the regridder but you need to pass a grid as documented here.
I am still working on publishing the API documentation. You can find the regrid function here
API
regrid
import cdms2 import vcs f=cdms2.open(vcs.sample_data+"/clt.nc") s=f("clt") u=f("u") s.regrid(u.getGrid())
Sorry, something went wrong.
dnadeau4
No branches or pull requests
gives:
The text was updated successfully, but these errors were encountered: