Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed #31766 -- Made GDALRaster.transform() return a clone for the same SRID and driver. #13365

Merged
merged 1 commit into from Sep 11, 2020

Conversation

bartonip
Copy link

Implemented a clone method using ds_copy to clone GDALRaster objects.
Added conditional to simply return a clone of GDALRaster if SRID matches with transform srs argument.

@bartonip bartonip force-pushed the master branch 3 times, most recently from a778f6b to 23e5900 Compare August 30, 2020 12:05
@bartonip bartonip force-pushed the master branch 8 times, most recently from 5aee02a to 25be51b Compare August 30, 2020 12:43
Copy link
Member

@felixxm felixxm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bartonip Thanks for this patch 👍 Have you checked the previous PR #13167?

django/contrib/gis/gdal/raster/source.py Outdated Show resolved Hide resolved
tests/gis_tests/gdal_tests/test_raster.py Outdated Show resolved Hide resolved
@bartonip bartonip force-pushed the master branch 10 times, most recently from 7cac0b5 to 03cc033 Compare August 31, 2020 12:10
@bartonip
Copy link
Author

bartonip commented Sep 1, 2020

@felixxm refer to the current build, its because it doesnt work

@felixxm
Copy link
Member

felixxm commented Sep 1, 2020

@bartonip Thanks for demonstration.

@bartonip
Copy link
Author

bartonip commented Sep 1, 2020

@felixxm reverted and ready for merge

@felixxm
Copy link
Member

felixxm commented Sep 5, 2020

@yellowcap Can you take a look? Thanks.

Copy link
Member

@felixxm felixxm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bartonip Thanks 👍 Welcome aboard ⛵

I pushed small edits and fixed a destination filename.

django/contrib/gis/gdal/raster/source.py Outdated Show resolved Hide resolved
@felixxm felixxm changed the title Fixed #31766 -- Avoided uncessary computation in GDALRaster Fixed #31766 -- Made GDALRaster.transform() return a clone for the same SRID. Sep 8, 2020
@felixxm felixxm force-pushed the master branch 2 times, most recently from 4484246 to a758017 Compare September 8, 2020 07:07
django/contrib/gis/gdal/raster/source.py Outdated Show resolved Hide resolved
django/contrib/gis/gdal/raster/source.py Outdated Show resolved Hide resolved
django/contrib/gis/gdal/raster/source.py Outdated Show resolved Hide resolved
django/contrib/gis/gdal/raster/source.py Outdated Show resolved Hide resolved
@felixxm
Copy link
Member

felixxm commented Sep 8, 2020

@yellowcap Thanks for the review 👍 I pushed edits and extra tests.

@felixxm felixxm changed the title Fixed #31766 -- Made GDALRaster.transform() return a clone for the same SRID. Fixed #31766 -- Made GDALRaster.transform() return a clone for the same SRID and driver. Sep 8, 2020
@felixxm
Copy link
Member

felixxm commented Sep 8, 2020

Daniel, Can you take a look at my updates? Thanks 🌟

…me SRID and driver.

Thanks Daniel Wiesmann for the review.
@felixxm
Copy link
Member

felixxm commented Sep 11, 2020

Thanks both 👍

@felixxm felixxm merged commit 12d6cae into django:master Sep 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
5 participants