nppmatt commited on
Commit
53a5efc
1 Parent(s): 7d14b15

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -2
app.py CHANGED
@@ -46,9 +46,8 @@ result
46
  # transform logit to get probabilities
47
  if (result.logits.size(dim=1) < 2):
48
  pad = (0, 1)
49
- result = nn.functional.pad(result.logits, pad, "constant", 0)
50
  st.write(result)
51
- prediction = nn.functional.softmax(result, dim=-1)
52
  prediction = nn.functional.softmax(result.logits, dim=-1)
53
  prediction
54
  #neutralProb = prediction.data[0][neutralIndex]
 
46
  # transform logit to get probabilities
47
  if (result.logits.size(dim=1) < 2):
48
  pad = (0, 1)
49
+ result.logits = nn.functional.pad(result.logits, pad, "constant", 0)
50
  st.write(result)
 
51
  prediction = nn.functional.softmax(result.logits, dim=-1)
52
  prediction
53
  #neutralProb = prediction.data[0][neutralIndex]