Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using Pre-Downloaded Domain Model is messy #176

Open
tsafs opened this issue Jun 5, 2024 · 1 comment
Open

Using Pre-Downloaded Domain Model is messy #176

tsafs opened this issue Jun 5, 2024 · 1 comment

Comments

@tsafs
Copy link

tsafs commented Jun 5, 2024

Hey there :)

I'm using spacy-pkuseg version 0.0.33. Since this is spacy-pkuseg, I'm not sure if this is the right place to report. I haven't looked through the your/their source code.

At some point pkuseg loads a domain model:

Downloading: "https://github.com/lancopku/pkuseg-python/releases/download/v0.0.16/mixed.zip" to /home/python/.pkuseg/mixed.zip 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 47330222/47330222 [00:01<00:00, 39315899.62it/s] WARNING: features.msgpack does not exist, try loading features.pkl

My goal is to pre-download this requirement such that it is not downloaded at runtime.

My first approach was to put the mixed.zip file at ~/.pkuseg/mixed.zip. This doesn't work. pkuseg re-downloads the file.

My second approach was to extract the mixed.zip contents and put it into ~/.pkuseg/mixed. I then deleted the original zip file. This doesn't work. pkuseg re-downloads the file.

My third approach was to keep and not remove the mixed.zip after extraction at ~/.pkuseg/mixed.zip. This did work, i.e. the file was not re-downloaded.

My issue is that I would expect both the first and second approach to work out of the box.

Is this some error in my application or is this some faulty check within pkuseg / spacy-pkuseg?

Thank you

@lcyyyyyyyyyyy
Copy link

lcyyyyyyyyyyy commented Jun 5, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants