CineAI commited on
Commit
cd9b829
1 Parent(s): 4acd1fa

Update audio_processing/config.py

Browse files
Files changed (1) hide show
  1. audio_processing/config.py +16 -8
audio_processing/config.py CHANGED
@@ -1,8 +1,6 @@
1
  import torch
2
 
3
  from transformers import pipeline
4
- from parler_tts import ParlerTTSForConditionalGeneration
5
- from transformers import AutoTokenizer, AutoFeatureExtractor
6
 
7
  # ArticMonkey:19.03.24:1700 example of version name in plaintext will be convert into hex using this site -> https://magictool.ai/tool/text-to-hex-converter/
8
  # Here ArticMonkey is name of version and rest of all is data and time
@@ -18,11 +16,21 @@ pipe = pipeline(
18
  chunk_length_s=30,
19
  )
20
 
21
- checkpoint_parler = "parler-tts/parler_tts_mini_v0.1"
 
22
 
23
- model_parler = ParlerTTSForConditionalGeneration.from_pretrained(checkpoint_parler).to(device)
24
- tokenizer = AutoTokenizer.from_pretrained(checkpoint_parler)
25
- feature_extractor = AutoFeatureExtractor.from_pretrained(checkpoint_parler)
26
 
27
- SAMPLE_RATE = feature_extractor.sampling_rate
28
- SEED = 42
 
 
 
 
 
 
 
 
 
 
 
 
1
  import torch
2
 
3
  from transformers import pipeline
 
 
4
 
5
  # ArticMonkey:19.03.24:1700 example of version name in plaintext will be convert into hex using this site -> https://magictool.ai/tool/text-to-hex-converter/
6
  # Here ArticMonkey is name of version and rest of all is data and time
 
16
  chunk_length_s=30,
17
  )
18
 
19
+ # from parler_tts import ParlerTTSForConditionalGeneration
20
+ # from transformers import AutoTokenizer, AutoFeatureExtractor
21
 
22
+ # checkpoint_parler = "parler-tts/parler_tts_mini_v0.1"
 
 
23
 
24
+ # model_parler = ParlerTTSForConditionalGeneration.from_pretrained(checkpoint_parler).to(device)
25
+ # tokenizer = AutoTokenizer.from_pretrained(checkpoint_parler)
26
+ # feature_extractor = AutoFeatureExtractor.from_pretrained(checkpoint_parler)
27
+
28
+ # SAMPLE_RATE = feature_extractor.sampling_rate
29
+ # SEED = 42
30
+
31
+ from transformers import VitsModel, AutoTokenizer
32
+
33
+ checkpoint_mms_tts_eng = "facebook/mms-tts-eng"
34
+
35
+ model_mms_tts_eng = VitsModel.from_pretrained(checkpoint_mms_tts_eng)
36
+ tokenizer_mms_tts_eng = AutoTokenizer.from_pretrained(checkpoint_mms_tts_eng)