Hi Eric,
The problem originates with your file "Region_1_Rain-Bi_Interp.nc".
If you list it:
filename: Region_1_Rain-Bi_Interp
path: Region_1_Rain-Bi_Interp.nc
file global attributes:
creation_date : Thu Mar 26 16:57:19 EDT 2009
Conventions : None
source_file :
title : Interpolated Precipitation: NCL Efficient Approach to
netCDF Creation
dimensions:
time = 31 // unlimited
lat = 13
lon = 21
ncl3 = 30
variables:
float lat ( lat )
units : degrees_north
float lon ( lon )
units : degrees_east
float RAIN ( time, lat, lon )
description : Total Precipitation Interpolated to Lat and
Lon Grid
longname : Total Precipitation
units : mm
_FillValue : -999
integer time ( ncl3 )
---- you will notice that you have a dimension called "time" with size 31 and a variable called "time", but the variable "time" has a dimension "ncl3" with size 30. Since dimension "time" and variable "time" have the same name, NCL thinks the variable "time" should be the coordinate variable for the first dimension of "RAIN". When it tries to fetch the coordinate variable for the "time" dimension during the call to create a rearranged copy of the variable, it notices the size mismatch and generates an error that eventually results in a core dump. So it really has little to do with the named dimension assignment that does the rearrangement. But you have found a bug, for which I thank you. NCL should not use a variable as a coordinate variable unless its dimension name is the same as the variable name. This should ensure that dimension size mismatches cannot occur. We will be updating the code to fix this. -dave On Mar 27, 2009, at 3:13 PM, Erik Noble wrote: > Hi. I keep running into an error when I try to rearrange dimensions > (below, ncl 13>). The error also closes NCL. I have used these > steps without any problems on similar data with the earlier version > of NCL. What could be causing this? > Could I have some help? > sincerely, > Erik > > Last login: Thu Mar 26 15:01:28 on ttys000 > noble:~ enoble$ cd /Volumes/Noble-Terabyte/APPLE_WRF_model_Output/ > WRF-FNL_SOP3_ifort11.0_ICC > noble:WRF-FNL_SOP3_ifort11.0_ICC enoble$ ncl > Copyright (C) 1995-2009 - All Rights Reserved > University Corporation for Atmospheric Research > NCAR Command Language Version 5.1.0 > The use of this software is governed by a License Agreement. > See http://www.ncl.ucar.edu/ for more details. > ncl 0> load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl" > ncl 1> load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl" > ncl 2> load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl" > ncl 3> load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/shea_util.ncl" > ncl 4> load "$NCARG_ROOT/lib/ncarg/nclscripts/wrf/WRFUserARW.ncl" > ncl 5> wrfoutfile="Region_1_Rain-Bi_Interp.nc" > ncl 6> obsfile = "/Volumes/Data_and_Models/Precipitation_data/ > observed/TRMM/ASCII/Daily_TRMM_2006-09-.5x.5.nc" > ncl 7> a = addfile (wrfoutfile,"r") > ncl 8> b = addfile (obsfile,"r") > ncl 9> rain = a->RAIN > ncl 10> printVarSummary(rain) > > > Variable: rain > Type: float > Total Size: 33852 bytes > 8463 values > Number of Dimensions: 3 > Dimensions and sizes: [time | 31] x [lat | 13] x [lon | 21] > Coordinates: > time: [1..30] > lat: [ 5..11] > lon: [-30..-20] > Number Of Attributes: 4 > description : Total Precipitation Interpolated to Lat and Lon Grid > longname : Total Precipitation > units : mm > _FillValue : -999 > ncl 11> rainb = b->RAIN(0:30,{5:11},{-30:-20}) > ncl 12> printVarSummary(rainb) > > > Variable: rainb > Type: float > Total Size: 32760 bytes > 8190 values > Number of Dimensions: 3 > Dimensions and sizes: [time | 31] x [lat | 13] x [lon | 21] > Coordinates: > time: [1..30] > lat: [ 5..11] > lon: [-30..-20] > Number Of Attributes: 2 > units : mm > _FillValue : -999 > ncl 13> raintest = rain(time|:, lon|:, lat|:) > fatal:Subscript out of range, error in subscript #0 > fatal:An error occurred reading unknown > Bus error > noble:WRF-FNL_SOP3_ifort11.0_ICC enoble$ > > _______________________________________________ > 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 Fri Mar 27 2009 - 18:21:53 MDT
This archive was generated by hypermail 2.2.0 : Mon Apr 06 2009 - 10:23:30 MDT