<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
</head>
<body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; color: rgb(0, 0, 0); font-size: 14px; font-family: Calibri, sans-serif;">
<div>
<div>Hello,</div>
<div>I am having issues with regridding a cmip5 ocean variable. &nbsp;Using the function “ESMF_regrid” (with NCL version 6.3.0) my script is as follows:</div>
<div>
<div><br>
</div>
<div>;**************************************</div>
<div>load &quot;$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl&quot;</div>
<div>load &quot;$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl&quot;</div>
<div>load &quot;$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl&quot;</div>
<div>load &quot;$NCARG_ROOT/lib/ncarg/nclscripts/esmf/ESMF_regridding.ncl&quot;</div>
<div>;**************************************</div>
<div>begin</div>
<div>;****************************************</div>
<div><br>
</div>
<div>&nbsp; diri = &quot;/Volumes/theato/&quot;</div>
<div><br>
</div>
<div>&nbsp; dp1 = addfile(diri&#43;&quot;theato_Omon_CESM1-BGC_rcp85_r1i1p1_200601-210012.nc&quot;,&quot;r&quot;)</div>
<div>&nbsp; tsi = dp1-&gt;theta</div>
<div>&nbsp; tsia = month_to_annual(tsi,1)</div>
<div><br>
</div>
<div>&nbsp; tsiax = tsia(0,:,:)</div>
<div>&nbsp; tsiax@lat2d = dp1-&gt;lat</div>
<div>&nbsp; tsiax@lon2d = dp1-&gt;lon</div>
<div><br>
</div>
<div>&nbsp; Opt = True</div>
<div>&nbsp; Opt@ForceOverwrite &nbsp; = True</div>
<div>&nbsp; Opt@SrcMask2D &nbsp; &nbsp; &nbsp;= where(.not.ismissing(tsiax),1,0)</div>
<div>&nbsp; Opt@DstGridType = &quot;1deg&quot;</div>
<div>&nbsp; Opt@SrcGridCornerLat = dp1-&gt;lat_vertices</div>
<div>&nbsp; Opt@SrcGridCornerLon = dp1-&gt;lon_vertices</div>
<div>&nbsp; Opt@DstLLCorner &nbsp; &nbsp; &nbsp;= (/-89.75d, &nbsp; 0.00d /)</div>
<div>&nbsp; Opt@DstURCorner &nbsp; &nbsp; &nbsp;= (/ 89.75d, 359.75d /)</div>
<div><br>
</div>
<div>&nbsp; rgtsi = ESMF_regrid(tsiax,Opt)</div>
<div><br>
</div>
<div>&nbsp; printVarSummary(rgtsi)</div>
</div>
<div><br>
</div>
<div>;**********************</div>
<div>End</div>
<div><br>
</div>
<div>The error message(s) I receive after running above script is as follows:</div>
<div><br>
</div>
<div>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;">
<span style="font-variant-ligatures: no-common-ligatures;">fatal:Variable (Opt) is undefined</span></p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;">
<span style="font-variant-ligatures: no-common-ligatures;">fatal:[&quot;Execute.c&quot;:8575]:Execute: Error occurred at or near line 1588 in file $NCARG_ROOT/lib/ncarg/nclscripts/esmf/ESMF_regridding.ncl</span></p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo; min-height: 13px;">
<span style="font-variant-ligatures: no-common-ligatures;"></span><br>
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;">
<span style="font-variant-ligatures: no-common-ligatures;">fatal:[&quot;Execute.c&quot;:8575]:Execute: Error occurred at or near line 3853 in file $NCARG_ROOT/lib/ncarg/nclscripts/esmf/ESMF_regridding.ncl</span></p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo; min-height: 13px;">
<span style="font-variant-ligatures: no-common-ligatures;"></span><br>
</p>
<p style="margin: 0px; font-size: 11px; line-height: normal; font-family: Menlo;">
<span style="font-variant-ligatures: no-common-ligatures;">fatal:[&quot;Execute.c&quot;:8575]:Execute: Error occurred at or near line 3983 in file $NCARG_ROOT/lib/ncarg/nclscripts/esmf/ESMF_regridding.ncl</span></p>
</div>
<div><span style="font-variant-ligatures: no-common-ligatures;"><br>
</span></div>
<div><span style="font-variant-ligatures: no-common-ligatures;"><br>
</span></div>
<div><span style="font-variant-ligatures: no-common-ligatures;">Is this a version issue because on a previous version (NCL 6.1.0) I did not run into this problem?</span></div>
<div><span style="font-variant-ligatures: no-common-ligatures;">Any help will be appreciated.</span></div>
<div><span style="font-variant-ligatures: no-common-ligatures;">Thank you.</span></div>
</div>
<div><span style="font-variant-ligatures: no-common-ligatures;"><br>
</span></div>
</body>
</html>