doc: improve modelopt error description (#12269)
This commit is contained in:
@@ -590,14 +590,20 @@ class ModelConfig:
|
||||
return
|
||||
|
||||
# Check if ModelOpt quantization is specified
|
||||
modelopt_quantization_specified = self.quantization in [
|
||||
_MODELOPT_QUANTIZATION_METHODS = [
|
||||
"modelopt",
|
||||
"modelopt_fp8",
|
||||
"modelopt_fp4",
|
||||
]
|
||||
modelopt_quantization_specified = (
|
||||
self.quantization in _MODELOPT_QUANTIZATION_METHODS
|
||||
)
|
||||
|
||||
if not modelopt_quantization_specified:
|
||||
raise ValueError("quantize_and_serve requires ModelOpt quantization")
|
||||
raise ValueError(
|
||||
"quantize_and_serve requires ModelOpt quantization (set with --quantization "
|
||||
f"{{{', '.join(sorted(_MODELOPT_QUANTIZATION_METHODS))}}})"
|
||||
)
|
||||
|
||||
# quantize_and_serve is disabled due to compatibility issues
|
||||
raise NotImplementedError(
|
||||
|
||||
Reference in New Issue
Block a user