pyogrio 0.7.2__cp310-cp310-win_amd64.whl → 0.9.0__cp310-cp310-win_amd64.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.

Potentially problematic release.


This version of pyogrio might be problematic. Click here for more details.

Files changed (83) hide show
  1. pyogrio/__init__.py +7 -3
  2. pyogrio/_compat.py +6 -1
  3. pyogrio/_err.c +855 -321
  4. pyogrio/_err.cp310-win_amd64.pyd +0 -0
  5. pyogrio/_err.pyx +7 -3
  6. pyogrio/_geometry.c +134 -75
  7. pyogrio/_geometry.cp310-win_amd64.pyd +0 -0
  8. pyogrio/_io.c +28462 -22659
  9. pyogrio/_io.cp310-win_amd64.pyd +0 -0
  10. pyogrio/_io.pyx +904 -242
  11. pyogrio/_ogr.c +1317 -1640
  12. pyogrio/_ogr.cp310-win_amd64.pyd +0 -0
  13. pyogrio/_ogr.pxd +69 -13
  14. pyogrio/_ogr.pyx +8 -24
  15. pyogrio/_version.py +3 -3
  16. pyogrio/_vsi.c +6815 -0
  17. pyogrio/_vsi.cp310-win_amd64.pyd +0 -0
  18. pyogrio/_vsi.pxd +4 -0
  19. pyogrio/_vsi.pyx +140 -0
  20. pyogrio/core.py +43 -44
  21. pyogrio/gdal_data/GDAL-targets-release.cmake +1 -1
  22. pyogrio/gdal_data/GDAL-targets.cmake +10 -6
  23. pyogrio/gdal_data/GDALConfigVersion.cmake +3 -3
  24. pyogrio/gdal_data/gdalinfo_output.schema.json +2 -0
  25. pyogrio/gdal_data/gdalvrt.xsd +163 -0
  26. pyogrio/gdal_data/ogrinfo_output.schema.json +12 -1
  27. pyogrio/gdal_data/vcpkg.spdx.json +23 -23
  28. pyogrio/gdal_data/vcpkg_abi_info.txt +29 -28
  29. pyogrio/geopandas.py +140 -34
  30. pyogrio/proj_data/ITRF2008 +2 -2
  31. pyogrio/proj_data/proj-config-version.cmake +2 -2
  32. pyogrio/proj_data/proj-config.cmake +2 -1
  33. pyogrio/proj_data/proj-targets-release.cmake +0 -1
  34. pyogrio/proj_data/proj-targets.cmake +10 -6
  35. pyogrio/proj_data/proj.db +0 -0
  36. pyogrio/proj_data/proj4-targets-release.cmake +0 -1
  37. pyogrio/proj_data/proj4-targets.cmake +10 -6
  38. pyogrio/proj_data/vcpkg.spdx.json +21 -43
  39. pyogrio/proj_data/vcpkg_abi_info.txt +16 -17
  40. pyogrio/raw.py +438 -116
  41. pyogrio/tests/conftest.py +75 -6
  42. pyogrio/tests/fixtures/poly_not_enough_points.shp.zip +0 -0
  43. pyogrio/tests/test_arrow.py +841 -7
  44. pyogrio/tests/test_core.py +99 -7
  45. pyogrio/tests/test_geopandas_io.py +827 -121
  46. pyogrio/tests/test_path.py +23 -3
  47. pyogrio/tests/test_raw_io.py +276 -50
  48. pyogrio/util.py +39 -19
  49. pyogrio-0.9.0.dist-info/DELVEWHEEL +2 -0
  50. {pyogrio-0.7.2.dist-info → pyogrio-0.9.0.dist-info}/METADATA +2 -2
  51. {pyogrio-0.7.2.dist-info → pyogrio-0.9.0.dist-info}/RECORD +72 -67
  52. {pyogrio-0.7.2.dist-info → pyogrio-0.9.0.dist-info}/WHEEL +1 -1
  53. pyogrio.libs/Lerc-5e4d8cbeeabca06f95e2270792304dc3.dll +0 -0
  54. pyogrio.libs/{gdal-c3b1d8f66682071d0cd26d86e4182013.dll → gdal-b434963605a006e01c486c0df6dea4e0.dll} +0 -0
  55. pyogrio.libs/geos-f0622d0794b81c937a851b2e6fa9b712.dll +0 -0
  56. pyogrio.libs/geos_c-0e16bf70612fc3301d077b9d863a3fdb.dll +0 -0
  57. pyogrio.libs/{geotiff-e43cdab688866b59f8800cfcde836d16.dll → geotiff-772e7c705fb15ddf91b432adb4eb1f6c.dll} +0 -0
  58. pyogrio.libs/iconv-2-8fcc23ddc6f096c45871011b6e008b44.dll +0 -0
  59. pyogrio.libs/{jpeg62-567ab743ac805dfb57fe3867ba5788a4.dll → jpeg62-2f9b7af22d78338e8f0be0058503dc35.dll} +0 -0
  60. pyogrio.libs/json-c-e52a077545e4057de42beb4948289b41.dll +0 -0
  61. pyogrio.libs/libcurl-bc81cd8afe15b10c0821b181b6af8bd0.dll +0 -0
  62. pyogrio.libs/libexpat-fbe03ca8917dfda776562d4338b289b8.dll +0 -0
  63. pyogrio.libs/{liblzma-de7f4770d4e3715acd031ca93883f10c.dll → liblzma-6b36f24d54d3dd45f274a2aebef81085.dll} +0 -0
  64. pyogrio.libs/libpng16-13928571ad910705eae8d7dd8eef8b11.dll +0 -0
  65. pyogrio.libs/{msvcp140-83b6a1a2fa8b1735a358b2fe13cabe4e.dll → msvcp140-46db46e967c8db2cb7a20fc75872a57e.dll} +0 -0
  66. pyogrio.libs/proj-8a30239ef2dfc3b9dd2bb48e8abb330f.dll +0 -0
  67. pyogrio.libs/{qhull_r-99ae8a526357acc44b162cb4df2c3bb6.dll → qhull_r-c45abde5d0c92faf723cc2942138af77.dll} +0 -0
  68. pyogrio.libs/sqlite3-df30c3cf230727e23c43c40126a530f7.dll +0 -0
  69. pyogrio.libs/{tiff-7c2d4b204ec2db46c81f6a597895c2f7.dll → tiff-43630f30487a9015213475ae86ed3fa3.dll} +0 -0
  70. pyogrio.libs/{zlib1-824de9299616f0908aeeb9441a084848.dll → zlib1-e1272810861a13dd8d6cff3beac47f17.dll} +0 -0
  71. pyogrio/tests/win32.py +0 -86
  72. pyogrio-0.7.2.dist-info/DELVEWHEEL +0 -2
  73. pyogrio.libs/Lerc-d5afc4101deffe7de21241ccd4d562f6.dll +0 -0
  74. pyogrio.libs/geos-1c764a1384537a0ad2995e83d23e8642.dll +0 -0
  75. pyogrio.libs/geos_c-0d7dfdcee49efa8df585e2fb993157aa.dll +0 -0
  76. pyogrio.libs/json-c-36c91e30c4410d41c22b2010c31183e3.dll +0 -0
  77. pyogrio.libs/libcurl-ebcc8c18195071a90e59f818902e10c6.dll +0 -0
  78. pyogrio.libs/libexpat-345379c9c11632130d8c383cbacde1a6.dll +0 -0
  79. pyogrio.libs/libpng16-2c30e6846653c47ef2ff9d7dec3338ba.dll +0 -0
  80. pyogrio.libs/proj-98758c96a6cb682b5cec7e8dc5e29a50.dll +0 -0
  81. pyogrio.libs/sqlite3-327ed7b38bfd91fb4a17544960e055e9.dll +0 -0
  82. {pyogrio-0.7.2.dist-info → pyogrio-0.9.0.dist-info}/LICENSE +0 -0
  83. {pyogrio-0.7.2.dist-info → pyogrio-0.9.0.dist-info}/top_level.txt +0 -0
