- orgranizace Py projektů:
- pip
- requirements.txt
- venv
- materiály:
- repozitář balíčků https://pypi.org
- virtualenv vs venv vs pyenv... https://stackoverflow.com/questions/41573587/what-is-the-difference-between-venv-pyvenv-pyenv-virtualenv-virtualenvwrappe
- pipenv (officially recommended) https://realpython.com/pipenv-guide/
-
ipython - https://ipython.readthedocs.io/en/stable/overview.html
- příklad pro
%load
: https://jsonplaceholder.typicode.com/todos/1
- příklad pro
-
jupyter notebook - https://jupyter.org/documentation
-
základy:
- numpy
- matplotlib
-
examples for live presentation:
-
other related libraries (not part of presentation):
- SciPy - library for mathematics, science, and engineering. https://docs.scipy.org/doc/scipy/reference/tutorial/general.html
- Pandas - library for data analysis. https://pandas.pydata.org/
- OpenCV - image processing (
pip install cv2
). https://docs.opencv.org/master/d6/d00/tutorial_py_root.html
-
úvod do tříd
- zapouzdření,
- třída vs. instance,
- self,
- class/inst property
-
inheritance, super()
-
examples for live presentation:
-
homework
-
materiály:
- PEP8
- clean code
- Enum
- examples for live presentation:
- exercise to practise (=called homework before):
- resources:
- pep8 - code style recommendations for Python, https://realpython.com/python-pep8/
- PEP8 song 😃 https://www.youtube.com/watch?v=wNcobO-TAyY
- clean code by examples - https://github.com/zedr/clean-code-python
- Enum - enumeration data type, https://docs.python.org/3/library/enum.html
- pep8 - code style recommendations for Python, https://realpython.com/python-pep8/
- Enum review
- typehints
- testing, pytest
- own defined exceptions
- examples for live presentation:
- exercise to practise
- resources
- mypy - static analysis of code, https://mypy.readthedocs.io/
- testing related:
- https://docs.python-guide.org/writing/tests/
- https://www.youtube.com/watch?v=FjwayiHNI1w
- testing as science https://www.youtube.com/watch?v=FjwayiHNI1w
- mocks, fakes, stubs, spies... - https://www.youtube.com/watch?v=-nJ-ZW_LP7s
- test driven development, https://en.wikipedia.org/wiki/Test-driven_development#Test-driven_development_cycle
- pytest - famous test runner, https://docs.pytest.org/en/stable/
- Pathlib https://docs.python.org/3/library/pathlib.html#correspondence-to-tools-in-the-os-module
- namedtuple https://docs.python.org/3/library/collections.html#namedtuple-factory-function-for-tuples-with-named-fields
- dataclasses https://docs.python.org/3/library/dataclasses.html
- lambda, map, filter, sort
- logging module
- jupyter notebook as presentation
- source jupyter notebook python2.6.presentation.demo.ipynb
- exported self-contained HTML python2.6.presentation.demo.slides.html
- tips for debugging in PyCharm
- examples for live presentation: