{"action":"created","issue":{"url":"https://api.github.com/repos/hotosm/oam-uploader-api/issues/42","repository_url":"https://api.github.com/repos/hotosm/oam-uploader-api","labels_url":"https://api.github.com/repos/hotosm/oam-uploader-api/issues/42/labels{/name}","comments_url":"https://api.github.com/repos/hotosm/oam-uploader-api/issues/42/comments","events_url":"https://api.github.com/repos/hotosm/oam-uploader-api/issues/42/events","html_url":"https://github.com/hotosm/oam-uploader-api/issues/42","id":184612136,"number":42,"title":"Resolution is not calculated correctly","user":{"login":"cgiovando","id":10201533,"avatar_url":"https://avatars2.githubusercontent.com/u/10201533?v=3","gravatar_id":"","url":"https://api.github.com/users/cgiovando","html_url":"https://github.com/cgiovando","followers_url":"https://api.github.com/users/cgiovando/followers","following_url":"https://api.github.com/users/cgiovando/following{/other_user}","gists_url":"https://api.github.com/users/cgiovando/gists{/gist_id}","starred_url":"https://api.github.com/users/cgiovando/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cgiovando/subscriptions","organizations_url":"https://api.github.com/users/cgiovando/orgs","repos_url":"https://api.github.com/users/cgiovando/repos","events_url":"https://api.github.com/users/cgiovando/events{/privacy}","received_events_url":"https://api.github.com/users/cgiovando/received_events","type":"User","site_admin":false},"labels":[{"id":244921085,"url":"https://api.github.com/repos/hotosm/oam-uploader-api/labels/bug","name":"bug","color":"fc2929","default":true}],"state":"open","locked":false,"assignee":{"login":"tombh","id":160835,"avatar_url":"https://avatars1.githubusercontent.com/u/160835?v=3","gravatar_id":"","url":"https://api.github.com/users/tombh","html_url":"https://github.com/tombh","followers_url":"https://api.github.com/users/tombh/followers","following_url":"https://api.github.com/users/tombh/following{/other_user}","gists_url":"https://api.github.com/users/tombh/gists{/gist_id}","starred_url":"https://api.github.com/users/tombh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tombh/subscriptions","organizations_url":"https://api.github.com/users/tombh/orgs","repos_url":"https://api.github.com/users/tombh/repos","events_url":"https://api.github.com/users/tombh/events{/privacy}","received_events_url":"https://api.github.com/users/tombh/received_events","type":"User","site_admin":false},"assignees":[{"login":"tombh","id":160835,"avatar_url":"https://avatars1.githubusercontent.com/u/160835?v=3","gravatar_id":"","url":"https://api.github.com/users/tombh","html_url":"https://github.com/tombh","followers_url":"https://api.github.com/users/tombh/followers","following_url":"https://api.github.com/users/tombh/following{/other_user}","gists_url":"https://api.github.com/users/tombh/gists{/gist_id}","starred_url":"https://api.github.com/users/tombh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tombh/subscriptions","organizations_url":"https://api.github.com/users/tombh/orgs","repos_url":"https://api.github.com/users/tombh/repos","events_url":"https://api.github.com/users/tombh/events{/privacy}","received_events_url":"https://api.github.com/users/tombh/received_events","type":"User","site_admin":false}],"milestone":null,"comments":13,"created_at":"2016-10-22T05:52:04Z","updated_at":"2017-04-25T20:24:15Z","closed_at":null,"body":"All the imagery that was [uploaded recently](https://beta.openaerialmap.org/#/-73.93524169921875,18.411866765202845,9?date=month&resolution=high&_k=6hcpfl) for Hurricane Matthew response shows `RESOLUTION` as `0`.\n\nPrevious images like [these UAV ones in Tajikistan](https://beta.openaerialmap.org/#/71.71875,37.71859032558816,5/1231003?resolution=high&_k=6e0tod), show the resolution correctly.\n"},"comment":{"url":"https://api.github.com/repos/hotosm/oam-uploader-api/issues/comments/297153925","html_url":"https://github.com/hotosm/oam-uploader-api/issues/42#issuecomment-297153925","issue_url":"https://api.github.com/repos/hotosm/oam-uploader-api/issues/42","id":297153925,"user":{"login":"mojodna","id":45,"avatar_url":"https://avatars1.githubusercontent.com/u/45?v=3","gravatar_id":"","url":"https://api.github.com/users/mojodna","html_url":"https://github.com/mojodna","followers_url":"https://api.github.com/users/mojodna/followers","following_url":"https://api.github.com/users/mojodna/following{/other_user}","gists_url":"https://api.github.com/users/mojodna/gists{/gist_id}","starred_url":"https://api.github.com/users/mojodna/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mojodna/subscriptions","organizations_url":"https://api.github.com/users/mojodna/orgs","repos_url":"https://api.github.com/users/mojodna/repos","events_url":"https://api.github.com/users/mojodna/events{/privacy}","received_events_url":"https://api.github.com/users/mojodna/received_events","type":"User","site_admin":false},"created_at":"2017-04-25T20:24:15Z","updated_at":"2017-04-25T20:24:15Z","body":"From Slack:\r\n\r\n```bash\r\n#!/usr/bin/env bash\r\n\r\nset -eo pipefail\r\n\r\naws s3 ls s3://${1}/ --recursive | \\\r\n  grep \\.tif$ | \\\r\n  awk \"{print \\\"s3://${1}/\\\" \\$4}\" | \\\r\n  while read src; do\r\n    echo $src\r\n    filename=$(basename $src)\r\n    aws s3 cp $src .\r\n\r\n    set +e\r\n    aws s3 cp ${src%.tif}_meta.json orig.json\r\n    set -e\r\n\r\n    oin-meta-generator $filename > new.json\r\n\r\n    if [[ -e orig.json ]]; then\r\n      jq -s '.[0] * .[1]' orig.json new.json > meta.json\r\n      aws s3 cp meta.json ${src%.tif}_meta.json\r\n    else\r\n      aws s3 cp new.json ${src%.tif}_meta.json\r\n    fi\r\n\r\n    rm -f $filename orig.json new.json meta.json\r\n  done\r\n```\r\n\r\nUsage: `backfill-metadata.sh <bucket>`\r\n\r\nShould be run from us-east-1 because it needs to download files from S3 in order to generate metadata from them."}}
{"actor":{"display_login":"mojodna"}}