Re: Request Enhancments Similar to -mode
Posted: 2011-03-29T17:32:39-07:00
Thanks for adding standard-deviation. However, I don't believe it is implemented correctly as it should look like an edge image.
original:
convert lena2g.jpg -statistic standard-deviation 3x3 lena2g_std.jpg
However, from my statsfilt script (which is limited to a 3x3 neighborhood), I get
And after -normalize
convert lena2g_opt6.jpg -normalize lena2g_opt6_norm.jpg
My script uses:
ave="1,1,1,1,1,1,1,1,1"
# -gamma 2 is equivalent to sqrt
# $tmpA is the input image
convert $tmpA -convolve "$ave" $tmp0
convert \( $tmpA $tmpA -compose multiply -composite -convolve "$ave" \) \
\( $tmp0 $tmp0 -compose multiply -composite \) +swap \
-compose minus -composite -gamma 2 $outfile
original:
convert lena2g.jpg -statistic standard-deviation 3x3 lena2g_std.jpg
However, from my statsfilt script (which is limited to a 3x3 neighborhood), I get
And after -normalize
convert lena2g_opt6.jpg -normalize lena2g_opt6_norm.jpg
My script uses:
ave="1,1,1,1,1,1,1,1,1"
# -gamma 2 is equivalent to sqrt
# $tmpA is the input image
convert $tmpA -convolve "$ave" $tmp0
convert \( $tmpA $tmpA -compose multiply -composite -convolve "$ave" \) \
\( $tmp0 $tmp0 -compose multiply -composite \) +swap \
-compose minus -composite -gamma 2 $outfile