AlBERTo-it icon indicating copy to clipboard operation
AlBERTo-it copied to clipboard

Doesn't load with transformers

Open giovanniOfficioso opened this issue 3 years ago • 0 comments

Hi dear I can't load the example with your indications. Where I 'm failing?

from tokenizer import *
from transformers import AutoTokenizer, AutoModel

a = AlBERTo_Preprocessing(do_lower_case=True)
s: str = "#IlGOverno presenta le linee guida sulla scuola #labuonascuola - http://t.co/SYS1T9QmQN"
b = a.preprocess(s)

tok = AutoTokenizer.from_pretrained("m-polignano-uniba/bert_uncased_L-12_H-768_A-12_italian_alb3rt0")
tokens = tok.tokenize(b)
print(tokens)

model = AutoModel.from_pretrained("m-polignano-uniba/bert_uncased_L-12_H-768_A-12_italian_alb3rt0")

When I write a = AlBERTo_Preprocessing(do_lower_case=True), I have an "unresolved reference AlBERTo_Preprocessing". What I could do? Thank you dear

giovanniOfficioso avatar Dec 23 '21 14:12 giovanniOfficioso