Let's import the required libraries:
import numpy as npimport matplotlib.pylab as pltfrom matplotlib.ticker import FuncFormatter