Added explicit ValueError exception if compression number is not recognised