{"action":"closed","issue":{"url":"https://api.github.com/repos/locationtech/geotrellis/issues/2635","repository_url":"https://api.github.com/repos/locationtech/geotrellis","labels_url":"https://api.github.com/repos/locationtech/geotrellis/issues/2635/labels{/name}","comments_url":"https://api.github.com/repos/locationtech/geotrellis/issues/2635/comments","events_url":"https://api.github.com/repos/locationtech/geotrellis/issues/2635/events","html_url":"https://github.com/locationtech/geotrellis/issues/2635","id":316469820,"number":2635,"title":"RDD readed by `HadoopCOGLayerReader` is incorrect","user":{"login":"Frophie","id":9249196,"avatar_url":"https://avatars0.githubusercontent.com/u/9249196?v=4","gravatar_id":"","url":"https://api.github.com/users/Frophie","html_url":"https://github.com/Frophie","followers_url":"https://api.github.com/users/Frophie/followers","following_url":"https://api.github.com/users/Frophie/following{/other_user}","gists_url":"https://api.github.com/users/Frophie/gists{/gist_id}","starred_url":"https://api.github.com/users/Frophie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Frophie/subscriptions","organizations_url":"https://api.github.com/users/Frophie/orgs","repos_url":"https://api.github.com/users/Frophie/repos","events_url":"https://api.github.com/users/Frophie/events{/privacy}","received_events_url":"https://api.github.com/users/Frophie/received_events","type":"User","site_admin":false},"labels":[{"id":217463,"url":"https://api.github.com/repos/locationtech/geotrellis/labels/bug","name":"bug","color":"e10c02","default":true}],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/locationtech/geotrellis/milestones/15","html_url":"https://github.com/locationtech/geotrellis/milestone/15","labels_url":"https://api.github.com/repos/locationtech/geotrellis/milestones/15/labels","id":2373556,"number":15,"title":"2.0","description":"","creator":{"login":"echeipesh","id":1158084,"avatar_url":"https://avatars2.githubusercontent.com/u/1158084?v=4","gravatar_id":"","url":"https://api.github.com/users/echeipesh","html_url":"https://github.com/echeipesh","followers_url":"https://api.github.com/users/echeipesh/followers","following_url":"https://api.github.com/users/echeipesh/following{/other_user}","gists_url":"https://api.github.com/users/echeipesh/gists{/gist_id}","starred_url":"https://api.github.com/users/echeipesh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/echeipesh/subscriptions","organizations_url":"https://api.github.com/users/echeipesh/orgs","repos_url":"https://api.github.com/users/echeipesh/repos","events_url":"https://api.github.com/users/echeipesh/events{/privacy}","received_events_url":"https://api.github.com/users/echeipesh/received_events","type":"User","site_admin":false},"open_issues":24,"closed_issues":44,"state":"open","created_at":"2017-03-09T03:57:56Z","updated_at":"2018-05-16T19:36:34Z","due_on":"2018-04-28T07:00:00Z","closed_at":null},"comments":1,"created_at":"2018-04-21T07:23:47Z","updated_at":"2018-05-16T19:36:34Z","closed_at":"2018-05-16T19:36:34Z","author_association":"NONE","body":"[COG.zip](https://github.com/locationtech/geotrellis/files/1934243/COG.zip)\r\nRead this COG catalog by `HadoopCOGLayerReader` and wtite the stitched result, like this:\r\n```\r\n    val reader = HadoopCOGLayerReader(path)(sc)\r\n\r\n    val layer = reader.read[SpatialKey, MultibandTile](LayerId(\"crop_COG\", 11))\r\n\r\n    val pathHadoop = new Path(path + \"stitched.tif\")\r\n    val raster = layer.stitch()\r\n    val geoTiff = GeoTiff(raster, layer.metadata.crs)\r\n    geoTiff.write(pathHadoop, sc.hadoopConfiguration)\r\n```\r\ngot a result with some tiles not in the right position.\r\nThis is the tiffs in \"7_11\" level:\r\n![cog](https://user-images.githubusercontent.com/9249196/39081598-d0fbabbe-4576-11e8-952b-b00a1d310e04.png)\r\nAnd this is the stitched result:\r\n![stitched](https://user-images.githubusercontent.com/9249196/39081602-e5491980-4576-11e8-9c1a-573d321a78dc.png)\r\nThe offset is one tile wide(256 cell), so I suspect the SpatailKey in RDD is miscalculated.\r\n\r\nNote: to use the COG catalog, need to change the `path` value in \"crop_COG___0___header.json\".\r\nThis COG catalog is created by 2.0.0-M2."}}
{"actor":{"display_login":"pomadchin"}}