My last post on Python with Windows got almost 5000 views in a day, and hundreds of comments on Reddit, and 22+ on my own. The most common comment was You Loser, can’t even install Python? You’re pathetic. The second most common comment was I faced the exact same problem, and decided to move away from Windows (& in some cases, Python itself).
This makes me sad. Clearly there is a problem. Worse than that, there is macho posturing and rudeness which is completely unhelpful to beginners.
The most interesting comment I got was from Sebastian, the runs the the DashingD3.js tutorial website:
“I teach live D3.js workshops where we use Python on the command line for running the simplest web server possible. EVERY SINGLE TIME – there are one to two people who have a windows computer instead of mac / linux / unix based computer. EVERY SINGLE TIME – this person falls behind because they have to spend somewhere between 10-60 minutes installing python on WIndows, getting python on their PATH, being able to run “python -m SimpleHTTPServer” on their command line”
Sebastian’s experience isn’t even that unique. If you teach Python, or regularly have to deal with beginners, you will see this problem again and again. Which is why I’ve trying to find solutions, and that’s what led me to Anaconda.
Anaconda: Why it’s useful
If you have struggled with Python on Windows, you might want to look at Anaconda. The advantages it has are:
1. Installs in one place only, no spreading Python libraries all over the place (I’m looking at you, Activestate). That means it’s easy to upgrade/remove. And it automatically adds itself to the path on Windows, solving a big pain for beginners.
2. Comes with most libraries you may need installed. This includes libraries like numpy, scipy which normally have to be compiled.
3. It comes with a fairly good packaging manager, Conda, as well as Pip.
Always use the package manager to install libraries. Try not to download and install them from online sources, as they might not be easy to remove. Especially on Windows, where nothing is ever uninstalled and lives like a ghost in the registry.
4. It allows you to create isolated environments. (But not really. see below)
Anaconda: Where it doesn’t work
But not everything is perfect with Anaconda. I found 2 big problems:
1. While you can create environments, activating them doesnt work, at least on Windows. I had to actually go into the directory to use the environment I created(which sort of beats the whole purpose). Now, this might be a problem with the Windows path variable, but it still reflects badly on Anaconda. I’d stick to VirtualEnv for now. (The problem with VirtualEnv is that it only allows you to create Python environments, while Conda environments are more flexible, ie, you can have non-Python libraries as well).
2. Anaconda allows you to add new packages(ones they don’t support) via an extenal service (binstar.org). When I tried to install OpenCv from it, however, it didn’t work, even though I tried to download from 3-4 different repositories. Again, it might be a problem of the people who uploaded them, but still. Since they market this feature on their website, they must also ensure it works.
In spite of these failures, I would still recommend Anaconda, as it’s miles better than anything out there. If you are on Windows, nothing beats Anaconda if you want a hassle free Python experience.PS: Want a free 1+ hour video course, Introduction to Web Scraping and Data Analysis? Also get a free mini-book, Python: From Apprentice to Master. I will never spam you. Unsubscribe anytime.