Colmap export bugs.

I found an issue in COLMAP text export after re-aligning a large project with added control points.
I aligned over 10 000 images from drone + DSLR using control points. Everything looks fine visually, got 1 component with like 98% of images aligned. Then, as usual, tried to export the data to colmap format so I can train a splat. No errors on export, everything saved fine (exported with image undistortion so I have pinhole cameras).
But I cant import this data anywhere, for example to Postshot. It throws an error about wrong database format. So I asked AI to validate the data and it confirmed that:

  • Many image records in images.txt reference camera IDs not present in cameras.txt.
  • IDs can be very large/unexpected (examples seen in validation: 37566, 79615, 44075, 939468).
  • cameras.txt reports around 10,334 cameras, ID range 1..10,334.
  • Exported images.txt appears structurally inconsistent in many places (missing keypoint second lines), causing parser desync in downstream tools.

Observed counts from exported files:

  • cameras.txt number of cameras: 10,334
  • images headers parsed: 10,334
  • image->camera missing references: 6,314
  • distinct missing camera IDs: 5,153
  • image keypoint lines with invalid token grouping (not x y point3D_ID triples): 7,014

Hello @ReverseGravity, can you provide us with detailed repro steps to replicate the problem, which also include the dataset? We will take a look at it.