Python Sessions | Sunday, February 5, 2023
Sunday, February 5, 2023
Green Earth Sciences Building
367 Panama Street, RM 104
Stanford, CA 94305
Please visit here for directions and parking.
Sessions Hosted By Geologica Geothermal Group
Two Sessions (Beginner and Intermediate Advanced) will be taught by Irene Wallis, Sunday afternoon preceding the Workshop.
A quick google of last year’s tech surveys tells us that Python’s popularity has been rapidly growing and last year was the second most used language by the 73-million code developers in GitHub (State of the Octoverse Survey). Python’s popularity is driven by its flexibility, readability, and the numerous open-source tools that are developed by an enthusiastic community. As illustrated by the Software Underground community (SWUG), Python is gaining wide popularity amongst earth scientists and engineers, so there are now many open-source libraries for mapping, geophysical inversion, solid mechanics, and thermodynamics more.
Applying Python as a tool involves skills in three areas:
- The language: The code itself, with its associated structures and conventions.
- The libraries: Python building blocks that are designed to solve a particular problem and are bundled together for easy use by others.
- The ecosystem: The social and computer science context in which we do our coding and that enables us to be more effective and connected.
Most introductory python courses focus almost solely on the language. This language-focused approach can be dull for research scientists and technical professionals who see code as a tool for solving problems rather than a topic of interest unto itself. Furthermore, a language-focused approach rarely deals with the fundamental barriers to applying python (or any other code language). These barriers typically arise from not knowing where to start within the wide range of libraries and ecosystem options available.
These two short workshops will treat all three areas, with the goal of arming participants with the knowledge to continue their own, self-directed skills development. Participants should bring their laptop if they would like to ‘code along’ or they can just come to listen. For those who would like to participate in the code-along, instructions will be provided prior to the workshop for installation and setup.
Each session is limited to 20 participants, open to registered participants of the Stanford Geothermal Workshop. There is a nominal registration fee of $50 for each session (or $100 for both).
Session 1: Introduction to Python for Geothermal Scientists and Engineers
1 – 2:30 pm
This introduction-level workshop covers elements of the language, library and ecosystem that will enable a geothermal scientist or engineer to navigate plethora of options for self-directed python skills development. Foundation terminology will be introduced, and a road map will be provided for how to fast-track toward practical application of python. The workshop includes examples for the practical application of python to geothermal problems and some code-along fun will be had. The workshop includes links to resources that participants can use to for future self-directed learning.
Session 2: Intermediate and Advanced Python Methods for Geothermal Reservoir Engineering and Geomechanics
3:00PM – 4:30PM
This workshop assumes a basic working knowledge of python and will cover intermediate and advanced methods. Several core and specialist libraries will be discussed, with a focus on reservoir geomechanics, fracture analysis, and reservoir engineering applications. Fundamental ecosystem components will be introduced, with a focus on those that enable participants to (A) leverage and contribute to open-source (B) effectively collaborate in-house.
Two technical topics will be addressed with a code-along option:
- Large dataset, compilation, exploration, transformation (including averaging), and visualisation using Pandas and various plotting libraries. These methods could be applied to processing steamfield monitoring data to calculate mass balance, weekly averages, or generate model input files.
- Curve fitting with numpy (numerical python) and SciPy (scientific python). Applications include decline analysis and any problem where you are evaluating the relationship between parameters.
Depending on the interest of participants, other advanced topics can be discussed including the implementation of calculus and linear algebra in python, where to start with machine learning approaches to problem solving, algorithmic thinking/problem solving, self-documenting code, and the role of python in robustness/repeatability of science/engineering.
Irene Wallis is a consultant with Geologica Geothermal Group who specializes in open-hole geophysics and geomechanics, well test analysis and analytical modelling for reservoir engineering, analysis of reservoir response to production, and the development of conceptual models. Since transitioning from mining to geothermal, she has accumulated more than 10 years’ experience in the exploration, development, and operation of conventional geothermal resources in New Zealand, Chile, USA, Djibouti, Indonesia, and the Philippines.
Irene started learning Python five years ago and last year was a finalist in the science category of the New Zealand Open-Source Awards for fractoolbox. She uses python daily for data cleaning and analysis, analytical modelling, and the generation of high-quality graphics. Irene has led public courses on geothermal well test analysis with Python and the generation of publication-ready figures, and has mentored other geoscientists and reservoir engineers in the practical use of Python.