Small update - support PHP 5.3 by removing the Array initialization shortcut.
Rewrite the slice algorithm to produce potentially more accurate results.
Instead of comparing slices from each end, just build up a list of the entropy across the entire image and find the highest-valued subset that matches the target image dimension.