<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content="text/html; charset=utf-8" http-equiv=Content-Type>
<STYLE>
BLOCKQUOTE {
        MARGIN-BOTTOM: 0px; MARGIN-LEFT: 2em; MARGIN-TOP: 0px
}
OL {
        MARGIN-BOTTOM: 0px; MARGIN-TOP: 0px
}
UL {
        MARGIN-BOTTOM: 0px; MARGIN-TOP: 0px
}
DIV.FoxDiv20150324112727576919 {
        COLOR: #000000
}
P {
        MARGIN-BOTTOM: 0px; MARGIN-TOP: 0px
}
DIV.FoxDiv20150324114958256214 {
        FONT-SIZE: 10.5pt; FONT-FAMILY: 微软雅黑; COLOR: #000080; MARGIN: 10px; LINE-HEIGHT: 1.5
}
BODY {
        FONT-SIZE: 10.5pt; FONT-FAMILY: 微软雅黑; COLOR: #000080; LINE-HEIGHT: 1.5
}
</STYLE>
<META name=GENERATOR content="MSHTML 11.00.9600.17690">
<STYLE>BLOCKQUOTE {
        MARGIN-TOP: 0px
}
OL {
        MARGIN-TOP: 0px
}
UL {
        MARGIN-TOP: 0px
}
</STYLE>
</HEAD>
<BODY style="MARGIN: 10px">
<DIV><SPAN><SPAN
style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; COLOR: #000000"><FONT
style="FONT-SIZE: 10.5pt; FONT-FAMILY: Times New Roman; FONT-WEIGHT: bold"
color=#008000 size=1 face=""><SPAN
style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; COLOR: #000000"><FONT
style="FONT-WEIGHT: normal; COLOR: #000000" color=#000001 face=微软雅黑>And I use
the pre-compiled binary version which is downloaded from the NCAR
website.</FONT></DIV></SPAN></FONT></SPAN><SPAN
style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; COLOR: #000000"></SPAN></SPAN>
<DIV> </DIV>
<DIV
style="BORDER-TOP: #b5c4df 1pt solid; BORDER-RIGHT: medium none; BORDER-BOTTOM: medium none; PADDING-BOTTOM: 0cm; PADDING-TOP: 3pt; PADDING-LEFT: 0cm; BORDER-LEFT: medium none; PADDING-RIGHT: 0cm">
<DIV
style="FONT-SIZE: 12px; BACKGROUND: #efefef; COLOR: #000000; PADDING-BOTTOM: 8px; PADDING-TOP: 8px; PADDING-LEFT: 8px; PADDING-RIGHT: 8px">
<DIV><B>From:</B> <A
href="mailto:fengfengabc003@163.com">ChenFeng</A></DIV>
<DIV><B>Date:</B> 2015-03-24 11:47</DIV>
<DIV><B>To:</B> <A href="mailto:shea@ucar.edu">Dennis Shea</A>; <A
href="mailto:alexander.schaefer@mines.sdsmt.edu">alexander.schaefer</A></DIV>
<DIV><B>CC:</B> <A href="mailto:ncl-talk@ucar.edu">ncl-talk</A></DIV>
<DIV><B>Subject:</B> Re: Re: [ncl-talk] Segmentation fault when reading
variables from NC</DIV></DIV></DIV>
<DIV>
<DIV class=FoxDiv20150324114958256214>
<STYLE>BLOCKQUOTE {
        MARGIN-BOTTOM: 0px; MARGIN-LEFT: 2em; MARGIN-TOP: 0px
}
OL {
        MARGIN-BOTTOM: 0px; MARGIN-TOP: 0px
}
UL {
        MARGIN-BOTTOM: 0px; MARGIN-TOP: 0px
}
DIV.FoxDiv20150324112727576919 {
        COLOR: #000000
}
P {
        MARGIN-BOTTOM: 0px; MARGIN-TOP: 0px
}
</STYLE>
<META name=GENERATOR content="MSHTML 11.00.9600.17690">
<DIV><SPAN><SPAN
style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; COLOR: #000000"><FONT
style="FONT-SIZE: 10.5pt; FONT-FAMILY: Times New Roman; FONT-WEIGHT: bold"
color=#008000 size=1 face=""><SPAN
style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; COLOR: #000000"><FONT color=#000080
face=微软雅黑>
<DIV style="FONT-WEIGHT: normal; COLOR: #000000">Thanks Dennis and Alexander
</DIV>
<DIV
style="FONT-WEIGHT: normal; COLOR: #000000">The reason I use the printVarSummary(lon2d) is only want to make sure whether the code above this line is correct.</DIV>
<DIV
style="FONT-WEIGHT: normal; COLOR: #000000">There is no problem when I use this code to read another geo_em.d01.nc file. So I think there is something wrong with the NC file. But I can use ncdump to see the structure and find nothing special.</DIV>
<DIV
style="FONT-WEIGHT: normal; COLOR: #000000">Is the variable dimention too large (474*524)? But I have also use this ncl version to read variables more large than this.</DIV>
<DIV
style="FONT-WEIGHT: normal; COLOR: #000000">I attached the file. Could you please help me check it with another ncl version and platform.</DIV>
<DIV style="FONT-WEIGHT: normal; COLOR: #000000">Thanks.</DIV>
<DIV style="FONT-WEIGHT: normal; COLOR: #000000"> </DIV>
<DIV
style="FONT-WEIGHT: normal; COLOR: #000000">Feng</DIV></FONT></DIV></SPAN></FONT></SPAN><SPAN
style="FONT-SIZE: 10.5pt; FONT-FAMILY: 宋体; COLOR: #000000"></SPAN></SPAN>
<DIV> </DIV>
<DIV
style="BORDER-TOP: #b5c4df 1pt solid; BORDER-RIGHT: medium none; BORDER-BOTTOM: medium none; PADDING-BOTTOM: 0cm; PADDING-TOP: 3pt; PADDING-LEFT: 0cm; BORDER-LEFT: medium none; PADDING-RIGHT: 0cm">
<DIV
style="FONT-SIZE: 12px; BACKGROUND: #efefef; COLOR: #000000; PADDING-BOTTOM: 8px; PADDING-TOP: 8px; PADDING-LEFT: 8px; PADDING-RIGHT: 8px">
<DIV><B>From:</B> <A href="mailto:shea@ucar.edu">Dennis Shea</A></DIV>
<DIV><B>Date:</B> 2015-03-23 22:40</DIV>
<DIV><B>To:</B> <A href="mailto:fengfengabc003@163.com">ChenFeng</A></DIV>
<DIV><B>CC:</B> <A href="mailto:ncl-talk@ucar.edu">ncl-talk</A></DIV>
<DIV><B>Subject:</B> Re: [ncl-talk] Segmentation fault when reading
variables from NC</DIV></DIV></DIV>
<DIV>
<DIV class=FoxDiv20150324112727576919>
<DIV dir=ltr>Also, forgot to mention ...<BR><BR>Using named dimensions should
only be done when reordering an array. Nothing wrong with doing so but is
is less efficient than
..<BR><BR>lon2d = inp0->XLONG_M (0, :, :)<BR></DIV>
<DIV class=gmail_extra><BR>
<DIV class=gmail_quote>On Mon, Mar 23, 2015 at 8:11 AM, Dennis Shea <SPAN
dir=ltr><<A href="mailto:shea@ucar.edu"
target=_blank>shea@ucar.edu</A>></SPAN> wrote:<BR>
<BLOCKQUOTE class=gmail_quote
style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">
<DIV dir=ltr>
<DIV>I don't understand why either. 6.1.2 is no longer available here so
I can not test with 6.1.2<BR><BR></DIV>When it does work ... what does
printVarSummary(lon2d) indicate?<BR></DIV>
<DIV class=gmail_extra><BR>
<DIV class=gmail_quote>
<DIV>
<DIV class=h5>On Mon, Mar 23, 2015 at 2:47 AM, ChenFeng <SPAN dir=ltr><<A
href="mailto:fengfengabc003@163.com"
target=_blank>fengfengabc003@163.com</A>></SPAN> wrote:<BR></DIV></DIV>
<BLOCKQUOTE class=gmail_quote
style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">
<DIV>
<DIV class=h5><U></U>
<DIV
style="FONT-SIZE: 10pt; FONT-FAMILY: 微软雅黑; COLOR: #000000; MARGIN-LEFT: 10px; MARGIN-TOP: 10px; MARGIN-RIGHT: 10px">
<DIV>Hi ncl-users,</DIV>
<DIV> </DIV>
<DIV>I have encounted an error when reading a variable from an NC file.</DIV>
<DIV>the code is listed below:</DIV>
<DIV>;************************************************</DIV>
<DIV>load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"</DIV>
<DIV>;************************************************</DIV>
<DIV>begin</DIV>
<DIV> inp0 = addfile("/public/home/chenf/AHWRF/TEST/WPSwks.T02/<A
href="http://geo_em.d01.nc" target=_blank>geo_em.d01.nc</A>","r")</DIV>
<DIV
style="FONT-WEIGHT: bold"> lon2d = inp0->XLONG_M (Time|0, south_north|:, west_east|:)</DIV>
<DIV> printVarSummary(lon2d)</DIV>
<DIV>;************************************************</DIV>
<DIV>end</DIV>
<DIV> </DIV>
<DIV>the error message is:</DIV>
<DIV> Copyright (C) 1995-2013 - All Rights Reserved</DIV>
<DIV> University Corporation for Atmospheric Research</DIV>
<DIV> NCAR Command Language Version 6.1.2</DIV>
<DIV> The use of this software is governed by a License Agreement.</DIV>
<DIV> See <A href="http://www.ncl.ucar.edu/"
target=_blank>http://www.ncl.ucar.edu/</A> for more details.</DIV>
<DIV>Segmentation fault (core dumped)</DIV>
<DIV> </DIV>
<DIV>The strange thing is when i'm reading the variable without any dimention name cited, the error disappeared.</DIV>
<DIV>The code changes into :</DIV>
<DIV>;************************************************</DIV>
<DIV>load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"</DIV>
<DIV>;************************************************</DIV>
<DIV>begin</DIV>
<DIV> inp0 = addfile("/public/home/chenf/AHWRF/TEST/WPSwks.T02/<A
href="http://geo_em.d01.nc" target=_blank>geo_em.d01.nc</A>","r")</DIV>
<DIV
style="FONT-WEIGHT: bold"> lon2d = inp0->XLONG_M</DIV>
<DIV> printVarSummary(lon2d)</DIV>
<DIV>;************************************************</DIV>
<DIV>end</DIV>
<DIV> </DIV>
<DIV>I don't understand why. It is very appreciate if anybody can tell
me the reason.</DIV>
<DIV>Thanks.</DIV>
<DIV> </DIV>
<DIV>Feng</DIV></DIV><BR></DIV></DIV>_______________________________________________<BR>ncl-talk
mailing list<BR>List instructions, subscriber options, unsubscribe:<BR><A
href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk"
target=_blank>http://mailman.ucar.edu/mailman/listinfo/ncl-talk</A><BR><BR></BLOCKQUOTE></DIV><BR></DIV></BLOCKQUOTE></DIV><BR></DIV></DIV></DIV></DIV></DIV></BODY></HTML>