Two CP correlation values alignment

Asked by Mike Perrett

I start an old 85 image B&W aerial map stitch with a CP correlation value of 8, I then couldn't find enough CPs at that level and was forced to drop down to 4 as some images were not of the same quality. Forests of trees in some images didn't permit a lot of CPs either which made it more difficult. I'm only new to stitching and my problem has probably been asked many times before, however is there a way to select all control points for alignment, instead of only the first value of 8 being automatically selected please? Only about 9 of every 16 get selected for alignment in the fast panorama preview window align which is not enough. I've been using the RXYZVB alignment, can you suggest a more optimal setting please.

Question information

Language:
English Edit question
Status:
Answered
For:
Hugin Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
tmodes (tmodes) said :
#1

It seems there is a understanding problem, maybe it is also a translation problem.
The cp correlation is a number between 0 and 1.0. It can only be set in the preferences. So I don't understand how you want to create a pano with a cp correlation of 8 or 4.
Hugin is always using all cp for optimization. So I don't understand why you think Hugin is using only a small subset of the cp for alignment.
So please provide more details of the steps you are using, otherwise we can't help further.

Revision history for this message
Mike Perrett (ballbooi) said :
#2

Thank you for the reply tmodes.

I think it is the CP value preference selection that is the problem, it seems that the first preference in my case 8 is locked in for that particular project and can't be altered mid project. If you are forced to use a lower CP value, in my case 4 in the same project, it ignores the second CP value of 4 you changed in the preference section for the same project. When using the assistant to align at the initial alignment start, it states how many CP it has selected to use for that alignment in the pop-up window, and in my case I have noted two sets of numbers selected for two separate same project alignments. The first was around 9,500 and the second alignment was about 16,500 CP selected for alignment.

If I use the fast panorama window and hit align it selects only about 9,500 CPs, however I managed to use more CPs by selecting the drop down menu 'user defined assistant' (I think I used either the 'scanned images TrXYZ' or 'Align image stack') in the geometric custom parameters optimizer tab. Because some photos in my project have few and sparse control points due to trees, the 'optimize now' in the optimizer tab had problems and stopped responding, so I was forced to use the drop down user defined assistant.

I'm no expert to be using the expert mode, but I needed the customer parameters for mosaic alignment. I'm not sure if I got the drop down assistant correct, any advice on that would be greatly appreciated. Once I have the project aligned, the optimise now in the optimizer tab works ok for RXYZ optimizing before stitching. What I am after is an alignment using both same project selected CP preferences of 4 and 8 to align using all CPs which I assume is the higher number of 16,500 CPs and not the first selected preference 8 with only 9,500 CPs.

I have an additional problem with one photo that doesn't seem to be the right size even though I set the Hfov to 11.5 for all photographs.
Which settings do I select in the optimizer tab to alter it please so it fits with all the surrounding images? Do I select that one photo only, or is it best to also select the 3 adjoining photos around it as well to optimize/alter it? (See attachment, problematic image is right ride)

Thanks for your help tmodes.

