Re: Regrid T62 data to POP grid

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Thu Oct 31 2013 - 21:50:43 MDT

Prasad,

Can you please be more specific about what you mean about the weight file being wrong? Are you getting some kind of error message, or are the values incorrect, or something else?

--Mary

On Oct 31, 2013, at 5:35 AM, "Prasad, Siva" <sp4436@mun.ca> wrote:

> Hi Dennis
>
> Thank you very much. I could resolve the error with the suggested change.
>
> Unfortunately, weightfile seems to be wrong.
>
> Regards
> Siva
>
>
> On Wed, Oct 30, 2013 at 4:57 PM, Dennis Shea <shea@ucar.edu> wrote:
> I am not sure about this but I speculate that the
> variable 'air' on the file is type short.
> It *must* be unscaled prior to use.
>
> short air(time,lat,lon)
> ^^^^^
>
> plus it will have associated attributes named:
> "add_offset" and "scale_factor"
>
> ===
>
> Try:
>
> var = short2flt(f->air)
>
> http://www.ncl.ucar.edu/Document/Functions/Contributed/short2flt.shtml
>
> ===
> The 1st rule of data processing is 'look at your data'.
>
> Please use the following to examimine file contents.
>
> %> ncdump -h air.2m.gauss.1997.nc | less
>
> or
>
> %> ncl_filedump air.2m.gauss.1997.nc | less
>
>
>
> On 10/30/13 11:48 AM, Prasad, Siva wrote:
> Hi all,
>
> I am new to NCL. I have generated a weight file for T62
> (map_T62_to_gx3_bilin_da_301310.nc)
>
> I tried to use the following ncl script to remap to the POP but it shows
> error
>
> load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"
> load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl"
> load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl"
> load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/popRemap.ncl"
>
> a = addfile("air.2m.gauss.1997.nc","r")
> var = a->air
> remap = PopLatLon(var,"T62","gx3","bilin","da","301310")
>
> out=addfile("t_10.nc","c")
> filedimdef(out,"time",-1,True)
> out->t10=remap
>
> I get the following error
>
> (0)
> (0) create_rmpPopFileName: ./map_T62_to_gx3_bilin_da_301310.nc
> fatal:pop_remap: dst_array must be of type float or double
> fatal:["Execute.c":8128]:Execute: Error occurred at or near line 462 in
> file $NCARG_ROOT/lib/ncarg/nclscripts/csm/popRemap.ncl
>
> fatal:["Execute.c":8128]:Execute: Error occurred at or near line 642 in
> file $NCAT
>
> Thanks and Regards
> Nandu
>
>
>
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
>
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Thu Oct 31 21:50:46 2013

This archive was generated by hypermail 2.1.8 : Fri Nov 01 2013 - 08:58:14 MDT