[ncl-talk] Query- error while running cyclone track script

Gaurav Tiwari gaurav16 at iiserb.ac.in
Sun May 7 10:49:59 MDT 2017


Hi Mary, Thank you for you support.

I have used the same script given by you (just changed the file name and
location) but still I am getting the exact errror i.e.  fatal:Dimension
sizes on right hand side of assignment do not match dimension sizes of left
hand side.

Now I you want, I can upload my wrfout*.nc file in your location, just let
me know the procedure for the same.


Thanks,

--Gaurav




*************************************************************************
*Gaurav Tiwari*
Research Scholar
Department of Earth and Environmental Sciences
Indian Institute of Science Education and Research Bhopal
(IISER B)
Bhopal- 462066, Madhya Pradesh
Email: gaurav16 at iiserb.ac.in <saquib16 at iiserb.ac.in>
Mob: +91-7471112407
LinkedIn
<https://www.linkedin.com/in/gaurav-tiwari-bb36357a?trk=hp-identity-name>
Research gate <https://www.researchgate.net/profile/Gaurav_Tiwari5>




*[image: Description: Description: Description: Description: Description:
Description: Description: cid:image001.jpg at 01CC2469.06E9E6A0] **Please
consider the environment before printing this e-mail*

On Sun, May 7, 2017 at 9:10 PM, Mary Haley <haley at ucar.edu> wrote:

