Skip to main content

Instructor-led training

Python for Applied Engineers Training in Schertz, Texas

Private Python Programming training for organizations from Hartmann Software Group, delivered onsite in Schertz, Texas or live online.

What you'll learn

This is a 4 - day course that provides a ramp - up to using Python for scientific and mathematical computing. Starting with the basics, it progresses to the most important Python modules for working with data, from arrays, to statistics, to plotting result s. The material is geared towards scientists and engineers. This is an intense, hands - on, programming class. All concepts are reinforced by informal practice during the lecture followed by lab exercises. Many labs build on earlier labs which helps student s retain the earlier material. Python for Programming is a practical introduction to a working programming language, not an academic overview of syntax and grammar. Students will immediately be able to use Python to complete tasks in the real world.

Private Training for Teams

This course is offered as private, instructor-led training for organizations, onsite in Schertz, Texas or live online. Dates, delivery format, and course content are arranged around your team's requirements.

This course is not currently scheduled as a public class for individual enrollment.

Request Group Training

Prerequisites

Must have some experience coding in Python.

Course Outline

Python Refresher
Variables
Python Data Types
Sequences
Mapping Types
Program Structure
Files an Console I/O
Conditionals
Loops
Defining a Function
Function Parameters
Builtins
 
Python 2 vs 3 differences
 
Pythonic Programming
Common Python Idioms
Slicing and Dicing
Unpacking Function Arguments
Lambda Functions
Nested Functions
List Comprehensions
Iterables
Generator Expressions
Writing Generators
Python Time Travel
Three Python Easter Eggs
A String Trick
String Formatting
 
Mapping and Filtering
 
Modules and Packages
Modules
Using import
Initialization Code
Namespaces
Executing Modules as Scripts
Packages
Configuring Import with
__init__.py
Name Resolution (AKA scope)
Nested Functions
Python Style
 
Classes
About OO Programming
Defining Classes
Constructors
Instance Methods
Properties
Class Methods and Data
Static Methods
"Private" Methods
Inheritance
Untangling the Nomenclature
Collections Module
 
Metaprogramming
Special Attributes
globals() and locals()
Working with Attributes
The inspect module
Decorators
Decorator Functions
Decorator Classes
Decorating Classes
Creating Classes at Runtime
Monkey Patching
 
Regular Expressions
 
Database Access
The DB API
Available Interfaces
Connecting to a Server
Creating a Cursor
Executing a Statement
Fetching Data
Tip: Making an iterator for large queries
Parameterized Statements
Dictionary Cursors
Metadata
Transactions
Object-relational Mappers
 
qt GUI Programming with PyQt4
What is PyQt4?
Event Driven Applications
GUI Application Flow Chart
External Anatomy of a PyQt4
Application
Internal Anatomy of a PyQt4
Application
Using designer
Anatomy of a designer-based application
Naming Conventions
Common Widgets
Layouts
Selectable Buttons
Making your application stretch
Actions and Events
Menu Bar
Status Bar
Using predefined dialogs
Creating Custom Dialogs
Tabs
Niceties
Working with Images
 
Network Programming
Sockets
Socket options
Client Concepts
Server Concepts
Application Protocols
Forking Servers
Grabbing HTML from the Web
Consuming Web Services
Web Data the Easier Way
Sending email
Binary Data
The struct module
 
Multiprogramming
What are Threads?
The Python Thread Manager
The threading module
Threads for the impatient
Creating a thread class
Variable Sharing
Using Queues
Debugging threaded programs
The multiprocessing module
Alternatives to multiprogramming
 
XML and JSON
About XML
Normal approaches to XML
Which module to use?
Getting Started with ElementTree
How ElementTree works
Creating a new XML Document
Parsing an XML Document
Navigating the XML Document
Using XPath
About JSON
Reading JSON
Writing JSON
 
Extending Python
Why extend Python?
Ways to extend Python with C
Hand-coded C
Overview
The C Program
Methods
The Method Table
The init function
Handling errors
Custom exception objects
Putting it all together
Using SWIG
The interface file
Generating the Wrappers
Building and installing the extension
cytpes
cffi
 
numpy
Python’s scientific stack
numpy overview
Creating arrays
Creating ranges
Working with arrays
Shapes
Slicing and indexing
Indexing with Booleans
Stacking
Iterating
Tricks with arrays
Matrices
Data types
numpy functions
 
scipy
About scipy
Polynomials
Vectorizing functions
Subpackages
Getting help
Weave
 
A Tour of scipy subpackages
cluster
constants
fftpack
integrate
interpolate
io
linalg
ndimage
odr
optimize
signal
sparse
spatial
special
stats
 
pandas
About
pandas
Pandas architecture
Series
DataFrames
Data Alignment
Index Objects
Basic Indexing
Broadcasting
Removing entries
Time series
Reading Data
 
matplotlib
About matplotlib
matplotlib architecture
matplotlib Terminology
matplotlib keeps state
What else can you do?

What makes this material hard to master

