Sponsored Content
Full Discussion: TR : surprises me
Top Forums Shell Programming and Scripting TR : surprises me Post 76566 by Perderabo on Wednesday 29th of June 2005 08:29:55 AM
Old 06-29-2005
tr does not match patterns. It works character by character. Both of args to tr end with "jpg". That means translate "j" to "j"; "p" to "p"; and "g" to "g". tr will never know that the string "jpg" appears in the data.
 
PUZZLE-DIFF(1)															    PUZZLE-DIFF(1)

NAME
puzzle-diff - Compare pictures with libpuzzle SYNOPSIS
[-b <contrast barrier for cropping>] [-c] [-C <max cropping ratio>] [-e] [-E <similarity threshold>] [-h] [-H <max height>] [-l <lambdas>] [-n <noise cutoff>] [-p <p ratio>] [-t] [-W <max width>] <file 1> <file 2> DESCRIPTION
puzzle-diff compares two pictures and outputs the normalized distance. Try puzzle-diff -h for more info. EXAMPLES
Output distance between two images: $ puzzle-diff pic-a-0.jpg pics-a-1.jpg 0.102286 Compare two images, exit with 10 if they look the same, exit with 20 if they don't (may be useful for scripts): $ puzzle-diff -e pic-a-0.jpg pics-a-1.jpg $ echo $? 10 Compute distance, without cropping and with computing the average intensity of the whole blocks: $ puzzle-diff -p 1.0 -c pic-a-0.jpg pic-a-1.jpg 0.0523151 AUTHORS
Frank DENIS libpuzzle at pureftpd dot org SEE ALSO
libpuzzle(3), puzzle_set(3) 2012-05-09 PUZZLE-DIFF(1)
All times are GMT -4. The time now is 04:48 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy