-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdynamic_programming_test.sh
More file actions
26 lines (24 loc) · 1.12 KB
/
Copy pathdynamic_programming_test.sh
File metadata and controls
26 lines (24 loc) · 1.12 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#bash instance encoding translator_params clasp_params converter_params dflatconverter_params
echo "bash instance encoding dflat/dynasp_params clasp_params converter_params dflatconverter_params output EDGE"
pid=$$
#clean ordering
#echo "" > g.inp.translator.$pid
echo "USING: $pid"
echo "DFLATing..."
#Using MCS!
#--elimination min-degree: use variable orderings instead of TDs (still MCS)
dflat -s dummy -e $8 --graphml-out g.inp.$pid -f $1 --print-decomposition $3 --no-empty-root --no-empty-leaves -n semi #--elimination min-degree #--path-decomposition
dflat -s dummy -e $8 --graphml-out g.xml.$7.$pid -f $1 --print-decomposition $3 --no-empty-root --no-empty-leaves -n semi #--elimination min-degree #--path-decomposition
echo "DFLAT done"
echo "DFLAT2ASPing..."
python Dflat2ASP.py $5 < g.inp.$pid > g.out.$pid
if [ $(wc -c < g.out.$pid) -le 4 ] #variable ordering mode
then
cp g.inp.$pid g.out.$pid
fi
echo "DFLAT2ASP done..."
echo "CLASPing..."
/usr/bin/time ./callpot.sh $1 $2 $pid $4 > g.g.out.$7.$pid.out 2> g.g.out.$7.$pid
echo "CLASP done"
cat g.g.out.$7.$pid >&2
cat g.g.out.$7.$pid.out