add input validity check to run.sh