Skip to content

Commit e63df48

Browse files
committed
Add fairseq as a submodule
1 parent 1a8a22d commit e63df48

18 files changed

Lines changed: 22 additions & 30 deletions

File tree

WavLLM/wavllm/scripts/inference_sft.sh

Lines changed: 6 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -9,22 +9,21 @@ src_dir=${model_path%/*}
99
cpt=${model_path##*/}
1010
cpt=${cpt%.*}
1111

12-
beam_size=$2
13-
gen_set=$3
12+
gen_set=$2
1413
[ -z $gen_set ] && gen_set="?"
1514
[ -z $beam_size ] && beam_size=1
1615

1716

1817
FAIRSEQ_ROOT=${PWD}
19-
DATA_DIR=$FAIRSEQ_ROOT/../wavllm/test_data
18+
DATA_DIR=$FAIRSEQ_ROOT/examples/wavllm/test_data
2019

2120
for subset in $gen_set; do
2221
results_path=$src_dir/decode_${cpt}_beam${beam_size}/${subset}
2322
[ ! -d $results_path ] && mkdir -p $results_path
2423

25-
python $FAIRSEQ_ROOT/../wavllm/inference/generate.py $DATA_DIR \
26-
--user-dir ../wavllm \
27-
--tokenizer-path $FAIRSEQ_ROOT/../wavllm/tokenizer/tokenizer.model \
24+
python $FAIRSEQ_ROOT/examples/wavllm/inference/generate.py $DATA_DIR \
25+
--user-dir examples/wavllm \
26+
--tokenizer-path $FAIRSEQ_ROOT/examples/wavllm/tokenizer/tokenizer.model \
2827
--gen-subset ${subset} \
2928
\
3029
--task speechllm_task \
@@ -37,16 +36,4 @@ for subset in $gen_set; do
3736
--max-tokens 1600000 \
3837
--sampling --beam 1 --nbest 1 --temperature 0.5 \
3938
--max-len-a 0 --max-len-b 512
40-
# --beam ${beam_size} \
41-
#
42-
43-
44-
# echo $results_path
45-
# tail -n 1 $results_path/generate-*.txt
46-
# sleep 1s
47-
done
48-
49-
#--max-sample-size 2000000 \
50-
# --max-len-a 0 --max-len-b 512 \
51-
# --skip-invalid-size-inputs-valid-test \
52-
# --max-sentences 20 \
39+
done
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
id audio n_frames prompt with_speech tgt_text
2+
0 SpeechT5/WavLLM/fairseq/examples/wavllm/test_data/audio/CoT-task.wav 214437 First of all, transcribe the audio recording into text, capturing every spoken word; Additionally given this audio clip and text, can you condense it into a clear, concise summary, no more than 20 words?; Lastly disregarding the sound, translate this English summary into German. True Drei Filme aus dem asiatisch-pazifischen Raum im Rennen in Cannes
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
id audio n_frames with_speech prompt tgt_text
2+
0 SpeechT5/WavLLM/fairseq/examples/wavllm/test_data/audio/II-task.wav 111111 True To begin, Transcribe the audio recording into text, capturing every spoken word; Subsequently, How does the woman finally decide to go home? A. By bus; B. In the man’s car; C. In her father’s car.; Furthermore, ignore the audio clip, What is the capital of New Zealand?; Lastly, Continue the narrative of given audio clip in a coherent and engaging way ASR+SQA+SFT+Continue

WavLLM/wavllm/test_data/SQA.tsv

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
id audio n_frames prompt tgt_text with_speech
2+
0 SpeechT5/WavLLM/fairseq/examples/wavllm/test_data/audio/sqa.wav 111111 What will the man do next? A. Start to take exercise; B. Do as he always does; C. Change his working time. A True

WavLLM/wavllm/test_data/SQQA.tsv

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
id audio n_frames prompt tgt_text with_speech
2+
0 SpeechT5/WavLLM/fairseq/examples/wavllm/test_data/audio/sqqa.wav 182574 The fundamental theorem of calculus is a theorem that links the concept of the derivative of a function with the concept of the integral . True

WavLLM/wavllm/test_data/asr.tsv

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
id audio n_frames prompt tgt_text with_speech
2+
0 SpeechT5/WavLLM/fairseq/examples/wavllm/test_data/audio/asr.flac 166960 Based on the attached audio, generate a comprehensive text transcription of the spoken content. he hoped there would be stew for dinner turnips and carrots and bruised potatoes and fat mutton pieces to be ladled out in thick peppered flour fattened sauce True
343 KB
Binary file not shown.
1.68 MB
Binary file not shown.
179 KB
Binary file not shown.
69.4 KB
Binary file not shown.

0 commit comments

Comments
 (0)