I was wondering if there is a command that can be run in Python REPL and is equivalent to
python -m spacy download en_core_web_sm
which is run in a bash shell?
Thanks.
I was wondering if there is a command that can be run in Python REPL and is equivalent to
python -m spacy download en_core_web_sm
which is run in a bash shell?
Thanks.
You can use subprocess.run
:
import subprocess
import sys
subprocess.run([sys.executable, '-m', 'spacy', 'download', 'en_core_web_sm'], check=True)