________________________________
From: <email address hidden> <email address hidden> on behalf of tmodes <email address hidden>
Sent: Friday, 13 November 2020 2:31 AM
To: <email address hidden> <email address hidden>
Subject: Re: [Question #693892]: Two CP correlation values alignment

Your question #693892 on Hugin changed:
https://answers.launchpad.net/hugin/+question/693892

    Status: Open => Needs information

tmodes requested more information:
It seems there is a understanding problem, maybe it is also a translation problem.
The cp correlation is a number between 0 and 1.0. It can only be set in the preferences. So I don't understand how you want to create a pano with a cp correlation of 8 or 4.
Hugin is always using all cp for optimization. So I don't understand why you think Hugin is using only a small subset of the cp for alignment.
So please provide more details of the steps you are using, otherwise we can't help further.

--
To answer this request for more information, you can either reply to
this email or enter your reply at the following page:
https://answers.launchpad.net/hugin/+question/693892

You received this question notification because you asked the question.

Revision history for this message
tmodes (tmodes) said :
#3

I still don't know to which setting you are referring for your numbers 8 or 4. Also there is *no* user-defined assistant on the geometric optimizer tab. Please use the exact caption in English (maybe you needed to temporarily switch to English language setting).

If a project has already control points the assistant does not search again for new ones. You can still invoke a control point finder from the images tab in the panorama editor.

Also please be more careful what assistant to use: scanned images does something completely different than align image stack.
E.g. align image stack is designed to align a stack of nearly completely overlapping images. It will probably fail when using for only partially overlapping images. All assistants have an optimized sequence of commands, which is only suited for the stated task and will probably fail (or not producing the wished results) when using for a different scenario.

PS In this answer section on launchpad there are no attachments to your mail visible.

Revision history for this message
Mike Perrett (ballbooi) said :
#4

Thank you for the reply bounces, tmode,

Apologies for no attachment in my last reply as I replied by e-mail and not directly to the launchpad website.

The 8 and 4 settings are simply the two different CP correlation threshold values entered into the 'control points editor' tab in the preference section for the same project. I had to change down to 4 from 8 because I couldn't get enough control points using the 8 threshold value due to poor image quality of some 1958 aerial photos in the project. I used the title 'Two CP correlation values alignment' because I noticed the fast panorama preview window alignment process was only using 57 percent of all control points, and I needed all points to be used.
You have now informed me the assistant doesn't look for new added control points, thank you.

"To invoke a control point finder from the images tab in the panorama editor", which setting do I look for please to achieve that?
Please note I don't want Hugin to add any more control points, I just want it to use all the control points that already exist in the next alignment exercise. I need to know exactly which setting to use in expert mode to achieve this please.

After starting the project , I learned about mosaic alignment from Hugin, so I have now tried to use this feature in the project which has meant I am using the expert mode for the first time. I'm not familiar with it very much at all as yet, but I'm learning. Please bear with me if I used the incorrect caption terminology. I'm Australian born and residing, so am ok with English, no translation problems. To select the 'align image stack' assistant in the 'geometric optimizer' tab I had to use the drop down menu via the 'user defined assistant' to open the connecting drop down menu to reach the 'align image stack assistant'. (please see attachment) https://1drv.ms/u/s!ApELJb4LPHBymUiN7VBMkQritH5u?e=t7o80d

Apologies for the 'scanned images (TrXYZ)' assistant, I got a little confused there as each image I am using is scanned from each individual 1958 aerial negative, so technically it is a scanned image. I'll avoid that in future.

I now have #81 images in 79 stacks. I ran out of lenses at 80 so had to share lens numbers. Stack 0 and 1 now have an extra photo in each stack, the extra photos are not linked, so am hoping they will be free to align correctly with their own respective individual assignment requirements?

I have one image that refuses to fit into the stitch. I made sure all images had a Hfov of 11.5 as there was no EXIF data available, all lenses are 152.09 mm. I have redone my attachment with more information and would appreciate any advice on how to fix this problem please, before realigning the project again. (Please see attachment) https://1drv.ms/u/s!ApELJb4LPHBymUl9G76Raga-O-8m?e=rtIwvU

I must have done something wrong with my mosaic RXYZ aligning as I have Y and P values as well now. I didn't tick the Y and P boxes, but it's there now. I've got a lot to learn in expert mode. Apologies if I'm missing something basic. Thank you.

Revision history for this message
tmodes (tmodes) said :
#5

Ok, we make small progress. The cp correlation threshold is a decimal value between 0 and 1 (as mentioned in the text beside the setting in the preferences). So you mean a setting of 0.8 and 0.4 instead of 8 and 4, right?
This setting is not used by the assistant. It is only used when manually adding cp or when calling fine-tune all cp. So you were calling fine-tune all cp when you get the information that not all cp are "selected for alignment". First you should not fine-tune cp which when cp were added by an automatic cp finder like cpfind. It should only be used for manually added cp.
Second, direct after fine-tune the alignment of the images does not change. You need to optimize the geometric position, before the changed cp take effect. Even in this case even the not fine-tuned cps are used for the alignment. But as already mentioned you don't need this function for automatically added cp.

Next issue: stacks in Burgin are only used for exposure brackets. If you don't have expose stacks or exposure brackets you should not use stacks. Hugin will still show stacks, but each stack contain technically only one image. (this is not meant when we refer to stacks). Also in this use case you should not use the "align image stack" assistant.

Concerning lenses it is difficult to advice remotely without further information. If all images were shoot with the same lens and scanned to exactly the same size (all images have exactly the same pixel width and pixel height) then you should only use a single lens. If the scanned the images to different pixel sizes then the hfov or Trz should be optimized for each image independently. Maybe you can provide a small subset of all images (maybe 5 to max. 10 images) so I can have a llok for myself (I don't want to download the full set)

Revision history for this message
Mike Perrett (ballbooi) said :
#6

Thank you for the reply tmodes,
Yes the CP correlation values are 0.4 and 0.8, my bad, apologies for the confusion.

I didn't realize you could fine tune cpfind points and manually added CPs separately. I just used the 'edit' drop down menu, 'fine-tune all points'. I didn't get any information about how many CPs were being fine-tuned or 'selected for alignment' when fine-tuning all CPs. The differing two sets of information about how many CPs were being selected for alignment came from the pop-up window immediately after initiating an alignment. It states right at the beginning how many good CPs it is selecting before starting the iteration process. The alignment pop-up window afore mentioned is the only place I got any information about the number of CPs selected for alignment.

The images are from 5 separate mapping runs and some are on different dates, but at least the approximate sale on all is 1:24,000 with the capture height of 3,810 (m). The original images are all the same pixel size 3800X4000, however I had to crop all of them to remove the frame information on each image, so my cropping will not make all the images the same precise size any longer as I lost a bit in varying amounts on each image I cropped. They are almost the same size now but not exactly. I used a separate lens for each image as I wanted to use mosaic mode. The Hugin tutorial I read suggested a new lens for the second image. Admittedly the tutorial was for flat scanned images, the aerial images project I'm currently doing seemed like a similar exercise as the lens is in a different position for each image. Tutorial images presumably scanned on flat bed and my images scanned from each negative. Mine of course having more edge distortions to deal with. http://hugin.sourceforge.net/tutorials/scans/en.shtml

I'm not sure I understand how you can use one lens for mosaic mode?
Does that mean you have unlink all the images except for one, since they're all sharing the same lens?
I honestly don't want to change the way Hugin has already set up my project, I think I'll get lost if I do something wrong.

I was thinking each image should be separately optimized, particularly as that one image didn't want to fit, and in your last 'concerning lenses' paragraph you suggest that with either Hfov or Trz. My image frame cropping has also made them various sizes additionally. I really only have the 152.09 mm lens information to go on with this project as it is stated on each image frame I had to crop off each image. Hugin selected the Hfov number of 11.5 but not the exact number for all images, most were 11.5 but some were between 11.4 and 11.5. I manually changed them all to 11.5. Given my images are in different stack numbers albeit incorrectly, and some are sharing lenses, to optimize each image, I have to use the 'Z(Trz)' box in the 'geometric optimizer' tab. I can't use the Hfov because of shared lenses in some stacks. Hence, to optimize each image, I tick only the 'Z(Trz)' box in the top window of the 'geometric optimizer' tab for each image and apply the optimized changes for each image, and repeat until I have done the lot right?

Next step, 'fine-tune all points', then optimize geometric position. For mosaic mode optimization, I only tick RXYZ boxes? and hit optimize.
To align the optimized images in the 'geometric optimizer' tab, which assistant do I use to engage all CPs?
The 'fast panoramic preview window' align doesn't seem to select all the CPs and why I posted this question to Hugin please.
Even though I've used all the wrong drop down menu assistants in the 'geometric optimizer' tab to date, they seem to have selected all the control points for alignment, however at this point I still need to know which drop down assistant to use correctly please.

Stacks: I loaded each image and selected a new lens for each, for mosaic mode. I didn't select the stacks, Hugin handled the stack or stack number placements. Hugin shows stack numbers for each image and as you mentioned most only having one image per stack. A few are sharing lenses because I ran out of lenses. I didn't set out to use 78 stacks, that's how Hugin has placed them. As you said, "this is not meant when we refer to stacks". A bit confused on stacks now.

Thank you for taking a look at the misfitting piece for me, greatly appreciated tmode. I think once I optimize all the images separately and correctly, when I know exactly how to do that, things might fit better. I just assumed they'd all be the same size, but possibly not. I have attached a screenshot of what the full stitch looks like, I hope you receive it this time. The problem area is in the top right corner. Thank you.

[https://outlook-2.cdn.office.net/assets/mail/file-icon/png/photo_16x16.png]1 2 QAP0771031 1 May, 1958 c.jpg<https://1drv.ms/u/s!ApELJb4LPHBymUp9SWkNZx2lPOCf?e=xxjxOg>
[https://outlook-2.cdn.office.net/assets/mail/file-icon/png/photo_16x16.png]3 end QAP0771033 1 May, 1958 c.jpg<https://1drv.ms/u/s!ApELJb4LPHBymUthLBQJF-h8eKR5?e=dCS98k>
[https://outlook-2.cdn.office.net/assets/mail/file-icon/png/photo_16x16.png]4 QAP0753119 1 May, 1958 c.jpg<https://1drv.ms/u/s!ApELJb4LPHBymUwkctrBZACCsyBB?e=7O7Lir>
[https://outlook-2.cdn.office.net/assets/mail/file-icon/png/photo_16x16.png]4 end QAP0753121 1 May, 1958 c.jpg<https://1drv.ms/u/s!ApELJb4LPHBymU2XbYy1fbZz2Pp-?e=Kkyf72>
[https://outlook-2.cdn.office.net/assets/mail/file-icon/png/photo_16x16.png]2 end QAP0742071 1 May, 1958 c.jpg<https://1drv.ms/u/s!ApELJb4LPHBymU5V5rIvb0kZqokq?e=t5l7i1>
[https://outlook-2.cdn.office.net/assets/mail/file-icon/png/photo_16x16.png]QAP0742073 1 May, 1958 c.jpg<https://1drv.ms/u/s!ApELJb4LPHBymU8BsSkw6OSq9NMp?e=UeW7u6>
[https://outlook-2.cdn.office.net/assets/mail/file-icon/png/photo_16x16.png]3 QAP0753122 1 May, 1958 c.jpg<https://1drv.ms/u/s!ApELJb4LPHBymVAn7F_dEwByj81p?e=6YDuxJ>
[https://outlook-2.cdn.office.net/assets/mail/file-icon/png/photo_16x16.png]QAP0770120 1 May, 1958 c.jpg<https://1drv.ms/u/s!ApELJb4LPHBymVG0HIPDeAXvsGZ1?e=vWcCZP>

Hugin tutorial — Stitching flat scanned images<http://hugin.sourceforge.net/tutorials/scans/en.shtml>
Hugin tutorial - Stitching flat scanned images. This tutorial covers another non-panoramic usage of Hugin -Taking two or more partial scanned images of a large object, such as an LP cover, map or poster, and stitching them seamlessly into a single final image.. Note: This tutorial has been prepared using the 2014.1.0 version of Hugin, and should be applicable for Hugin-2013.0.0 and later.
hugin.sourceforge.net

________________________________
From: <email address hidden> <email address hidden> on behalf of tmodes <email address hidden>
Sent: Wednesday, 18 November 2020 2:45 AM
To: <email address hidden> <email address hidden>
Subject: Re: [Question #693892]: Two CP correlation values alignment

Your question #693892 on Hugin changed:
https://answers.launchpad.net/hugin/+question/693892

    Status: Open => Needs information

tmodes requested more information:
Ok, we make small progress. The cp correlation threshold is a decimal value between 0 and 1 (as mentioned in the text beside the setting in the preferences). So you mean a setting of 0.8 and 0.4 instead of 8 and 4, right?
This setting is not used by the assistant. It is only used when manually adding cp or when calling fine-tune all cp. So you were calling fine-tune all cp when you get the information that not all cp are "selected for alignment". First you should not fine-tune cp which when cp were added by an automatic cp finder like cpfind. It should only be used for manually added cp.
Second, direct after fine-tune the alignment of the images does not change. You need to optimize the geometric position, before the changed cp take effect. Even in this case even the not fine-tuned cps are used for the alignment. But as already mentioned you don't need this function for automatically added cp.

Next issue: stacks in Burgin are only used for exposure brackets. If
you don't have expose stacks or exposure brackets you should not use
stacks. Hugin will still show stacks, but each stack contain technically
only one image. (this is not meant when we refer to stacks). Also in
this use case you should not use the "align image stack" assistant.

Concerning lenses it is difficult to advice remotely without further
information. If all images were shoot with the same lens and scanned to
exactly the same size (all images have exactly the same pixel width and
pixel height) then you should only use a single lens. If the scanned the
images to different pixel sizes then the hfov or Trz should be optimized
for each image independently. Maybe you can provide a small subset of
all images (maybe 5 to max. 10 images) so I can have a llok for myself
(I don't want to download the full set)

--
To answer this request for more information, you can either reply to
this email or enter your reply at the following page:
https://answers.launchpad.net/hugin/+question/693892

You received this question notification because you asked the question.

Revision history for this message
Mike Perrett (ballbooi) said :
#7

The full stitch attachment tmodes.
https://1drv.ms/u/s!ApELJb4LPHBymVJrIw6swdbC3H2f

Revision history for this message
Mike Perrett (ballbooi) said :
#8

I finally realized what you meant by "not fine-tune cp which when cp were added by an automatic cp finder" tmodes, apologies my mind was still on the preparation for alignment subject. You were referring to the adding or checking CPs in the 'control points' tab.

Revision history for this message
tmodes (tmodes) said :
#9

The cp correlation value in the preferences is not used by the assistant. So the different number of cp have to have another cause.

So that only a low number of cp is selecting for alignment is caused by the fact that you used the "align image stack" assistant , but there are no image stacks. You have only partially overlapping images, but no image stacks.

I did the following with your images:
1. Load all images, set HFOV to 11 deg for each image.
2. Run "Scanned images TRXYZ" user defined assisant.
3. Stitched

All is aligned fined.

So I assume most of the problems stem from the fact that you try to assign lenses or stacks by yourself and using a wrong user defined assistant.

Can you help with this problem?

Provide an answer of your own, or ask Mike Perrett for more information if necessary.

To post a message you must log in.