Python Forum
How Do I Download Models Using PIP?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How Do I Download Models Using PIP?
#1
I installed Spacy but from what I am reading I also need a model for English. Spacy's installation directions say "python -m spacy download en_core_web_md". Since this is my first Python project I have no clue what that means. I tried typing it into my .py file and running it in Visual Studio only to get a syntax error.

According to Spacy that should not be my only option "Models can be installed from a download URL or a local directory, manually or via pip." Unfortunately, they do not say how to download using PIP. They say it can be done and offer no tips as to how.

Well, I managed to finally find the manual download link on GitHub, the problem was that the Spacy website links to it as "Release Details" instead of "download" or similar language.

I unzipped the files and copied them to my project in Visual Studio, but when I try to run setup.py I get an error that says:

Severity Code Description Project File Line Suppression State
Error file has both Unicode marker and PEP-263 file encoding. You must use "utf-8" as the encoding name when a BOM is present. PDFParser C:\Users\suername\source\repos\PDFParser\PDFParser\en_core_web_md-2.2.5\setup.py 2

My project looks like this:

This is where a screenshot would go if I could upload one, but instead this form wants the URL of an image already uploaded elsewhere.
Reply
#2
python -m pip install <package> where package is the module you want to install
I welcome all feedback.
The only dumb question, is one that doesn't get asked.
My Github
How to post code using bbtags


Reply
#3
Installation instructions here: https://spacy.io/models , not pypi version, so pip won't work
Reply
#4
To install SpaCy, type these two lines of code one by one in your command prompt
pip install spacy
python -m spacy download en_core_web_sm
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
Question Triying to store values from models Larry1888 1 649 Nov-02-2022, 02:08 AM
Last Post: Pedroski55
  Python3 requests.models.Response ogautier 4 5,361 Feb-17-2022, 04:46 PM
Last Post: ogautier
  download with internet download manager coral_raha 0 2,940 Jul-18-2021, 03:11 PM
Last Post: coral_raha
  Multivariate mixed effects models primeprover 1 2,582 Aug-19-2018, 01:14 PM
Last Post: ketanm
  view_db.models [HELP] Lartos 0 1,900 Jun-14-2018, 03:33 PM
Last Post: Lartos
  creating a blog, models.py is empty rickadams 3 3,508 Nov-11-2017, 03:51 PM
Last Post: snippsat

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020