Forum

Author Topic: output camera EXIF and location  (Read 17796 times)

jondandois

  • Newbie
  • *
  • Posts: 10
    • View Profile
output camera EXIF and location
« on: April 27, 2011, 06:42:34 PM »
Hi,

Is there a way to be able to link the input photo EXIF tag info to the camera locations in the output point cloud data?

I have looked through the forums and done my own research with the software, but have not found any such capabilities.  I am running some automated computations on the output point cloud data and it would be great to have a programmatic link to the EXIF tag info for the cameras.

Is the output camera list in a specific order?  Or is there a way to export all of this information?  I am working with large sets of 200+ photos so an automated approach would be best.

Thanks!

Jonathan

p.s. - this software has been an amazing asset for our research, thank you

jondandois

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: output camera EXIF and location
« Reply #1 on: May 18, 2011, 06:58:47 PM »
No love on this one ?  :(

I've been thinking about the question some more and thought it might help to rephrase the problem.

Given the output camera information (for example in the XML format) how do I know which input photo corresponds to each <camera></camera> entry?

So if I have this:

<camera>
    <calibration>
      <fx>3.0395601606145174e+03</fx>
      <fy>3.0395601606145174e+03</fy>
      <cx>1.8259359612702883e+03</cx>
      <cy>1.3677519995605307e+03</cy>
      <skew>0.0000000000000000e+00</skew>
      <k1>-6.5117167652428865e-02</k1>
      <k2>2.9058271616028013e-02</k2>
      <k3>1.0967418712134738e-02</k3>
      <p1>0.0000000000000000e+00</p1>
      <p2>0.0000000000000000e+00</p2>
    </calibration>
    <R>9.9509537269842752e-01 -9.8913964610180746e-02 -1.1076277685300021e-03 9.8653421411748501e-02 9.9317156332172407e-01 -6.2271568575382082e-02 7.2595921327352937e-03 6.1856878471019373e-02 9.9805862799130585e-01</R>
    <t>-6.9239825500717087e+00 2.0587097282920755e+01 -4.8773705651924737e-01</t>
  </camera>


...I know that it corresponds to photo X.jpg.

Anyone else have any experience with this?

Thanks!

Jonathan

Monserrat

  • Newbie
  • *
  • Posts: 18
    • View Profile
Re: output camera EXIF and location
« Reply #2 on: May 18, 2011, 07:45:00 PM »
This is already resolved in its final version:

PhotoScan Change Log

Version 0.8.1 build 877 (01 May 2011)

    Added support for GPS camera coordinates import from EXIF meta data.

jondandois

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: output camera EXIF and location
« Reply #3 on: May 18, 2011, 08:37:04 PM »
Thanks for the response Monserrat, but I think what I am asking is not the same thing as what was addressed in the build update. 

When I export points, for example as XML, I get a list of the solved camera intrinsics and extrinsics, but there is no tag or information about what photograph those parameters are associated with. 

This information must be present at some level in the software as the 'camera' points are shown associated with the input photos in the 3D model display.  But what I am trying to find is if that connection between solved camera information and original photo information can be exported.  I specifically want to be able to get the EXIF time at each solved camera point.

Thanks!

Dmitry Semyonov

  • Agisoft Technical Support
  • Full Member
  • *****
  • Posts: 202
    • View Profile
Re: output camera EXIF and location
« Reply #4 on: May 19, 2011, 01:24:53 AM »
Hello Jonathan,

When saving camera intrinsics/extrinsics in the PhotoScan structure xml file format, the cameras are listed in the same order, as they appear in the Workspace/Photos panes.

Unfortunately no other tags or photo identifiers are currently stored in the file.

We can probably include a label for each camera with a file name of the corresponding photo in the next update. Will that fulfill your requirements?

With best regards,
Dmitry Semyonov
AgiSoft LLC
With best regards,
Dmitry Semyonov
Agisoft

jondandois

  • Newbie
  • *
  • Posts: 10
    • View Profile
Re: output camera EXIF and location
« Reply #5 on: May 24, 2011, 07:10:18 PM »
Hi Dmitry,

The info that the XML camera list is in the same order as the input image list is already very helpful, and I suspected that it was something like that.  Of course, having a tag in the XML file would be even better for our applications!

Something like:

<camera>
    <filename>IMG_0001.JPG</filename>
    <calibration>
     ...
    </calibration>
    <R>...</R>
    <t>...</t>
</camera>

I will be working with what information we have so far.

Thank you!

Jonathan

JasonInVegas

  • Newbie
  • *
  • Posts: 1
    • View Profile
Re: output camera EXIF and location
« Reply #6 on: May 25, 2011, 09:28:41 PM »
Hi Jon (and Dmitry),

Firstly, I hope that this post is helpful and adds to solutions rather than confusion.

My comments are two points: first is a reminder that cameras are calibrated using multiple images, and second that the XML addition of a single photo filename in the camera is a poor normalization of data....because camera positions can potentially shoot multiple photos.

Instead, I propose that camera XML headers simply receive their UUID or other unique 'project' identifier, then that camera identifier can be exported in the XML for the photos.....since any photo can only come from one and only one camera.

Illustrating this in XML , I suggest:

<camera>
  <ID>AU345FK9FKEHCIRKS991</ID>
  <calibration>
  </calibration>
</camera>

and in the photos....

<photo>
  <filename>IMG_0001.JPG</filename>
  <camera_ID>AU345FK9FKEHCIRKS991</camera_ID>
  <EXIF>
       ...
  </EXIF>
</photo>

From this information you can derive which photos were used in the camera calibrations, and which EXIF parameters were compiled by which cameras, etc., all using the photos as the relationship to the camera(s) of interest.

It is also noteworthy to mention that this is how other 'competitor systems' export their camera-to-photo mappings. I am more a fan of proper data normalization rather than doing it just because it is already being done that way...but in this case it makes sense from both perspectives, in my opinion.

Again I hope this helps!  What would also help is a better understanding of what EXIF tag parameters you are trying to lift from the photos and associate with the camera points.

Lastly, if by any chance you are loading these points into ESRI's ArcGIS, then I already have a script which programmatically tags the camera observations with the photo names, EXIF tags, and the calibration details.

Regards,
Jason Schwartz, Principal Investigator
Follow-Me Systems, LLC
Las Vegas, NV USA
www.follow-me-systems.com

Monserrat

  • Newbie
  • *
  • Posts: 18
    • View Profile
Re: output camera EXIF and location
« Reply #7 on: May 25, 2011, 09:48:58 PM »
I think it works, very well.  We should not add confusion to the issue. What has worked well, let it work well.