Serhiy Stetskovych commited on
Commit
a60a79a
·
1 Parent(s): 1b8633f

Add vocal models

Browse files
app.py CHANGED
@@ -45,14 +45,23 @@ texts
45
 
46
 
47
  apollo_config = get_config('configs/apollo.yaml')
 
48
  apollo_model = look2hear.models.BaseModel.from_pretrain('weights/apollo.bin', **apollo_config['model']).to(device)
 
 
 
 
49
 
50
  models = {
51
- 'apollo': apollo_model
 
 
52
  }
53
 
54
  choices = [
55
- ('MP3 restore', 'apollo')
 
 
56
  ]
57
 
58
  @spaces.GPU
 
45
 
46
 
47
  apollo_config = get_config('configs/apollo.yaml')
48
+ apollo_vocal_config = get_config('configs/config_apollo_vocal.yaml')
49
  apollo_model = look2hear.models.BaseModel.from_pretrain('weights/apollo.bin', **apollo_config['model']).to(device)
50
+ apollo_vocal = look2hear.models.BaseModel.from_pretrain('weights/apollo_vocal.bin', **apollo_vocal_config['model']).to(device)
51
+ apollo_vocal2 = look2hear.models.BaseModel.from_pretrain('weights/apollo_vocal2.bin', **apollo_vocal_config['model']).to(device)
52
+
53
+
54
 
55
  models = {
56
+ 'apollo': apollo_model,
57
+ 'apollo_vocal': apollo_vocal,
58
+ 'apollo_vocal2': apollo_vocal2
59
  }
60
 
61
  choices = [
62
+ ('MP3 restore', 'apollo'),
63
+ ('Apollo vocal', 'apollo_vocal'),
64
+ ('Apollo vocal2', 'apollo_vocal2')
65
  ]
66
 
67
  @spaces.GPU
configs/config_apollo_vocal.yaml ADDED
@@ -0,0 +1,41 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ audio:
2
+ chunk_size: 132300
3
+ num_channels: 2
4
+ sample_rate: 44100
5
+ min_mean_abs: 0.0
6
+
7
+ model:
8
+ sr: 44100
9
+ win: 20
10
+ feature_dim: 192
11
+ layer: 6
12
+
13
+ training:
14
+ instruments: ['restored', 'addition']
15
+ target_instrument: 'restored'
16
+ batch_size: 1
17
+ gradient_accumulation_steps: 2
18
+ num_steps: 1000
19
+ num_epochs: 1000
20
+ optimizer: 'prodigy'
21
+ lr: 1.0
22
+ patience: 2
23
+ reduce_factor: 0.95
24
+ coarse_loss_clip: true
25
+ grad_clip: 0
26
+ q: 0.95
27
+ use_amp: false
28
+
29
+ optimizer:
30
+ weight_decay: 0.01
31
+ betas: [0.5, 0.99]
32
+
33
+ augmentations:
34
+ enable: false # enable or disable all augmentations (to fast disable if needed)
35
+ loudness: true # randomly change loudness of each stem on the range (loudness_min; loudness_max)
36
+ loudness_min: 0.5
37
+ loudness_max: 1.5
38
+
39
+ inference:
40
+ batch_size: 1
41
+ num_overlap: 4
weights/apollo_vocal.bin ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:61b93332da9cde13925b2726b0b31167b05bc20030271b19a583ccf76d69354b
3
+ size 66532080
weights/apollo_vocal2.bin ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:d9255c2f43b467840260dc4c0f99f26bcdb0a7c3523d7b5165d13322ca955b41
3
+ size 38159792