Commit fe07b1ab authored by Maxime Hubert's avatar Maxime Hubert
Browse files

validate-execution: bugfix for validate-only mode

parent 92f718b7
Pipeline #141395 passed with stage
in 1 minute and 6 seconds
......@@ -20,23 +20,20 @@ def entry_point(output, reference, activity_index, file_index, result, score):
# go into the right directory to execute the script
path = os.path.dirname(__file__)
execution_validation_dir = os.path.join(path, '../implementation/validate_execution')
if score:
s = "true"
else:
s = "false"
installation_script = os.path.join(execution_validation_dir, 'install.sh')
script = os.path.join(execution_validation_dir, 'score.sh')
script += " " + output + \
" " + reference + \
" " + activity_index + \
" " + file_index + \
" " + result + \
" " + s
script += " " + output
script += " " + reference if reference else " "
script += " " + activity_index
script += " " + file_index
script += " " + result if result else " "
script += " true" if score else " false"
# execute the script
# status is the exit status code returned by the program
status = os.system('cd ' + execution_validation_dir + \
';. ' + installation_script + \
'; . ' + installation_script + \
';' + script)
if status != 0:
raise Exception("Error occured in install.sh or score.sh")
......
......@@ -17,7 +17,7 @@ result=$5
score=$6
# Execute ActEV Scorer
cd ActEV_Scorer
if [ $score == "true" ] ; then
if [[ $score == "true" ]] ; then
python2 ActEV_Scorer.py \
ActEV18_AD \
-s $output \
......
Supports Markdown
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