Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
leoalenc committed Sep 11, 2024
1 parent 16ac8f5 commit 70f7947
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions src/RunTenFoldCrossValidation.sh
Original file line number Diff line number Diff line change
@@ -1,16 +1,26 @@
#!/bin/bash
# Author: Leonel Figueiredo de Alencar
# Last update: September 10, 2024
# Last update: September 11, 2024

echo "Split $1 treebank file in ten folds." > log.txt
# Check for correct number of arguments (expecting 1 argument)
if [ "$#" -ne 1 ]; then
echo "Usage: $0 <treebank_file>"
exit 1
fi

echo "Creating 'log.txt' file."
touch log.txt
echo "File 'log.txt' written to disk."
echo "Split $1 treebank file in ten folds, each fold consisting of a test and a train set." >> log.txt
TestSuite.py $1

echo "Create 10 different models. This may take up several hours." >> log.txt
echo "Create 10 different models, one for each fold. This may take up several hours." >> log.txt
CreateModels.sh

echo "Parse and test 10 times using each time a different model and test file." >> log.txt
TenFoldCrossVal.sh

echo "Process the results of parsing with gold tokenization and gold tags." >> log.txt
ParseGoldTokResults.py > results.txt
echo "File 'results.txt' written to disk."

0 comments on commit 70f7947

Please sign in to comment.