Created
May 12, 2016 01:12
-
-
Save shawngraham/239edbcd7f5a495a7218bb93a9ce76a1 to your computer and use it in GitHub Desktop.
using spelling as a proxy for ocr quality. `brew install aspell` to get that part of the equation running.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for f in *.txt; do | |
totalbadwords="$(cat "$f" | aspell list -d en_CA --encoding utf-8 | wc -w)" | |
totalwords="$(wc -w "$f")" | |
echo "$totalbadwords, $totalwords" >> "finalscore.csv" | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment