mirror of
https://github.com/NVIDIA/Model-Optimizer.git
synced 2026-10-02 03:14:52 +08:00
Move phi4_mm warning to above (#389)
Signed-off-by: Chenjie Luo <108829653+cjluo-nv@users.noreply.github.com>
This commit is contained in:
@@ -328,6 +328,9 @@ def main(args):
|
||||
model = model.language_model
|
||||
model_type = get_model_type(model)
|
||||
|
||||
if model_type == "phi4mm":
|
||||
warnings.warn("Please set the default input_mode to InputMode.LANGUAGE before quantizing.")
|
||||
|
||||
if args.sparsity_fmt != "dense":
|
||||
if args.batch_size == 0:
|
||||
# Sparse algorithm takes more GPU memory so we reduce the batch_size by 4.
|
||||
@@ -478,9 +481,6 @@ def main(args):
|
||||
quant_cfg["quant_cfg"]["*audio*"] = {"enable": False}
|
||||
quant_cfg["quant_cfg"]["*image*"] = {"enable": False}
|
||||
quant_cfg["quant_cfg"]["*vision*"] = {"enable": False}
|
||||
warnings.warn(
|
||||
"Please set the default input_mode to InputMode.LANGUAGE before quantizing."
|
||||
)
|
||||
|
||||
if not model_is_already_quantized or calibration_only:
|
||||
# Only run single sample for preview
|
||||
|
||||
Reference in New Issue
Block a user