Python for Network & Systems Engineers
This is a course for network engineers and systems engineers, devops staff, hardware engineers, and back-end developers.
Some familiarity with programming concepts (in any language) is assumed.
By the end of the course, you will have all the knowledge you need to write and interact with Python code for a variety of purposes, with a particular focus on controlling machines, automating system processes, and interacting with APIs. You will understand the elegance and power of Python and have had experience using several important standard and third-party libraries, including for parsing text and log files, matching strings with regular expressions, and scripting tasks via SSH connections. You will also have learned about consuming and creating web APIs and some best practices in Python for writing maintainable code.
Day 1: Python basics
Day 1 covers how to use Python for general programming tasks, including tips and tricks for making this easy. The syllabus is as follows:
- Setting up your Python development environment (IDE, Jupyter notebook)
- Packages and modules
- Python syntax and concepts: an introduction through examples
- Functions and their arguments
- Essential data types, tips and tricks: strings, tuples, lists
- String methods; input and output of text data (including CSV files)
- Dictionaries and their applications
- Worked example: consuming web APIs
- Raising and handling exceptions
Day 2: Handling, analysing, and presenting data in Python
Day 2 will introduce further important concepts and tools for making the most of Python. In particular, it will give you a comprehensive introduction to reading and writing the most important data formats; slicing, dicing and analysing data in powerful ways, and exploratory data visualisation.
- Further important data types: namedtuples and sets
- Classes and objects
- Reading and writing essential data formats: JSON, CSV, Excel, SQL databases
- Indexing and filtering data in Pandas
- Data fusion: joining & merging datasets
- Summarisation with “group by” operations; pivot tables; hierarchical indices; reshaping data
- Handling dates, times, and time-series
- Interactive visualisation and data exploration with Altair
Day 3: Network and system automation
Day 3 gives you a tour of the amazing standard library and important 3rd-party tools for automating various systems-level tasks with Python:
- Network automation via SSH with Fabric
- Parsing log files with regular expressions
- Handling files & paths; dates, times, and IP addresses
- Cryptographic hashing of file contents (SHA256, MD5 etc.)
- Worked example: finding duplicate files (by contents)
- Compressing and uncompressing data (zip, tar, bzip2 etc.)
- Running external commands as subprocesses
- Process and system monitoring with psutil
- Worked example: automatically sending emails
Day 4: Web APIs and best practices
Day 4 shows you how to automate a variety of further tasks, such as consuming and creating web APIs. It also teaches you about some "best practices" of development using Python:
- Accessing web APIs in more depth (sessions, OAuth)
- Creating web APIs with Flask
- Templating with Jinja2; automatically creating config files (e.g. YAML)
- Python developer tools and debugging tools
- Best practices for maintainability; tips and tricks
- Creating scripts that take command-line arguments
- Creating reusable modules and packages
- Logging and unit testing
We will supply you with printed course notes, cheat sheets, and a USB stick containing kitchen-sink Python installers for multiple platforms, solutions to the programming exercises, several written tutorials, and reference documentation on Python and the third-party packages covered in the course.
- Personal help:
- Your trainer(s) will be available after the course each day for you to ask any one-on-one questions you like — whether about the course material and exercises or about specific problems you face in your work and how to use Python to solve them.
- Food and drink:
- We will provide lunch, morning and afternoon tea, and drinks.
- The course will run from 9:00 to roughly 17:00 each day, with breaks of 45 minutes for lunch and 20 minutes each for morning and afternoon tea.
An internet-connected computer will be provided for you for the training.
There are currently no events. Contact Us to arrange an event in your location.