On Tue, 2010-06-29 at 05:53 -0600, Pete Holzmann wrote:

> The 50 image pano is sluggish. The 150 image pano is painful:
> 
> - File Save or Save-As is horribly slow. Takes minutes of CPU; *NO DISK 
> ACCESS.*

I tried saving a 33 image, 613 control point panorama with Valgrind's
callgrind. The main delay is calculating image overlaps for the HDR
stacks in the Makefile. I gave it a linear speed up (3 times less
instruction fetches) without changing the algorithm.

After my change, 74% of instruction fetches during saving is still in
HuginBase::CalculateImageOverlap::calculate(unsigned int), inclusive of
functions it calls. It is called by HuginBase::getHDRStacks.
The 18% mostly HuginBase::getImagesinROI, which calls
HuginBase::estimateOutputROI, which calls
HuginBase::estimateImageAlpha<HuginBase::PTools::Transform>. These don't
do much by themselves.

Both HuginBase::estimateImageAlpha<HuginBase::PTools::Transform> and
HuginBase::CalculateImageOverlap::calculate(unsigned int) call
HuginBase::PTools::Transform::transformImgCoord(double&, double&,
double, double) const many times (especially calculate). 

transformImgCoord accounts for 83% of instruction fetches during saving.
The majority of that (81% of saving) is in execute_stack_new from
libpano13.

The makefile export is 93% of the instruction fetches during saving.
Improving these algorithms would be good. However, since the makefile
can be generated on the command line with pto2mk, perhaps it shouldn't
be saved with the project anyway?

HuginBase::Panorama::printPanoramaScript, which writes the project file,
actually causes less than half a percent of instruction fetches made
when you save.

> - Every change to the control point list takes a minute or more (delete, 
> insert, etc)
> - About a minute delay per action in the Mask tab
> - (Fast) preview and crop tabs are slow. Layout tab feels like a hang. I 
> didn't bother 
> timing it

I think these things are also worth investigating.

-- 
You received this message because you are subscribed to the Google Groups 
"hugin and other free panoramic software" group.
A list of frequently asked questions is available at: 
http://wiki.panotools.org/Hugin_FAQ
To post to this group, send email to hugin-ptx@googlegroups.com
To unsubscribe from this group, send email to 
hugin-ptx+unsubscr...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/hugin-ptx

Reply via email to