PyCOOL — A Cosmological Object-Oriented Lattice code written in Python