jfforero commited on
Commit
867ad7f
·
verified ·
1 Parent(s): 4e7f2d5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -5
app.py CHANGED
@@ -47,17 +47,15 @@ def predict_emotion_from_audio(wav_filepath):
47
  # Predict emotion from audio
48
  def get_predictions(audio_input):
49
  emotion_prediction = predict_emotion_from_audio(audio_input)
50
- return emotion_prediction # Return a single prediction instead of a list
 
 
51
 
52
 
53
 
54
  ###
55
 
56
- # Define the API key for DeepAI Text to Image API
57
- api_key = 'dee3e3f2-d5cf-474c-8072-bd6bea47e865'
58
 
59
- # Generate the image with the transcribed text using DeepAI Text to Image API
60
- image = generate_image(api_key, emotion_prediction)
61
 
62
 
63
 
 
47
  # Predict emotion from audio
48
  def get_predictions(audio_input):
49
  emotion_prediction = predict_emotion_from_audio(audio_input)
50
+ # Generate image here or call a separate function
51
+ image = generate_image(api_key, emotion_prediction)
52
+ return emotion_prediction, image
53
 
54
 
55
 
56
  ###
57
 
 
 
58
 
 
 
59
 
60
 
61