dm4
12/12/2012 - 7:15 PM

submit to ml12fall final from remote host

submit to ml12fall final from remote host

id="your id here"
pw="your password here"
filename="$1"
algo_name="$2"

curl -s -c cookie -d "team_name=${id}&passwd=${pw}&submit=submit" 'http://main.learner.csie.ntu.edu.tw/php/ml12fall/login.php' > /dev/null
curl -s -o output.html -b cookie -F "userfile=@${filename};type=text/plain" -F "algouse=${algo_name}" 'http://main.learner.csie.ntu.edu.tw/php/ml12fall/cal.php'

sed -nE 's/.*(AUC \(first-half\): [0-9\.]+).*/\1/p' output.html