Python Course

Agenda

Toggle sub-themes

Python basics

Course Intro.

  1. About Iva E. Popova
  2. Course Resources.

Introduction to CLI, Terminal

  1. CLI and "terminal" overview
  2. Command Prompt Basics
  3. Current Working Directory (CWD)
  4. Viewing Folder Contents
  5. Navigating Through Folders

Python Introduction: interpreters, distributions, IDEs.

  1. What's the use of Python?
  2. Python distributions.
  3. Install and setting up Python (on Windows, Mac, Linux).
  4. Run Python Code in CLI
  5. Python IDEs and text editors.
  6. Write Python in VS Code

Core types: int, float, complex, strings. Variables.

  1. What's in a Python program?
  2. Numeric Types: integers, floating point numbers, and complex numbers.
  3. Python arithmetic.
  4. Strings. Common operations.
  5. Variables and naming conventions.
  6. How to comment our code?
  7. Exercises.

Basic IO. String formatting

  1. Escape Sequences.
  2. Basic IO.
  3. Formatted strings.

Booleans and Logical operations. Conditional Statements. Expressions and Operator precedence

  1. Boolean type.
  2. Logical operators.
  3. if:elif:else statements.
  4. Statement vs Expression in Python.
  5. Operator precedence.
  6. Exercises

Data structures: Sequence Types (list, tuple,range objects).

  1. Lists
  2. Tuples
  3. Range Objects
  4. Strings as sequence

Data structures: Dictionaries and Sets

  1. Dictionaries
  2. Operations with Dictionaries
  3. Sets
  4. Set Operations

Loops in Python: for, while, break, continue.

  1. while/do loops.
  2. for loops.
  3. break, continue.

Functions

  1. What are Functions?
  2. Function Definition
  3. Function Call
  4. Function Parameters (positional, keywords)
  5. Arguments unpacking - the ** operator
  6. Function Return Values
  7. Variables Scope

OOP: Classes, encapsulation, inheritance, operator overloading.

  1. OOP - Main Concepts
  2. Classes and Objects in Python
  3. Attributes
  4. Class Constructor
  5. Magic (dunder) methods
  6. Encapsulation and Data Hiding
  7. Inspecting Classes and Objects.
  8. Inheritance
  9. Method overriding
  10. Operator overloading

Exceptions: raising and handling

  1. What are Exceptions
  2. Exceptions Handling
  3. Handling different Exception Types
  4. Raising Exceptions

Iterators. Generators. Comprehensions

  1. Iterators in Python
  2. Iterables vs Iterators
  3. Creating custom Iterator Types
  4. Generators in Python
  5. Creating custom Generator function
  6. Custom Generator vs Custom Iterator - example
  7. List, dict and generator comprehensions

Functional topics: map/filter/reduce.

  1. map/filter/reduce.

Organizing code: imports, modules, packages

  1. Creating a custom Python modules
  2. Import module
  3. Module alias
  4. Import object from module
  5. Where import looks for a module?
  6. Python's built-in and third-party modules
  7. Packages in Python
  8. Import-related module attributes (__name__, __file__)

Practicalities: Virtual Environments

  1. PIP - the Python Package Manager
  2. Python Virtual Environments

Practicalities: linting, formating, documentation

  1. Python Best Practises: PEP8 && PEP20
  2. Linters
  3. Formaters
  4. Documentation Conventions

Notable Standard Library Modules

  1. sys - interface with Python Interpreter
  2. command line arguments

Date and Time support

  1. datetime.date
  2. datetime.time
  3. datetime.datetime
  4. datetime.timedelta

Using the file-system

  1. Introduction to OS Module
  2. Basic Concepts: Paths and Current Working Directory
  3. Directory Manipulations
  4. Files Manipulations

Various formats handling

  1. Parse JSON
  2. Parse CSV
  3. Parse XML

Encoding. Unicode in Python

  1. Unicode Overview
  2. Python’s Unicode Support
  3. Encode-Decode Flow
  4. encode() and decode() functions
  5. base64

Reflection in Python

  1. dir(), type() and id() functions
  2. hasattr(), getattr() and setattr()
  3. isinstance() and issubclass() functions
  4. the inspect built-in module

Debugging Python applications

  1. How to Debug A Python Code?
  2. Overview of VSCode Debugger
  3. Debug menu
  4. Setup/Launch configurations
  5. Basic debug Commands (Start/Stop; Continue/Pause; Step Over/Into/Out; )
  6. Set Breakpoints
  7. Watch Variables

Regular Expressions in Python

  1. Regular Expressions Overview
  2. Regular Expressions in Python - the re module

Parallel programming: multithreading and multiprocessing

  1. Shape the concepts: multithreading, multiprocessing
  2. Example using the built-in multiprocessing module

Data science basics. Working with Numpy, Pandas and Jupyter Notebooks.

  1. Data Science process overview.
  2. Get familiar with numpy and pandas
  3. Working with Jupiter Notebook

Databases: SQLAlchemy

  1. What is an ORM?
  2. SQLAlchemy - the Python ORM
  3. Connect, Declare a Mapping,Create a Schema
  4. Demo example with SQLAlchemy and SQLite3

GUI: PyQt.

  1. PyQt - Overview
  2. Create a simple desktop GUI app with PyQt

Web Programming with Python. Django. FastAPI.

  1. An overview of Django -The (Python) web framework for perfectionists with deadlines.
  2. A demo example of ToDo List app with FastAPI
  3. A demo example of ToDo List app with Django

Course Project

Course Project Task