natcap / urban-online-workflow

This repository hosts the beta implementation of the Urban Online ES Workflow. The project is intended to give urban planners the ability to create and assess scenarios using InVEST Urban models.
1 stars 5 forks source link

projection for derived LULC rasters #65

Closed davemfish closed 1 year ago

davemfish commented 1 year ago

I just noticed that the geotiffs created via wallpapering/fill operations are in an Albers projection, matching the parent LULC I assume.

If we want to add those tiffs to the frontend's map (that's what I was just trying to do), we'll need web mercator versions of them. Since the parcel geometries for wallpapering/filling are also in web mercator units, does it make sense to do all the processing in that projection?

I also wonder if any of the invest models have projection requirements to adhere to? Web mercator is probably a bad choice for that.

phargogh commented 1 year ago

Shoot, you're right! I'll take care of it this morning.

Since the parcel geometries for wallpapering/filling are also in web mercator units, does it make sense to do all the processing in that projection?

Yeah, it might. I'll take a look at this as well. I bet we could save some processing time too if we had the NLCD in web mercator from the get-go.

I also wonder if any of the invest models have projection requirements to adhere to? Web mercator is probably a bad choice for that.

Yeah, we'll need to dig into that a bit more. I don't think that any of the models will need to do anything special, but better to be sure. Even so, if a model does have specific projection requirements, I think we should be able to do that in that model's data prep in that model's execution job.

phargogh commented 1 year ago

Ok @davemfish I went ahead and changed all of the backend's assumptions so that the backend is now working entirely in EPSG3857 Web Mercator. Seems to be OK so far! This is as of rev 70c10dd.

Note that the backend app now looks for the web mercator NLCD now in the public bucket and in appdata/ at appdata/NLCD_2016_epsg3857.tif and appdata/NLCD_2016_epsg3857.aux.xml.tif. These files can both be grabbed from the public bucket if you'd like a local copy for speed.

@dcdenu4 I also changed the default LULC in the server files (sql_app.py, main.py), so I hope I didn't mess anything up there!

davemfish commented 1 year ago

Thanks, @phargogh ! We can now load these rasters with OpenLayers.

I didn't find the .xml file in the bucket, but I had one on hand already that went with the Albers tif. It's probably identical to the one you were using, but I didn't upload it myself just in case it's not.