-
Notifications
You must be signed in to change notification settings - Fork 319
Installation on Windows
Carl edited this page May 14, 2019
·
8 revisions
This was tested for a 64-bit Python installation on Windows Server 2012 but it should be similar for other modern Windows versions.
- Download mingw-w64. I used this pre-built version.
- Unzip mingw-w64 to a directory with no spaces e.g.
C:\mingw64\
- Add the
bin\
directory to your PATH - Verify that running
where gcc.exe
in a command prompt prints your MinGW64 installation first. Re-arrange your PATH if not
- Install an up-to-date version of
libpython
(conda install "libpython>=2.1"
) - Clone this repository and move into its root directory (
glove-python
) - Run
python setup.py build_ext --compiler=mingw32
to verify it builds and double check it uses your installation of MinGW64. You can ignore the warnings but make sure it creates a directory calledbuild\lib.blah
with some.pyd
files inside
Run pip install .
to add the compiled libraries to your current environment
Running pytest
should give the following output:
============================= test session starts =============================
platform win32 -- Python 3.6.5, pytest-3.6.0, py-1.5.3, pluggy-0.6.0
rootdir: E:\Carl\glove-python, inifile:
collected 8 items
tests\test_corpus.py ...... [ 75%]
tests\test_glove.py .. [100%]
========================== 8 passed in 5.36 seconds ===========================