def show_all_circles(image, cx, cy, rad, color='r'):
"""
image: numpy array, representing the grayscsale image
cx, cy: numpy arrays or lists, centers of the detected blobs
rad: numpy array or list, radius of the detected blobs
"""
import matplotlib.pyplot as plt
from matplotlib.patches import Circle
fig, ax = plt.subplots()
ax.set_aspect('equal')
ax.imshow(image, cmap='gray')
for x, y, r in zip(cx, cy, rad):
circ = Circle((x, y), r, color=color, fill=False)
ax.add_patch(circ)
plt.title('%i circles' % len(cx))
plt.show()