locationtech / locationtech/geotrellis

GeoTrellisRasterSource possible reprojection bug

Open
#3,258 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Scala
Stars
1.4k
Forks
360
Avg merge
6h 57m
Merged PRs (30d)
12

Description

During the geotrellis-server work I notcied that WMS produces an incorrect metadata for some certain layers:

val rs = RasterSource("gt+s3://geotrellis-demo/catalog/napl?layer=markham&zoom=18&band_count=1")
val rr = rs.reproject(LatLng)
val expected = ReprojectRasterExtent(rs.gridExtent, rs.crs, LatLng, Options.DEFAULT)
rr.extent shouldBe expected.extent

//  actual: Extent(-79.40248489379884, 43.81618476019972, -79.15603855282134, 43.943257696006555) was not equal to 
// expected: Extent(-79.42689299583435, 43.78121880534035, -79.13940902524496, 43.95686961703119)

The difference is pretty signifcant for WMS visualisation. The temporary workaround for WMS services would be applied.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the RasterSource.reproject(LatLng) path and compare its extent with ReprojectRasterExtent(rs.gridExtent, rs.crs, LatLng, Options.DEFAULT) using the supplied S3 catalog example. Run or add a focused regression test around the shown extent mismatch; done means the reprojection metadata matches the expected extent and WMS visualization no longer needs the workaround.

Written by the indexing model from the issue text.

Assessment

Tech stack
scala
Domain
data, web-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.