Howto: installation on Windows

(George) #123

For python --version >>> Python 3.6.4 :: Anaconda, Inc.
For which python >>> …/anaconda3/bin/python


(ecdrid) #124

Then you are set to go…
Just a side note, can you share your conda list in a seperate TXT file uploaded on some drive and shared here

Re run the server once
And update us here…
(Not sure whether I am helping you…)


(ecdrid) #125

New Installation Instructions (updated Jan 26, 2018)
The following instructions are somewhat easier than the preceeding ones, but they have not been tested on windows 10 yet. Should an installation attempt fail, fall back to the older instructions below.
Update: They have actually been successfully tested by Jeremy in person.

A) This tutorial assumes you already have a functional anaconda installation.
Moreover, if you don’t have git installed on your machine, install it by following these instructions:

B) Now, move into a directory where you are comfortable installing the Fastai repo, with its libraries and required packages.
Now you got to clone that repo as follows:

git clone

C) Once the cloning process finishes, be sure to be in the directory created by git for the Fastai repository, and type:

conda env create -f environment-win.yml

followed by:

activate fastai

This will install the required packages and their dependencies into the fastai environment by leveraging the file environment-win.yml prepared by Fast.ai16.

D) Now, open jupyter:

(fastai)> jupyter notebook

and create a new notebook (or open one of the lessons’ notebooks). Check if an appropriate kernel has been installed by the preceeding command(s). If you find out you don’t have any kernel other than the base one (usually named python 3.6), you got to install it manually:

(fastai)>python -m ipykernel install --user --name fastai --display-name “fastAI custom”

Once you open jupyter, you will select fastAI custom from the available kernels.

That would be all.
Remind that you will probably need to edit some lessons’ notebooks code, or at least the parts where you interact with the filesystem from inside the notebook.
Indeed, Fastai notebooks are written down aiming at linux systems, so if you call, for example, ls -la | head, it won’t work (quite obviously) on Windows.

Accessing the workstation remotely:
one may want to log in into such workstation remotely. In that case, there are various options, for example:

Using remote desktop (mind that it’s slow if you have a slow or high-latency connection)
Just leaving the notebook server on (unpractical: you would not be able to run administration tasks)
Using the Windows Subsystem for Linux, AKA “linux on windows” with tmux (install LoW from windows store)
Using an ssh server (which, contrarily to popular belief, is natively supported by Windows, although a bit clumsy to get working. Google for it).


Fastai Installation Error - Maybe PyTorch
(George) #126

Here is the list.

asn1crypto 0.24.0 py36_0
awscli 1.14.46
bcolz 1.1.2 py36h00f5784_0
beautifulsoup4 4.6.0
bleach 2.1.2 py36_0
bokeh 0.12.14 py36_0
botocore 1.8.50
bzip2 1.0.6 h9a117a8_4
ca-certificates 2017.08.26 h1d4fec5_0
certifi 2018.1.18 py36_0
cffi 1.11.4 py36h9745a5d_0
chardet 3.0.4 py36h0f667ec_1
click 6.7 py36h5253387_0
cliff 2.8.0
cloudpickle 0.5.2 py36_1
cmd2 0.8.0
colorama 0.3.7
configparser 3.5.0
cryptography 2.1.4 py36hd09be54_0
cssselect 1.0.3
cuda90 1.0 h6433d27_0

cudatoolkit 8.0 3
cudnn 7.0.5 cuda8.0_0
cycler 0.10.0 py36h93f1223_0
cymem 1.31.2 py36_0
cytoolz 0.8.2 py36h708bfd4_0
dask 0.17.1 py36_0
dask-core 0.17.1 py36_0
dbus 1.12.2 hc3f9b76_1
decorator 4.2.1 py36_0
dill py36h644ae93_0
distributed 1.21.1 py36_0
docutils 0.14
entrypoints 0.2.3 py36h1aec115_2
expat 2.2.5 he0dffb1_0
feather-format 0.4.0
fontconfig 2.12.4 h88586e7_1
freetype 2.8 hab7d2ae_1
ftfy 4.4.3 py36_0
glib 2.53.6 h5d9569c_2
gmp 6.1.2 h6c8ec71_1
graphviz 0.8.2
gst-plugins-base 1.12.4 h33fb286_0
gstreamer 1.12.4 hb53b477_0
hdf5 1.10.1 h9caa474_1
heapdict 1.0.0 py36_2
html5lib 1.0.1 py36h2f9c1c0_0
icu 58.2 h9c2bf20_1
idna 2.6 py36h82fb2a8_1
intel-openmp 2018.0.0 hc7b2577_8
ipykernel 4.8.2 py36_0
ipython 6.2.1 py36h88c514a_1
ipython_genutils 0.2.0 py36hb52b0d5_0
ipywidgets 7.1.2 py36_0
isoweek 1.3.3
jedi 0.11.1 py36_0
jinja2 2.10 py36ha16c418_0
jmespath 0.9.3
jpeg 9b h024ee3a_2
jsonschema 2.6.0 py36h006f8b5_0
jupyter 1.0.0 py36_4
jupyter-contrib-core 0.3.3
jupyter-contrib-nbextensions 0.4.0
jupyter-highlight-selected-word 0.1.0

