Skip to content

Latest commit

 

History

History
76 lines (51 loc) · 5.44 KB

README.md

File metadata and controls

76 lines (51 loc) · 5.44 KB

CoFI Examples

Open In Colab badge CoFI docs

Related repositories by InLab:

CoFI (Common Framework for Inference) is an open-source initiative for interfacing between generic inference algorithms and specific geoscience problems. Read CoFI's documentation for more details.

This repository contains examples for running inversion algorithms using CoFI with increasing complexity in problems.

Run the examples

  • To run the examples interactively without any local setup, click on the "Colab" (recommended) or "binder" badges above
  • To view the examples and sample output (without interaction, no local setup), click on the "Example Gallery"
  • To install cofi and run the examples locally, follow the instructions below

Run the examples with cofi locally

Step 1. Get cofi

(Strongly recommended) Create a virtual environment to avoid conflicts with your other projects:

$ conda env create -f envs/environment.yml
$ conda activate cofi_env

For MacOS M1 users, unfortunately tetgen (which is a dependency of pygimli) doesn't support ARM machines yet. Please use conda env create -f envs/environment_arm.yml instead, and use another X86 machine to run the notebooks that make use of pygimli.

Otherwise (skip this if you've followed above), ensure you have scipy and jupyter-lab in your environment and then install cofi with:

$ pip install cofi

Step 2. Get the examples

Clone this repository:

$ git clone https://github.com/inlab-geo/cofi-examples.git

Step 3. Run the examples

Open up Jupyter-lab:

$ cd cofi-examples
$ jupyter-lab

Run through examples and have fun 🎉! We recommend opening up the index.ipynb at root folder to decide where to start.

Contribution

Thanks for contributing! Please refer to our Contributor's Guide for details.

Troubleshooting for interactive lab

If you've followed the instructions on running locally above, and are still having trouble displaying the ipython widgets, then hopefully this StackOverflow thread will help you.