-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathpipeline_rnafm.sh
executable file
·44 lines (37 loc) · 1.41 KB
/
pipeline_rnafm.sh
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#!/bin/bash
test -d ./output || mkdir ./output
source ../scripts/config.py
model=$SPLICEBERT_510
prefix="finetune_rnafm_on_spliceator"
batch_size=16
for group in "donor" "acceptor"; do
run_name="./output/${prefix}_GS-GS_1_${group}_cv"
test -e ${run_name}.log && continue
./train_rnafm_cv.py \
-lr 0.00001 \
-b ${batch_size} \
-p ../data/spliceator/Training_data/Positive/GS/POS_${group}_600.csv \
-n ../data/spliceator/Training_data/Negative/GS/GS_1/NEG_600_${group}.csv \
-o ${run_name} &> ${run_name}.log
done
for ss_type in "donor" "acceptor"; do
for fold in `seq 0 9`; do
weight="./output/${prefix}_GS-GS_1_${ss_type}_cv/fold${fold}/checkpoint.pt.best_model.pt"
if [ -e $weight ]; then
echo "run model: $weight"
else
echo "missing $weight, skip"
continue
fi
for species in Danio Fly Worm Thaliana; do
outdir="./output/${prefix}_GS-GS_1_${ss_type}_cv/fold${fold}/benchmark_${species}"
mkdir -p $outdir
./predict_by_rnafm.py \
-w $weight \
-p "../data/spliceator/Benchmarks/${species}/SA_sequences_${ss_type}_400_Final_3.positive.txt" \
-n "../data/spliceator/Benchmarks/${species}/SA_sequences_${ss_type}_400_Final_3.negative.txt" \
-o $outdir &> ${outdir}.log
done
wait
done
done