Przeglądaj źródła

fix bug in timestamp inference

shixian.shi 2 lat temu
rodzic
commit
33a9bafbcc
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      funasr/bin/asr_inference_launch.py

+ 1 - 1
funasr/bin/asr_inference_launch.py

@@ -427,7 +427,7 @@ def inference_paraformer(
                         else:
                             text_postprocessed, word_lists = postprocessed_result[0], postprocessed_result[1]
                         item = {'key': key, 'value': text_postprocessed}
-                        if timestamp_postprocessed != "" or len(timestamp) == 0:
+                        if timestamp_postprocessed != "":
                             item['timestamp'] = timestamp_postprocessed
                         asr_result_list.append(item)
                         finish_count += 1