Munzali commited on
Commit
c00506e
·
verified ·
1 Parent(s): a9c42e5

Update app.py

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