Cast literal constants to correct numpy data type.