eladhoffer / quantized.pytorch

MIT License
212 stars 57 forks source link

Prediction with quantized model #3

Open indrajitsg opened 6 years ago

indrajitsg commented 6 years ago

Hi,

I am trying to run prediction but hitting a roadblock with CUDA not supporting Byte tensor:

d, l = next(iter(train_loader))
d, l = d.type(torch.ByteTensor), l.type(torch.ByteTensor)
d, l = Variable(d.cuda()), Variable(l.cuda())
model_q(d)

Any thoughts how can I directly use a quantized model?