Kaushik Bar commited on
Commit
8ac7f12
1 Parent(s): 70ebd67

first commit

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -114,7 +114,7 @@ def sequence_to_classify(text, labels):
114
  probs = probs.softmax(dim=-1).cpu().numpy()
115
  scores = list(probs.flatten())
116
 
117
- sorted_sl = sorted(zip(scores, candidate_labels), key=lambda t:t[0], reverse=True)
118
 
119
  pred["labels"] = textlet
120
  pred["scores"], pred["labels"] = zip(*sorted_sl)
 
114
  probs = probs.softmax(dim=-1).cpu().numpy()
115
  scores = list(probs.flatten())
116
 
117
+ sorted_sl = sorted(zip(scores, labels), key=lambda t:t[0], reverse=True)
118
 
119
  pred["labels"] = textlet
120
  pred["scores"], pred["labels"] = zip(*sorted_sl)