viewtif 0.1.10__py3-none-any.whl → 0.2.1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
viewtif/tif_viewer.py CHANGED
@@ -40,6 +40,10 @@ from PySide6.QtGui import QImage, QPixmap, QPainter, QPen, QColor, QPainterPath
40
40
  from PySide6.QtCore import Qt
41
41
 
42
42
  import matplotlib.cm as cm
43
+ import warnings
44
+ warnings.filterwarnings("ignore", category=RuntimeWarning, module="shapely")
45
+
46
+ __version__ = "0.2.1"
43
47
 
44
48
  # Optional overlay deps
45
49
  try:
@@ -729,7 +733,7 @@ def run_viewer(
729
733
  import click
730
734
 
731
735
  @click.command()
732
- @click.version_option("0.1.10", prog_name="viewtif")
736
+ @click.version_option("0.2.1", prog_name="viewtif")
733
737
  @click.argument("tif_path", required=False)
734
738
  @click.option("--band", default=1, show_default=True, type=int, help="Band number to display")
735
739
  @click.option("--scale", default=1.0, show_default=True, type=int, help="Scale factor for display")
@@ -1,7 +1,7 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: viewtif
3
- Version: 0.1.10
4
- Summary: Lightweight GeoTIFF, HDF/HDF5, and Esri File Geodatabase (.gdb) viewer with shapefile overlay and large-raster safeguard.
3
+ Version: 0.2.1
4
+ Summary: Lightweight GeoTIFF, NetCDF, HDF/HDF5, and Esri File Geodatabase (.gdb) viewer with optional shapefile overlay. NetCDF and cartopy support available via pip install viewtif[netcdf].
5
5
  Project-URL: Homepage, https://github.com/nkeikon/tifviewer
6
6
  Project-URL: Source, https://github.com/nkeikon/tifviewer
7
7
  Project-URL: Issues, https://github.com/nkeikon/tifviewer/issues
@@ -25,14 +25,7 @@ Description-Content-Type: text/markdown
25
25
 
26
26
  A lightweight GeoTIFF viewer for quick visualization directly from the command line.
27
27
 
28
- You can visualize single-band GeoTIFFs, RGB composites, and shapefile overlays in a simple Qt-based window.
29
-
30
- ---
31
- Latest stable release: v0.1.9 (PyPI)
32
-
33
- Development branch: v0.2.0-dev (experimental, not released)
34
-
35
- ---
28
+ You can visualize single-band GeoTIFFs, RGB composites, HDF, NetCDF files and shapefile overlays in a simple Qt-based window.
36
29
 
37
30
  ## Installation
38
31
 
@@ -52,7 +45,7 @@ pip install "viewtif[geo]"
52
45
  > **Note:** For macOS(zsh) users:
53
46
  > Make sure to include the quotes, or zsh will interpret it as a pattern.
54
47
 
55
- #### HDF/HDF5 support
48
+ #### HDF/HDF5 support
56
49
  ```bash
57
50
  brew install gdal # macOS
58
51
  sudo apt install gdal-bin python3-gdal # Linux
@@ -91,9 +84,15 @@ viewtif AG100.v003.33.-107.0001.h5 --subset 1 --band 3
91
84
  `[WARN] raster lacks CRS/transform; cannot place overlays.`
92
85
 
93
86
  ### Update in v1.0.7: File Geodatabase (.gdb) support
94
- `viewtif` can now open raster datasets stored inside Esri File Geodatabases (`.gdb`), using the GDAL `OpenFileGDB` driver.
87
+ `viewtif` can now open raster datasets stored inside Esri File Geodatabases (`.gdb`).
95
88
  When you open a .gdb directly, `viewtif` will list available raster datasets first, then you can choose one to view.
96
89
 
90
+ Most Rasterio installations already include the OpenFileGDB driver, so .gdb datasets often open without installing GDAL manually.
91
+
92
+ If you encounter:
93
+ RuntimeError: GDB support requires GDAL,
94
+ install GDAL as shown above to enable the driver.
95
+
97
96
  ```bash
98
97
  # List available raster datasets
99
98
  viewtif /path/to/geodatabase.gdb
@@ -101,7 +100,7 @@ viewtif /path/to/geodatabase.gdb
101
100
  # Open a specific raster
102
101
  viewtif "OpenFileGDB:/path/to/geodatabase.gdb:RasterName"
103
102
  ```
104
- > **Note:** Requires GDAL 3.7 or later with the OpenFileGDB driver enabled. If multiple raster datasets are present, viewtif lists them all and shows how to open each. The .gdb path and raster name must be separated by a colon (:).
103
+ > **Note:** If multiple raster datasets are present, viewtif lists them all and shows how to open each. The .gdb path and raster name must be separated by a colon (:).
105
104
 
106
105
  ### Update in v1.0.7: Large raster safeguard
107
106
  As of v1.0.7, `viewtif` automatically checks the raster size before loading.
@@ -116,12 +115,12 @@ You can proceed manually or rerun with the `--scale` option for a smaller, faste
116
115
  | `C` / `V` | Increase / decrease contrast |
117
116
  | `G` / `H` | Increase / decrease gamma |
118
117
  | `M` | Toggle colormap (`viridis` ↔ `magma`) |
119
- | `[` / `]` | Previous / next band (single-band only) |
118
+ | `[` / `]` | Previous / next band (or time step) |
120
119
  | `R` | Reset view |
121
120
 
122
121
  ## Features
123
122
  - Command-line driven GeoTIFF viewer.
124
- - Supports single-band, RGB composite, and HDF/HDF5 subdatasets.
123
+ - Supports single-band, RGB composite, HDF/HDF5 subdatasets, and NetCDF.
125
124
  - Optional shapefile overlay for geographic context.
126
125
  - Adjustable contrast, gamma, and colormap.
127
126
  - Fast preview using rasterio and PySide6.
@@ -142,5 +141,5 @@ Longenecker, Jake; Lee, Christine; Hulley, Glynn; Cawse-Nicholson, Kerry; Purkis
142
141
  This project is released under the MIT License.
143
142
 
144
143
  ## Contributors
145
- - [@HarshShinde0](https://github.com/HarshShinde0) — added mouse-wheel and trackpad zoom support
144
+ - [@HarshShinde0](https://github.com/HarshShinde0) — added mouse-wheel and trackpad zoom support; added NetCDF support with [@nkeikon](https://github.com/nkeikon)
146
145
  - [@p-vdp](https://github.com/p-vdp) — added File Geodatabase (.gdb) raster support
@@ -0,0 +1,5 @@
1
+ viewtif/tif_viewer.py,sha256=cHu62pMpvYFZD4MNhpsOme6AYD2eNAsd13FGmaxVSd8,31075
2
+ viewtif-0.2.1.dist-info/METADATA,sha256=EveWboZK5lTOaAXyzFCs6O5zaebSkdKCb9Al1Av_br4,6522
3
+ viewtif-0.2.1.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
4
+ viewtif-0.2.1.dist-info/entry_points.txt,sha256=NVEjlRyJ7R7hFPOVsZJio3Hl0VqlX7_oVfA7819XvHM,52
5
+ viewtif-0.2.1.dist-info/RECORD,,
@@ -1,5 +0,0 @@
1
- viewtif/tif_viewer.py,sha256=6mTylUguRn56QaJDZiNLSVPyqNWTDW_HKRRoa9eqjKY,30960
2
- viewtif-0.1.10.dist-info/METADATA,sha256=OTaQUPKmNLiL-L6Pvp5Sin3--KP6s3-MsNWQ7uJKWSk,6338
3
- viewtif-0.1.10.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
4
- viewtif-0.1.10.dist-info/entry_points.txt,sha256=NVEjlRyJ7R7hFPOVsZJio3Hl0VqlX7_oVfA7819XvHM,52
5
- viewtif-0.1.10.dist-info/RECORD,,