- Conda Python 2.7
- Python Conda Installation
- Python Conda Download
- Best Python Installation For Mac Brew Condado
Macでbrew install opencvが使える一方で pip install opencvやconda install opencvが使えます。 この違いはなんでしょうか。 またどのように違いを把握したり、勉強すればいいのか手がかりをご存知でしょうか。 brewで入れた場合はgitを落としてmakeした場合と同じで.
Prerequisites¶
- Python interpreter
- Adjust your path
- Packaging tools
Python interpreter¶
- It’s easy to install multiple versions of python on a Mac computer using installers from python.org, Homebrew, Conda, or other sources.This could create conflicts if a user wants to run one version of python but bash calls a different version instead.
- And Conda for Mac is a Python Package Manager but also an amazing Python Environment Manager. So with just few Conda Commands you can set up a totally Separate Environment to run that different version of Python, while continuing to run your usual version of Python in your normal Environment.
- Aug 26, 2020 If you are on Linux, then you may have cmake installed, and you can install boost with sudo apt-get install libboost-all-dev I'm on a Mac, and I installed cmake with conda and boost with brew.
Install Python for your operating system. Consult the official Python documentation for details.
You can install the Python binaries from python.org. Alternatively on macOS, you can use the homebrew package manager.
Adjust your path¶
Ensure that your
bin
folder is on your path for your platform. Typically ~/.local/
for UNIX and macOS, or %APPDATA%Python
on Windows. (See the Python documentation for site.USER_BASE for full details.)UNIX and macOS¶
For bash shells, add the following to your
.bash_profile
(adjust for other shells):Remember to load changes with
source~/.bash_profile
or open a new shell session.Windows¶
Ensure the directory where cookiecutter will be installed is in your environment’s
Path
in order to make it possible to invoke it from a command prompt. To do so, search for “Environment Variables” on your computer (on Windows 10, it is under SystemProperties
–> Advanced
) and add that directory to the Path
environment variable, using the GUI to edit path segments.Example segments should look like
%APPDATA%PythonPython3xScripts
, where you have your version of Python instead of Python3x
.You may need to restart your command prompt session to load the environment variables.
See also
See Configuring Python (on Windows) for full details.
Unix on Windows
Aug 11, 2018 Jana Gana Mana, Indian National Anthem. Royalty free, copyright free usage. Checking copyright strike to use in YouTube video with monetization. If you see A. Jan 01, 2002 Play Jana Gana Mana (Instrumental) Song by Unni Krishnan from the Tamil album National Patriotic Songs. Listen Jana Gana Mana (Instrumental) song online, free on Gaana.com. Download Royalty Free Jana Gana Mana, i.e The National Anthem of India in WAV (16bit, 44.1Khz) and MP3 (320Kbps, 44.1Khz). Jana gana mana song instrumental free download.
You may also install Windows Subsystem for Linux or GNU utilities for Win32 to use Unix commands on Windows.
Packaging tools¶
pip
and setuptools
now come with Python 2 >=2.7.9 or Python 3 >=3.5. See the Python Packaging Authority’s (PyPA) documentation Requirements for Installing Packages for full details.Install cookiecutter¶
At the command line:
Or, if you do not have pip:
Though, pip is recommended.
Or, if you are using conda, first add conda-forge to your channels:
Once the conda-forge channel has been enabled, cookiecutter can be installed with:
Alternate installations¶
Homebrew (Mac OS X only):
Pipsi (Linux/OSX only):
Debian/Ubuntu:
Upgrading from 0.6.4 to 0.7.0 or greater¶
First, read History in detail. There are a lot of majorchanges. The big ones are:
- Cookiecutter no longer deletes the cloned repo after generating a project.
- Cloned repos are saved into ~/.cookiecutters/.
- You can optionally create a ~/.cookiecutterrc config file.
Upgrade Cookiecutter either with easy_install:
Or with pip:
Then you should be good to go.
The title of the page isn’t a hyperbole. If you have every tried to use Python beyond toy problems on Windows, you will have struggled with library clashes, 32/64 bit versions, ghost libraries (that seemed to be installed, but can’t be called).
As someone who uninstalled and reinstalled Python eight times in the last four weeks, let me tell you, getting Python working perfectly on Windows isn’t easy.
“But Mr T,” you say, “what’s the problem? You go to python.org and just download it. What’s the big deal?”
Conda Python 2.7
(Note: Lots of people have taken the previous sentence as an insult. It is not, and I apologise if it came out that way. All I meant was, in this day and age, it’s a shame there is no good packager for Python on Windows).
But I found that as soon as you try to do anything more complicated, like install libraries which need to be compiled (like numpy or scipy), the official build starts falling down. For my upcoming course on Python, I needed a lot of third party libraries, and I found that Python’s packaging system is really broken.
Here are some of the few Python versions I’ve tried:
1. The official from Python.org: Especially on Windows, this is good only for learning. I didn’t find it very stable, and even installing basic things like Virtualenv gave me problems.
Python Conda Installation
2. The version from ActiveState: ActiveState have a version of Python, and it’s a lot more stable than the official version. It also makes it easy to install packages, and for a long time, this is what I used. But then I tried to install OpenCv, and got problems with versions. I decided to re-install Python, and that’s when I hit problems.
For some stupid reason, ActiveState install libraries in the C:users<name>roaming region. These libraries take precedence over the local files (maybe due it being higher on the path hierarchy). Anyway, even after installing a different Python build (from Conda, see below), I kept getting library clashes which I couldn’t trace. I blamed Conda and spent weeks investigating obtuse error messages. I finally realised that ActiveState was to blame. The path to Python libraries must have been put in the registry or something, because even when I deleted the folders, it still looked for them in the Roaming folders.
Python Conda Download
I had to reinstall ActiveState Python, remove the libraries, and then uninstall it again.
Why am I telling you this? To show you how hard getting Python running can be on Windows. Recently, I discovered Anaconda, and that’s what I recommend now.
Why am I telling you this? To show you how hard getting Python running can be on Windows. Recently, I discovered Anaconda, and that’s what I recommend now.
3. Anaconda
Based on the open source Conda packaging system, Anaconda is the best Python distribution I have found till now. For one, it comes with all the scientific libraries like numpy, scipy etc preinstalled, so you don’t have to worry about messing with compiling them yourself.
Based on the open source Conda packaging system, Anaconda is the best Python distribution I have found till now. For one, it comes with all the scientific libraries like numpy, scipy etc preinstalled, so you don’t have to worry about messing with compiling them yourself.
Second, it does not put important stuff in hidden folders (as far as I can see). Uninstalling it is easy and works.
Best Python Installation For Mac Brew Condado
Conda isn’t perfect, as I couldn’t get its environment system to work. But it’s a lot better than anything out there, and the only one I would recommend, at least on Windows
To install new packages, first try to use Conda install. If there is no Conda package, try pip, and then compiling from source (but never use easy_install).
In conclusion
Stop struggling with Python on Windows. Avoid distributions with fancy install methods (I’m looking at you, ActiveState). Install the Anaconda build, preferably 32 bit (as some libraries aren’t available for 64 bit, and you will get library clashes).