Reaper200 commited on
Commit
32e2270
·
verified ·
1 Parent(s): 04292cd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +10 -0
app.py CHANGED
@@ -1,3 +1,13 @@
 
 
 
 
 
 
 
 
 
 
1
  import os
2
  import shutil
3
  import tempfile
 
1
+ import torch
2
+ from torch.serialization import add_safe_globals
3
+ import numpy.core.multiarray
4
+
5
+ # Patch for PyTorch 2.6 to allow loading Bark's model checkpoints
6
+ add_safe_globals({
7
+ 'scalar': numpy.core.multiarray.scalar
8
+ })
9
+
10
+
11
  import os
12
  import shutil
13
  import tempfile