matplotlib bbox color code example
Example: plt.text background alpha
plt_text = plt.text(
0.5, # x
0.5, # y
'your text', # text
fontsize=30
)
plt_text.set_bbox(dict(
facecolor='red', # background color
alpha=0.5, # background alpha
edgecolor='red' # border color
))