GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Only set Conventions = CF-1.7 attribute for NetCDF grid type · GenericMappingTools/pygmt@5888e10

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • pygmt/datatypes
    • header.py
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎pygmt/datatypes/header.py‎

Copy file name to clipboardExpand all lines: pygmt/datatypes/header.py
+2-1Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,8 @@ def data_attrs(self) -> dict[str, Any]:
203203
Attributes for the data variable from the grid header.
204204
"""
205205
attrs: dict[str, Any] = {}
206-
attrs["Conventions"] = "CF-1.7"
206+
if self.type == 18: # Grid file format: ns = GMT netCDF format
207+
attrs["Conventions"] = "CF-1.7"
207208
attrs["title"] = self.title.decode()
208209
attrs["history"] = self.command.decode()
209210
attrs["description"] = self.remark.decode()

0 commit comments

Comments
0 (0)
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.