yzhangcs / parser

:rocket: State-of-the-art parsers for natural language.
https://parser.yzhang.site/
MIT License
825 stars 138 forks source link

'con-crf-roberta-en' won't load #123

Closed dslim23 closed 1 year ago

dslim23 commented 1 year ago

Description

I was trying to load a model using Parser.load('con-crf-roberta-en') and predict on a sentence, but I encountered a ValueError saying "unknown url type: 'con-crf-roberta-en".

This error occurred running your code snippet in README.md:

from supar import Parser

parser = Parser.load('con-crf-roberta-en')

dataset = parser.predict('I saw Sarah with a telescope.', lang='en', prob=True, verbose=False)
dslim23 commented 1 year ago

upon a bit of investigation, it seems like the models here http://hlt.suda.edu.cn/~yzhang/supar/v1.1.0/ptb.crf.con.roberta.zip aren't accessible (perhaps due to server overload)

yzhangcs commented 1 year ago

@dslim23 Hi, you might need to install supar from source code

pip install -U git+https://github.com/yzhangcs/parser
dslim23 commented 1 year ago

I got it working with your suggestion thank you! is this still an issue https://github.com/yzhangcs/parser/issues/118#issuecomment-1431639685? I would like to use the pretrained weights. if so, what's the last version that could use these pt Roberta weights?

yzhangcs commented 1 year ago

@dslim23 Hi, I've submitted some patches, so installing from source are ok for RoBERTa :-)

Quang-elec44 commented 2 weeks ago

@yzhangcs Hi, can you check the again since I coudn't download this checkpoint?