jupyter-latex-envs 1.4.3 jupyter-nbextensions-configurator 0.4.0 jupyter_client 5.2.2 py36_0 jupyter_console 5.2.0 py36he59e554_1 jupyter_core 4.4.0 py36h7c827e3_0 kaggle-cli 0.12.13 libedit 3.1 heed3624_0 libffi 3.2.1 hd88cf55_4 libgcc-ng 7.2.0 h7cc24e2_2 libgfortran-ng 7.2.0 h9f7466a_2 libiconv 1.15 h63c8f33_5 libpng 1.6.34 hb9fc6fc_0 libsodium 1.0.15 hf101ebd_0 libstdcxx-ng 7.2.0 h7a57d05_2 libtiff 4.0.9 h28f6b97_0 libxcb 1.12 hcd93eb1_4 libxml2 2.9.7 h26e45fe_0 locket 0.2.0 py36h787c0ad_1 lxml 4.1.1 lzo 2.10 h49e0be7_2 markupsafe 1.0 py36hd9260cd_1 matplotlib 2.1.2 py36h0e671d2_0 MechanicalSoup 0.8.0 mistune 0.8.3 py36_0 mizani 0.4.4 mkl 2018.0.1 h19d6760_4 msgpack-numpy 0.4.1 py36hfef8c07_0 msgpack-python 0.5.5 py36h6bb024c_0 murmurhash 0.28.0 py36_0 nbconvert 5.3.1 py36hb41ffb7_0 nbformat 4.4.0 py36h31c9010_0 ncurses 6.0 h9df7e31_2 notebook 5.4.0 py36_0 numexpr 2.6.4 py36hc4a3f9a_0 numpy 1.14.1 py36h3dfced4_1 olefile 0.45.1 py36_0 opencv-python openssl 1.0.2n hb7f436b_0 packaging 16.8 py36ha668100_1 palettable 3.1.0 pandas 0.22.0 py36hf484d3e_0 pandas-summary 0.0.41 pandoc hea2e7c5_1 pandocfilters 1.4.2 py36ha6701b7_1 parso 0.1.1 py36h35f843b_0 partd 0.3.8 py36h36fd896_0 11.0 py36_0 pathlib 1.0.1 py36_0 patsy 0.5.0 py36_0 pbr 3.1.1 pcre 8.41 hc27e229_1 PDPbox 0.1 pexpect 4.4.0 py36_0 pickleshare 0.7.4 py36h63277f8_0 pillow 5.0.0 py36h3deb7b8_0 pip 9.0.1 py36h6c6f9ce_4 plac 0.9.6 py36_0 plotnine 0.3.0 preshed 1.0.0 py36_0 prettytable 0.7.2 progressbar2 3.34.3 prompt_toolkit 1.0.15 py36h17d85b1_0 psutil 5.4.3 py36h14c3975_0 ptyprocess 0.5.2 py36h69acd42_0 pyarrow 0.8.0 pyasn1 0.4.2 pycparser 2.18 py36hf9f622e_1 pygments 2.2.0 py36h0d3125c_0 pyopenssl 17.5.0 py36h20ba746_0 pyparsing 2.2.0 py36hee85983_1 pyperclip 1.6.0 pyqt 5.6.0 py36h0386399_5 pysocks 1.6.7 py36hd97a5b1_1 pytables 3.4.2 py36h3b5282a_2 python 3.6.4 hc3d631a_1 python-dateutil 2.6.1 py36h88d3b88_1 python-utils 2.3.0 pytorch 0.3.1