@@ -3,13 +3,13 @@
3
3
  "spdxVersion": "SPDX-2.2",
4
4
  "dataLicense": "CC0-1.0",
5
5
  "SPDXID": "SPDXRef-DOCUMENT",
6
- "documentNamespace": "https://spdx.org/spdxdocs/gdal-x64-windows-dynamic-release-3.7.2-c3808deb-83da-4811-bfd3-b900649ab3ff",
7
- "name": "gdal:x64-windows-dynamic-release@3.7.2 49358e40b2d03888efeda81a03b0de4298a85293bb018e3cb76f3c045ca15c02",
6
+ "documentNamespace": "https://spdx.org/spdxdocs/gdal-x64-windows-dynamic-release-3.8.5-653a0a71-62a0-4545-aa58-6da328eb469b",
7
+ "name": "gdal:x64-windows-dynamic-release@3.8.5 01b2cda46d4fb8561a26b07ca676fec776a271a7085bffcd357dad675131c27c",
8
8
  "creationInfo": {
9
9
  "creators": [
10
- "Tool: vcpkg-ac02a9f660977426b8ec6392919fbb1d51b10998"
10
+ "Tool: vcpkg-d6945642ee5c3076addd1a42c331bbf4cfc97457"
11
11
  ],
12
- "created": "2023-10-20T03:38:26Z"
12
+ "created": "2024-06-17T19:57:14Z"
13
13
  },
