kaiku03 commited on
Commit
3310597
1 Parent(s): ba0d5d7

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -40,7 +40,7 @@ def predict(img) -> Tuple[Dict, float]:
40
  effnet_b1.eval()
41
  with torch.inference_mode():
42
  # Pass the transformed image through the model and turn the prediction logits into prediction probabilities
43
- pred_probs = torch.softmax(effnetb0(img), dim=1)
44
 
45
  # Create a prediction label and prediction probability dictionary for each prediction class (this is the required format for Gradio's output parameter)
46
  pred_labels_and_probs = {class_names[i]: float(pred_probs[0][i]) for i in range(len(class_names))}
 
40
  effnet_b1.eval()
41
  with torch.inference_mode():
42
  # Pass the transformed image through the model and turn the prediction logits into prediction probabilities
43
+ pred_probs = torch.softmax(effnet_b1(img), dim=1)
44
 
45
  # Create a prediction label and prediction probability dictionary for each prediction class (this is the required format for Gradio's output parameter)
46
  pred_labels_and_probs = {class_names[i]: float(pred_probs[0][i]) for i in range(len(class_names))}