From fc8f3bdeefc7e069c993e2665629670535466269 Mon Sep 17 00:00:00 2001 From: Dongdong Tian Date: Thu, 8 Aug 2024 00:02:33 +0800 Subject: [PATCH] GMT_IMAGE: Remove 'nan_value' from the doctest since it depends on GMT versions --- pygmt/datatypes/image.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pygmt/datatypes/image.py b/pygmt/datatypes/image.py index 63c267b1ca0..672c640c67d 100644 --- a/pygmt/datatypes/image.py +++ b/pygmt/datatypes/image.py @@ -18,7 +18,7 @@ class _GMT_IMAGE(ctp.Structure): # noqa: N801 >>> from pygmt.clib import Session >>> with Session() as lib: ... with lib.virtualfile_out(kind="image") as voutimg: - ... lib.call_module("read", ["@earth_day_01d", voutimg, "-Ti"]) + ... lib.call_module("read", ["@earth_day_01d_p", voutimg, "-Ti"]) ... # Read the image from the virtual file ... image = lib.read_virtualfile(vfname=voutimg, kind="image").contents ... # The image header @@ -34,7 +34,7 @@ class _GMT_IMAGE(ctp.Structure): # noqa: N801 ... print(header.nm, header.size, header.complex_mode) ... print(header.type, header.n_bands, header.mx, header.my) ... print(header.pad[:]) - ... print(header.mem_layout, header.nan_value, header.xy_off) + ... print(header.mem_layout, header.xy_off) ... # Image-specific attributes. ... print(image.type, image.n_indexed_colors) ... # The x and y coordinates @@ -58,7 +58,7 @@ class _GMT_IMAGE(ctp.Structure): # noqa: N801 64800 66976 0 0 3 364 184 [2, 2, 2, 2] - b'BRPa' 0.0 0.5 + b'BRPa' 0.5 1 0 >>> x [-179.5, -178.5, ..., 178.5, 179.5]