rekado pushed a commit to branch master
in repository guix.

commit 0794869d0a355f5aa081c5010353f80f21a50325
Author: Ricardo Wurmus <[email protected]>
AuthorDate: Fri Jan 3 10:16:52 2025 +0100

    gnu: Add python-pyogrio.
    
    * gnu/packages/geo.scm (python-pyogrio): New variable.
    
    Change-Id: If0ab4652cf49a883191e7442465f761a68570286
---
 gnu/packages/geo.scm | 49 ++++++++++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 48 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/geo.scm b/gnu/packages/geo.scm
index 28cd33b677..36c8f719f5 100644
--- a/gnu/packages/geo.scm
+++ b/gnu/packages/geo.scm
@@ -3,7 +3,7 @@
 ;;; Copyright © 2016 Alex Griffin <[email protected]>
 ;;; Copyright © 2017, 2018 Björn Höfling <[email protected]>
 ;;; Copyright © 2018–2021 Tobias Geerinckx-Rice <[email protected]>
-;;; Copyright © 2018, 2023, 2024 Ricardo Wurmus <[email protected]>
+;;; Copyright © 2018, 2023-2025 Ricardo Wurmus <[email protected]>
 ;;; Copyright © 2018, 2019 Arun Isaac <[email protected]>
 ;;; Copyright © 2018 Joshua Sierles, Nextjournal <[email protected]>
 ;;; Copyright © 2018, 2019, 2020, 2021 Julien Lepiller <[email protected]>
@@ -859,6 +859,53 @@ projections.")
                    ;; cmake/*
                    license:boost1.0))))
 
+(define-public python-pyogrio
+  (package
+    (name "python-pyogrio")
+    (version "0.10.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (pypi-uri "pyogrio" version))
+       (sha256
+        (base32 "0g5j3a2n5hdnmi45261y84rqk1bikcvrdblgh9wfhk9jd2siq1gc"))))
+    (properties
+     `((updater-extra-inputs . ("gdal"))))
+    (build-system pyproject-build-system)
+    (arguments
+     (list
+      #:test-flags
+      ;; These tests need Internet access.
+      '(list "-k" (string-append "not test_url"
+                                 " and not test_url_with_zip"
+                                 " and not test_uri_s3"))
+      #:phases
+      '(modify-phases %standard-phases
+         (add-before 'check 'build-extensions
+           (lambda _
+             (invoke "python" "setup.py" "build_ext" "--inplace"))))))
+    (propagated-inputs (list python-certifi python-numpy python-packaging))
+    (inputs (list gdal))
+    (native-inputs (list python-cython-3
+                         python-pytest
+                         python-pytest-cov
+                         python-setuptools
+                         python-tomli
+                         python-versioneer
+                         python-wheel))
+    (home-page "https://pypi.org/project/pyogrio/";)
+    (synopsis "Vectorized spatial vector file format I/O using GDAL/OGR")
+    (description "Pyogrio provides a GeoPandas-oriented API to OGR vector data
+sources, such as ESRI Shapefile, GeoPackage, and GeoJSON.  Vector data sources
+have geometries, such as points, lines, or polygons, and associated records
+with potentially many columns worth of data.  Pyogrio uses a vectorized
+approach for reading and writing GeoDataFrames to and from OGR vector data
+sources in order to give you faster interoperability.  It uses pre-compiled
+bindings for GDAL/OGR so that the performance is primarily limited by the
+underlying I/O speed of data source drivers in GDAL/OGR rather than multiple
+steps of converting to and from Python data types within Python.")
+    (license license:expat)))
+
 (define-public python-pyproj
   (package
     (name "python-pyproj")

Reply via email to