Forum

Author Topic: Georeferencing. Very confused. Please help  (Read 6431 times)

Dagon

  • Newbie
  • *
  • Posts: 26
    • View Profile
Georeferencing. Very confused. Please help
« on: April 29, 2017, 06:09:26 PM »
Hi, I'm going to be UAV mapping archaeological sites in South America next month and I'm new to Agisoft.

I am required to build georeferecned maps from which we can derive GPS coordinates of features from the orthomaps back home in the lab, so we can easily locate them on the ground on subsequent trips.

We are using DJI Phantom 3 Advanced and Phantom 4 Pro UAVs with Agisoft Photoscan Professional 1.3.0

In the Agisoft tutorials for orthomosaics and DEMs with and without GCPs, the first step is to load camera positions. Where do I get the .txt file for this and/or how do I generate it? Isn't this data supposed to come directly from the headers of each image? If not, I can't imagine how I would retrieve it.

The tutorial for creating maps with GCPs also has a step to import EXIF. Again, I'm confused about what this is and where it comes from.

Finally, how do I query a map for a coordinate system of a particular feature?

I need to spin up on this asap, so please help!

Packy_GIS

  • Full Member
  • ***
  • Posts: 107
    • View Profile
Re: Georeferencing. Very confused. Please help
« Reply #1 on: April 29, 2017, 10:14:46 PM »
Well - I would suggest to define, stabilize (place/draw) and measure GCPs with a precise GPS/total station if you work in local coordinate system. If your research is serious and a lot of effort and money goes into it I would better have this backed up - if you are not familiar with IMU data from your UAV.
I myself do the same job as you in Nort-East Afrika and I always have a backup solution ... because back in the lab you won't be able to measure stuff again.
Jan

Dagon

  • Newbie
  • *
  • Posts: 26
    • View Profile
Re: Georeferencing. Very confused. Please help
« Reply #2 on: April 29, 2017, 11:07:23 PM »
Thanks Jan.  No total station, just a drone in a backpack, a handheld GPS unit, compass and tape in the middle of nowhere. I know it's not ideal but I have to do the best I can within my limitations.

The first question I need answered is about importing camera positions. So, you are saying that the camera position data that is imported in the tutorial is IMU data and is necessary in addition to camera position data embedded in the photos?

I have used DroneDeploy, which uses only the information it can retrieve from the UAV images, to query the orthomap for GPS coordinates and have found the results adequate to our requirements but DroneDeploy is a web-based solution and we will be beyond internet access and generating maps on a laptop, hence Agisoft.

Also, I haven't found a way to retrieve a GPS coordinate from an Agisoft map (the equivalent of right-clicking on Google Maps to get lat/lon data). I assume it's possible?

 
 

Packy_GIS

  • Full Member
  • ***
  • Posts: 107
    • View Profile
Re: Georeferencing. Very confused. Please help
« Reply #3 on: April 30, 2017, 10:13:16 PM »
Hi again,
I am not familiar with DJI drones, but here is the workflow I use and/or could be useful:
1. As far I have read - the DJI's global accuacy is about 1m (in position) and about 3m in altitude - hope this is enough for you
2. I don't know how are your images geotaged - if the information is kept in the exif of your images (you may check this i.e. using Ifran View ->Image->Information and then Exif button - an additional extension may be installed). There you should see the Northing, Easting and other data from the IMU unit (Omega, Phi, Kappa - resp. Yaw, Pirch Roll). If you load such images into PhotoScan - you should see this information in the Reference pane (in the top part - where is this iformation for each image) - then you just go and compute it.
3. I have IMU unit for my Near-IR camera Tetracam - here I recieve a TXT file in which I have the LAT/LOT/Elev/Yaw/Pitch/Roll defined for each of my images - I just load this information into PS, say which field is whih and it should look like in my point 2.
4. Just for case - I don't know how large are the areas you will be working with - but this is what I would do ... I would define a local coordinate system and use it in case of emergency, when the drone data won't be working.
a) pick a point in an aera that is flat - this will be your inital point [0, 0, hanheld measured elevation as Z].
b) you shold shift the the ccoridnates i.e. to [1000, 1000, Z] so you won't fall into negative values
c) Pick another point laying in approximately the same altitude and measure the distance in-between these two points (measure it several times with a tape and make an overage) - this point will define the Y axis of your coordinate system and it's coodinates will be [0, DISTANCE, Z] - resp. [1000, 1000 + DISTANCE, Z]
d) Pick the third point - perpedincular (as much as possible) to the line defined by point 1 and 2 (from the point 1) and measure the distance again. This will have the coordinate [Distance 2, 0, Z].
e) use some kind of "Targets" that will be visible on the photos
f) use these points as markers when you will be processing the photos in PS
g) three points are the miminum for having the model "georeferenced" - it may not be well possitionally accuravy in all of the points, as only three GPCs were used (and are not equally placed) but your model will be in scale with the defined accuracy
h) check my "image" for the local coordinta system estalishment in the attachement


