Forum

Author Topic: Force selection of pairs to solve?  (Read 5321 times)

luminus

  • Newbie
  • *
  • Posts: 13
    • View Profile
Force selection of pairs to solve?
« on: June 26, 2018, 11:32:58 PM »
If I have the ability to select pairs I want to Photoscan to use, can I force it to only use those pairs for feature detection, matching, and camera alignment?

I can verify that the pairs being selected would provide sufficient connectivity. It would be important that only those pairs get used, and no others.

This is because Photoscan fails to align datasets that frequently have either time or location coincident images where the pair matches do not have good 3d information (no baseline).

Alternatively, is there a way to force Photoscan to not attempt to align time or location coincident images? I understand it probably doesn't have image acqusiition time, but a simple way to do this for location would be to not use any pairs that are not sufficient far enough away from each other.

luminus

  • Newbie
  • *
  • Posts: 13
    • View Profile
Re: Force selection of pairs to solve?
« Reply #1 on: June 27, 2018, 03:24:30 AM »
This is why this is needed. It solved the cameras, but all the time coincident images generated a ton of bad data and definitely impacted the final geometry solution.

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 15650
    • View Profile
Re: Force selection of pairs to solve?
« Reply #2 on: June 27, 2018, 04:54:14 PM »
Hello luminus,

You can use custom preselection via Python:
Code: [Select]
chunk.matchPhotos(accuracy=HighAccuracy, generic_preselection=False, reference_preselection=False, keypoint_limit=40000, tiepoint_limit=4000, pairs = camera_pairs)
#where camera_pairs is a list of PhotoScan.Camera tuples
camera_pairs = [(chunk.cameras[0], chunk.cameras[1]), (chunk.cameras[1], chunk.cameras[2])]

But what kind of data you are using for this project and which sensor has been used to capture them?
Best regards,
Alexey Pasumansky,
Agisoft LLC

luminus

  • Newbie
  • *
  • Posts: 13
    • View Profile
Re: Force selection of pairs to solve?
« Reply #3 on: June 28, 2018, 01:09:14 AM »
I believed I tried this last year and there was indication it was still using pairs that I didn't specify (as seen by view matches). I will try again with the latest version and make sure to explicitly disable the other preselection types.

This is 6 band data (Color, NIR, Red edge, thermal) from a dual swath camera configuration, so 8 cameras. All images are precisely exposed simultaneously.

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 15650
    • View Profile
Re: Force selection of pairs to solve?
« Reply #4 on: June 28, 2018, 06:32:50 PM »
Hello luminus,

If the same point is a tie point for the pair (image A, image B) and pair (image B, image C) it will become the tie point between image A and image C automatically, even if you haven't used that pair in your custom preselection.

For multispectral layout you should provide pairs for the cameras inside each band separately, and also provide all possible pairs for all bands of the same camera station.
Best regards,
Alexey Pasumansky,
Agisoft LLC