Skip to content

WizelineIntroToPythonML/02-setup

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Session 02

Setup Python locally

Course Hero

Moneyball Discussion

Moneyball Poster

Article Discussion

How a Math Genius Hacked OkCupid to Find True Love Article Image

Anaconda Distribution

Anaconda Distribution

There is a way to install and use Python that is different to the ¨normal¨one, Anaconda Distribution.

Anaconda Distribution

Anaconda works great when you are doing Data Analysis and Machine Learning, and not ¨normal¨ Python development. In our case we won´t use it because it requires for us to buy licenses if we are going to use it in a big company.

In any case is a great option, worth exploring for learning and small projects, or paying in the case of commercial use.

Web Page

Check if Python is already installed

Open a Terminal (or Command) window.

Type python3 --version.

We expect the result to be Python 3.8 or more. Currently the latest version (2022-07-13) is 3.10.5.

If we don't have Python installed it shows like this:

If we have Python installed it shows like this:

Python Installed

If it is not installed it shows like this:

Python Missing

If we already have Python Installed we are good to go

Python Installation

The process is different for each Operating System.

The easy way

Install from the Python Webpage

Installation menu

MacOS installation using Homebrew

brew install python3

Linux

sudo apt install python3

OR

sudo yum install python3

Create a Virtual Environment

  • Confirm Python is installed running python3 --version in a terminal or console.
  • Create a directory for the Bootcamp.
  • Move to the new directory.
  • Create the virtual environment with: python3 -m venv venv

The command reads as follows: python3 --- Use the Python 3 interpreter -m venv --- Use a module named venv > venv -- Create the new Virtual Environment in the venv directory

  • Activate the virtual environment
    • In MacOS and Linux run source venv/bin/activate
    • In Windows run .\env\Scripts\activate

Virtual Environment Creation

  • Confirm you are using the virtual environment
    • In MacOS and Linux run which python
    • In Windows run where python

Full Virtual Environments documentation HERE

Install and Run Jupyter

Jupyter Logo

Run in the terminal pip install jupyterlab

Jupyter installation start

Jupyter installation end

Run Jupyter Lab with jupyter-lab

Full Jupyter Install Documentation HERE

Feedback

Your Feedback Matters

Please helps us filling up the Feedback Form.

Next session

We will learn how to use IDEs (in particular Visual Studio Code), Git and GitHub.

Homework:

Read the article: We Can Protect the Economy From Pandemics. Why Didn't We?

Nathan Wolfe Cover

Optional See the movie: The Big Short

Movie Poster

About

Installing and using Python locally in our computer

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published