ONNX Model Zoo

Intel/bert-base-uncased-mrpc-int8-dynamic-inc

By Intel · ↓ 11 · ♥ 0 · Updated 2024-03-21

What's in this repo

This page lists the files in Intel/bert-base-uncased-mrpc-int8-dynamic-inc, including model.onnx.

  • 1 ONNX models (.onnx files)
  • 9 files, including 4 .json, 1 .md, 1 .onnx, 1 .bin, 1 .txt
  • Last updated 2024-03-21

ONNX files

File Size Download
model.onnx — Download

How to use

These ONNX files can be loaded with ONNX Runtime. To inspect a model graph, upload the file to the Netron viewer. Download links point to the original files on Hugging Face.

README

INT8 BERT base uncased finetuned MRPC

Post-training dynamic quantization

PyTorch

This is an INT8 PyTorch model quantized with huggingface/optimum-intel through the usage of Intel® Neural Compressor.

The original fp32 model comes from the fine-tuned model Intel/bert-base-uncased-mrpc.

Test result
INT8 FP32
Accuracy (eval-f1) 0.8997 0.9042
Model size (MB) 174 418
Load with optimum:
from optimum.intel import INCModelForSequenceClassification

model_id = "Intel/bert-base-uncased-mrpc-int8-dynamic"
int8_model = INCModelForSequenceClassification.from_pretrained(model_id)

ONNX

This is an INT8 ONNX model quantized with Intel® Neural Compressor.

The original fp32 model comes from the fine-tuned model Intel/bert-base-uncased-mrpc.

Test result
INT8 FP32
Accuracy (eval-f1) 0.8958 0.9042
Model size (MB) 107 418
Load ONNX model:
from optimum.onnxruntime import ORTModelForSequenceClassification
model = ORTModelForSequenceClassification.from_pretrained('Intel/bert-base-uncased-mrpc-int8-dynamic')

Model info

text-classification transformers
transformers pytorch onnx bert text-classification text-classfication int8 Intel® Neural Compressor PostTrainingDynamic en dataset:mrpc license:apache-2.0
↓ 11 ♥ 0

Created: 2022-04-21

Updated: 2024-03-21

View on Hugging Face

Files (9)

.gitattributes
README.md
config.json
model.onnx ONNX
pytorch_model.bin
special_tokens_map.json
tokenizer.json
tokenizer_config.json
vocab.txt

Related models