Python for Engineering

360 ore de studiu
42 ședințe live
6 luni
    1. Python Language Fundamentals
      The Python Ecosystem & Dev Environment
      • Interpreted languages paradigm • Python 3 ecosystem & popular frameworks by domain • VS Code & PyCharm setup • Jupyter Notebook & Google Colab • Running your first Python script
      Language Syntax - Variables & Basic Types
      • Python keywords & reserved words • Code blocks & indentation • Comments & multi-line statements (PEP 8) • Variables & identifiers • Numeric types: int, float, bool • Strings: str basics • The None singleton • Dynamic typing
      Operators - Expressions & Basic I/O
      • Arithmetic, comparison, logical, assignment operators • Identity operators: is, is not • Operator precedence & order of evaluation • The ternary operator • Reading input from keyboard: input() • Writing to console: print(), f-strings
      Control Flow & Program Structure
      • if / elif / else • while loops • for loops & range() • break, continue, pass • match / case (structural pattern matching)
      Strings & Text Processing
      • String indexing & slicing • Common string methods: strip, split, join, replace, find • String formatting: f-strings, format() • Raw strings & escape sequences • Multiline strings • String immutability
      Functions — Definition - Parameters & Reuse
      • Defining functions: def, return • Positional & keyword arguments • Default parameter values • *args & **kwargs • Variable scope: local vs global • Docstrings
      Python code in practice:
      • Exercises covering syntax, control flow, strings & functions • Code review & debugging practice • Writing clean, readable Python from day one
    2. Organising Code and Data
      Modules, Packages & the Standard Library
      • What is a module: import forms • The __name__ == '__main__' pattern • Packages & __init__.py • Useful standard library modules: os, sys, math, random, datetime, pathlib • Third-party packages overview
      Managing Python Environments (venv, requirements.txt, pyproject.toml)
      • Why isolated environments matter • pyenv — managing Python versions • Creating & activating virtual environments with venv • Installing packages with pip • Freezing dependencies: requirements.txt • Modern project config: pyproject.toml & TOML format • pipx for global tools
      Lists, Tuples, Sets & Dictionaries
      • Lists: creation, indexing, slicing, mutation • Tuples: immutability & unpacking • Sets: uniqueness, set operations • Dictionaries: keys, values, items, nested dicts • Choosing the right data structure • Common patterns: counting, grouping, deduplication
      Comprehensions, Generators & Iterators
      • List, dict & set comprehensions • Conditional comprehensions • The iterator protocol: __iter__, __next__ • Generator functions & yield • Generator expressions • Lazy evaluation & memory efficiency
      Object-Oriented Programming — Basics
      • Classes & objects • __init__ & instance attributes • Instance methods vs class methods vs static methods • Encapsulation & name mangling • __str__ & __repr__ • Dunder methods overview
      Data Classes, NamedTuple & Enum
      • @dataclass — automatic __init__, __repr__, __eq__ • field() — defaults, factories, metadata • Frozen dataclasses • NamedTuple — lightweight immutable records • Enum & IntEnum — named constants • When to use each
      Advanced OOP in practice
      • Inheritance & polymorphism • Abstract base classes • Hands-on refactoring exercise
    3. Understanding Pythonic Code
      Functions as First-Class Citizens
      • Functions as objects: passing & returning functions • Higher-order functions: map(), filter(), sorted() • Lambda expressions: syntax & use cases • functools.partial — pre-filling arguments • Practical patterns with higher-order functions
      Decorators
      • Closures & free variables • Writing a decorator from scratch • functools.wraps — preserving metadata • Decorators with arguments • Stacking multiple decorators • Real-world examples: timing, logging, access control
      Functional Programming in Practice
      • functools: reduce, lru_cache, cached_property, singledispatch • itertools: chain, islice, groupby, product, combinations • Generator pipelines • Lazy evaluation patterns • When functional style improves readability
      File I/O & Context Managers
      • JSON, CSV & pathlib • Context managers: with statement • Parsing & serializing JSON • Files for big data: JSONL, Parquet
      Exceptions & Debugging
      • Exception hierarchy • try / except / else / finally • Raising & re-raising exceptions • Custom exception classes • Writing __enter__ & __exit__ • Debugging in VS Code: breakpoints, watch, call stack • Reading tracebacks
      Type Hints & the Typing System
      • Why type hints matter • Basic annotations: int, str, float, bool, None • Collections: list[int], dict[str, int], tuple • Optional & Union • Type aliases • Running mypy for static analysis
      Advanced Typing
      • TypedDict, Intro to Pydantic • Protocol — static duck typing • Runtime type inspection • Parsing & serializing JSON • Why Pydantic over plain dataclasses for APIs

Tehnologii studiate

Python Language & Ecosystem
  • Python 3
  • venv
  • pip
  • python-dotenv
  • pipx
  • pyenv
Web & API
  • FastAPI
  • Pydantic v2
  • requests
  • asyncio
  • Uvicorn
  • BeautifulSoup
Baze de date & ORM
  • SQLite
  • SQLAlchemy
  • Alembic
Data Science & ML
  • pandas
  • NumPy
  • scikit-learn
  • Matplotlib
  • joblib
  • Seaborn
Testing & Debugging
  • pytest
  • pdb
  • logging
  • unittest.mock
  • Coverage.py
Medii de dezvoltare & Editoare
  • VS Code
  • Jupyter Notebook
  • Google Colab
  • PyCharm

Nivel