Rewriting numpy.int64 to numpy.int32