Spark808 commited on
Commit
2daeef6
·
1 Parent(s): 96cc7d5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -88,16 +88,16 @@ if __name__ == '__main__':
88
  args, unknown = parser.parse_known_args()
89
  load_hubert()
90
  models = []
91
- with open("weights/model_info.json", "r", encoding="utf-8") as f:
92
  models_info = json.load(f)
93
  for name, info in models_info.items():
94
  if not info['enable']:
95
  continue
96
  title = info['title']
97
- cover = f"weights/{name}/{info['cover']}"
98
- index = f"weights/{name}/{info['feature_retrieval_library']}"
99
- npy = f"weights/{name}/{info['feature_file']}"
100
- cpt = torch.load(f"weights/{name}/{name}.pth", map_location="cpu")
101
  tgt_sr = cpt["config"][-1]
102
  if_f0 = cpt.get("f0", 1)
103
  if if_f0 == 1:
 
88
  args, unknown = parser.parse_known_args()
89
  load_hubert()
90
  models = []
91
+ with open("Weights/model_info.json", "r", encoding="utf-8") as f:
92
  models_info = json.load(f)
93
  for name, info in models_info.items():
94
  if not info['enable']:
95
  continue
96
  title = info['title']
97
+ cover = f"Weights/{name}/{info['cover']}"
98
+ index = f"Weights/{name}/{info['feature_retrieval_library']}"
99
+ npy = f"Weights/{name}/{info['feature_file']}"
100
+ cpt = torch.load(f"Weights/{name}/{name}.pth", map_location="cpu")
101
  tgt_sr = cpt["config"][-1]
102
  if_f0 = cpt.get("f0", 1)
103
  if if_f0 == 1: