How to set up Windows 10 for

(Dominique Gilleman) #22

Thanks Andrea,[quote=“balnazzar, post:12, topic:9811, full:true”]

I see some issues:

  1. In torchvision installation instruction, Pip is written with a capital P. I think it won’t work in OSX.
  2. You will end up with two versions of bcolz, one installed with conda, the other by fastai, in the same env.
  3. I think you should explicitly add some instruction for GPU version of pytorch, since a beginner will just copy & paste your instructions no matter whether he has a GPU or not.
  4. Instructions for creating a separate env should be provided, otherwise a beginner will install everything in the base env, which is generally not advisable.

i have updated instructions to install.
On windows, bcolz installed with fastai is failing, it’s needed to be installed with conda first.

(Andrea de Luca) #23



(Chamin Nalinda) #25

Thanks a great deal for the post. While following your instructions, I encountered with an error saying “Failed building wheel for bcolz”. I noted that the “bcolz” dependency does not come default. So I executed “conda install bcolz”. Then run again “pip install fastai”. Then it worked. Hope this helps who came across the same situation :slightly_smiling_face::slightly_smiling_face::slightly_smiling_face:

(ecdrid) #26

If we are not using Linux terminal on Windows then we will not be able to execute code unless we make a lot of changes so that the dir matches
With Windows…

(Jeremy Howard (Admin)) #27

What are you finding happening with bcolz exactly? It’s listed in environment.yml, so I’m confused why you’re having to install it separately. Are you remembering to activate the fastai environment?

(Andrea de Luca) #28

Yes, it was pointed out in “Additional Notes”. Unfortunately, it happens just on Windows: you have to manually install bcolz using conda.

(Andrea de Luca) #29

Yes @jeremy, it just happens on Windows, and it’s independent from env activation. pip install fastai just fails to install bcolz.
Note that pip install fastai does install bcolz flawlessly when executed on Linux.
It’s not a big issue, but Windows users have to be aware of it in order not to get stuck. Maybe it’s better to take it from Additional Notes and put it into the main guide…

(Jeremy Howard (Admin)) #30

Oh I didn’t realize that’s what you’re doing. The recommended method for the course is conda env update, not pip install. The pip version is pretty old FYI.

(Andrea de Luca) #31

I think this could be considered as an occasion for digging deeper into the os python api. Not a big issue, in the end.

(Andrea de Luca) #32

@jeremy I don’t know if I’m understanding you correctly, but you have to pip install fastai the first time you create the fresh env for fastai. Am I wrong?

(Jeremy Howard (Admin)) #33

You are indeed wrong. :slight_smile: You should simply type ‘conda env update’ from the fastai folder cloned from git. You should not use pip to install fastai or its dependencies.

(Andrea de Luca) #34

Great! Thanks, @jeremy. In order to update the windows guide, let me summarize.

  1. Create a new anaconda env.
  2. Install (presumably) PyTorch for windows from peterjc123 repository.
  3. Install git and clone the official repository.
  4. Do a ‘conda env update’ to get everything up and running.

And you are finished. May you confirm? Thanks!

Note: will you have torchvision installed?

(ecdrid) #35

Actually the change needs to be done within the codes also…
Like where ever we have / to \
I had tried to run it on Win10 itself…(it always reports error on specific functions (especially when the validation set is called)))

(Andrea de Luca) #36

Yes, you have to rewrite a bit of code, but just the parts where you call the os for filesystem operations (at least, that’s what I have observed).

(Jeremy Howard (Admin)) #37

That sounds about right. (Of course after step 3 you’ll need to cd into the cloned repo.)

Torchvision should get installed just fine by conda automatically.

(Andrea de Luca) #38

Very good :slight_smile: Thanks!

Of course it woud be great if someone could try and perform a fresh windows installation as per that new guideline.
I’m not too happy at the perspective of compromising my working installation testing with a new env. :thinking:

(Jeremy Howard (Admin)) #39

I’m pretty sure that’s how I tested.

(Andrea de Luca) #40

I updated the guide. If you find time and will to review it, let me know if it’s ok (or edit it yourself straight away :slight_smile: )



I decided to take one for the team and redo my windows install following the new instructions. I am sad to say that they do not work just yet, at least for me. Running the “conda env update” can’t resolve several (10) packages, most notably torchvision. I also tried to update the env outside of the active environment using the -n flag to no avail. We still have some work to do…

(Andrea de Luca) #42

Sorry to hear that. @jeremy reports that conda env update gets everything up and running, but I didn’t quite catch whether he has tested it on both win and linux.

Regardless, what about the older instructions?