Author Topic: 179 Kappa causing a problem when scripting  (Read 1881 times)


  • Newbie
  • *
  • Posts: 2
    • View Profile
179 Kappa causing a problem when scripting
« on: June 07, 2018, 12:19:24 AM »

I have been beating my head against the wall for several days about this problem. I have about 30 individual sites comprising of 4-5  medium format images in a single flight line. I am trying to automatically process this data using python script AKA zero human input.

I have a very accurate EO and Camera calibration parameters that I know are good. My logic is if I input these parameters and then allow Photoscan a little freedom to match them between each photo I will have near perfect absolute accuracy and relative accuracy. I am inputting every parameter I can. Exterior orientation, camera calibration, focal length, and pixel size. I am letting it have some freedom when it comes to lens distortion K123. Everything else is hard set because I know it is good information and keeps me from needing GCPs.

The EO or "reference data" for each photo is in Omega Phi Kappa format. My script works on roughly 25 of these 30 sites. The sites it won't work on were all flown south to north. This makes the Kappa/heading be around 179 or -179. 

On these sites when I go to align them it is directing the pictures off to the side. Instead of straight down.  It says my Phi error is 75 degrees off.  My documented camera accuracy in meters is .05 and in degrees .5 So I know good and well my Phi isn't 75 degrees off.

So, I have found a work around by manually using "convert reference" I convert the rotation angles to Yaw  pitch roll and I can manually finish out the process and the ortho mosaic lines up exactly where it should!

So, I went to the software that deferentially corrects my data and produces the EO to see if I can output Yaw pitch and roll. I wanted to do it this way to keep from re scripting the conversion from OPK to YPR.

I figured out a way to output YPR and go to use it in PS. BUT, my Yaw is 359 degrees from my correction software but when I converted the OPK in Photoscan it is saying its 179 degrees.

The result of each process is the 359 degree Yaw is upside down and the 179 degree Yaw is perfect.

It seems my current work around is going to need to be to code the conversion from OPK to YPR. But it just doesn't make sense why this wont work with my current code like the remaining 25 sites that are flown the other cardinal directions.

I know the software does best when it has side lap. And I know that this isn't an issue on the sites where multiple lines are flown alternating directions. We are working with an airplane based system with gyro stabilized mount, GPS/IMU, USGS certified and calibrated cameras. We know the absolute accuracy is going to be roughly 3X the cell size without using Photoscan. I am hoping with adding Photoscan our relative accuracy will be such that no seamlines will be visible in the final product.

Flying multiple lines is not an option for every site. Nor is it needed. The 25 sites that worked are single lines and they line up perfectly with our normal ERDAS workflow orthomosaics. Only the Photoscan mosaic has zero visible seamlines where ERDAS most every seamline is visible.

Thanks for the help!

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 14965
    • View Profile
Re: 179 Kappa causing a problem when scripting
« Reply #1 on: June 12, 2018, 06:52:59 PM »
Hello Lhancock04,

Thank you for reporting.

We'll try to reproduce the problem.
Best regards,
Alexey Pasumansky,
Agisoft LLC


  • Newbie
  • *
  • Posts: 2
    • View Profile
Re: 179 Kappa causing a problem when scripting
« Reply #2 on: June 13, 2018, 11:09:20 PM »
Thanks Alexey!