Installing & Setting Up Environment

Before diving into deep learning projects, it is essential to set up a proper development environment. A well-configured environment ensures that all libraries, frameworks, and tools work seamlessly, reducing errors and improving productivity. This lesson will guide you through installing Python, deep learning frameworks, and configuring your environment for AI development.

Step 1: Install Python
Python is the primary programming language for deep learning. You can install Python using:

  • Anaconda (Recommended for Beginners): Comes with Python, Jupyter Notebook, and common libraries pre-installed. Download Anaconda from https://www.anaconda.com/products/individual
  • Official Python Installer: Install Python from the official website. Download Python from https://www.python.org/downloads/

Step 2: Install a Code Editor
A code editor helps write and manage your Python scripts efficiently. Popular choices include:

  • VS Code – Lightweight, customizable, with extensions for Python and AI development.
  • PyCharm – Feature-rich IDE for Python development.
  • Jupyter Notebook / JupyterLab – Interactive coding environment, ideal for experiments.

Step 3: Install Deep Learning Frameworks
Install the frameworks required for deep learning projects:

  • TensorFlow
pip install tensorflow
  • PyTorch
pip install torch torchvision
  • Keras (if using standalone)
pip install keras

Step 4: Install Supporting Libraries
Other essential libraries for data handling and visualization:

pip install numpy pandas matplotlib seaborn scikit-learn

Step 5: Set Up Virtual Environments (Optional but Recommended)
Virtual environments help isolate project dependencies:

# Create a virtual environment
python -m venv myenv# Activate environment (Windows)
myenv\Scripts\activate# Activate environment (Mac/Linux)
source myenv/bin/activate# Install required packages inside environment
pip install tensorflow torch keras numpy pandas matplotlib seaborn

Step 6: Verify Installation
Ensure that Python, frameworks, and libraries are installed correctly:

import sys
import tensorflow as tf
import torch
import kerasprint("Python version:", sys.version)
print("TensorFlow version:", tf.__version__)
print("PyTorch version:", torch.__version__)
print("Keras version:", keras.__version__)

Step 7: Optional – GPU Setup for Faster Training
For accelerated deep learning, configure GPU support:

  • NVIDIA GPU Drivers – Install latest drivers for your GPU.
  • CUDA Toolkit – Required for TensorFlow and PyTorch GPU support.
  • cuDNN Library – Deep learning primitives optimized for NVIDIA GPUs.
  • Verify GPU availability:
import tensorflow as tf
print("Num GPUs Available:", len(tf.config.list_physical_devices('GPU')))

Lesson Summary
In this lesson, you learned how to install Python, set up a code editor, install deep learning frameworks, supporting libraries, and configure virtual environments. Proper environment setup ensures smooth development and faster experimentation in deep learning projects.

Home » Deep Learning Foundations (Beginner) > Deep Learning Frameworks > Installing & Setting Up Environment