forked from stamps/FAS
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsmall.sh
More file actions
executable file
·21 lines (20 loc) · 973 Bytes
/
small.sh
File metadata and controls
executable file
·21 lines (20 loc) · 973 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
echo "First, we need to compile the java files"
javac -cp "lib/*" -d bin ./*.java
STR="small"
EDGELIST="_edgelist"
EDGELISTSORTED='_edgelistsorted'
INVERSE='-t'
ALGO="ArrayFAS" #or BergerShorFAS
echo "convert files for "$STR
echo "for this, we need the edgelist and its inverse"
python get_inverse_graph.py $STR$EDGELIST
sort -nk 1 $STR$EDGELIST | uniq > $STR$EDGELISTSORTED
sort -nk 1 $STR$EDGELIST$INVERSE | uniq > $STR$EDGELISTSORTED$INVERSE
echo "convert to webgraph format"
java -cp "lib/*" it.unimi.dsi.webgraph.BVGraph -1 -g ArcListASCIIGraph dummy $STR < $STR$EDGELISTSORTED
java -cp "lib/*" it.unimi.dsi.webgraph.BVGraph -1 -g ArcListASCIIGraph dummy $STR$INVERSE < $STR$EDGELISTSORTED$INVERSE
echo "now compute the offset files"
java -cp "lib/*" it.unimi.dsi.webgraph.BVGraph -o -O -L $STR
java -cp "lib/*" it.unimi.dsi.webgraph.BVGraph -o -O -L $STR$INVERSE
echo "and now Compute the arc to be removed"
java -cp "bin:lib/*" $ALGO $STR