ogr2ogr: speed-up reprojection in Arrow code path #10717
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
(on top of PR #10716)
Use newly added OGRWKBTransform(), when possible, to speed-up -t_srs in Arrow code path (which is triggered in Parquet/GPKG -> anything, when no option or no other option than -t_srs is specified). Also use multi-threaded coordinate transformation by splitting the features within each batch in several sub-batches, each processed in its own thread.
Can result in a 3.3x speed-up in ogr2ogr Parquet->Parquet -t_srs use case on a 3.2 million feature dataset:
No reprojection:
Reprojection EPSG:2193 ("NZGD2000 / New Zealand Transverse Mercator 2000") to EPSG:4326 without optimization:
Reprojection with optimization using 6 theads for reprojection:
Reprojection with optimization using 1 thead for reprojection:
Also applies for GPKG -> GPKG with a 2x speedup:
Without optimization: