You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Error message:
neural_compressor\experimental\export\torch2onnx.py", line 389, in torch_to_int8_onnx
assert q_config is not None, "'q_config' is needed when export an INT8 model."
AssertionError: 'q_config' is needed when export an INT8 model.
Hi,
I want to convert and quantize Pytorch model to ONNX model. I refer to this example https://github.com/intel/neural-compressor/blob/master/examples/pytorch/image_recognition/torchvision_models/export/fx/main.py
When calling export function, there is error "'q_config' is needed when export an INT8 model"
I don't see anything about q_config in example code. May I know how to solve this issue?
Here is my code:
if name == "main":
model = timm.create_model('resnet50.a1_in1k', pretrained=True)
model = model.eval()
Error message:
neural_compressor\experimental\export\torch2onnx.py", line 389, in torch_to_int8_onnx
assert q_config is not None, "'q_config' is needed when export an INT8 model."
AssertionError: 'q_config' is needed when export an INT8 model.
torch.version '2.2.2+cpu'
neural_compressor.version '2.6'
The text was updated successfully, but these errors were encountered: