A spherical harmonics code in Python