NameError: name 'cm' is not defined code example Example: name 'cm' is not defined from matplotlib import cm