kya5 commited on
Commit
244714e
1 Parent(s): c862814

Update translation_api.py

Browse files
Files changed (1) hide show
  1. translation_api.py +1 -1
translation_api.py CHANGED
@@ -52,7 +52,7 @@ def tos(translated_text_file_path, video_path):
52
  video_audio(video_path, output_file_path, output,translated_text,new_video_path)
53
  return output
54
 
55
- def translate(input_text_path, output_text_path, source_lang='en', target_lang='fr', model_name="Helsinki-NLP/opus-mt-en-fr", batch_size=8):
56
  model = MarianMTModel.from_pretrained(model_name)
57
  tokenizer = MarianTokenizer.from_pretrained(model_name)
58
 
 
52
  video_audio(video_path, output_file_path, output,translated_text,new_video_path)
53
  return output
54
 
55
+ def translate(input_text_path, output_text_path, source_lang='en', target_lang='jp', model_name="Helsinki-NLP/opus-mt-en-jp", batch_size=8):
56
  model = MarianMTModel.from_pretrained(model_name)
57
  tokenizer = MarianTokenizer.from_pretrained(model_name)
58