|
From: | Jonas Lindqvist |
Subject: | Re: [help-GIFT] Optimizing |
Date: | Fri, 18 Aug 2006 07:48:41 +0200 |
Hi!
I would have expected the extractor to not just deal with one image at a time... Why not alter it to take any number of images as command line parameters, or no parameter to read an image from stdin (and in that case pipe the result to stdout)? If gift-extract-features would take any number of images parameters on the command line, the perl hack could send it batches of N images to deal with. This COULD give further performance improvements as well. After all, if memory allocation is in fact such a hog that replacing a call to calloc with a fixed array makes a difference, then you could surely save a lot more by just allocating that memory (with calloc) once, and just clear it (memset with zero) before handling each image, and realloc it whenever a larger image comes along. No (compile time) fixed sizes would be needed. (I'm assuming the thing isn't threaded, and that it doesn't leak memory or other resources...) /Jonas |
smime.p7s
Description: S/MIME cryptographic signature
[Prev in Thread] | Current Thread | [Next in Thread] |