Pavani2704 commited on
Commit
759ea45
β€’
1 Parent(s): 518f1a5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -7
app.py CHANGED
@@ -54,19 +54,19 @@ elif option == "Emotion Detection":
54
  if st.button("Submit"):
55
  if text:
56
  emotion=emopipe(text)[0]["label"]
57
- if emotion = "sadness":
58
  st.write("Emotion : ",emotion,"😒")
59
- elif emotion = "joy":
60
  st.write("Emotion : ",emotion,"πŸ˜ƒ")
61
- elif emotion = "fear":
62
  st.write("Emotion : ",emotion,"😨")
63
- elif emotion = "anger":
64
  st.write("Emotion : ",emotion,"😑")
65
- elif emotion = "neutral":
66
  st.write("Emotion : ",emotion,"😐")
67
- elif emotion = "disgust":
68
  st.write("Emotion : ",emotion,"🀒")
69
- elif emotion = "surprise":
70
  st.write("Emotion : ",emotion,"😲")
71
  else:
72
  st.write("Please enter text.")
 
54
  if st.button("Submit"):
55
  if text:
56
  emotion=emopipe(text)[0]["label"]
57
+ if emotion == "sadness":
58
  st.write("Emotion : ",emotion,"😒")
59
+ elif emotion == "joy":
60
  st.write("Emotion : ",emotion,"πŸ˜ƒ")
61
+ elif emotion == "fear":
62
  st.write("Emotion : ",emotion,"😨")
63
+ elif emotion == "anger":
64
  st.write("Emotion : ",emotion,"😑")
65
+ elif emotion == "neutral":
66
  st.write("Emotion : ",emotion,"😐")
67
+ elif emotion == "disgust":
68
  st.write("Emotion : ",emotion,"🀒")
69
+ elif emotion == "surprise":
70
  st.write("Emotion : ",emotion,"😲")
71
  else:
72
  st.write("Please enter text.")