<div dir="ltr">Thank you for the clarification.</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Apr 3, 2019 at 2:09 PM Will Hobbs <<a href="mailto:will.hobbs@utas.edu.au">will.hobbs@utas.edu.au</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-AU">
<div class="gmail-m_-8108718928128102296WordSection1">
<p class="MsoNormal">I would guess this is the relevant error message:<u></u><u></u></p>
<p class="MsoNormal">‘fatal:Eq: Dimension size, for dimension number 0, of operands does not match, can't continue’<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">You’ve assigned a 4d array (rf) to an attribute that expects a 2d array:<u></u><u></u></p>
<p class="MsoNormal">Opt@SrcMask2D = where(.not.ismissing(rf),1,0)<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">I assume you meant to type rf1 rather than rf……<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<div style="border-right:none;border-bottom:none;border-left:none;border-top:1pt solid rgb(181,196,223);padding:3pt 0cm 0cm">
<p class="MsoNormal"><b><span style="font-size:12pt;color:black">From: </span></b><span style="font-size:12pt;color:black">ncl-talk <<a href="mailto:ncl-talk-bounces@ucar.edu" target="_blank">ncl-talk-bounces@ucar.edu</a>> on behalf of Smrati Purwar <<a href="mailto:ritipurwar@gmail.com" target="_blank">ritipurwar@gmail.com</a>><br>
<b>Date: </b>Wednesday, 3 April 2019 at 7:32 PM<br>
<b>To: </b>Ncl-talk <<a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a>><br>
<b>Subject: </b>[ncl-talk] [ncl- talk] regridding 2x2 degree data<u></u><u></u></span></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<div>
<div>
<p class="MsoNormal">Hello all,<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"> i have .5 degree data . i am trying to regrid it in 2 degree data .But it is giving error. Please help<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal"> <br clear="all">
<u></u><u></u></p>
<div>
<div>
<p class="MsoNormal">Variable: rf1<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">Type: float<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">Total Size: 69660 bytes<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"> 17415 values<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">Number of Dimensions: 2<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">Dimensions and sizes: [lat | 129] x [lon | 135]<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">Coordinates: <u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"> lat: [6.5..38.5]<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"> lon: [66.5..100]<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">Number Of Attributes: 4<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"> _FillValue : -999<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"> long_name : GRIDDED RAINFALL<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"> average_op_ncl : dim_avg_n over dimension(s): sfc<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"> missing_value : -999<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">fatal:Eq: Dimension size, for dimension number 0, of operands does not match, can't continue<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">fatal:["Execute.c":8640]:Execute: Error occurred at or near line 1639 in file $NCARG_ROOT/lib/ncarg/nclscripts/esmf/ESMF_regridding.ncl<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">fatal:["Execute.c":8640]:Execute: Error occurred at or near line 1847 in file $NCARG_ROOT/lib/ncarg/nclscripts/esmf/ESMF_regridding.ncl<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">fatal:["Execute.c":8640]:Execute: Error occurred at or near line 3910 in file $NCARG_ROOT/lib/ncarg/nclscripts/esmf/ESMF_regridding.ncl<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">fatal:["Execute.c":8640]:Execute: Error occurred at or near line 4042 in file $NCARG_ROOT/lib/ncarg/nclscripts/esmf/ESMF_regridding.ncl<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">fatal:["Execute.c":8640]:Execute: Error occurred at or near line 18 in file grid.ncl<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">fatal:Variable (rf_regrid) is undefined<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">fatal:["Execute.c":8640]:Execute: Error occurred at or near line 19 in file grid.ncl<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">fatal:Variable (rf_regrid) is undefined<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">fatal:["Execute.c":8640]:Execute: Error occurred at or near line 22 in file grid.ncl<u></u><u></u></p>
</div>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">Here is my script<u></u><u></u></p>
</div>
<div>
<div>
<p class="MsoNormal">load "$NCARG_ROOT/lib/ncarg/nclscripts/esmf/ESMF_regridding.ncl"<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">f = addfile("<a href="http://rainfall2013.nc" target="_blank">rainfall2013.nc</a>","r")<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">time = f ->time<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">rf = f->rf(0:30,:,:,:) ; {7:36},{68:100})<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">;printVarSummary(rf)<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">rf1 = dim_avg_n_Wrap(dim_avg_n_Wrap(rf,0),0)<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">printVarSummary(rf1)<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">;print(rf1&lat)<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">Opt = True<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">Opt@SrcMask2D = where(.not.ismissing(rf),1,0)<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">Opt@Overwrite = True<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">Opt@DstLLCorner = (/8.00d,68.00d/)<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">Opt@DstURCorner = (/36.00d,100.00d/)<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">Opt@DstGridType = "2deg"<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">Opt@InterpMethod = "bilinear"<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">rf_regrid = ESMF_regrid(rf,Opt)<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">printVarSummary(rf_regrid)<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">system("rm -rf regrid_bilinear2X2.nc")<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">fout = addfile("regrid_bilinear2X2.nc", "c")<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">fout->rf = rf_regrid<u></u><u></u></p>
</div>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<p class="MsoNormal">-- <u></u><u></u></p>
<div>
<div>
<div>
<div>
<div>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Georgia,serif;color:blue">With Thanks & Regards</span><u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Georgia,serif;color:blue">Smrati Purwar</span><u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Georgia,serif;color:blue">Ph.D Scholar(CSIR-JRF)</span><u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Georgia,serif;color:blue">CSIR- 4th Paradigm Institute(CMMACS)</span><u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Georgia,serif;color:blue">NAL Belur Campus, Wind tunnel road</span><u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Georgia,serif;color:blue">Bangalore, India-560037</span><u></u><u></u></p>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<p style="font-size:10pt;line-height:10pt;font-family:Calibri,sans-serif"><br>
<br>
University of Tasmania Electronic Communications Policy (December, 2014). <br>
This email is confidential, and is for the intended recipient only. Access, disclosure, copying, distribution, or reliance on any of it by anyone outside the intended recipient organisation is prohibited and may be a criminal offence. Please delete if obtained
in error and email confirmation to the sender. The views expressed in this email are not necessarily the views of the University of Tasmania, unless clearly intended otherwise.
</p>
</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><br>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><font size="2"><span style="color:rgb(0,0,255)"><span style="font-family:georgia,serif">With Thanks & Regards</span></span></font></div><div><font size="2"><span style="color:rgb(0,0,255)"><span style="font-family:georgia,serif">Smrati Purwar</span></span></font></div><div><font size="2"><span style="color:rgb(0,0,255)"><span style="font-family:georgia,serif">Ph.D Scholar(CSIR-JRF<span style="background-color:rgb(153,0,255)"></span>)<br></span></span></font></div><div><font size="2"><span style="color:rgb(0,0,255)"><span style="font-family:georgia,serif">CSIR- 4th Paradigm Institute(CMMACS)<br></span></span></font></div><div><font size="2"><span style="color:rgb(0,0,255)"><span style="font-family:georgia,serif">NAL Belur Campus, Wind tunnel road<br></span></span></font></div><div><font size="2"><span style="color:rgb(0,0,255)"><span style="font-family:georgia,serif">Bangalore, India-560037</span></span></font></div></div></div></div></div>