py36_cuda9.0.176_cudnn7.0.5_2 [cuda90] pytorch
pytz 2018.3 py36_0
pyyaml 3.12 py36hafb9ca4_1
pyzmq 16.0.3 py36he2533c7_0
qt 5.6.2 hd25b39d_14
qtconsole 4.3.1 py36h8f73b5b_0
readline 7.0 ha6073c6_4
regex 2017.4.5 py36_0
requests 2.18.4 py36he2e5f8d_1
rsa 3.4.2
s3transfer 0.1.13
scikit-learn 0.19.1
scipy 1.0.0 py36hbf646e7_0
seaborn 0.8.1 py36hfad7ec4_0
send2trash 1.5.0 py36_0
setuptools 38.5.1 py36_0
simplegeneric 0.8.1 py36_2
sip 4.18.1 py36h51ed4ed_2
six 1.11.0 py36h372c433_1
sklearn-pandas 1.6.0
sortedcontainers 1.5.9 py36_0
spacy 2.0.5 py36hf484d3e_0
sqlite 3.22.0 h1bed415_0
statsmodels 0.8.0 py36h8533d0b_0
stevedore 1.28.0
tblib 1.3.2 py36h34cf8b6_0
termcolor 1.1.0 py36_0
terminado 0.8.1 py36_1
testpath 0.3.1 py36h8cadb63_0
thinc 6.10.1 py36hd61447b_0
tk 8.6.7 hc745277_3
toolz 0.9.0 py36_0
torchtext 0.2.1
torchvision 0.2.0
tornado 4.5.3 py36_0
tqdm 4.19.4 py36ha5a5176_0
traitlets 4.3.2 py36h674d592_0
ujson 1.35 py36_0
urllib3 1.22 py36hbe7ace6_0
wcwidth 0.1.7 py36hdf4376a_0
webencodings 0.5.1 py36h800622e_1
wheel 0.30.0 py36hfd4bba0_1
widgetsnbextension 3.1.4 py36_0
wrapt 1.10.11 py36h28b7045_0
xz 5.2.3 h55aa19d_2
yaml 0.1.7 had09818_2
zeromq 4.2.2 hbedb6e5_2
zict 0.1.3 py36h3a3bf81_0
zlib 1.2.11 ha838bed_2


(ecdrid) #127

So the environment has everything…
Still the error?

Try firing jupyter notebook and redirect to the directory’s notebooks



Hi Om,
I am also facing this error

—> 76 from torch._C import *
78 all += [name for name in dir(_C)

ImportError: DLL load failed: The specified module could not be found.

Are you able to overcome this error?


(Sam) #129

I am also experiencing similar challenge.
My environment is Windows10, CUDA80_CUDNN51
(6, 1)
‘GeForce GTX 1050 Ti’

GPU-Z shows no GPU Load

I wonder if I should insert line
learn.cuda() after
learn = ConvLearner.pretrained(arch, data, precompute=True)

Any suggestions are welcome.
Am just afraid of installingt CUDA90 and CUDNN7 at this time since not sure of Tensorflow support

1 Like

(Sam) #130

I confirm this is resolved for me.


seems to have done the trick
epoch time improved to 12 min from 1 hr 24 min

GTX 1050Ti is a Liliput amongst all Goliath that people seem to be using


(Abdul Muqsit Abbasi) #131

Cannot seem to solve this problem.


(Sam) #132

I take back my earlier comment. :sleepy:
inserting line


has not solved the problem.
instead a new error:

AttributeError: ‘ConvLearner’ object has no attribute ‘cuda’


(ecdrid) #133

(ecdrid) #134

Should the model by default use Your GPU.?

Try runningg on some sample tutorial programs to check whether your current configuration is making PyTorch/TF/Keras use your GPU…


(Abdul Muqsit Abbasi) #135

I have been trying to find a way around the gpu. I’ll train my networks on another system. Is it possible to follow these tutorials without GPU?


(Sam) #136


It does use GPU…just that the activity seen at GPU-Z suggests that the GPU is starved of data. I think I should play a little with parameters like num_workers in the ImageClassifierData. I also think that a SSD would work better i/o a HDD.
Currently what I see is that GPU load shows a pulse with 90% load and is silent for a few seconds and again gets a spike and so on.


(Dominique Gilleman) #137

I had the same error.

The only way so solve it, i’ve re-created an Anaconda environment with Pytorch 3.1 and fastai as:

Now it’s fine.


(nok) #138

Same error, no luck, looking for solution. I think the previous version was ok as I successfully built before, but since 1/2 weeks ago I rebuild it on other computer it fails.


(Jeremy Howard (Admin)) #139

FYI I’ve done nearly all development of part 2 so far on my windows laptop (surface book 15 inch) and haven’t had a single issue so far. So Windows support in fastai/pytorch is looking really solid!


(Igor Kasianenko) #140

Hi, do you use 16 GB laptop?

I run into MemoryError in lesson 2, with my 16GB laptop, and this post workaround solved this problem.


(Hafidz Zulkifli) #141

Words can’t describe how glad I am to hear that :smile:

1 Like

(Om) #142

No, Abhishek. I tried all way and did not get much help. I am using paperspace until I have working setup.