> Guarav,
>
> We ask people to CC ncl-talk whenever you have follow-up questions, unless
> we specifically ask to take the conversation offline.
>
> Your script is hard-coded to your files and it's not really the same if I
> just plug in any random WRF output files.
>
> For example, you have this:
>
>   date = (/2812,2900,2912,3000,3012,3100/)
>   sdate = sprinti("%4.0i",date)
>
> I don't know what these values are.
>
> I changed them to just use a subset of the wrf output file names, just so
> I could get the script to work:
>
>   sdate = str_get_cols(fs,16,26)
>
> Making a few other minor changes to the script, I was able to get a plot.
> However, it's a bit nonsensical because I'm using some dummy WRF output
> data.
>
> See the attached track_mod.ncl script and the resultant image I got.
>
> If you continue to have problems with this, we can't keep debugging it
> without your data files to try it on.
>
> Thanks for your consideration,
>
>
> --Mary
>
>
>
> On Fri, May 5, 2017 at 1:25 AM, Gaurav Tiwari <gaurav16 at iiserb.ac.in>
> wrote:
>
>> Hi Mary,
>>    Sorry but it seems I am unable to fix out the problem and which is
>> required on urgent basis. Kindly check my script if you have any
>> *wrfout*.nc* file.
>>
>>
>>
>>
>>
>> *************************************************************************
>> *Gaurav Tiwari*
>> Research Scholar
>> Department of Earth and Environmental Sciences
>> Indian Institute of Science Education and Research Bhopal
>> (IISER B)
>> Bhopal- 462066, Madhya Pradesh
>> Email: gaurav16 at iiserb.ac.in <saquib16 at iiserb.ac.in>
>> Mob: +91-7471112407 <+91%2074711%2012407>
>> LinkedIn
>> <https://www.linkedin.com/in/gaurav-tiwari-bb36357a?trk=hp-identity-name>
>> Research gate <https://www.researchgate.net/profile/Gaurav_Tiwari5>
>>
>>
>>
>>
>> *[image: Description: Description: Description: Description: Description:
>> Description: Description: cid:image001.jpg at 01CC2469.06E9E6A0] **Please
>> consider the environment before printing this e-mail*
>>
>> On Fri, May 5, 2017 at 4:12 AM, Mary Haley <haley at ucar.edu> wrote:
>>
>>> Gaurav,
>>>
>>> The error message:
>>>
>>> fatal:Dimension sizes on right hand side of assignment do not match
>>> dimension sizes of left hand side
>>>
>>> is telling you that you have a statement where the dimensions of the
>>> array being referenced on the left side of the equation don't match with
>>> the dimensions of the right side.
>>>
>>> I think line 51 in your code is this one:
>>>
>>>     slp2d = wrf_user_getvar(f,"slp",0)
>>>
>>> My guess is that the error is occurring sometime after the first time
>>> through the loop, and that "slp2d" is a different size than it was
>>> previously.
>>>
>>> NCL doesn't allow you to assign a new variable to an existing variable
>>> if it's a different size or higher type.
>>>
>>> You can easily fix this problem by using the reassignment operator,
>>> which forces the reassignment to take place:
>>>
>>>     slp2d := wrf_user_getvar(f,"slp",0)
>>>
>>> When you get error messages in NCL you don't understand, you might find
>>> an explanation and solution on this page:
>>>
>>> http://www.ncl.ucar.edu/Document/Language/error_messages.shtml
>>>
>>> --Mary
>>>
>>>
>>>
>>> On Wed, May 3, 2017 at 10:57 AM, Gaurav Tiwari <gaurav16 at iiserb.ac.in>
>>> wrote:
>>>
>>>> Now I am getting the following error, script is also attached:
>>>>
>>>> (0)    Check input data:1 .ne. 9
>>>>
>>>>
>>>> Variable: times
>>>> Type: string
>>>> Total Size: 392 bytes
>>>>             49 values
>>>> Number of Dimensions: 1
>>>> Dimensions and sizes:    [49]
>>>> Coordinates:
>>>> Number Of Attributes: 2
>>>>   description :    times in file
>>>>   _FillValue :    missing
>>>> (0)    2014-10-26_00:00:00
>>>> (1)    2014-10-26_03:00:00
>>>> (2)    2014-10-26_06:00:00
>>>> (3)    2014-10-26_09:00:00
>>>> (4)    2014-10-26_12:00:00
>>>> (5)    2014-10-26_15:00:00
>>>> (6)    2014-10-26_18:00:00
>>>> (7)    2014-10-26_21:00:00
>>>> (8)    2014-10-27_00:00:00
>>>> (9)    2014-10-27_03:00:00
>>>> (10)    2014-10-27_06:00:00
>>>> (11)    2014-10-27_09:00:00
>>>> (12)    2014-10-27_12:00:00
>>>> (13)    2014-10-27_15:00:00
>>>> (14)    2014-10-27_18:00:00
>>>> (15)    2014-10-27_21:00:00
>>>> (16)    2014-10-28_00:00:00
>>>> (17)    2014-10-28_03:00:00
>>>> (18)    2014-10-28_06:00:00
>>>> (19)    2014-10-28_09:00:00
>>>> (20)    2014-10-28_12:00:00
>>>> (21)    2014-10-28_15:00:00
>>>> (22)    2014-10-28_18:00:00
>>>> (23)    2014-10-28_21:00:00
>>>> (24)    2014-10-29_00:00:00
>>>> (25)    2014-10-29_03:00:00
>>>> (26)    2014-10-29_06:00:00
>>>> (27)    2014-10-29_09:00:00
>>>> (28)    2014-10-29_12:00:00
>>>> (29)    2014-10-29_15:00:00
>>>> (30)    2014-10-29_18:00:00
>>>> (31)    2014-10-29_21:00:00
>>>> (32)    2014-10-30_00:00:00
>>>> (33)    2014-10-30_03:00:00
>>>> (34)    2014-10-30_06:00:00
>>>> (35)    2014-10-30_09:00:00
>>>> (36)    2014-10-30_12:00:00
>>>> (37)    2014-10-30_15:00:00
>>>> (38)    2014-10-30_18:00:00
>>>> (39)    2014-10-30_21:00:00
>>>> (40)    2014-10-31_00:00:00
>>>> (41)    2014-10-31_03:00:00
>>>> (42)    2014-10-31_06:00:00
>>>> (43)    2014-10-31_09:00:00
>>>> (44)    2014-10-31_12:00:00
>>>> (45)    2014-10-31_15:00:00
>>>> (46)    2014-10-31_18:00:00
>>>> (47)    2014-10-31_21:00:00
>>>> (48)    2014-11-01_00:00:00
>>>> fatal:Dimension sizes on right hand side of assignment do not match
>>>> dimension sizes of left hand side
>>>> fatal:["Execute.c":8640]:Execute: Error occurred at or near line 51 in
>>>> file trak.ncl
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> ************************************************************
>>>> *************
>>>> *Gaurav Tiwari*
>>>> Research Scholar
>>>> Department of Earth and Environmental Sciences
>>>> Indian Institute of Science Education and Research Bhopal
>>>> (IISER B)
>>>> Bhopal- 462066, Madhya Pradesh
>>>> Email: gaurav16 at iiserb.ac.in <saquib16 at iiserb.ac.in>
>>>> Mob: +91-7471112407 <+91%2074711%2012407>
>>>> LinkedIn
>>>> <https://www.linkedin.com/in/gaurav-tiwari-bb36357a?trk=hp-identity-name>
>>>> Research gate <https://www.researchgate.net/profile/Gaurav_Tiwari5>
>>>>
>>>>
>>>>
>>>>
>>>> *[image: Description: Description: Description: Description:
>>>> Description: Description: Description: cid:image001.jpg at 01CC2469.06E9E6A0] **Please
>>>> consider the environment before printing this e-mail*
>>>>
>>>> On Wed, May 3, 2017 at 6:36 PM, Gaurav Tiwari <gaurav16 at iiserb.ac.in>
>>>> wrote:
>>>>
>>>>> Yes, exactly.
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> ************************************************************
>>>>> *************
>>>>> *Gaurav Tiwari*
>>>>> Research Scholar
>>>>> Department of Earth and Environmental Sciences
>>>>> Indian Institute of Science Education and Research Bhopal
>>>>> (IISER B)
>>>>> Bhopal- 462066, Madhya Pradesh
>>>>> Email: gaurav16 at iiserb.ac.in <saquib16 at iiserb.ac.in>
>>>>> Mob: +91-7471112407 <+91%2074711%2012407>
>>>>> LinkedIn
>>>>> <https://www.linkedin.com/in/gaurav-tiwari-bb36357a?trk=hp-identity-name>
>>>>> Research gate <https://www.researchgate.net/profile/Gaurav_Tiwari5>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> *[image: Description: Description: Description: Description:
>>>>> Description: Description: Description: cid:image001.jpg at 01CC2469.06E9E6A0] **Please
>>>>> consider the environment before printing this e-mail*
>>>>>
>>>>> On Wed, May 3, 2017 at 6:31 PM, Rick Brownrigg <brownrig at ucar.edu>
>>>>> wrote:
>>>>>
>>>>>> Did you load the supporting library, as described in the docs?
>>>>>>
>>>>>>   http://www.ncl.ucar.edu/Document/Functions/WRF_contributed
>>>>>> /wrf_mapres_c.shtml
>>>>>>
>>>>>> ie.,:
>>>>>>
>>>>>>   load "$NCARG_ROOT/lib/ncarg/nclscripts/wrf/WRF_contributed.ncl"
>>>>>>
>>>>>> In NCL 6.4.0, many of these libraries are loaded automatically. WRF_contributed is not one of them.  You also may want to consider using wrf_map_resources() instead of wrf_mapres_c(), as described in the docs.
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> On Wed, May 3, 2017 at 5:47 AM, Gaurav Tiwari <gaurav16 at iiserb.ac.in>
>>>>>> wrote:
>>>>>>
>>>>>>> Still I am getting the same error:
>>>>>>>
>>>>>>> fatal:syntax error: line 73 in file trak.ncl before or near ; Set up
>>>>>>> map resources
>>>>>>>
>>>>>>>   wrf_mapres_c(a,res,0)                          ; Set up map
>>>>>>> resources
>>>>>>> ^
>>>>>>>
>>>>>>> fatal:syntax error: possibly an undefined procedure
>>>>>>> fatal:Syntax Error in block, block not executed
>>>>>>> fatal:error at line 143 in file trak.ncl
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> ************************************************************
>>>>>>> *************
>>>>>>> *Gaurav Tiwari*
>>>>>>> Research Scholar
>>>>>>> Department of Earth and Environmental Sciences
>>>>>>> Indian Institute of Science Education and Research Bhopal
>>>>>>> (IISER B)
>>>>>>> Bhopal- 462066, Madhya Pradesh
>>>>>>> Email: gaurav16 at iiserb.ac.in <saquib16 at iiserb.ac.in>
>>>>>>> Mob: +91-7471112407 <+91%2074711%2012407>
>>>>>>> LinkedIn
>>>>>>> <https://www.linkedin.com/in/gaurav-tiwari-bb36357a?trk=hp-identity-name>
>>>>>>> Research gate <https://www.researchgate.net/profile/Gaurav_Tiwari5>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> *[image: Description: Description: Description: Description:
>>>>>>> Description: Description: Description: cid:image001.jpg at 01CC2469.06E9E6A0] **Please
>>>>>>> consider the environment before printing this e-mail*
>>>>>>>
>>>>>>> On Wed, May 3, 2017 at 2:02 AM, Gaurav Tiwari <gaurav16 at iiserb.ac.in
>>>>>>> > wrote:
>>>>>>>
>>>>>>>> Thank you Rick. I will try it and update you.
>>>>>>>>
>>>>>>>> Thanks,
>>>>>>>> Gaurav
>>>>>>>>
>>>>>>>> On May 2, 2017 11:58 PM, "Rick Brownrigg" <brownrig at ucar.edu>
>>>>>>>> wrote:
>>>>>>>>
>>>>>>>>> The error message means just what it says -- there is no procedure
>>>>>>>>> found by the name WRF_map_c.  So you either have a typo (names
>>>>>>>>> are case-sensitive) or there is no such function. If I were speculate,
>>>>>>>>> there is a function in NCL named wrf_mapres_c() that takes three arguments:
>>>>>>>>>
>>>>>>>>> http://www.ncl.ucar.edu/Document/Functions/WRF_contributed/w
>>>>>>>>> rf_mapres_c.shtml
>>>>>>>>>
>>>>>>>>> Note that it is deprecated in favor of wrf_map_resources.
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On Tue, May 2, 2017 at 10:44 AM, Gaurav Tiwari <
>>>>>>>>> gaurav16 at iiserb.ac.in> wrote:
>>>>>>>>>
>>>>>>>>>> Hi,
>>>>>>>>>>    I am running NCL script to plot cyclone track but I am getting
>>>>>>>>>> an error which is given below:
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> gaurav at 2-Lenovo-S510:~/ncl_scripts$ ncl track.ncl
>>>>>>>>>>  Copyright (C) 1995-2017 - All Rights Reserved
>>>>>>>>>>  University Corporation for Atmospheric Research
>>>>>>>>>>  NCAR Command Language Version 6.4.0
>>>>>>>>>>  The use of this software is governed by a License Agreement.
>>>>>>>>>>  See http://www.ncl.ucar.edu/ for more details.
>>>>>>>>>> fatal:syntax error: line 73 in file track.ncl before or near \n
>>>>>>>>>>   WRF_map_c(a,res,0)
>>>>>>>>>> --------------------^
>>>>>>>>>>
>>>>>>>>>> fatal:syntax error: possibly an undefined procedure
>>>>>>>>>> fatal:Syntax Error in block, block not executed
>>>>>>>>>> fatal:error at line 142 in file track.ncl
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> My script is attached here. Kindly help me to short out this
>>>>>>>>>> issue.
>>>>>>>>>>
>>>>>>>>>> Thanks,
>>>>>>>>>> Gaurav
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> ************************************************************
>>>>>>>>>> *************
>>>>>>>>>> *Gaurav Tiwari*
>>>>>>>>>> Research Scholar
>>>>>>>>>> Department of Earth and Environmental Sciences
>>>>>>>>>> Indian Institute of Science Education and Research Bhopal
>>>>>>>>>> (IISER B)
>>>>>>>>>> Bhopal- 462066, Madhya Pradesh
>>>>>>>>>> Email: gaurav16 at iiserb.ac.in <saquib16 at iiserb.ac.in>
>>>>>>>>>> Mob: +91-7471112407 <+91%2074711%2012407>
>>>>>>>>>> LinkedIn
>>>>>>>>>> <https://www.linkedin.com/in/gaurav-tiwari-bb36357a?trk=hp-identity-name>
>>>>>>>>>> Research gate
>>>>>>>>>> <https://www.researchgate.net/profile/Gaurav_Tiwari5>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> *[image: Description: Description: Description: Description:
>>>>>>>>>> Description: Description: Description: cid:image001.jpg at 01CC2469.06E9E6A0] **Please
>>>>>>>>>> consider the environment before printing this e-mail*
>>>>>>>>>>
>>>>>>>>>> _______________________________________________
>>>>>>>>>> ncl-talk mailing list
>>>>>>>>>> ncl-talk at ucar.edu
>>>>>>>>>> List instructions, subscriber options, unsubscribe:
>>>>>>>>>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>
>>>>>>>
>>>>>>
>>>>>
>>>>
>>>> _______________________________________________
>>>> ncl-talk mailing list
>>>> ncl-talk at ucar.edu
>>>> List instructions, subscriber options, unsubscribe:
>>>> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>>>>
>>>>
>>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170507/4830028a/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.png
Type: image/png
Size: 2898 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170507/4830028a/attachment.png 


More information about the ncl-talk mailing list