6.2 Modular Code Development - CodeRefinery 2025 Mar
Автор: CodeRefinery
Загружено: 3 апр. 2025 г.
Просмотров: 19 просмотров
In this live-coding demo session we take a Python script as starting point which reads data, computes simple statistics, and generates a plot. Together we then improve this code based on suggestions from the audience to arrive at a more reusable code with reusable components. We start in the Jupyter notebook, later move to a Python script/module, introduce testing, and finally introduce and motivate a command line interface to our code.
In this demonstration we use JupyterLab, Python, Pandas, Matplotlib, pytest, and Click. It is also a great demonstration of pair programming.
https://coderefinery.github.io/modula...
00:00 Introduction to the lesson / § Starting questions
17:08 § Our starting task
17:53 Start by coping into a Jupyter notebook and get it to run
19:56 Adjust formatting and stuff
22:58 Loop over multiple temperatures
26:51 Split code into a script file (and run from command line)
29:42 Make functions
32:25 Some debugging
34:59 More generalization and general restructuring
42:44 Generalize the statistics (mean) calculation some
47:45 Command-line interface with click
1:00:32 Add tests
-----
This is part of the CodeRefinery 2025 March workshop. The videos are available to everyone, but may be most useful to the people who attended the workshop and want to review later. Day 1-2: git (individual) Day 3: git (collaborative) Day 4: reproducible research and social coding. Day 5: documentation and Jupyter. Day 6: testing and modular code development.
Playlist: • CodeRefinery workshop 2025 March
Workshop webpage: https://coderefinery.github.io/2025-0...
CodeRefinery: https://coderefinery.org/

Доступные форматы для скачивания:
Скачать видео mp4
-
Информация по загрузке: