This repository has been archived on 2023-08-20. You can view files and clone it, but cannot push or open issues or pull requests.
yap-6.3/packages/CLPBN/benchmarks/school/run_school_tests.sh

65 lines
1.3 KiB
Bash
Raw Normal View History

2012-05-23 14:56:01 +01:00
#!/bin/bash
2013-01-09 15:25:14 +00:00
source ../benchs.sh
2012-05-23 14:56:01 +01:00
2013-01-09 15:25:14 +00:00
SHORTNAME="school"
SOLVER="school"
2012-05-23 14:56:01 +01:00
2013-01-09 15:25:14 +00:00
function learn_params
2012-05-23 14:56:01 +01:00
{
2013-01-09 15:25:14 +00:00
NETWORK="'./../../examples/School/school_32'"
CONSTRAINT=$2
SOLVER=$1
echo $NETWORK
/usr/bin/time -o $LOG_FILE -a -f "%U\t%S\t%e\t%M" \
$YAP << EOF >> ignore.$LOG_FILE 2>> ignore.$LOG_FILE
use_module(library(pfl)).
use_module(library(clpbn/learning/em)).
[$NETWORK].
[$CONSTRAINT].
set_em_solver($SOLVER).
2012-05-23 14:56:01 +01:00
graph(L),
2013-01-09 15:25:14 +00:00
% em(L, 0.01, 10, _, Lik),
open("$LOG_FILE", 'append', S),
format(S, "$CONSTRAINT: ~15+ Lik = ~3f\t", [Lik]),
close(S).
2012-05-23 14:56:01 +01:00
EOF
}
2013-01-09 15:25:14 +00:00
prepare_new_run
write_header hve
learn_params hve missing5
learn_params hve missing10
learn_params hve missing20
#learn_params hve missing30
#learn_params hve missing40
#learn_params hve missing50
2012-05-23 14:56:01 +01:00
2013-01-09 15:25:14 +00:00
write_header ve
learn_params ve missing5
learn_params ve missing10
learn_params ve missing20
#learn_params ve missing30
#learn_params ve missing40
#learn_params hve missing50
2012-05-23 14:56:01 +01:00
2013-01-09 15:25:14 +00:00
write_header bp
learn_params bp missing5
learn_params bp missing10
learn_params bp missing20
#learn_params bp missing30
#learn_params bp missing40
#learn_params bp missing50
2012-05-23 14:56:01 +01:00
2013-01-09 15:25:14 +00:00
write_header cbp
learn_params cbp missing5
learn_params cbp missing10
learn_params cbp missing20
#learn_params cbp missing30
#learn_params cbp missing40
#learn_params cbp missing50
2012-05-23 14:56:01 +01:00