OpenDroneMap / NodeMICMAC

A Lightweight REST API to Access MICMAC Photogrammetry and SFM Engine.
https://opendronemap.org/nodemicmac/
GNU General Public License v3.0
79 stars 21 forks source link

Fixed path issue in loading ODM GCP file #39

Closed pierotofy closed 4 years ago

pierotofy commented 4 years ago

os.listdir returns relative paths, but since the current working directory is /var/www/data/<uuid>/images, gcp_list.txt is resolved as /var/www/data/<uuid>/images/gcp_list.txt, which is not correct.

The GCP file is in /var/www/data/<uuid>/gcp/gcp_list.txt.

os.path.join resolves this issue.

pierotofy commented 4 years ago

Also note, per NodeODM specification, the GCP file might not be necessarily be named gcp_list.txt. Any file with .txt extension should be treated as a GCP. https://github.com/OpenDroneMap/NodeODM/blob/master/docs/index.adoc#post-tasknew