0% found this document useful (0 votes)
32 views2 pages

Climate Change Tutorial Class #0 For B2 Student, SA Department March 2018 I. How To Install Python On Windows

This document provides instructions for installing Python and related packages on Windows, MacOS, and Ubuntu systems. For Windows, it describes downloading Python from the official website and using get-pip.py to install pip. It recommends downloading binary files for NumPy, Matplotlib, netCDF4, PyProj, and Basemap from an unofficial website and using pip to install them. For MacOS and Ubuntu, it lists commands to install Python, pip, and the various data science packages through pip and by compiling source codes for Basemap.

Uploaded by

Hanh Tran
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
32 views2 pages

Climate Change Tutorial Class #0 For B2 Student, SA Department March 2018 I. How To Install Python On Windows

This document provides instructions for installing Python and related packages on Windows, MacOS, and Ubuntu systems. For Windows, it describes downloading Python from the official website and using get-pip.py to install pip. It recommends downloading binary files for NumPy, Matplotlib, netCDF4, PyProj, and Basemap from an unofficial website and using pip to install them. For MacOS and Ubuntu, it lists commands to install Python, pip, and the various data science packages through pip and by compiling source codes for Basemap.

Uploaded by

Hanh Tran
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 2

Climate Change

Tutorial class #0 for B2 Student, SA Department


March 2018
I. HOW TO INSTALL PYTHON ON WINDOWS

1) Install Python for Windows


https://www.python.org/downloads/release/python-2713/
2) Download get-pip.py to C:\Python27\
 Get-pip.py can be downloaded at https://bootstrap.pypa.io/get-pip.py or
https://github.com/pypa/get-pip
 Open Windows command windows (Start  type “cmd” at the box “Search
programs and files”)
 At the command prompt, go to C:\Python27\ by typing: “cd C:\Python27\
 Type: python get-pip.py

3) Please note the Unofficial Windows Binaries for Python Extension Packages:
http://www.lfd.uci.edu/~gohlke/pythonlibs/
You can download the needed binaries and to install it, pls read carefully the following
instructions:

4) To install Numpy
http://www.lfd.uci.edu/~gohlke/pythonlibs/#numpy
 download file numpy-1.11.3+mkl-cp27-cp27m-win_amd64.whl to the folder:
C:\Python27\Scripts
 At the command prompt, navigate to the above directory and type:
pip2.7.exe install “numpy-1.11.3+mkl-cp27-cp27m-win_amd64.whl”
5) To install MatPLOTLIB/ NETCDF4/ PYPROJ/ BASEMAP
 Go to http://www.lfd.uci.edu/~gohlke/pythonlibs/ to download
o matplotlib-1.5.3-cp27-cp27m-win_amd64.whl
o netCDF4-1.2.8-cp27-cp27m-win_amd64.whl
o pyproj-1.9.5.1-cp27-cp27m-sin_amd64.whl
o basemap-1.1.0-cp27-cp27m-win_amd64.whl
 Follow similar installation steps as for Numpy
II. HOW TO INSTALL PYTHON ON MacOS

III. HOW TO INSTALL PYTHON ON UBUNTU


1) Install python2.7
2) Download: get-pip.py
3) sudo python get-pip.py
4) sudo pip install numpy
5) sudo pip install matplotlib
6) sudo pip install netcdf4
7) Install Basemap
1. sudo pip install geos
2. sudo pip install proj
3. # download basemap source code from
https://sourceforge.net/projects/matplotlib/files/matplotlib-
toolkits/basemap-1.0.7
4. # untar the source code, cd basemap-1.x.x/geos-3.3.3
5. export GEOS_DIR=/usr/local (or where you want)
6. ./configure --prefix=$GEOS_DIR
7. sudo make; sudo make install
8. cd .. (i.e. go to the basemap-1.x.x folder)
9. sudo python setup.py install

You might also like