kartoza / rezoning-2-project

Rezoning project organizational repository
Creative Commons Zero v1.0 Universal
0 stars 4 forks source link

Clip Regions [Epic 4] #7

Closed NEDJIMAbelgacem closed 1 year ago

NEDJIMAbelgacem commented 1 year ago

Expectation:

Clip regional analysis data, which is currently a global layer.

Dependencies:

None

Description:

When selecting a region instead of a country, the current application simply navigates to the regional extent, but provides a global layer which is not clipped or masked accordingly.

Scope:

The optimal process may depend on existing implementation details.

Requirements:

Data processing pipeline details and access to vector source processes

Success Criteria:

Vector features are visibly limited in extent to the selected regional boundaries

NEDJIMAbelgacem commented 1 year ago

Relates to https://github.com/kartoza/rezoning-2-project/issues/6 Probably simular aproach

NEDJIMAbelgacem commented 1 year ago

UPDATE:

There is a huge distiction between this and https://github.com/kartoza/rezoning-2-project/issues/6. The current behaviour of the app is that when a region is selected there is nothing specified for regions in the layer request: For example for a URL requesting tile 5,17,13 of gsa-pvout layer of the country DZD will look like this: https://d2b8erzy6y494p.cloudfront.net/v1/layers/DZA/solar/gsa-pvout/5/17/13.png?colormap=viridis But for selecting MENA region for example the request URLs for the same tile 5, 17,13 will look like this: https://d2b8erzy6y494p.cloudfront.net/v1/layers/gsa-pvout/5/17/13.png?colormap=viridis Which doesn't contain any country or region code to be used by the backend in order to clip the unnecessary tiles. This ultimately turns in to the displayed solar power output (gsa-pvout raster) for a region looking like this:

clip-regions

Potential way to fix it:

NEDJIMAbelgacem commented 1 year ago

Addressed in https://github.com/worldbank/WB-rezoning-explorer/pull/4 and https://github.com/worldbank/WB-rezoning-explorer-api/pull/4 Ping @ClaraIV , @gclapp1

ClaraIV commented 1 year ago

this is not oin staging site yet

ClaraIV commented 1 year ago

Please see errors in layer for Black Sea/ Carribean/ Caspian Sea below; these errors appear for all raster layers displayed for these regions

image

image

image

ClaraIV commented 1 year ago

Offshore wind doesn't look right neither for the inland regions, see how Offshore Wind layer is presented in land below:

image

gclapp1 commented 1 year ago

None of the regional level Offshore wind appear to be generating correctly:

NEDJIMAbelgacem commented 1 year ago

The script for creating the geometries has some broken parts and I'm currently investigating this problem. One clue I have is that some countries like russia have some very wide areas which break the creation of cutline (masking) of tiles, but I am yet to apply solution to it.

ClaraIV commented 1 year ago

The issue seems to be global for offshore wind - see below the case for Cabo Verde, a small area:

Image

NEDJIMAbelgacem commented 1 year ago

The artifact of this have been addressed and doesn't appear anymore.

ClaraIV commented 1 year ago

@akshay2408 @dimasciput Perhaps related or a separate ticket, but the offshore wind layer is not loading properly for all countries - please try Greenland - there is data for the country but it is not displayed in its entirety image

image

gclapp1 commented 1 year ago

Looks great, tested all 6 regions and clipping is now consistent with geographic area of interest.

Closing ticket and moving to Accepted.