bharat-raghunathan commited on
Commit
988248b
1 Parent(s): 6822e53

Update app v0.92

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -13,7 +13,7 @@ def lyrics_categories(input_text):
13
  predictions = torch.nn.functional.softmax(outputs.logits, dim=-1)
14
  predictions = predictions.detach().numpy()[0]
15
  index_sorted = np.argsort(predictions)[::-1]
16
- clean_outputs = {labels[idx]:str(predictions[idx]) for idx in index_sorted}
17
  print(clean_outputs)
18
  return clean_outputs
19
 
 
13
  predictions = torch.nn.functional.softmax(outputs.logits, dim=-1)
14
  predictions = predictions.detach().numpy()[0]
15
  index_sorted = np.argsort(predictions)[::-1]
16
+ clean_outputs = {labels[idx]:predictions[idx] for idx in index_sorted}
17
  print(clean_outputs)
18
  return clean_outputs
19