The course covers a lot of ground in four days. It starts with general-purpose Python and ends in the scientific stack, and each stage assumes the one before it.

  • Idiomatic Python first. The refresher moves quickly into list comprehensions, generator expressions, writing generators, lambda and nested functions, and slicing. The array and DataFrame sections later lean on these habits, so code written as loops over indexes tends to carry over badly.
  • Object model and metaprogramming. Classes, properties, inheritance, decorator functions and classes, special attributes, the inspect module and runtime class creation form the most abstract block. Decorators and scope rules (name resolution, nested functions) are where many learners stall.
  • Systems topics. The DB API with parameterized statements and transactions, sockets, the struct module, threading with queues, multiprocessing, ElementTree and JSON, and extending Python with C (hand-coded, SWIG, ctypes, cffi) each introduce a different failure mode. Shared-variable bugs in threads and reference handling in C extensions are hard to reproduce.
  • The scientific stack. numpy covers shapes, Boolean indexing, stacking and data types. scipy is a tour of subpackages (integrate, optimize, signal, linalg, stats, and others), not one library. pandas adds Series, DataFrames, index objects, data alignment and time series. The common misconception is that these behave like plain Python lists. Shape mismatches, broadcasting and index alignment can produce plausible but wrong numbers without an error.

The syllabus also includes a section on Python 2 versus 3 differences. The course materials name Python 2.x, whose support ended in January 2020, so expect to translate between the two when reading older code.

Who it suits and what to take around it

This course suits scientists, engineers and developers who already write some Python and need to apply it to data, numerical work and instrument or system integration. It also suits teams that maintain existing Python 2.x scripts and tooling. The stated prerequisite is some experience coding in Python.

If your team is new to the language, Beginning Python builds the basics this course's refresher moves through quickly. If most of your work is arrays and tables, Python Data Analysis with NumPy and Pandas goes deeper on that part of the syllabus than this course's closing sections do. For a longer, more science-focused treatment, Python for Scientists is the related five-day option.

Organizations working on newer Python releases can ask about tailored private training through the training proposal request. More options are listed in the Python Programming courses and learning guide.

Illustrative scenarios

The scenarios below are illustrations of how the course material can be applied. They are not descriptions of specific organizations or of the course's lab exercises.

  • Analyzing measurement data. For example, an engineer might load logged readings with pandas, align two time series on their indexes, filter noise with scipy's signal subpackage, fit a curve with optimize, and plot the result with matplotlib.
  • Connecting instruments and databases. A team might read binary records from a device with struct, collect them over a socket on a worker thread feeding a queue, and write them to a relational database using parameterized statements and explicit transactions.
  • Speeding up or wrapping existing code. A group maintaining a numerical routine written in C might expose it to Python through ctypes, cffi or a SWIG interface file, then call it on numpy arrays from a script that parses its configuration from XML or JSON.

Using AI coding assistants with these topics

AI coding assistants are useful for numpy and pandas boilerplate, regular expressions, ElementTree or JSON parsing code, and first drafts of DB API calls. They are also good at explaining unfamiliar scipy subpackages and suggesting a comprehension in place of a loop.

They fail in predictable ways for this material:

  • They often produce Python 3 code by default. Pasted into a Python 2.x codebase, it can fail or quietly change behavior (print, division, strings and bytes).
  • They can suggest string-built SQL instead of parameterized statements.
  • They can write array code with wrong shapes or broadcasting, or pandas code that relies on index alignment in ways that produce NaN values.
  • They tend to produce thread code with unprotected shared variables, and C extension code with reference-handling mistakes.
  • They may mix up GUI toolkit versions, such as PyQt4 versus later bindings.

To verify, run the code on the interpreter version you actually use. Assert array shapes and dtypes, and compare results against a hand-computed or known case. Test empty and malformed input, review any SQL for parameterization, and stress-test threaded code rather than trusting one clean run.

Frequently asked questions

What level is this course?

It is a general-level, hands-on course for people who already code in Python. It starts with a refresher and moves quickly into advanced language features and the scientific stack.

What do I need to know beforehand?

Some experience coding in Python. You do not need prior experience with numpy, scipy, pandas or matplotlib, since the syllabus introduces each of them.

What does the course cover?

It covers Python idioms, modules and packages, classes, decorators and metaprogramming, regular expressions, database access, PyQt4 GUIs, sockets, threading and multiprocessing, XML and JSON, and extending Python with C. The final sections cover numpy, scipy, pandas and matplotlib.

Can it be delivered privately for our team, onsite or online?

Yes. HSG delivers private training for organizations at the client's location or live online.

Can the content be customized to our Python version or focus?

Private training can be tailored to the technology versions an organization uses, including current releases, and content can be customized. You can describe your needs through the training proposal request.

Training locations

Python for Applied Engineers training across the U.S. and beyond.

We provide private Python for Applied Engineers training for organizations, onsite at your location or live online, throughout the United States and internationally.

View all Python for Applied Engineers training locations

Train your team with HSG

Private, instructor-led training customized for your organization.

  • Onsite or live online delivery
  • Customized curriculum
  • For a single employee or an entire team
  • Flexible scheduling
  • Experienced instructors
Request Group Training

Questions? Call us at 303.377.6176
or email info@hartmannsoftware.com

Ready to train your team?

Let's customize this training for your organization.

Tell us about your employees, your goals, and your preferred schedule. We'll prepare a training proposal covering scope, delivery format, and pricing.