forked from alibaba/libgrape-lite
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsampler_test.sh
executable file
·20 lines (17 loc) · 920 Bytes
/
sampler_test.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/bin/bash -e
GRAPE_HOME="$( cd "$(dirname "$0")/.." >/dev/null 2>&1 ; pwd -P )"
GRAPH=p2p-31
function RunSamplerOnStaticGraph {
cmd_random="mpirun -n 4 ./run_sampler --vfile ${GRAPE_HOME}/dataset/${GRAPH}.v --efile ${GRAPE_HOME}/dataset/${GRAPH}.e --sampling_strategy random --hop_and_num 4-5 --out_prefix ./output_sampling"
echo "${cmd_random}"
eval ${cmd_random}
cmd_weight="mpirun -n 4 ./run_sampler --vfile ${GRAPE_HOME}/dataset/${GRAPH}.v --efile ${GRAPE_HOME}/dataset/${GRAPH}.e --sampling_strategy edge_weight --hop_and_num 4-5 --out_prefix ./output_sampling"
echo "${cmd_weight}"
eval ${cmd_weight}
cmd_top_k="mpirun -n 4 ./run_sampler --vfile ${GRAPE_HOME}/dataset/${GRAPH}.v --efile ${GRAPE_HOME}/dataset/${GRAPH}.e --sampling_strategy top_k --hop_and_num 4-5 --out_prefix ./output_sampling"
echo "${cmd_top_k}"
eval ${cmd_top_k}
}
pushd ${GRAPE_HOME}/build
RunSamplerOnStaticGraph
popd