I hope that you will my guide a little bit usefull.
As I wrote earlier - the last method is the least accurate but can save your data. Use any axes orientation  - but remember to calculate the coordinate values correctly.

Jan

SAV

  • Hero Member
  • *****
  • Posts: 710
    • View Profile
Re: Georeferencing. Very confused. Please help
« Reply #4 on: May 01, 2017, 02:59:43 AM »
Hi Dagon,

DJI Phantom 3 Advanced and Phantom 4 Pro both store the location in the pictures (= geotagged images). The coordinate system which is used is WGS84. If you process these images in Photoscan, your point cloud/orthophoto/DEM will be georeferenced.
However, there is an issue with the elevation (Z-coordinate) that DJI drones store in the images (EXIF information). When you import them into Photoscan, the elevation has a negative value because it uses BELOW SEA LEVEL as a reference instead of ABOVE SEA LEVEL. However, there are some solutions to that issue in the Photoscan forum.
One is to measure the elevation at the point of take-off with a handheld GPS and then manually add the flight altitude to each picture. This works very well when you fly an autonomous mission at a pre-defined AGL (altitude above ground). For example, your point of take off is at 132m above sea level (measured with your Garmin GPS) and you plan a mission with an AGL of 60m. This would give you an altitude of 192m which you would use in the reference pane. Won't be very accurate though (+-3m), but probably the best solution for you.

Maybe use a few scale bars to help to scale your model. This would increase the overall accuracy. Use a few markers and measure the distance between those markers with a tape measure (for larger areas, your scale bars should be >10m). However, there might still be some tilt in your final model. But if you are just after the location of features in the orthophoto, then this should not be a big such a big issue (as long as you are aware of the inaccuracies).

I agree with Packy_GIS. If you want to get really accurate results, you would need to use GCPs and survey them with a total station or RTK GPS (which has cm accuracy). Or a drone that has RTK GPS capabilities built in (which is quite expensive though).

In the end it depends on what you would like to do with the dataset. As far as I understand you work in a difficult environment/remote location and you want to keep it as simple as possible, which makes sense.

One more thing. I would only use the Phantom 3 Advanced as a backup machine because the camera on the Phantom 4 Pro is MUCH better.
And last but not least, use either MapPilot or DJI GS Pro to plan your survey (you will need an iPad or iPhone to run them). DJI GS Pro (is free) and MapPilot both allow you to plan autonomous missions, which makes the image acquisition process so much easier and also more efficient.

All the best.

Regards
SAV



« Last Edit: May 01, 2017, 03:01:58 AM by SAV »

smcmurray

  • Newbie
  • *
  • Posts: 15
  • Registered Mine Surveyor
    • View Profile
Re: Georeferencing. Very confused. Please help
« Reply #5 on: June 27, 2017, 01:57:57 AM »
I disagree with the elevation issue I have used a P4 and P4 Pro extensively for stockpile surveys and the raw WGS-84 ellipsoidal height that comes through is positive as it should be. I am not sure whether this is a Nth Hemisphere thing but I doubt it SAV I am not sure why yours does this most unusual.

We have found the XYZ exif heading data in some cases can be as close as 900mm to the GCP control network that is surveyed in using traditional methods. Depends on sat config and fix.

Steve

SAV

  • Hero Member
  • *****
  • Posts: 710
    • View Profile
Re: Georeferencing. Very confused. Please help
« Reply #6 on: June 27, 2017, 08:01:14 AM »
Hi Steve,

The elevation issue on the P4 and P4 Pro might also depend on the firmware that is installed.

We have flown one survey in Feb 2017 with a Phantom 4 Pro. We were taking off on the beach (= sea level). However, the GPS altitude derived from EXIF/XMP stated 30m BELOW SEA LEVEL. This variation is due to the difference between the GEOID and ELLIPSOID, which varies around the globe and also depends on the which ellipsoid/geoid is used.

One needs to be aware of this potential issue; but it is quite simple to correct it in post processing.

Regards
SAV
« Last Edit: June 28, 2017, 05:32:57 AM by SAV »