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
I have applied dynamic quantization to a flan-t5-large model. However, when I try to evaluate the generated summaries I get this error:
RuntimeError: empty_strided not supported on quantized tensors yet see https://github.com/pytorch/pytorch/issues/74540
Code:
from optimum.intel.neural_compressor import INCModelForSeq2SeqLM
model = INCModelForSeq2SeqLM.from_pretrained(model_name).to(device)
for examples_chunk in tqdm(list(chunks(examples, batch_size))):
examples_chunk = [prefix + text for text in examples_chunk]
batch = tokenizer(examples_chunk, return_tensors="pt", truncation=True, padding="longest").to(device)
summaries = model.generate(
input_ids=batch.input_ids,
attention_mask=batch.attention_mask,
**generate_kwargs,
)
I have applied dynamic quantization to a
flan-t5-large
model. However, when I try to evaluate the generated summaries I get this error:RuntimeError: empty_strided not supported on quantized tensors yet see https://github.com/pytorch/pytorch/issues/74540
Code:
Dependencies:
Traceback:
The text was updated successfully, but these errors were encountered: