Commit 853a6c83 authored by Stefan Westerfeld's avatar Stefan Westerfeld

Support AWM_SEEDS for testing with multiple --seed values.

Signed-off-by: Stefan Westerfeld's avatarStefan Westerfeld <stefan@space.twc.de>
parent 5f6ac66c
......@@ -5,6 +5,9 @@ TRANSFORM=$1
if [ "x$AWM_SET" == "x" ]; then
AWM_SET=small
fi
if [ "x$AWM_SEEDS" == "x" ]; then
AWM_SEEDS=0
fi
{
if [ "x$AWM_SET" == "xsmall" ]; then
......@@ -17,8 +20,10 @@ fi
fi
} | while read i
do
for SEED in $AWM_SEEDS
do
echo $i
audiowmark add "$i" t.wav $PATTERN $AWM_PARAMS >/dev/null
audiowmark add "$i" t.wav $PATTERN $AWM_PARAMS --seed $SEED >/dev/null
if [ "x$TRANSFORM" == "xmp3" ]; then
if [ "x$2" == "x" ]; then
echo "need mp3 bitrate" >&2
......@@ -66,5 +71,6 @@ do
echo "unknown transform $TRANSFORM" >&2
exit 1
fi
audiowmark cmp t.wav $PATTERN $AWM_PARAMS
audiowmark cmp t.wav $PATTERN $AWM_PARAMS --seed $SEED
done
done | grep bit_error_rate | awk '{ er += $2; n++; if ($2 > max_er) max_er = $2;} END { print er / n, max_er; }'
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment