<div dir="ltr"><div>Hi,</div><div><br></div><div>This does not appear to be a complete script; for example, where does "sst" come from? <br><div><br></div><div>The error message is fairly descriptive; somewhere there's a mismatch between the data coming in and the requirements for ESMF_regrid(). To find/understand that, I would do:<br></div></div><div><br></div><div> printVarSummary(tas)</div><div> printVarSummary(sst)</div><div> printVarSummary(lat2D)</div><div> printVarSummary(lon2D)</div><div><br></div><div><br></div><div>HTH...</div><div>Rick</div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, Feb 15, 2020 at 10:05 AM Morteza Qadimi via ncl-talk <<a href="mailto:ncl-talk@ucar.edu">ncl-talk@ucar.edu</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div lang="EN-US"><div class="gmail-m_-8697357528863055437WordSection1"><p class="MsoNormal">Dear NCL wizards,</p><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal">I want to regrid BNU-ESM (which is tripolar curvilinear) to rectilinear using ESMF_regrid. You can find my code below:</p><p class="MsoNormal"><u></u> <u></u></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">tas = in->tas<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">lat2d = in->lat<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">lon2d = in->lon<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">sst@lat2d = lat2d<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">sst@lon2d = lon2d<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">lat = fspan(-90,90,181)<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">lon = fspan(0.5,359.5,360)<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><u></u> <u></u></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">Opt = True<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><u></u> <u></u></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">Opt@SrcGridType = "curvilinear"<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">Opt@SrcFileName = "ORCA_SCRIP.nc"<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">Opt@DstFileName = "World1deg_SCRIP.nc"<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">Opt@WgtFileName = "ORCA_2_World_SCRIP.nc"<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">Opt@ForceOverwrite = True<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">Opt@DstGridType = "1deg"<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">Opt@DstTitle = "World grid 1x1 degree resolution"<u></u><u></u></span></span></span></p><div><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">Opt@InterpMethod = “bilinear”<u></u><u></u></span></span></span></p></div><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><u></u> <u></u></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><u></u> <u></u></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">tas_regrid = ESMF_regrid(sst,Opt) <u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">printVarSummary(tos_regrid)<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><u></u> <u></u></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">but I get an annoying error saying that:<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><u></u> <u></u></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">fatal:Number of dimensions in parameter (1) of (curvilinear_to_SCRIP) is (1), (2) dimensions were expected<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">fatal:["Execute.c":8637]:Execute: Error occurred at or near line 3882 in file $NCARG_ROOT/lib/ncarg/nclscripts/esmf/ESMF_regridding.ncl<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><u></u> <u></u></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:rgb(127,127,127)"><span style="color:windowtext">fatal:["Execute.c":8637]:Execute: Error occurred at or near line 4010 in file $NCARG_ROOT/lib/ncarg/nclscripts/esmf/ESMF_regridding.ncl<u></u><u></u></span></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:black;font-style:normal"><u></u> <u></u></span></span></p><p class="MsoNormal"><span class="gmail-m_-8697357528863055437MsoSubtleEmphasis"><span style="color:black;font-style:normal">Any solution?<u></u><u></u></span></span></p></div></div>_______________________________________________<br>
ncl-talk mailing list<br>
<a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a><br>
List instructions, subscriber options, unsubscribe:<br>
<a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" rel="noreferrer" target="_blank">http://mailman.ucar.edu/mailman/listinfo/ncl-talk</a></blockquote></div>