14
14
  "relationships": [
15
15
  {
@@ -117,8 +117,8 @@
117
117
  {
118
118
  "name": "gdal",
119
119
  "SPDXID": "SPDXRef-port",
120
- "versionInfo": "3.7.2",
121
- "downloadLocation": "git+https://github.com/Microsoft/vcpkg@d01864aaa21a85e1e8f7bb6748d607e953c52e77",
120
+ "versionInfo": "3.8.5",
121
+ "downloadLocation": "git+https://github.com/Microsoft/vcpkg@ea4d3f8cb9ab32d885ac60b974421a604fdbcc87",
122
122
  "homepage": "https://gdal.org",
123
123
  "licenseConcluded": "NOASSERTION",
124
124
  "licenseDeclared": "NOASSERTION",
@@ -129,7 +129,7 @@
129
129
  {
130
130
  "name": "gdal:x64-windows-dynamic-release",
131
131
  "SPDXID": "SPDXRef-binary",
132
- "versionInfo": "49358e40b2d03888efeda81a03b0de4298a85293bb018e3cb76f3c045ca15c02",
132
+ "versionInfo": "01b2cda46d4fb8561a26b07ca676fec776a271a7085bffcd357dad675131c27c",
133
133
  "downloadLocation": "NONE",
134
134
  "licenseConcluded": "NOASSERTION",
135
135
  "licenseDeclared": "NOASSERTION",
@@ -139,33 +139,33 @@
139
139
  {
140
140
  "SPDXID": "SPDXRef-resource-1",
141
141
  "name": "OSGeo/gdal",
142
- "downloadLocation": "git+https://github.com/OSGeo/gdal@v3.7.2",
142
+ "downloadLocation": "git+https://github.com/OSGeo/gdal@v3.8.5",
143
143
  "licenseConcluded": "NOASSERTION",
144
144
  "licenseDeclared": "NOASSERTION",
145
145
  "copyrightText": "NOASSERTION",
146
146
  "checksums": [
147
147
  {
148
148
  "algorithm": "SHA512",
149
- "checksumValue": "95b0dee07a616c8fb26ded2c538a6933ba070c0567e88af9356daea9b1df6c910edb4fcf55766839c1873829d20948b1714b3e2285e5ac57de8fcf0970ff53ff"
149
+ "checksumValue": "5b155229225e904b3619628ec27efdd273d9f083c1ee4f6d94041897d5bc9c3133590b70885ad61fc8864da2f334a75cf32bafe7f776c40bbbc3673fe842c986"
150
150
  }
151
151
  ]
152
152
  }
153
153
  ],
154
154
  "files": [
155
155
  {
156
- "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/d01864aaa21a85e1e8f7bb6748d607e953c52e77/cmake-project-include.cmake",
156
+ "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/ea4d3f8cb9ab32d885ac60b974421a604fdbcc87/cmake-project-include.cmake",
157
157
  "SPDXID": "SPDXRef-file-0",
158
158
  "checksums": [
159
159
  {
160
160
  "algorithm": "SHA256",
161
- "checksumValue": "71c0138c71e6286cf8391e562775d853d3a29f5d58597ecc1b47a8bfb8b6412c"
161
+ "checksumValue": "60c0f79155c78ec0ec4ccdc77e00f4613ae4630c6697f51f884bf8f979a48593"
162
162
  }
163
163
  ],
164
164
  "licenseConcluded": "NOASSERTION",
165
165
  "copyrightText": "NOASSERTION"
166
166
  },
167
167
  {
168
- "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/d01864aaa21a85e1e8f7bb6748d607e953c52e77/find-link-libraries.patch",
168
+ "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/ea4d3f8cb9ab32d885ac60b974421a604fdbcc87/find-link-libraries.patch",
169
169
  "SPDXID": "SPDXRef-file-1",
170
170
  "checksums": [
171
171
  {
@@ -177,7 +177,7 @@
177
177
  "copyrightText": "NOASSERTION"
178
178
  },
179
179
  {
180
- "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/d01864aaa21a85e1e8f7bb6748d607e953c52e77/fix-gdal-target-interfaces.patch",
180
+ "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/ea4d3f8cb9ab32d885ac60b974421a604fdbcc87/fix-gdal-target-interfaces.patch",
181
181
  "SPDXID": "SPDXRef-file-2",
182
182
  "checksums": [
183
183
  {
@@ -189,43 +189,43 @@
189
189
  "copyrightText": "NOASSERTION"
190
190
  },
191
191
  {
192
- "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/d01864aaa21a85e1e8f7bb6748d607e953c52e77/fix-jpeg.patch",
192
+ "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/ea4d3f8cb9ab32d885ac60b974421a604fdbcc87/libkml.patch",
193
193
  "SPDXID": "SPDXRef-file-3",
194
194
  "checksums": [
195
195
  {
196
196
  "algorithm": "SHA256",
197
- "checksumValue": "28a04f01c92e6b99a5e918f38333c8245089a6ba2f67191e9fbc54288cfa941e"
197
+ "checksumValue": "fe888df8a7c9e468cdd87640c025f48f165d5264af1fa20604bd60859e6f000f"
198
198
  }
199
199
  ],
200
200
  "licenseConcluded": "NOASSERTION",
201
201
  "copyrightText": "NOASSERTION"
202
202
  },
203
203
  {
204
- "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/d01864aaa21a85e1e8f7bb6748d607e953c52e77/libkml.patch",
204
+ "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/ea4d3f8cb9ab32d885ac60b974421a604fdbcc87/portfile.cmake",
205
205
  "SPDXID": "SPDXRef-file-4",
206
206
  "checksums": [
207
207
  {
208
208
  "algorithm": "SHA256",
209
- "checksumValue": "fe888df8a7c9e468cdd87640c025f48f165d5264af1fa20604bd60859e6f000f"
209
+ "checksumValue": "7e5f1f6c6f1f420b994e149d8a31e1e31e23492a881ce29b3c30307ab28f2f92"
210
210
  }
211
211
  ],
212
212
  "licenseConcluded": "NOASSERTION",
213
213
  "copyrightText": "NOASSERTION"
214
214
  },
215
215
  {
216
- "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/d01864aaa21a85e1e8f7bb6748d607e953c52e77/portfile.cmake",
216
+ "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/ea4d3f8cb9ab32d885ac60b974421a604fdbcc87/target-is-valid.patch",
217
217
  "SPDXID": "SPDXRef-file-5",
218
218
  "checksums": [
219
219
  {
220
220
  "algorithm": "SHA256",
221
- "checksumValue": "47aff7e31c70f25ca782b23c4e93004c989cd346d0d18ea9737545283779573f"
221
+ "checksumValue": "6a369356c57860f97bd756d3604e7219774e2bfe5c74e5e0178496fad253900f"
222
222
  }
223
223
  ],
224
224
  "licenseConcluded": "NOASSERTION",
225
225
  "copyrightText": "NOASSERTION"
226
226
  },
227
227
  {
228
- "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/d01864aaa21a85e1e8f7bb6748d607e953c52e77/usage",
228
+ "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/ea4d3f8cb9ab32d885ac60b974421a604fdbcc87/usage",
229
229
  "SPDXID": "SPDXRef-file-6",
230
230
  "checksums": [
231
231
  {
@@ -237,7 +237,7 @@
237
237
  "copyrightText": "NOASSERTION"
238
238
  },
239
239
  {
240
- "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/d01864aaa21a85e1e8f7bb6748d607e953c52e77/vcpkg-cmake-wrapper.cmake",
240
+ "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/ea4d3f8cb9ab32d885ac60b974421a604fdbcc87/vcpkg-cmake-wrapper.cmake",
241
241
  "SPDXID": "SPDXRef-file-7",
242
242
  "checksums": [
243
243
  {
@@ -249,12 +249,12 @@
249
249
  "copyrightText": "NOASSERTION"
250
250
  },
251
251
  {
252
- "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/d01864aaa21a85e1e8f7bb6748d607e953c52e77/vcpkg.json",
252
+ "fileName": "./C:/vcpkg/buildtrees/versioning_/versions/gdal/ea4d3f8cb9ab32d885ac60b974421a604fdbcc87/vcpkg.json",
253
253
  "SPDXID": "SPDXRef-file-8",
254
254
  "checksums": [
255
255
  {
256
256
  "algorithm": "SHA256",
257
- "checksumValue": "2a27cd0721793c5e2a4e66a834f3cf25f76ffafc178e1d6d703fba9e78139bd4"
257
+ "checksumValue": "15039815ee85e9996bda2f7cb66eb87de8b544bcafba85f2518ba1b3f28c9fd5"
258
258
  }
259
259
  ],
260
260
  "licenseConcluded": "NOASSERTION",
@@ -1,41 +1,42 @@
1
- cmake 3.27.7
2
- cmake-project-include.cmake 71c0138c71e6286cf8391e562775d853d3a29f5d58597ecc1b47a8bfb8b6412c
3
- curl 5f473ef0cffa199edbf0f6b44a042f99e3df48f7f33ec28d33e9420d980131b1
4
- expat 7d77ed9f18a358044a905444256520237ec5f2b6f49e0013942e09871e7bf62f
5
- features core;curl;expat;geos;jpeg;lerc;png;qhull;recommended-features;sqlite3
1
+ cmake 3.29.5
2
+ cmake-project-include.cmake 60c0f79155c78ec0ec4ccdc77e00f4613ae4630c6697f51f884bf8f979a48593
3
+ curl 6a9f6535d0371ecc5300df22e045bc77397b1b9fa38595d0b422c548ef9b9a5f
4
+ expat 3e3294a2dbb460754a04febc201b60450806146f63a05c420d29fc1ea9b8958b
5
+ features core;curl;expat;geos;iconv;jpeg;lerc;png;qhull;recommended-features;sqlite3
6
6
  find-link-libraries.patch 9e390300ab79cf6fef1bb009416346a1f98d4946cb14c71ee4ea46217e3cb9d2
7
7
  fix-gdal-target-interfaces.patch 9dbe9d5e0dbc3a21370bb3560aa32811d10cc0b19e4b6833cd7258699d206215
8
- fix-jpeg.patch 28a04f01c92e6b99a5e918f38333c8245089a6ba2f67191e9fbc54288cfa941e
9
- geos e5ea43b0b8b36db86bfe5b7a3a9496cec78f5005d7c2aa07f1c3501c97268c88
10
- json-c f8d2fd8ff50183f9286fef00639ef5ee39dac9301d73bd2601db05f3fa9d958d
11
- lerc 3ff7682eb53cf8e76c6096be4a74f16489274779cd58033fc5234095ecb98357
12
- libgeotiff e631c7ad3eb81515a498081b7fd374c1c431ae0c65c059650657a4ed3c5d13de
13
- libjpeg-turbo 4bb19e4996b70d2a4a6ab98ffb468a2950e71c4ab53962c0d810f9feef00f59f
8
+ geos afdf4774a86df785fe123db9139c5fea70fff4d0db8d3e034d95b68376d68ffc
9
+ json-c f9b1dbdc253bc16bec561498a404903175584d5dc73e88fa1b14a934eb9e62ca
10
+ lerc cf26beb212a79cc4c17fbbfcb0b1d9e8ddb8d559224dd0a3b8434d2e319c05fe
11
+ libgeotiff cccfb39c55648738c7f1993f38df11c9664981e172210e1172e3d4494df78290
12
+ libiconv d57236602b9415098a31b6d131e933d865b2121e9d9364c73b2c76776023cf35
13
+ libjpeg-turbo 668190347b83ea4664c1975e288074d29b0b0be2970ca24a23a1daf557020a32
14
14
  libkml.patch fe888df8a7c9e468cdd87640c025f48f165d5264af1fa20604bd60859e6f000f
15
- libpng 4dd488f6316a0a9ad7728ea74bf4b749dd433ef83ff0ef88ea9292254fd068b2
16
- pkgconf 2665ab03f05cc7ef0d8ae2c83d034decdd552c036d4d7e5f03c6a3719c00a519
17
- portfile.cmake 47aff7e31c70f25ca782b23c4e93004c989cd346d0d18ea9737545283779573f
18
- ports.cmake 5a8e00cedff0c898b1f90f7d129329d0288801bc9056562b039698caf31ff3f3
15
+ libpng 24506bc052488610e0720e2981b82ba2f81210040a199ade945ef71852a21555
16
+ pkgconf d7e5d8c03e2bd3bf217278ab8f6ddfb9ed770b53a9569486515e16008936f3b2
17
+ portfile.cmake 7e5f1f6c6f1f420b994e149d8a31e1e31e23492a881ce29b3c30307ab28f2f92
18
+ ports.cmake 0500e9e2422fe0084c99bdd0c9de4c7069b76da14c8b58228a7e95ebac43058a
19
19
  post_build_checks 2
20
- powershell 7.2.15
21
- proj 6d12687ff77f297212103e041ea2f50cb0b47917291617180bff526516536adf
22
- qhull 7210cbf8f0143c3afa8398ee1566d55de1f5f38c513ce05268b02f0fb67df3af
23
- sqlite3 d82f7970a8a122644b8c93b03405cd562f4b7a2bf225789baf17b5fa56cba6f3
24
- tiff b44e6cf773fd116aaf4e9cc3a5a5f9c835a700ba48ac8694f29aae6d36f139f0
20
+ powershell 7.4.2
21
+ proj 516fa62b68e81f38b2aa8da0bb1252756e2fe2ca50e4bcfc768ed71aaf477468
22
+ qhull 525843716525c8d7bba0ec61bd4684467dfde9961a4c36326cd56e41344e3d1e
23
+ sqlite3 0ea00a282f5b99592dd974e790033e3709e3273da3ffc774f8db4fbe4f342f9c
24
+ target-is-valid.patch 6a369356c57860f97bd756d3604e7219774e2bfe5c74e5e0178496fad253900f
25
+ tiff ffa4985cd425743272cac47070bf68ec92b8919d8deeb849fb8e7bd7ec242df9
25
26
  triplet x64-windows-dynamic-release
26
- triplet_abi 36210185afbd528d6d7303808480ab7d54f062730bbef9fc1603f69b72ca549a-e36df1c7f50ab25f9c182fa927d06c19ae082e0d599f132b3f655784b49e4b33-029ebeb215a7397eed4e23b15ca7cbd36c741c3e
27
+ triplet_abi 36210185afbd528d6d7303808480ab7d54f062730bbef9fc1603f69b72ca549a-e36df1c7f50ab25f9c182fa927d06c19ae082e0d599f132b3f655784b49e4b33-3361a17d8afbd07b0f5c7f4dac4bd892b23a29d3
27
28
  usage c85584261e2011a94b86f04c3a28dd2e165c9e6b47677a9bee26a3d387bc05f2
28
- vcpkg-cmake f33680d4f6cae27d575580b5126316cd1d5f30a754bfac01ce7a0ba5066fdccb
29
- vcpkg-cmake-config 9bb96f79577c3c4ae19138b30b6c922756ed4556a88ac3b45293f57262130e77
29
+ vcpkg-cmake fa107b73894bb46b2c72b30466a3255d25400d5579640cabf6665ac44176d095
30
+ vcpkg-cmake-config 5a8514250466c9d2b68d50c2037242af99e55bd8fabcd47e0f10562bb3e69683
30
31
  vcpkg-cmake-wrapper.cmake c507eaa077072e9877607fd5f70381eebf19900661e2e1fd099d84c4df1b8c24
31
- vcpkg-pkgconfig-get-modules 02ac15bf5617b96bf1ce568154960acd3efc9b50d2e89b1d907384b2a4a911c3
32
- vcpkg.json 2a27cd0721793c5e2a4e66a834f3cf25f76ffafc178e1d6d703fba9e78139bd4
32
+ vcpkg-pkgconfig-get-modules 09c4dd36692798074e246249296f4220dcf5b6a9435be77e954291fd090ed35b
33
+ vcpkg.json 15039815ee85e9996bda2f7cb66eb87de8b544bcafba85f2518ba1b3f28c9fd5
33
34
  vcpkg_check_features 943b217e0968d64cf2cb9c272608e6a0b497377e792034f819809a79e1502c2b
34
35
  vcpkg_copy_pdbs d57e4f196c82dc562a9968c6155073094513c31e2de475694143d3aa47954b1c
35
36
  vcpkg_copy_tools 3d45ff761bddbabe8923b52330168dc3abd295fa469d3f2e47cb14dce85332d5
36
- vcpkg_fixup_pkgconfig 588d833ff057d3ca99c14616c7ecfb5948b5e2a9e4fc02517dceb8b803473457
37
- vcpkg_from_git 8f27bff0d01c6d15a3e691758df52bfbb0b1b929da45c4ebba02ef76b54b1881
37
+ vcpkg_fixup_pkgconfig 904e67c46ecbb67379911bc1d7222855c0cbfcf1129bf47783858bcf0cc44970
38
+ vcpkg_from_git 96ed81968f76354c00096dd8cd4e63c6a235fa969334a11ab18d11c0c512ff58
38
39
  vcpkg_from_github b743742296a114ea1b18ae99672e02f142c4eb2bef7f57d36c038bedbfb0502f
39
40
  vcpkg_install_copyright ba6c169ab4e59fa05682e530cdeb883767de22c8391f023d4e6844a7ec5dd3d2
40
41
  vcpkg_replace_string d43c8699ce27e25d47367c970d1c546f6bc36b6df8fb0be0c3986eb5830bd4f1
41
- zlib 3fe501fbca4a5cb1ab69c6faa51705ba608015cdb7e495d8e78c3495e285bcb8
42
+ zlib 50d932c2c9f99e68b8dca30919d9939ce9c394534323e25ae835cd89b37dc863
pyogrio/geopandas.py CHANGED
@@ -2,14 +2,14 @@ import os
2
2
 
3
3
  import numpy as np
4
4
 
5
- from pyogrio._compat import HAS_GEOPANDAS, PANDAS_GE_15, PANDAS_GE_20
5
+ from pyogrio._compat import HAS_GEOPANDAS, PANDAS_GE_15, PANDAS_GE_20, PANDAS_GE_22
6
6
  from pyogrio.raw import (
7
7
  DRIVERS_NO_MIXED_SINGLE_MULTI,
8
8
  DRIVERS_NO_MIXED_DIMENSIONS,
9
- detect_write_driver,
10
9
  read,
11
10
  read_arrow,
12
11
  write,
12
+ _get_write_path_driver,
13
13
  )
14
14
  from pyogrio.errors import DataSourceError
15
15
  import warnings
@@ -33,7 +33,9 @@ def _stringify_path(path):
33
33
  def _try_parse_datetime(ser):
34
34
  import pandas as pd # only called when pandas is known to be installed
35
35
 
36
- if PANDAS_GE_20:
36
+ if PANDAS_GE_22:
37
+ datetime_kwargs = dict(format="ISO8601")
38
+ elif PANDAS_GE_20:
37
39
  datetime_kwargs = dict(format="ISO8601", errors="ignore")
38
40
  else:
39
41
  datetime_kwargs = dict(yearfirst=True)
@@ -48,10 +50,13 @@ def _try_parse_datetime(ser):
48
50
  try:
49
51
  res = pd.to_datetime(ser, **datetime_kwargs)
50
52
  except Exception:
51
- pass
53
+ res = ser
52
54
  # if object dtype, try parse as utc instead
53
55
  if res.dtype == "object":
54
- res = pd.to_datetime(ser, utc=True, **datetime_kwargs)
56
+ try:
57
+ res = pd.to_datetime(ser, utc=True, **datetime_kwargs)
58
+ except Exception:
59
+ pass
55
60
 
56
61
  if res.dtype != "object":
57
62
  # GDAL only supports ms precision, convert outputs to match.
@@ -82,6 +87,7 @@ def read_dataframe(
82
87
  sql_dialect=None,
83
88
  fid_as_index=False,
84
89
  use_arrow=None,
90
+ on_invalid="raise",
85
91
  arrow_to_pandas_kwargs=None,
86
92
  **kwargs,
87
93
  ):
@@ -101,13 +107,16 @@ def read_dataframe(
101
107
  of the layer in the data source. Defaults to first layer in data source.
102
108
  encoding : str, optional (default: None)
103
109
  If present, will be used as the encoding for reading string values from
104
- the data source, unless encoding can be inferred directly from the data
105
- source.
110
+ the data source. By default will automatically try to detect the native
111
+ encoding and decode to ``UTF-8``.
106
112
  columns : list-like, optional (default: all columns)
107
113
  List of column names to import from the data source. Column names must
108
114
  exactly match the names in the data source, and will be returned in
109
115
  the order they occur in the data source. To avoid reading any columns,
110
- pass an empty list-like.
116
+ pass an empty list-like. If combined with ``where`` parameter, must
117
+ include columns referenced in the ``where`` expression or the data may
118
+ not be correctly read; the data source may return empty results or
119
+ raise an exception (behavior varies by driver).
111
120
  read_geometry : bool, optional (default: True)
112
121
  If True, will read geometry into a GeoSeries. If False, a Pandas DataFrame
113
122
  will be returned instead.
@@ -152,7 +161,12 @@ def read_dataframe(
152
161
  the starting index is driver and file specific (e.g. typically 0 for
153
162
  Shapefile and 1 for GeoPackage, but can still depend on the specific
154
163
  file). The performance of reading a large number of features usings FIDs
155
- is also driver specific.
164
+ is also driver specific and depends on the value of ``use_arrow``. The order
165
+ of the rows returned is undefined. If you would like to sort based on FID, use
166
+ ``fid_as_index=True`` to have the index of the GeoDataFrame returned set to the
167
+ FIDs of the features read. If ``use_arrow=True``, the number of FIDs is limited
168
+ to 4997 for drivers with 'OGRSQL' as default SQL dialect. To read a larger
169
+ number of FIDs, set ``user_arrow=False``.
156
170
  sql : str, optional (default: None)
157
171
  The SQL statement to execute. Look at the sql_dialect parameter for more
158
172
  information on the syntax to use for the query. When combined with other
@@ -184,6 +198,15 @@ def read_dataframe(
184
198
  installed). When enabled, this provides a further speed-up.
185
199
  Defaults to False, but this default can also be globally overridden
186
200
  by setting the ``PYOGRIO_USE_ARROW=1`` environment variable.
201
+ on_invalid : str, optional (default: "raise")
202
+
203
+ - **raise**: an exception will be raised if a WKB input geometry is
204
+ invalid.
205
+ - **warn**: a warning will be raised and invalid WKB geometries will be
206
+ returned as ``None``.
207
+ - **ignore**: invalid WKB geometries will be returned as ``None``
208
+ without a warning.
209
+
187
210
  arrow_to_pandas_kwargs : dict, optional (default: None)
188
211
  When `use_arrow` is True, these kwargs will be passed to the `to_pandas`_
189
212
  call for the arrow to pandas conversion.
@@ -221,7 +244,6 @@ def read_dataframe(
221
244
 
222
245
  import pandas as pd
223
246
  import geopandas as gp
224
- from geopandas.array import from_wkb
225
247
  import shapely # if geopandas is present, shapely is expected to be present
226
248
 
227
249
  path_or_buffer = _stringify_path(path_or_buffer)
@@ -279,10 +301,10 @@ def read_dataframe(
279
301
  if PANDAS_GE_15 and wkb_values.dtype != object:
280
302
  # for example ArrowDtype will otherwise create numpy array with pd.NA
281
303
  wkb_values = wkb_values.to_numpy(na_value=None)
282
- df["geometry"] = from_wkb(wkb_values, crs=meta["crs"])
304
+ df["geometry"] = shapely.from_wkb(wkb_values, on_invalid=on_invalid)
283
305
  if force_2d:
284
306
  df["geometry"] = shapely.force_2d(df["geometry"])
285
- return gp.GeoDataFrame(df, geometry="geometry")
307
+ return gp.GeoDataFrame(df, geometry="geometry", crs=meta["crs"])
286
308
  else:
287
309
  return df
288
310
 
@@ -302,9 +324,9 @@ def read_dataframe(
302
324
  if geometry is None or not read_geometry:
303
325
  return df
304
326
 
305
- geometry = from_wkb(geometry, crs=meta["crs"])
327
+ geometry = shapely.from_wkb(geometry, on_invalid=on_invalid)
306
328
 
307
- return gp.GeoDataFrame(df, geometry=geometry)
329
+ return gp.GeoDataFrame(df, geometry=geometry, crs=meta["crs"])
308
330
 
309
331
 
310
332
  # TODO: handle index properly
@@ -318,6 +340,7 @@ def write_dataframe(
318
340
  promote_to_multi=None,
319
341
  nan_as_null=True,
320
342
  append=False,
343
+ use_arrow=None,
321
344
  dataset_metadata=None,
322
345
  layer_metadata=None,
323
346
  metadata=None,
@@ -335,16 +358,20 @@ def write_dataframe(
335
358
  all values will be converted to strings to be written to the
336
359
  output file, except None and np.nan, which will be set to NULL
337
360
  in the output file.
338
- path : str
339
- path to file
340
- layer :str, optional (default: None)
341
- layer name
361
+ path : str or io.BytesIO
362
+ path to output file on writeable file system or an io.BytesIO object to
363
+ allow writing to memory
364
+ NOTE: support for writing to memory is limited to specific drivers.
365
+ layer : str, optional (default: None)
366
+ layer name to create. If writing to memory and layer name is not
367
+ provided, it layer name will be set to a UUID4 value.
342
368
  driver : string, optional (default: None)
343
- The OGR format driver used to write the vector file. By default write_dataframe
344
- attempts to infer driver from path.
369
+ The OGR format driver used to write the vector file. By default attempts
370
+ to infer driver from path. Must be provided to write to memory.
345
371
  encoding : str, optional (default: None)
346
372
  If present, will be used as the encoding for writing string values to
347
- the file.
373
+ the file. Use with caution, only certain drivers support encodings
374
+ other than UTF-8.
348
375
  geometry_type : string, optional (default: None)
349
376
  By default, the geometry type of the layer will be inferred from the
350
377
  data, after applying the promote_to_multi logic. If the data only contains a
@@ -376,8 +403,17 @@ def write_dataframe(
376
403
  append : bool, optional (default: False)
377
404
  If True, the data source specified by path already exists, and the
378
405
  driver supports appending to an existing data source, will cause the
379
- data to be appended to the existing records in the data source.
406
+ data to be appended to the existing records in the data source. Not
407
+ supported for writing to in-memory files.
380
408
  NOTE: append support is limited to specific drivers and GDAL versions.
409
+ use_arrow : bool, optional (default: False)
410
+ Whether to use Arrow as the transfer mechanism of the data to write
411
+ from Python to GDAL (requires GDAL >= 3.8 and `pyarrow` to be
412
+ installed). When enabled, this provides a further speed-up.
413
+ Defaults to False, but this default can also be globally overridden
414
+ by setting the ``PYOGRIO_USE_ARROW=1`` environment variable.
415
+ Using Arrow does not support writing an object-dtype column with
416
+ mixed types.
381
417
  dataset_metadata : dict, optional (default: None)
382
418
  Metadata to be stored at the dataset level in the output file; limited
383
419
  to drivers that support writing metadata, such as GPKG, and silently
@@ -389,10 +425,10 @@ def write_dataframe(
389
425
  metadata : dict, optional (default: None)
390
426
  alias of layer_metadata
391
427
  dataset_options : dict, optional
392
- Dataset creation option (format specific) passed to OGR. Specify as
428
+ Dataset creation options (format specific) passed to OGR. Specify as
393
429
  a key-value dictionary.
394
430
  layer_options : dict, optional
395
- Layer creation option (format specific) passed to OGR. Specify as
431
+ Layer creation options (format specific) passed to OGR. Specify as
396
432
  a key-value dictionary.
397
433
  **kwargs
398
434
  Additional driver-specific dataset or layer creation options passed
@@ -412,13 +448,12 @@ def write_dataframe(
412
448
  import pandas as pd
413
449
  from pyproj.enums import WktVersion # if geopandas is available so is pyproj
414
450
 
415
- path = str(path)
416
-
417
451
  if not isinstance(df, pd.DataFrame):
418
452
  raise ValueError("'df' must be a DataFrame or GeoDataFrame")
419
453
 
420
- if driver is None:
421
- driver = detect_write_driver(path)
454
+ if use_arrow is None:
455
+ use_arrow = bool(int(os.environ.get("PYOGRIO_USE_ARROW", "0")))
456
+ path, driver = _get_write_path_driver(path, driver, append=append)
422
457
 
423
458
  geometry_columns = df.columns[df.dtypes == "geometry"]
424
459
  if len(geometry_columns) > 1:
@@ -456,7 +491,7 @@ def write_dataframe(
456
491
  # https://gdal.org/development/rfc/rfc56_millisecond_precision.html#core-changes
457
492
  # Convert each row offset to a signed multiple of 15m and add to GMT value
458
493
  gdal_offset_representation = tz_offset // pd.Timedelta("15m") + 100
459
- gdal_tz_offsets[name] = gdal_offset_representation
494
+ gdal_tz_offsets[name] = gdal_offset_representation.values
460
495
  else:
461
496
  values = col.values
462
497
  if isinstance(values, pd.api.extensions.ExtensionArray):
@@ -473,6 +508,9 @@ def write_dataframe(
473
508
  field_mask.append(None)
474
509
 
475
510
  # Determine geometry_type and/or promote_to_multi
511
+ if geometry_column is not None:
512
+ geometry_types_all = geometry.geom_type
513
+
476
514
  if geometry_column is not None and (
477
515
  geometry_type is None or promote_to_multi is None
478
516
  ):
@@ -482,9 +520,7 @@ def write_dataframe(
482
520
  # If there is data, infer layer geometry type + promote_to_multi
483
521
  if not df.empty:
484
522
  # None/Empty geometries sometimes report as Z incorrectly, so ignore them
485
- has_z_arr = geometry[
486
- (geometry != np.array(None)) & (~geometry.is_empty)
487
- ].has_z
523
+ has_z_arr = geometry[geometry.notna() & (~geometry.is_empty)].has_z
488
524
  has_z = has_z_arr.any()
489
525
  all_z = has_z_arr.all()
490
526
 
@@ -493,7 +529,7 @@ def write_dataframe(
493
529
  f"Mixed 2D and 3D coordinates are not supported by {driver}"
494
530
  )
495
531
 
496
- geometry_types = pd.Series(geometry.type.unique()).dropna().values
532
+ geometry_types = pd.Series(geometry_types_all.unique()).dropna().values
497
533
  if len(geometry_types) == 1:
498
534
  tmp_geometry_type = geometry_types[0]
499
535
  if promote_to_multi and tmp_geometry_type in (
@@ -537,10 +573,80 @@ def write_dataframe(
537
573
  # if possible use EPSG codes instead
538
574
  epsg = geometry.crs.to_epsg()
539
575
  if epsg:
540
- crs = f"EPSG:{epsg}"
576
+ crs = f"EPSG:{epsg}" # noqa: E231
541
577
  else:
542
578
  crs = geometry.crs.to_wkt(WktVersion.WKT1_GDAL)
543
579
 
580
+ if use_arrow:
581
+ import pyarrow as pa
582
+ from pyogrio.raw import write_arrow
583
+
584
+ if geometry_column is not None:
585
+ # Convert to multi type
586
+ if promote_to_multi:
587
+ import shapely
588
+
589
+ mask_points = geometry_types_all == "Point"
590
+ mask_linestrings = geometry_types_all == "LineString"
591
+ mask_polygons = geometry_types_all == "Polygon"
592
+
593
+ if mask_points.any():
594
+ geometry[mask_points] = shapely.multipoints(
595
+ np.atleast_2d(geometry[mask_points]), axis=0
596
+ )
597
+
598
+ if mask_linestrings.any():
599
+ geometry[mask_linestrings] = shapely.multilinestrings(
600
+ np.atleast_2d(geometry[mask_linestrings]), axis=0
601
+ )
602
+
603
+ if mask_polygons.any():
604
+ geometry[mask_polygons] = shapely.multipolygons(
605
+ np.atleast_2d(geometry[mask_polygons]), axis=0
606
+ )
607
+
608
+ geometry = to_wkb(geometry.values)
609
+ df = df.copy(deep=False)
610
+ # convert to plain DataFrame to avoid warning from geopandas about
611
+ # writing non-geometries to the geometry column
612
+ df = pd.DataFrame(df, copy=False)
613
+ df[geometry_column] = geometry
614
+
615
+ table = pa.Table.from_pandas(df, preserve_index=False)
616
+
617
+ if geometry_column is not None:
618
+ # ensure that the geometry column is binary (for all-null geometries,
619
+ # this could be a wrong type)
620
+ geom_field = table.schema.field(geometry_column)
621
+ if not (
622
+ pa.types.is_binary(geom_field.type)
623
+ or pa.types.is_large_binary(geom_field.type)
624
+ ):
625
+ table = table.set_column(
626
+ table.schema.get_field_index(geometry_column),
627
+ geom_field.with_type(pa.binary()),
628
+ table[geometry_column].cast(pa.binary()),
629
+ )
630
+
631
+ write_arrow(
632
+ table,
633
+ path,
634
+ layer=layer,
635
+ driver=driver,
636
+ geometry_name=geometry_column,
637
+ geometry_type=geometry_type,
638
+ crs=crs,
639
+ encoding=encoding,
640
+ append=append,
641
+ dataset_metadata=dataset_metadata,
642
+ layer_metadata=layer_metadata,
643
+ metadata=metadata,
644
+ dataset_options=dataset_options,
645
+ layer_options=layer_options,
646
+ **kwargs,
647
+ )
648
+ return
649
+
544
650
  # If there is geometry data, prepare it to be written
545
651
  if geometry_column is not None:
546
652
  geometry = to_wkb(geometry.values)
@@ -42,7 +42,7 @@
42
42
 
43
43
  <CARB> +proj=helmert +drx=0.000049 +dry=-0.001088 +drz=0.000664 +convention=position_vector
44
44
 
45
- <EURA> +proj=helmert +drx=-0.000083 +dry=0.000534 +drz=0.000750 +convention=position_vector
45
+ <EURA> +proj=helmert +drx=-0.000083 +dry=-0.000534 +drz=0.000750 +convention=position_vector
46
46
 
47
47
  <INDI> +proj=helmert +drx=0.001232 +dry=0.000303 +drz=0.001540 +convention=position_vector
48
48
 
@@ -75,7 +75,7 @@
75
75
 
76
76
  <CARB_T> +proj=helmert +dx=0.00041 +dy=0.00022 +dz=0.00041 +drx=0.000049 +dry=-0.001088 +drz=0.000664 +convention=position_vector
77
77
 
78
- <EURA_T> +proj=helmert +dx=0.00041 +dy=0.00022 +dz=0.00041 +drx=-0.000083 +dry=0.000534 +drz=0.000750 +convention=position_vector
78
+ <EURA_T> +proj=helmert +dx=0.00041 +dy=0.00022 +dz=0.00041 +drx=-0.000083 +dry=-0.000534 +drz=0.000750 +convention=position_vector
79
79
 
80
80
  <INDI_T> +proj=helmert +dx=0.00041 +dy=0.00022 +dz=0.00041 +drx=0.001232 +dry=0.000303 +drz=0.001540 +convention=position_vector
81
81
 
@@ -1,8 +1,8 @@
1
1
  # Version checking for PROJ
2
2
 
3
- set (PACKAGE_VERSION "9.3.0")
3
+ set (PACKAGE_VERSION "9.4.0")
4
4
  set (PACKAGE_VERSION_MAJOR "9")
5
- set (PACKAGE_VERSION_MINOR "3")
5
+ set (PACKAGE_VERSION_MINOR "4")
6
6
  set (PACKAGE_VERSION_PATCH "0")
7
7
 
8
8
  # These variable definitions parallel those in PROJ's
@@ -27,7 +27,8 @@ if("TRUE")
27
27
  endif()
28
28
  cmake_policy(POP)
29
29
 
30
- find_dependency(unofficial-sqlite3 CONFIG)
30
+ find_dependency(SQLite3)
31
+
31
32
  if(DEFINED PROJ_CONFIG_FIND_TIFF_DEP)
32
33
  find_dependency(TIFF)
33
34
  endif()
@@ -9,7 +9,6 @@ set(CMAKE_IMPORT_FILE_VERSION 1)
9
9
  set_property(TARGET PROJ::proj APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE)
10
10
  set_target_properties(PROJ::proj PROPERTIES
11
11
  IMPORTED_IMPLIB_RELEASE "${_IMPORT_PREFIX}/lib/proj.lib"
12
- IMPORTED_LINK_DEPENDENT_LIBRARIES_RELEASE "unofficial::sqlite3::sqlite3;CURL::libcurl"
13
12
  IMPORTED_LOCATION_RELEASE "${_IMPORT_PREFIX}/bin/proj.dll"
14
13
  )
15
14
 
@@ -7,7 +7,7 @@ if(CMAKE_VERSION VERSION_LESS "2.8.3")
7
7
  message(FATAL_ERROR "CMake >= 2.8.3 required")
8
8
  endif()
9
9
  cmake_policy(PUSH)
10
- cmake_policy(VERSION 2.8.3...3.25)
10
+ cmake_policy(VERSION 2.8.3...3.27)
11
11
  #----------------------------------------------------------------
12
12
  # Generated CMake target import file.
13
13
  #----------------------------------------------------------------
@@ -74,9 +74,12 @@ set(_IMPORT_PREFIX)
74
74
 
75
75
  # Loop over all imported files and verify that they actually exist
76
76
  foreach(_cmake_target IN LISTS _cmake_import_check_targets)
77
- foreach(_cmake_file IN LISTS "_cmake_import_check_files_for_${_cmake_target}")
78
- if(NOT EXISTS "${_cmake_file}")
79
- message(FATAL_ERROR "The imported target \"${_cmake_target}\" references the file
77
+ if(CMAKE_VERSION VERSION_LESS "3.28"
78
+ OR NOT DEFINED _cmake_import_check_xcframework_for_${_cmake_target}
79
+ OR NOT IS_DIRECTORY "${_cmake_import_check_xcframework_for_${_cmake_target}}")
80
+ foreach(_cmake_file IN LISTS "_cmake_import_check_files_for_${_cmake_target}")
81
+ if(NOT EXISTS "${_cmake_file}")
82
+ message(FATAL_ERROR "The imported target \"${_cmake_target}\" references the file
80
83
  \"${_cmake_file}\"
81
84
  but this file does not exist. Possible reasons include:
82
85
  * The file was deleted, renamed, or moved to another location.
@@ -85,8 +88,9 @@ but this file does not exist. Possible reasons include:
85
88
  \"${CMAKE_CURRENT_LIST_FILE}\"
86
89
  but not all the files it references.
87
90
  ")
88
- endif()
89
- endforeach()
91
+ endif()
92
+ endforeach()
93
+ endif()
90
94
  unset(_cmake_file)
91
95
  unset("_cmake_import_check_files_for_${_cmake_target}")
92
96
  endforeach()
pyogrio/proj_data/proj.db CHANGED
Binary file