Forum

Author Topic: Replacing photos in a project  (Read 2052 times)

macsurveyr

  • Jr. Member
  • **
  • Posts: 69
    • View Profile
Replacing photos in a project
« on: May 18, 2017, 10:13:06 PM »
Is there a way to get PhotoScan to fully recognize photos if they are changed, replaced that is?

For instance, if I create a project with 3 band TIF images, align, refine things, add GCP’s etc. and then decide that I would like to swap out the 3 band imagery for 4 band, PhotoScan does not show anything other than the original 3 bands.

The images are exactly the same dimensions and all found tie points, markers, and camera calibrations have not changed and everything should work fine. If only I could get the new images fully recognized.

Thanks,

Tom

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 14813
    • View Profile
Re: Replacing photos in a project
« Reply #1 on: May 24, 2017, 12:47:14 PM »
Hello Tom,

Sorry for the late reply. You might have already received the reply via e-mail, but the case may be also interesting to others.

It is safe to swap if the number of bands is the same. PhotoScan doesn’t store information image bit depth (8 bit, 16 bit, 32 bit, integer of float) so, for example, 8 bit images can be swapped with 16 bit images at any time.
 
Swapping the images with the different number of bands is more complicated, because PhotoScan loads the list of bands when the images are added to the project and stores them in the project file. So besides swapping the images themselves it is required to update the list of bands in the project itself. This can be done using a Python script in PhotoScan Pro.

For example, assuming there is only one sensor (calibration group) in the project, you can change the list of bands by executing the following line in Console pane (or in the script):

Code: [Select]
PhotoScan.app.document.chunk.sensors[0].bands = ['Band 1', 'Band 2', 'Band 3', 'Band 4']
The number of bands and their names can be changed as needed.
Best regards,
Alexey Pasumansky,
Agisoft LLC