seyia92coding commited on
Commit
c049c60
1 Parent(s): 0f824c3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +0 -7
app.py CHANGED
@@ -24,7 +24,6 @@ import seaborn as sns
24
  import gradio as gr
25
  #https://gradio.app/docs/#i_slider
26
  import matplotlib.pyplot as plt
27
- import matplotlib.patches as mpatches
28
  import time
29
  import numpy as np
30
 
@@ -169,12 +168,6 @@ def gradio_music_graph(client_id, client_secret, artist_name): #total_albums
169
 
170
  sns.boxplot(x=df["album_name"], y=df["popularity"], ax=ax)
171
 
172
- leg_handles = []
173
- for label, artist in zip(labels,ax.artists):
174
- handle = mpatches.Patch(facecolor=artist.get_facecolor(),label=label)
175
- leg_handles.append(handle)
176
- ax.legend(handles=leg_handles,bbox_to_anchor=(0., 1.02, 1., .102), loc=3, ncol=1, mode="expand", borderaxespad=0.)
177
-
178
  plt.show()
179
 
180
  return fig
 
24
  import gradio as gr
25
  #https://gradio.app/docs/#i_slider
26
  import matplotlib.pyplot as plt
 
27
  import time
28
  import numpy as np
29
 
 
168
 
169
  sns.boxplot(x=df["album_name"], y=df["popularity"], ax=ax)
170
 
 
 
 
 
 
 
171
  plt.show()
172
 
173
  return fig