Enblend oddity

717 views
Skip to first unread message

Benjamin Schnieders

unread,
Aug 25, 2017, 10:06:28 AM8/25/17
to hugi...@googlegroups.com
Hi everyone,

I ran into an interesting little problem stitching a project of mine. I attached a minimal example - from the size of the pano you can imagine there are a lot more input images, but the error shows with the first 3 images alone.

I'm using Hugin 2017.0.0.eac5e8cc546e and enblend 4.2.

In short, enblend refuses to blend the 3 images, for varying reasons.
Typically, I have "--levels=29" set by default, with that, it complains:
BasicImage::BasicImage(Diff2D size): size.x and size.y must be >= 0
(I guess this is a case of an error caught in the wrong spot.... or at least the message does not help...)

Dropping the "levels", it hints that I might want to try --pre-assemble, then fails with

enblend: info: loading next image: testing0000.tif 1/1
enblend: info: loading next image: testing0001.tif 1/1
enblend: warning: images do not overlap; they will be combined without blending
enblend: info: loading next image: testing0002.tif 1/1
enblend: encountered degenerate image/mask geometry; too high risk of defective seam line

Adding --pre-assemble does not change the outcome. I am aware that I'm blending a disconnected set, in the whole pano, these images are eventually connected by other images - also, blending image 0 and 1, 0 and 2, and 1 and 2 works, so I would assume 0,1,2 to work as well - but nope, that fails.

Any idea how I can get my panorama to stitch after all?

Thanks!
Benjamin

enblendProb.zip

Monkey

unread,
Aug 26, 2017, 1:48:53 PM8/26/17
to hugin and other free panoramic software
Are you wedded to enblend? multiblend would have no such issues, and actually does blend, not just assemble, disconnected images.

Alternatively, have you tried reordering the images? Rename testing0002.tif to testing0000.tif and vice versa.

Benjamin Schnieders

unread,
Aug 26, 2017, 7:59:27 PM8/26/17
to hugi...@googlegroups.com
Hrrmmm, I'm in a committed long-term relationship with enblend, but seeing that it can't fulfil my needs right now, I had a quick flirt with multiblend.... works! Most of the images have good overlap and no parallax/moving objects anyway, so hardly any blending was necessary.

Interesting. Was just about to write that re-ordering didn't work, but wasn't sure if I tried all combinations. Yes, in a certain order, it blends without problems. Maybe that's worth filing a bug report for...?

(Also, I should add a feature request for multiblend: support deflate compression ...)

Thanks! You saved my pano. :)

Best,
Benjamin

Monkey

unread,
Aug 27, 2017, 5:56:52 AM8/27/17
to hugin and other free panoramic software
There is/was a command line switch to enable DEFLATE, but for some reason it's commented out in the source code and I didn't leave myself a note to tell me why.

As for enblend, it's hard to say whether it's a bug, but it might be. Enblend produces different outputs if you supply images in a different order - one reason I wrote multiblend - but I think that's more like a slightly unsatisfactory compromise than a bug.

Benjamin Schnieders

unread,
Jun 27, 2018, 7:33:42 PM6/27/18
to hugi...@googlegroups.com
Hi all,

a while ago, I had this nasty enblend behavior that I could only fix by using, well, multiblend. (See old "Enblend Oddity" thread.)

Still have the same problem, when stitching, enblend complains at some point that there's a too high risk for a defective seam line.

Was unable to provide a minimal example this time, but uploaded a snapshot while blending to
http://airesearch.de/files/staticimgs/enblendProb/ (500mb)

After remapping, enblend loads and blends images 0001..0020 without problem, then fails with 21. See the attached screenshot as well - all images have sufficient overlap.
(I could convince it to also blend in 21 by re-arranging the order)


So next, it would blend 22 onto the rest, like so:
$ enblend -a -o result.tif --compression=DEFLATE --no-optimize -f70994x8819+3868+645 step.tif medium0022.tif
enblend: info: combining non-overlapping images: step.tif 1/1
enblend: info: combining non-overlapping images: medium0022.tif 1/1
enblend: encountered degenerate image/mask geometry; too high risk of defective seam line
enblend: info: remove invalid output image "result.tif"
$ enblend --show-signature
Version 4.2-1ubuntu1~xenial/xenial - Wed, 11 May 2016 22:27:29 +0200


