Skip to content

Instantly share code, notes, and snippets.

@vinipsmaker
Created March 27, 2014 15:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vinipsmaker/9809599 to your computer and use it in GitHub Desktop.
Save vinipsmaker/9809599 to your computer and use it in GitHub Desktop.
#!/usr/bin/env zsh
BIN="/home/vinicius/Projetos/libdepixelize/build/src/depixelize-kopf2011/depixelize-kopf2011"
ARGS=("-o" "/dev/null")
# The first run at each step only warms the cache
for file in *.png; do
out="${file/.png}.txt"
echo ${file} > ${out}
echo >> ${out}
echo Voronoi: >> ${out}
${BIN} ${ARGS} ${file} -v 2> /dev/null
${BIN} ${ARGS} ${file} -v 2>> ${out}
echo >> ${out}
echo Grouped Voronoi: >> ${out}
${BIN} ${ARGS} ${file} -g 2> /dev/null
${BIN} ${ARGS} ${file} -g 2>> ${out}
echo >> ${out}
echo Non-smooth: >> ${out}
${BIN} ${ARGS} ${file} -n 2> /dev/null
${BIN} ${ARGS} ${file} -n 2>> ${out}
echo >> ${out}
echo Smooth: >> ${out}
${BIN} ${ARGS} ${file} 2> /dev/null
${BIN} ${ARGS} ${file} 2>> ${out}
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment