Re: Problems with ESMF_regrid

From: Mary Haley <haley_at_nyahnyahspammersnyahnyah>
Date: Wed Sep 12 2012 - 12:59:15 MDT

Jane,

When you use the "conserve" method, you need to provide the grid corners, otherwise the NCL-ESMF software
will have to guess at them. I didn't see any grid corner lat/lon info on your NARR file, so we are having to
use whatever NCL guesses. I think in this case, the guess was not ideal, and hence you got a "concave"
error message.

I noticed that your source grid (the WRF grid) was in a smaller area than your destination grid (NARR),
so I decided to subscript the NARR grid to be roughly in the same area as the WRF grid, before
regridding. I used region_ind to do this.

Please see the attached modified version of your script and the resultant PDF file. You may want to play
around with the latS, latN, lonW, and lonE values if you want a larger area of the destination grid to be used.

Meanwhile, I will see if we can improve things so that in the future you don't have to subscript
the destination grid.

--Mary

On Sep 12, 2012, at 10:51 AM, jokalebo@huskers.unl.edu wrote:

> Yes Mary, I now notice that regridding from WRF to NARR works well with "bilinear" and "patch". It generates weights quite okay.
>
> ESMF_regrid_gen_weights: 'ESMF_RegridWeightGen' was successful.
>
> However, I get the message:
>
> (0) daily total precipitation: min=0 max=38.1984
> (0) check_for_y_lat_coord: Warning: Data either does not contain a valid latitude coordinate array or doesn't contain one at all.
> (0) A valid latitude coordinate array should have a 'units' attribute equal to one of the following values:
> (0) 'degrees_north' 'degrees-north' 'degree_north' 'degrees north' 'degrees_N' 'Degrees_north' 'degree_N' 'degreeN' 'degreesN' 'deg north'
> (0) check_for_lon_coord: Warning: Data either does not contain a valid longitude coordinate array or doesn't contain one at all.
> (0) A valid longitude coordinate array should have a 'units' attribute equal to one of the following values:
> (0) 'degrees_east' 'degrees-east' 'degree_east' 'degrees east' 'degrees_E' 'Degrees_east' 'degree_E' 'degreeE' 'degreesE' 'deg east'
> (0) get_lon_values: Warning: The range your of longitude values is greater than 360.
> (0) get_lon_values: Warning: The range your of longitude values is greater than 360.
>
>
> I have now sent the file to the incoming folder and these are the files:
>
> "narrmon-a_221_20020601_0000_000.nc"
> "ESMF_regrid_16.ncl"
> "WRF_monthly_CLM_2002_06.nc"
> and "narrmon-a_221_20020601_0000_000.grb"
>
> Please assist me address the problems that are mentioned above.
>
> I generated the narrmon-a_221_20020601_0000_000.nc file by converting a grib file using ncl_convert2nc
> Thanks.
>
>
>
> Jane Okalebo
> PhD student
> HPRCC, School of Natural Resources
> University of Nebraska-Lincoln
> 249 Hardin Hall
> 3310 Holdrege,
> Lincoln, Nebraska 68583-0749 U.S.A.
>
>
> ________________________________________
> From: Mary Haley [haley@ucar.edu]
> Sent: Wednesday, September 12, 2012 9:04 AM
> To: jokalebo@huskers.unl.edu
> Cc: ncl-talk@ucar.edu
> Subject: Re: Problems with ESMF_regrid
>
> Hi Jane,
>
> Just out of curiosity, do you get an error if you use the "bilinear" or "patch" method?
>
> Can you provide your script and data so we can run it here? I need to see what's causing the
> "concave cell" error, and I also may need to forward this to the ESMF folks.
>
> If you can provide the script and data, and you don't have a place to put the files, then see
> our ftp information at:
>
> http://www.ncl.ucar.edu/report_bug.shtml#HowToFTP
>
> --Mary
>
> On Sep 12, 2012, at 3:18 AM, jokalebo@huskers.unl.edu wrote:
>
>> Dear all,
>>
>>
>> I am using ESMF_regrid to regrid a WRF.nc file to destination file: NARR.nc. I am using the ESMF_regrid_16.ncl example.
>> The projection of both the WRF and NARR files are lambert conformal. I think they are both curvilinear.
>>
>>
>> However I was not successful
>>
>> (0) ESMF_regrid_gen_weights: output from 'ESMF_RegridWeightGen':
>> (0) Starting weight generation with these inputs:
>> (1) Source File: source_grid_file.nc
>> (2) Destination File: destination_grid_file.nc
>> (3) Weight File: weights_file.nc
>> (4) Source File is in SCRIP format
>> (5) Source Grid is a regional grid
>> (6) Source Grid is a logically rectangular grid
>> (7) Destination File is in SCRIP format
>> (8) Destination Grid is a regional grid
>> (9) Destination Grid is a logically rectangular grid
>> (10) Regrid Method: conserve
>> (11) Pole option: NONE
>> (12) Ignore unmapped destination points
>> (13)
>> (14) ERROR: Problem on processor 0 . Please see the PET*.RegridWeightGen.Log files for a traceback.
>> (0) --------------------------------------------------
>> (0) ESMF_regrid_gen_weights: 'ESMF_RegridWeightGen' was not successful.
>>
>>
>> I opened the PET*.RegridWeightGen.Log files and have these statements:
>>
>>
>> 20120912 040805.390 INFO PET0 Running with ESMF Version 5.2.0rp2
>> 20120912 040806.638 ERROR PET0 ESMCI_Regrid_F.C:146 c_esmc_regrid_create() Invalid argument - Dst contains a concave cell
>> 20120912 040806.638 ERROR PET0 ESMCI_Regrid_F.C:282 c_esmc_regrid_create() Invalid argument Internal subroutine call returned Error
>> 20120912 040806.638 ERROR PET0 ESMF_Regrid.F90:383 ESMF_RegridStore Invalid argument - Internal subroutine call returned Error
>> 20120912 040806.638 ERROR PET0 ESMF_FieldRegrid.F90:771 ESMF_FieldRegridStoreNX Invalid argument - Internal subroutine call returned Error
>>
>>
>> Jane Okalebo
>> PhD student
>> HPRCC, School of Natural Resources
>> University of Nebraska-Lincoln
>> 249 Hardin Hall
>> 3310 Holdrege,
>> Lincoln, Nebraska 68583-0749 U.S.A.
>>
>> _______________________________________________
>> 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 Wed Sep 12 12:59:31 2012

This archive was generated by hypermail 2.1.8 : Thu Sep 13 2012 - 14:22:31 MDT