forked from ZhengPeng7/BiRefNet
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtest.sh
More file actions
executable file
·27 lines (19 loc) · 822 Bytes
/
test.sh
File metadata and controls
executable file
·27 lines (19 loc) · 822 Bytes
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
26
27
devices=${1:-0}
pred_root=${2:-e_preds}
resolutions=${3:-"config.size"}
# Inference
# resolutions="1024x1024 None"
for resolution in ${resolutions}; do
CUDA_VISIBLE_DEVICES=${devices} python inference.py --pred_root ${pred_root} --resolution ${resolution}
done
echo Inference finished at $(date)
# Evaluation
log_dir=e_logs && mkdir ${log_dir}
task=$(python3 config.py --print_task)
testsets=$(python3 config.py --print_testsets)
testsets=(`echo ${testsets} | tr ',' ' '`) && testsets=${testsets[@]}
for testset in ${testsets}; do
# python eval_existingOnes.py --pred_root ${pred_root} --data_lst ${testset} > ${log_dir}/eval_${testset}.out
nohup python eval_existingOnes.py --pred_root ${pred_root} --data_lst ${testset} > ${log_dir}/eval_${testset}.out 2>&1 &
done
echo Evaluation started at $(date)