Dear all,
thank you for help on legend thickness problem! I should have
searched more.
Now I experienced a segmentation fault with the ncl script below.
What I wanted was to adapt the script roms_1.ncl to my problem,
that is do a 2 dimensional draw of a field and I did only very
minimal modification to it.
What is the common cause of segfaults? What is general policy
against them? Also, maybe it would be good to have all the files
of example available from the web site so as to be able to test
all examples for correctness of installation.
Thank you,
Mathieu
The .nc files needed are available from the following links:
http://www.liga.ens.fr/~dutour/Sending/adria02_grid2.nc
http://www.liga.ens.fr/~dutour/Sending/ADRIA02_HydrostaticInsta.nc
The error I got on fedora 8 and fedora 5 is:
mathieu_at_oceanus:~/NCL_BathyPaperDraws$ ncl ADRIA02_Hydrostatic.ncl
Copyright (C) 1995-2007 - All Rights Reserved
University Corporation for Atmospheric Research
NCAR Command Language Version 4.3.1
The use of this software is governed by a License Agreement.
See http://www.ncl.ucar.edu/ for more details.
warning:GKS:GSVP: --RECTANGLE DEFINITION IS INVALID
fatal:MapSetTrans: error initializing map: MAPINT/MDPINT/GKS ERROR REPORTED
FROM libhlu.a(Error.o)
warning:GKS:GSVP: --RECTANGLE DEFINITION IS INVALID
fatal:MapSetTrans: error initializing map: MAPINT/MDPINT/GKS ERROR REPORTED
FROM libhlu.a(Error.o)
warning:["SetValues.c":474]:SetValuesChild never occurred on
map.PlotManager: Error in mapPlotClass
*** glibc detected *** ncl: realloc(): invalid pointer: 0x0c750ae8 ***
The program that create it is:
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl"
begin
grid= addfile("adria02_grid2.nc", "r")
lat2d = grid->lat_rho
lon2d = grid->lon_rho
f = addfile("ADRIA02_HydrostaticInsta.nc", "r")
rx1max= f->rx1max
rx1max_at_lat2d=lat2d
rx1max_at_lon2d=lon2d
wks = gsn_open_wks ("eps", "ADRIA02_Hydrostatic")
gsn_define_colormap (wks,"testcmap")
i = NhlNewColor(wks,0.8,0.8,0.8) ; add gray to colormap
res = True ; plot mods desired
res_at_cnFillOn = True ; color fill
res_at_cnLinesOn = False ; no contour lines
res_at_cnLineLabelsOn = False ; no contour labels
res_at_cnFillDrawOrder = "PreDraw" ; put continents on top
res_at_gsnSpreadColors = True ; use total colormap
res_at_gsnSpreadColorEnd = -3
res_at_cnInfoLabelOn = False ; no contour info label
res_at_mpProjection = "LambertConformal"
res_at_mpLambertParallel1F = grid->PLAT(0)
res_at_mpLambertParallel2F = grid->PLAT(1)
res_at_mpLambertMeridianF = grid->PLONG
res_at_mpLimitMode = "Corners" ; choose range of map
res_at_mpLeftCornerLatF = grid->P1
res_at_mpLeftCornerLonF = grid->P2
res_at_mpRightCornerLatF = grid->P3
res_at_mpRightCornerLonF = grid->P4
res_at_mpDataBaseVersion = "HighRes" ; use high resolution coast
res_at_pmTickMarkDisplayMode = "Always" ; turn on tickmarks
plot = gsn_csm_contour_map(wks,rx1max,res)
end
_______________________________________________
ncl-talk mailing list
ncl-talk_at_ucar.edu
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Mon Jan 21 2008 - 04:40:14 MST
This archive was generated by hypermail 2.2.0 : Wed Jan 23 2008 - 14:19:33 MST