Forum

Author Topic: Incremental images alignement not working  (Read 1458 times)

djyoung

  • Newbie
  • *
  • Posts: 21
    • View Profile
Incremental images alignement not working
« on: March 24, 2024, 07:55:43 PM »
Hello -- I am attempting to follow the "incremental image alignment" procedure to align a new set of images to an existing set of tie points (sparse cloud). I have selected the "Keep key points" preference, and when I align the second set of images, I disable "Reset current alignment" option.

The behavior is easy to reproduce:
1. Add this folder (https://ucdavis.box.com/s/1ms3sqr13t001k0poiylspt4hl4cn9us) of 174 photos and align.
2. Build and export DEM based on tie points.
3. Add this folder (https://ucdavis.box.com/s/mq9woeeffua83t9688oa81pl6lnak9zz) of 145 photos and align.
4. Build and export DEM based on tie points.

The DEM from Step 4 is shifted relative to the DEM from Step 2, indicating the tie points have been reset and recreated from scratch in Step 3.

I am running this on Ubuntu 22.10. I align using quality Medium, with adaptive camera model fitting. The same thing happens to me in versions 2.1.1, 2.1.0, 1.8.4, and 1.7.1. I've seen multiple reports in the forum over the years of the same issue. I'd appreciate it if Metashape support could attempt to reproduce this issue with my dataset to identify a solution to this bug. Thank you!

Alexey Pasumansky

  • Agisoft Technical Support
  • Hero Member
  • *****
  • Posts: 14927
    • View Profile
Re: Incremental images alignement not working
« Reply #1 on: March 26, 2024, 02:56:27 PM »
Hello djyoung,

Are you checking on cameras in the Reference pane after adding new folder at step 3? If so, then shift between alignments after step 3 and step 1 seem expected, as different reference data is used for these cases.
Best regards,
Alexey Pasumansky,
Agisoft LLC

djyoung

  • Newbie
  • *
  • Posts: 21
    • View Profile
Re: Incremental images alignement not working
« Reply #2 on: March 27, 2024, 07:47:55 AM »
Hi Alexey -- No, I was leaving the checks as their default values (all checked, for first and second set of images). However, I just tried unchecking all images in the second set before aligning, and I got the same result (objects in the second DEM shifted by about 3.5 m relative to the first DEM. What can I do to force the initial tie points (and their locations) to be retained? Thank you.

(For others reading this post, my workflow is outlined here: https://www.agisoft.com/forum/index.php?topic=15638.0)

djyoung

  • Newbie
  • *
  • Posts: 21
    • View Profile
Re: Incremental images alignement not working
« Reply #3 on: April 04, 2024, 06:22:45 PM »
Hi Alexey -- I'm just following up on this inquiry. I'd appreciate any insight you could provide. Thank you.

djyoung

  • Newbie
  • *
  • Posts: 21
    • View Profile
Re: Incremental images alignement not working
« Reply #4 on: April 15, 2024, 06:05:15 PM »
Hi Alexey (or Agisoft Support generally) -- I'm following up to see if you can help me resolve this issue. If you follow my workflow, with the data files I shared, you'll see that incremental alignment isn't working as expected, even with your suggestion of unchecking the cameras. Thank you in advance for your help with this.

djyoung

  • Newbie
  • *
  • Posts: 21
    • View Profile
Re: Incremental images alignement not working
« Reply #5 on: April 22, 2024, 08:36:50 PM »
Hello Agisoft -- I'm just following up on this issue (potential bug). I'd appreciate your insight when you have a moment. Thank you.

e.spiridonova

  • Agisoft Technical Support
  • Newbie
  • *****
  • Posts: 38
    • View Profile
Re: Incremental images alignement not working
« Reply #6 on: April 26, 2024, 11:24:10 AM »
Dear djyoung,

During the incremental alignment, the chunk.transform changes, so you can observe a slight shift in the original tie point cloud. If you want to leave the first part unchanged, then as a workaround we can offer the following workflow:
- In one chunk, perform alignment for the data that you would like not to change.
- After that, duplicate it (select Duplicate... command from the Chunk context menu on the Workspace pane).
- Add the part you want to align to the duplicated chunk and perform the alignment.
- After that, using Python, you can apply the transformation matrix from the first chunk to the second. To do this, open the Console pane (select View > Console) and run the following command:
Metashape.app.document.chunks[1].transform.matrix = Metashape.app.document.chunks[0].transform.matrix


Best regards,
Elizaveta Spiridonova,
Agisoft LLC