What confuses Hugin

97 views
Skip to first unread message

Steve Edmonds

unread,
Oct 14, 2016, 3:17:59 AM10/14/16
to hugin and other free panoramic software
I have just started to use Hugin.
After trying to take some pictures with effect in a forest (and failing) I did some comparative tests between panorama and wide angle for the same HFOV.
This has led me to delve deeper into the panorama style and the use of Hugin. I have a pano head arriving next week.

I am trying to get to grips with Hugin and figure out what throws it out. I went back to a very simple window frame with horizontals, verticals and straight lines, 3 shot hand held panorama.
In each image the frame lines are straight within 3 pixels worst case with no lens correction. I only add control points manually to marks on the frames, control points placed within 1 pixel.
I can perspective correct each frame individually in Hugin (http://hugin.sourceforge.net/tutorials/perspective/en.shtml) and they are spot on to easily merge in gimp say.

If I put all 3 images into Hugin and match up the same control points the window frame goes all humpty and I the errors are not good.
I guess I must be doing something to confuse Hugin but can't figure it out.
Should I be perspective correcting the images before combining, does Hugin correct each image first and then try to combine or just try to average things out.
Do I need to keep the camera dead level to avoid confusing Hugin, i.e wait for the pano head.
Any help appreciated as this has me a bit baffled.

Steve

Luís Henrique Camargo Quiroz

unread,
Oct 14, 2016, 7:36:00 AM10/14/16
to hugi...@googlegroups.com

  Hi Steve,

  Have you optimized, after finding the control points, for yaw, pitch, roll, and perhaps (better after yaw, pitch, roll, in a second step) also for positions? It is this optimization that reduces the initial errors and thus correctly repositions each image in order to build a panorama.
  In this process Hugin itself will correct for perspective in your photos, so the images will perfectly match if you have little parallax.

  If you did optimized, I did not understand well what could have happened, so some screenshot of your result, if possible, would clarify for us your problem.

  Hugin is a great software and you surely should get stunning results with it.

  Luís Henrique

--
A list of frequently asked questions is available at: http://wiki.panotools.org/Hugin_FAQ
---
You received this message because you are subscribed to the Google Groups "hugin and other free panoramic software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hugin-ptx+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/hugin-ptx/027a0ff6-ac7a-444e-84f8-a8f401bcff07%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--

Steve Edmonds

unread,
Oct 14, 2016, 4:43:56 PM10/14/16
to hugin and other free panoramic software
Hi Luis
Yes it is great software. I added pano-sift-c last night to see how that runs.
I ran through some tutorials and they all work out ok. I stitched images across a corrugated iron barn and it won't take much to do a final blend of the corrugations.
I am treating this as a "learning about the software" exercise and I think I must be doing something fundamentally wrong at the optimiser or control points stage that is throwing Hugin out. Does Hugin stretch/scale.
Below the 3 images.


And the result just running these through the basic interface.

My mean errors are always over 50 and worst in the hundreds. I have managed a straighter frame in expert mode using control points only on the frame (images stitched with corners and mid points each window frame, horizontal and vertical lines defined for the frame of each window) but the result is no where near correct.

Is there a sequence for optimising, i.e. just y,p,r and then a second step for position. Do I optimise y,p,r for 1 frame at a time and then position. I tried various selections on the drop down list and also custom to get the optimiser tab and ctl-click a few adjustments at a time. Loading one image at a time I can get the frames straight and as mentioned quite easily join them in Gimp, but that's not helping me learn to drive Hugin.


As I mentioned straight from the lens (28mm/FX) the lines are pretty straight (<3px on a frame) without lens correction. Does Hugin apply some general correction for an averagely curved lens. I don't see where the curvature introduced by Hugin comes in.

All help appreciated, steve


On Saturday, 15 October 2016 00:36:00 UTC+13, Luís Henrique Camargo Quiroz wrote:

  Hi Steve,

  Have you optimized, after finding the control points, for yaw, pitch, roll, and perhaps (better after yaw, pitch, roll, in a second step) also for positions? It is this optimization that reduces the initial errors and thus correctly repositions each image in order to build a panorama.
  In this process Hugin itself will correct for perspective in your photos, so the images will perfectly match if you have little parallax.

  If you did optimized, I did not understand well what could have happened, so some screenshot of your result, if possible, would clarify for us your problem.

  Hugin is a great software and you surely should get stunning results with it.

  Luís Henrique
2016-10-14 4:17 GMT-03:00 Steve Edmonds <st...@edmondsfamily.co.nz>:
I have just started to use Hugin.
After trying to take some pictures with effect in a forest (and failing) I did some comparative tests between panorama and wide angle for the same HFOV.
This has led me to delve deeper into the panorama style and the use of Hugin. I have a pano head arriving next week.

I am trying to get to grips with Hugin and figure out what throws it out. I went back to a very simple window frame with horizontals, verticals and straight lines, 3 shot hand held panorama.
In each image the frame lines are straight within 3 pixels worst case with no lens correction. I only add control points manually to marks on the frames, control points placed within 1 pixel.
I can perspective correct each frame individually in Hugin (http://hugin.sourceforge.net/tutorials/perspective/en.shtml) and they are spot on to easily merge in gimp say.

If I put all 3 images into Hugin and match up the same control points the window frame goes all humpty and I the errors are not good.
I guess I must be doing something to confuse Hugin but can't figure it out.
Should I be perspective correcting the images before combining, does Hugin correct each image first and then try to combine or just try to average things out.
Do I need to keep the camera dead level to avoid confusing Hugin, i.e wait for the pano head.
Any help appreciated as this has me a bit baffled.

Steve

--
A list of frequently asked questions is available at: http://wiki.panotools.org/Hugin_FAQ
---
You received this message because you are subscribed to the Google Groups "hugin and other free panoramic software" group.
To unsubscribe from this group and stop receiving emails from it, send an email to hugin-ptx+...@googlegroups.com.
Auto Generated Inline Image 1
Auto Generated Inline Image 2
Auto Generated Inline Image 3

Steve Edmonds

unread,
Oct 14, 2016, 5:43:39 PM10/14/16
to hugin and other free panoramic software
Changing the focal length of the lens does affect the straightness of the window frames, but introduces some other problems. At setting 200mm (for the images taken with 28mm) the frames are straight in the preview but not aligned or perspective corrected.
So may be I am not understanding the lens function correctly and for some reason Hugin introduces curvature.

Steve Edmonds

unread,
Oct 14, 2016, 7:40:41 PM10/14/16
to hugin and other free panoramic software
If someone can see what I have done wrong, the images and my project are here.
https://drive.google.com/open?id=0ByFEFUXgJhGkNjlEYWpNcVRiaEU

The images are close to 40 megs total.

Steve Edmonds

unread,
Oct 14, 2016, 7:53:57 PM10/14/16
to hugin and other free panoramic software

  In this process Hugin itself will correct for perspective in your photos, so the images will perfectly match if you have little parallax.

I have a bit of parallax (you will see this in the background) but am not interested within this exercise in the background, or anything outside the plane of the window frames and hence why all my control points are on the frames.
Steve

Steve Edmonds

unread,
Oct 14, 2016, 8:38:47 PM10/14/16
to hugin and other free panoramic software
Thanks for the tip on focusing on optimisation. I looked at how some tutorials optimised and played around .
I optimised the p,r,y, lens view, a,b,c of the anchor image. Then fixed that and optimised the other 2 images p,r,y, lens v,a,b,c. Then fixed those and optimised the 2 non-anchor images for X,Y,Z, Plane yaw, plane pitch, lens v,a,b,c.

The maximum misalignment I can now find in the stitching of the window frame is 3px. It is all in the optimising, thanks again for the lead.
steve

Auto Generated Inline Image 1

Carl von Einem

unread,
Oct 15, 2016, 3:41:25 AM10/15/16
to hugi...@googlegroups.com
Hi Steve,

Steve Edmonds wrote on 15.10.16 01:53:
You identified one of the main problems but choose to ignore it. The
_huge_ parallax error you introduce with your setup in combination with
objects at a close distance make the shown images useless for stitching.

Start with finding / adjusting the no-parallax point
<http://wiki.panotools.org/No-parallax_point> of your lens.

If you still have no panoramic head try using a philopod. That's simple
to set up, I still use it a lot: <http://wiki.panotools.org/Philopod>.
Have a look at <http://wiki.panotools.org/Heads#Self_made> to see what
effort others put into their shooting setup.

Find an easier to shoot place: outside, maybe the facade of a building,
no objects in foreground to make still occuring smaller parallax errors
less of a problem.

Note that shooting in portrait mode is a good idea.

Here is a nice list of tutorials <http://wiki.panotools.org/Tutorials>.
Some may be a bit old but you get the idea, like with this one:
<https://panospace.wordpress.com/2008/02/29/parallax/>

Carl

Steve Edmonds

unread,
Oct 15, 2016, 3:38:01 PM10/15/16
to hugin and other free panoramic software
Thanks Carl.
I have looked through your references and have more in depth reading there.
I was aware of the parallax. Also some plane pitch and slight roll between images.
As my concern was only with the window frame, so I was stitching at only one depth, the parallax issue diminished. My pano head is on its way so will help a lot.

This was an exercise on finding what throws Hugin out or makes it difficult for Hugin and how to manage those situations.
As it was I got it pretty well sorted, but having your references on optimisation would have saved me some hours.
Thanks, steve



Reply all
Reply to author
Forward
0 new messages