Closed
Description
Description of the problem
There appears to be a double-frame on the x and y-axis when making a perspective plot using grdview
with the -Jz
flag. Originally detected at GenericMappingTools/pygmt#589 (comment).
Actual (incorrect) plot | Expected (correct) plot |
---|---|
![]() |
![]() |
Full script that generated the error
gmt begin doubleframe png
gmt grdcut @earth_relief_01d_g -R-116/-109/-47/-44 -Gtempgrid.nc
gmt grdview tempgrid.nc -p225/30 -Jz0.005 -Bzaf -Vd
gmt end
Full error message
gmt [DEBUG]: Obtained the ppid from parent: 176
gmt [DEBUG]: Enter: gmtinit_new_GMT_ctrl
gmt [DEBUG]: GMT->session.SHAREDIR = /srv/conda/envs/notebook/share/gmt
gmt [DEBUG]: GMT->session.HOMEDIR = /home/jovyan
gmt [DEBUG]: GMT->session.USERDIR = /home/jovyan/.gmt [created]
gmt [DEBUG]: GMT->session.CACHEDIR = /home/jovyan/.gmt/cache [created]
gmt [DEBUG]: GMT: 0. Will try to find subdir=postscriptlight stem = PSL_custom_fonts suffix=.txt
gmt [DEBUG]: GMT: 1. gmt_getsharepath trying current dir
gmt [DEBUG]: GMT: 2. gmt_getsharepath trying USERDIR /home/jovyan/.gmt
gmt [DEBUG]: GMT: 3. gmt_getsharepath trying USERDIR subdir /home/jovyan/.gmt/postscriptlight
gmt [DEBUG]: GMT: 4. gmt_getsharepath trying SHAREDIR subdir /srv/conda/envs/notebook/share/gmt/postscriptlight
gmt [DEBUG]: GMT: 5. gmt_getsharepath trying SHAREDIR /srv/conda/envs/notebook/share/gmt
gmt [DEBUG]: GMT: 6. gmt_getsharepath failed
gmt [DEBUG]: Map distance calculation will be Cartesian
gmt [DEBUG]: Exit: gmtinit_new_GMT_ctrl
gmt [DEBUG]: Enter: New_PSL_Ctrl
gmt [DEBUG]: Exit: New_PSL_Ctrl
gmt [DEBUG]: Enter: gmt_manage_workflow
gmt [DEBUG]: GMT now running in modern mode [Session ID = 176]
gmt [DEBUG]: Exit : gmt_manage_workflow
gmt [DEBUG]: Enter: PSL_beginsession
gmt [DEBUG]: Exit : PSL_beginsession
gmt [DEBUG]: Enter: PSL_setdefaults
gmt [DEBUG]: Exit : PSL_setdefaults
gmt [DEBUG]: Enter: gmtlib_io_init
gmt [DEBUG]: Exit : gmtlib_io_init
gmt [DEBUG]: Enter: gmt_hash_init
gmt [DEBUG]: Exit: gmt_hash_init
gmt [DEBUG]: Enter: gmt_hash_init
gmt [DEBUG]: Exit: gmt_hash_init
gmt [DEBUG]: Enter: gmt_reload_settings
gmt [DEBUG]: The PROJ_GEODESIC set to Vincenty
gmt [DEBUG]: gmtlib_get_graphics_item: Fig: 0 Subplot: 2 Panel: () Inset: 0
gmt [DEBUG]: Reading GMT Default parameters from file: /home/jovyan/.gmt/sessions/gmt_session.176/gmt.conf
gmt [DEBUG]: Exit: gmt_reload_settings
gmt [DEBUG]: Enter: gmtlib_plot_C_format
gmt [DEBUG]: Exit: gmtlib_plot_C_format
gmt [DEBUG]: Enter: gmtinit_get_history
gmt [DEBUG]: gmtlib_get_graphics_item: Fig: 0 Subplot: 2 Panel: () Inset: 0
gmt [DEBUG]: Enter: gmt_hash_init
gmt [DEBUG]: Exit: gmt_hash_init
gmt [DEBUG]: Exit: gmtinit_get_history
gmt [DEBUG]: Initialize FFTW with 6 threads.
gmt [DEBUG]: GMT_Create_Session initialized GMT structure
gmt [DEBUG]: Loading core GMT shared library: libgmt.so
gmt [DEBUG]: Shared Library # 0 (core). Path = libgmt.so
gmt [DEBUG]: Loading GMT plugins from: /srv/conda/envs/notebook/lib/gmt/plugins
gmt [DEBUG]: Shared Library # 1 (supplements). Path = /srv/conda/envs/notebook/lib/gmt/plugins/supplements.so
gmt [DEBUG]: GMT now running in modern mode [Session ID = 176]
gmt [DEBUG]: Use PS filename /home/jovyan/.gmt/sessions/gmt_session.176/gmt_0.ps-
gmt [DEBUG]: gmtinit_get_current_panel: No current panel selected so not in subplot mode
gmt [DEBUG]: Modern mode: Added -R to options since history is available.
gmt [DEBUG]: Modern: Adding -JX15c to options since there is no history available.
gmt [DEBUG]: Revised options: tempgrid.nc -p225/30 -Jz0.005 -Bzaf -Vd -R -JX15c
grdview [DEBUG]: History: Process -p225/30
grdview [DEBUG]: History: Process -Jz0.005
grdview [DEBUG]: History: Process -R
grdview [DEBUG]: History: Process -JX15c
grdview [DEBUG]: gmt_get_filename: In: -116/-109/-47/-44 Out: -116/-109/-47/-44
grdview [DEBUG]: Look for file -116/-109/-47/-44 in /home/jovyan/.gmt
grdview [DEBUG]: Look for file -116/-109/-47/-44 in /home/jovyan/.gmt/cache
grdview [DEBUG]: Look for file -116/-109/-47/-44 in /home/jovyan/.gmt/server
grdview [DEBUG]: Got regular w/e/s/n for region (-116/-109/-47/-44)
grdview [DEBUG]: gmt_get_filename: In: tempgrid.nc Out: tempgrid.nc
grdview [DEBUG]: Found readable file tempgrid.nc
grdview [DEBUG]: Replace file tempgrid.nc with path tempgrid.nc
grdview [DEBUG]: Replace file tempgrid.nc with tempgrid.nc
grdview [DEBUG]: Local file /home/jovyan/.gmt/server/gmt_data_server.txt found
grdview [DEBUG]: File /home/jovyan/.gmt/server/gmt_data_server.txt less than 24 hours old, refresh is premature.
grdview [DEBUG]: Load contents from /home/jovyan/.gmt/server/gmt_data_server.txt
grdview [DEBUG]: Local file /home/jovyan/.gmt/server/gmt_hash_server.txt found
grdview [DEBUG]: File /home/jovyan/.gmt/server/gmt_hash_server.txt less than 24 hours old, refresh is premature.
grdview [DEBUG]: gmt_get_filename: In: tempgrid.nc Out: tempgrid.nc
grdview [DEBUG]: Found readable file tempgrid.nc
grdview [DEBUG]: Replace file tempgrid.nc with path tempgrid.nc
grdview [DEBUG]: gmt_get_filename: In: tempgrid.nc Out: tempgrid.nc
grdview [DEBUG]: Found readable file tempgrid.nc
grdview [DEBUG]: Replace file tempgrid.nc with path tempgrid.nc
grdview [DEBUG]: gmt_get_filename: In: tempgrid.nc Out: tempgrid.nc
grdview [DEBUG]: gmt_get_filename: In: tempgrid.nc Out: tempgrid.nc
grdview [DEBUG]: Found readable file tempgrid.nc
grdview [DEBUG]: Object ID 0 : Registered Grid File tempgrid.nc as an Input resource with geometry Surface [n_objects = 1]
grdview [DEBUG]: gmtapi_begin_io: Input resource access is now enabled [container]
grdview [DEBUG]: gmtapi_import_grid: Passed ID = 0 and mode = 1
grdview [DEBUG]: Found readable file tempgrid.nc
grdview [DEBUG]: gmt_get_filename: In: tempgrid.nc Out: tempgrid.nc
grdview [DEBUG]: Call gmtgrdio_doctor_geo_increments on a geographic grid
grdview [DEBUG]: Geographic input grid, longitudes span less than 360
grdview [DEBUG]: GMT_End_IO: Input resource access is now disabled
grdview [DEBUG]: Projected values in meters: -3.5 3.5 -47 -44
grdview [DEBUG]: Auto-frame interval for axis 2 item 0: d = 200 f = 100
grdview [INFORMATION]: Auto-frame interval for z-axis (item 0): a200f100
grdview [INFORMATION]: Map scale is 0.000466667 km per cm or 1:46.6667.
grdview [INFORMATION]: Processing shape grid
grdview [DEBUG]: gmtapi_begin_io: Input resource access is now enabled [container]
grdview [DEBUG]: gmtapi_import_grid: Passed ID = 0 and mode = 2
grdview [INFORMATION]: Reading grid from file tempgrid.nc
grdview [DEBUG]: packed z-range: [-3606.5,-2614.5]
grdview [DEBUG]: Geographic input grid, longitudes span less than 360
grdview [DEBUG]: Chosen boundary condition for all edges: geographic
grdview [INFORMATION]: Set boundary condition for all edges: natural
grdview [INFORMATION]: Set boundary condition for left edge: natural
grdview [INFORMATION]: Set boundary condition for right edge: natural
grdview [INFORMATION]: Set boundary condition for bottom edge: natural
grdview [INFORMATION]: Set boundary condition for top edge: natural
grdview [DEBUG]: GMT_End_IO: Input resource access is now disabled
grdview [DEBUG]: Octant 4 (az = 153.435) one = 1
grdview [DEBUG]: Outer loop over x doing 6:-1:-1
grdview [DEBUG]: Inner loop over y doing 1:1:4
grdview [INFORMATION]: Start creating PostScript plot
grdview [DEBUG]: Running in PS mode modern
grdview [DEBUG]: Use PS filename /home/jovyan/.gmt/sessions/gmt_session.176/gmt_0.ps-
grdview [DEBUG]: Create hidden PS file /home/jovyan/.gmt/sessions/gmt_session.176/gmt_0.ps-
grdview [DEBUG]: No figure file /home/jovyan/.gmt/sessions/gmt_session.176/gmt.figures - nothing to do
grdview [DEBUG]: Got session name as doubleframe and default graphics formats as png
grdview [INFORMATION]: Do mesh plot with mesh color white
grdview [DEBUG]: Current size of half-baked PS file /home/jovyan/.gmt/sessions/gmt_session.176/gmt_0.ps- = 22543.
grdview [DEBUG]: gmtlib_garbage_collection: Destroying object: C=0 A=0 ID=0 W=Input F=Grid M=File S=Used P=56499f4a5350 N=tempgrid.nc
grdview [DEBUG]: GMTAPI_Garbage_Collection freed 1 memory objects
grdview [DEBUG]: gmtlib_unregister_io: Unregistering object no 0 [n_objects = 0]
grdview (gmtlib_free_tmp_arrays): tried to free unallocated memory
gmt [DEBUG]: Entering GMT_Destroy_Session
gmt [DEBUG]: gmtlib_get_graphics_item: Fig: 0 Subplot: 2 Panel: () Inset: 0
System information
I've reproduced this both on my personal computer and on the try-gmt.
- Operating system: Linux-4.19.112+-x86_64-with-glibc2.10
- GMT version (
gmt --version
): 6.1.1