(If someone could confirm this behavior please?)

Again, re-arranging the order "fixes" the problem, but I'd a) very much prefer to blend all my images in one go, without trying all possible combinations, and b) I want to save the blending masks for different exposures, which will become difficult with the manual incremental blend.
Tried all combinations (no)-optimize, -a, coarse/fine mask, different generation algorithms...
The problem does not exist in lower resolutions, so the 500mb original .tif is the best I can do.

Suggestions?

Best,
Benjamin
screenshot2.jpg

Roberto ornelas orozco

unread,
May 17, 2019, 1:55:46 AM5/17/19
to hugin and other free panoramic software
Hi!! 
I had exactly the same error with Hugin 2019. I tried with enblend 3.2 and the error doesn't appears any more.
Hope that works for you.

Matija Kogoj

unread,
May 23, 2019, 8:04:57 AM5/23/19
to hugin and other free panoramic software
Seeing this post originated in 2017 and the last entry being May 17th (without the 'th at the end) was really confusing. But it brought multiblend to my attention and now I have a question:

How do I make it work?
I downloaded it (32 and 64 versions in the package), unzipped it, pointed Hugin's "use different enblend software" to its location aaand it returned an error.
I've no idea what version of Enblend I'm running either, but the "high risk of deformed seams" has been a pain in a 60-picture batch I made yesterday. Pretty sure I am using the latest Enblend, at least the one that can be downloaded as exe for windows from their site.

Roberto ornelas orozco

unread,
May 26, 2019, 10:20:43 AM5/26/19
to hugin and other free panoramic software
Try using enblend 3.2 instead of 4. You can download ir from their page un sourceforge

zarl

unread,
May 28, 2019, 8:25:07 AM5/28/19
to hugin and other free panoramic software
Hi!


Am Sonntag, 26. Mai 2019 16:20:43 UTC+2 schrieb Roberto ornelas orozco:
Try using enblend 3.2 instead of 4. You can download ir from their page un sourceforge

The current enblend version 4.2 that ships with Hugin 2019.0.0 actually works. No need to use old versions. Just check Hugin's preferences for the default enblend arguments (used for new projects), they changed from version 3.2 to 4.x and need to be adapted if you still use old settings. If you work with old .pto files you might want to check the enblend arguments for this project.

The documentation is available from http://enblend.sourceforge.net/index.htm or directly here:

Some notes:

- Basic enblend arguments for Hugin

In Hugin you can add commandline arguments either by entering directly to the 'options' dialog for your current project or as a default for new projects in the Preferences. If it works for you without options just leave this line empty.

- There are basically to points to look up in the documentation when

  - enblend's output shows artefacts or you'd like to improve the way the seam is generated -> current enblend features
  - enblend fails to run on the complete set of your images -> problem solving

Since enblend is a work in progress each version can show certain changes in how it processes your images with certain arguments. That's why you need to first of all determine the enblend version your current installation of Hugin is using:

- stitch a simple panorama (to save some time you can deactivate all but two overlapping images in the preview window) and keep an eye on the stitching log. Search the first dozen lines for a line starting with 'Blender:'

- If that log closes too fast make sure (that in Hugin Preferences the 'Stitching' tab uses (in the third paragraph 'Processor') PTBatcherGUI with option 'Verbose Output' activated). Now while stitching your panorama switch to PTBatcherGUI and make sure that both options 'Verbose output' (shows a separate window describing step by step what's happening while PTBatcherGUI processes your project file) and 'Always save log' are activated. The latter saves a .log file in the same directory as your .pto project file. The .log file can be opened in a basic text editor like Notepad++ (Windows) or BBEdit (OS X). The verbosity level can be increased in Hugin's Preferences and for enblend in the stitching tab (add '-v' once or even up to 6 times to make it a real chatter box)

Here are the current enblend arguments I use:
--preassemble --primary-seam-generator=nft --blend-colorspace=identity


Reply all
Reply to author
Forward
0 new messages