Skip to content

emsig/houston23-mc3

Repository files navigation

Masterclass 3: EM Modelling

Delphi-Consortium

2023 Delphi Meetings in Houston & The Hague

MyBinder

Colab

JupyterLite

License

In the following 1.5 h we are going to use empymod and emg3d to model electromagnetic data in the diffusive regime, as commonly used in geophysical exploration.

Structure of this Masterclass

Pre-requisites to run the examples

  • In this Masterclass we will use Python within Jupyter Notebooks.
  • For scientific computations I always advice against using your PC's Python installation; you should use dedicated Python installations for your coding.
  • For various reasons I also advice to use Mambaforge, or alternatively the regular conda.

Local Installation

  1. Download and install the corresponding Mambaforge for your OS: https://github.com/conda-forge/miniforge#mambaforge

    (Mambaforge uses mamba, the faster conda implementation, and sets conda-forge, the community maintained package repository, as default source.)

  2. Download or clone the repo at https://github.com/emsig/houston23-mc3, and cd to the directory.
  3. Install the environment with

    mamba env create -f environment.yml

    This will install an environment called houston23-mc3.

  4. Activate the environment with

    mamba activate houston23-mc3
  5. Add this kernel to the recognized Jupyter kernels (optional, to have access from other envs as well) with

    python -m ipykernel install --user --name houston23-mc3
  6. Start Jupyter Lab

    jupyter lab

The following google docs contains some further instructions, which might be useful (particular for Windows users): https://swu.ng/t20-python-setup

I will use Python 3.11. However, Python 3.7-3.11 should work; earlier versions might work, but potentially with older versions of the packages.

If you prefer to install the required packages in whatever other way, feel free to do so. Here the packages lists:

  • Required: empymod, emg3d, matplotlib, discretize, h5py, pooch, xarray; ipyml (for interactive plots in the Jupyter lab).
  • Optional: scooby, mkl, tqdm.

Online

  • MyBinder

    MyBinder: I tested the repo on MyBinder, and it should work; however, be aware that it can take some time to start-up a virtual machine.

  • Colab

    Google Colab: If you have a Google account you can also run it on Colab. You have to login in order to run it.

  • JupyterLite

    JupyterLite: I transferred some of the notebooks (the computationally light ones) to JupyterLite. JupyterLite is a static website with client-side computation. You can run everything in it without installing anything at all. Just be aware that everything happens in the cache of your browser. If you clean the cache, your stuff is gone.

Codes, their manuals and galleries

empymod logo

Full 3D electromagnetic modeller for 1D VTI media.

emg3d logo

A multigrid solver for 3D electromagnetic diffusion.

empymod/emg3d with inversion frameworks

DISC 2017 & em-apps

Software Underground (Swung) Transform Tutorials swu.ng

  • Marine Electromagnetic Methods - Beginnings to Today by Steve Constable: Video; Slides.
  • Multi-physics analysis: Extracting the most from diverse datasets by Lucy MacGregor: Video; Slides.
  • Fundamentals of Inversion by Douglas Oldenburg: Video; Slides.
  • custEM: by Raphael Rochlitz: Video; Slides.