in reply to Re^4: PDL: Looking for efficient way to extract sub-images, by finding bounding boxes of "objects" (7000x faster)
in thread PDL: Looking for efficient way to extract sub-images, by finding bounding boxes of "objects"
It turns out that the reason for the pathologic behaviour of your code under 5.10 is entirely down to your use of $&, as described in the FAQ since circa 1999 or before.
Replacing my $c = ord( $& ) - 1; with my $c = ord( substr $$str, $-[0], 1 ) - 1; entirely eliminates the performance problem on 5.10.1.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^6: PDL: Looking for efficient way to extract sub-images, by finding bounding boxes of "objects" (FAQ6: $&)
by vr (Curate) on Nov 22, 2016 at 10:42 UTC | |
by BrowserUk (Patriarch) on Nov 22, 2016 at 11:19 UTC |