Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GemPy 2.2.3 #493

Merged
merged 54 commits into from Jul 27, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
54 commits
Select commit Hold shift + click to select a range
0b2db6e
- init docs-devs branch
Leguark May 27, 2020
2873ff6
[DOC] Fixing the bar
Leguark May 28, 2020
0eb2c46
Merge branches 'docs-devs' and 'master' of https://github.com/cgre-aa…
Leguark May 29, 2020
1721097
fixed markup in installation.rst
SimonVirgo Jun 2, 2020
c8b39cb
updated installation instructions for MacOS and minor edits
SimonVirgo Jun 2, 2020
3dc065a
[BUG] Minor bugs for strange order of calls
Leguark Jun 2, 2020
ca05567
[BUG] Travis sets the right domain for the documentation
Leguark Jun 2, 2020
860e943
Merge branch 'master' of https://github.com/cgre-aachen/gempy into do…
Leguark Jun 2, 2020
8452702
fixed typos and minor formatting
SimonVirgo Jun 2, 2020
25d016e
Merge remote-tracking branch 'origin/docs-devs' into docs-devs
SimonVirgo Jun 2, 2020
8f18cf0
minor formatting in index.rst
SimonVirgo Jun 2, 2020
a1210d5
Merge remote-tracking branch 'origin/docs-devs' into docs-devs
Leguark Jun 3, 2020
07e59c8
[BUG] Second try fixing travis domain
Leguark Jun 3, 2020
8b64d7a
formatting and minor corrections in Ch1_1_basic
SimonVirgo Jun 3, 2020
bda5c34
Merge remote-tracking branch 'origin/docs-devs' into docs-devs
SimonVirgo Jun 3, 2020
cac842f
minor corrections in installation.rst and unified heading style in ch1_1
SimonVirgo Jun 3, 2020
345e1e0
minor corrections and formatting in ch1_2a
SimonVirgo Jun 3, 2020
5d51046
minor corrections and formatting in ch1_2b
SimonVirgo Jun 3, 2020
55439e6
[DOC] Small changes to the installation.rst
Leguark Jun 3, 2020
389c854
minor corrections and formatting in ch1_3a
SimonVirgo Jun 3, 2020
d51c9a5
Merge remote-tracking branch 'origin/docs-devs' into docs-devs
SimonVirgo Jun 3, 2020
3966298
Small changes to Index
Jun 4, 2020
05fa064
Small changes to index
Jun 4, 2020
0834a5a
- init docs-devs branch
Leguark Jun 4, 2020
db3473f
Merge remote-tracking branch 'origin/docs-devs' into docs-devs
Leguark Jun 4, 2020
4c7a19d
minor corrections and formatting in ch1_3c and merge with ch1_3d
SimonVirgo Jun 4, 2020
3711e01
Merge remote-tracking branch 'origin/docs-devs' into docs-devs
SimonVirgo Jun 4, 2020
f89a5fd
minor corrections in installation.rst
SimonVirgo Jun 4, 2020
063c063
[BUG] patching gempy to be compatible with pyvista 0.25
Leguark Jun 6, 2020
0911c7e
[BUG] Allowing user to have pyvista .24 too
Leguark Jun 6, 2020
82c4e62
Merge remote-tracking branch 'origin/docs-devs' into docs-devs
Leguark Jun 6, 2020
570643a
[DOC] Added some links to the repo badges
Leguark Jun 6, 2020
d4c8fdc
[BUG] Adding flag for pyvista sphinx
Leguark Jun 6, 2020
bef4280
[BUG] Fixing travis
Leguark Jun 8, 2020
5dd9109
[BUG] Fixing travis
Leguark Jun 8, 2020
998460e
[BUG] Fixing travis - Minor tweaks on to setup.py
Leguark Jun 8, 2020
863e7b4
[BUG] Fixing travis - Minor tweaks on to setup.py
Leguark Jun 8, 2020
0de1f12
Fix Travis for emg3d/pymc3. (#439)
prisae Jun 12, 2020
46a4764
Add the license to the manifest for inclusion in source code (#435)
AndrewAnnex Jun 12, 2020
2b806b5
Update manifest.in to be explicit (#444)
AndrewAnnex Jun 12, 2020
2279e4a
Update README.md
bluetyson Jun 17, 2020
2e46591
Remove use of optional argument which was providing wrong index
Jul 1, 2020
fa99b15
Merge pull request #468 from cgre-aachen/fix_466
Jul 1, 2020
e185fc4
Have Travis only check master and release branches
Jul 1, 2020
52256a7
Randomly generate colors when deterministic colors run out. Also clar…
Jul 1, 2020
11ec393
# Added new model for simple geometry examples
javoha Jun 26, 2020
04982c6
Merge pull request #459 from cgre-aachen/new_example_model
agzimmerman Jul 1, 2020
4e5496e
Merge pull request #471 from cgre-aachen/fix_451_try3
Jul 2, 2020
a80f16a
Fix version of discretize installed by Travis
Jul 14, 2020
f8b1d48
Merge pull request #469 from cgre-aachen/change_travis_behavior
agzimmerman Jul 14, 2020
0eac58e
Merge pull request #478 from cgre-aachen/fix_477
agzimmerman Jul 14, 2020
7345509
Merge pull request #447 from bluetyson/patch-1
agzimmerman Jul 21, 2020
2339444
Fix4 (#490)
Leguark Jul 24, 2020
8d2081d
Gempy to rex (#485)
Leguark Jul 27, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
72 changes: 40 additions & 32 deletions .travis.yml
@@ -1,47 +1,56 @@
language: python

os: linux
dist: xenial

branches:
only:
- master
- release

python:
- '3.7'

env: TRAVIS=true

before_install:
# configure a headless display
- git clone --depth 1 git://github.com/pyvista/gl-ci-helpers.git
- source ./gl-ci-helpers/travis/setup_headless_display.sh

install:
- wget https://repo.anaconda.com/pkgs/misc/conda-execs/conda-latest-linux-64.exe -O conda.exe
- chmod +x conda.exe
- export CONDA_ALWAYS_YES=1
# This is where you put any extra dependencies you may have.
- ./conda.exe create -p $HOME/miniconda python=$TRAVIS_PYTHON_VERSION conda conda-build pytest six pytest-cov pytest-mock
- sudo apt-get update
# We do this conditionally because it saves us some downloading if the
# version is the same.
- wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh;
- bash miniconda.sh -b -p $HOME/miniconda
- export PATH="$HOME/miniconda/bin:$PATH"
- hash -r
- pip install --upgrade setuptools pip
- pip install -r requirements.txt
- pip install sphinx-gallery
- pip install qgrid
- pip install nbval
- pip install pyevtk
- pip install arviz
- pip install recommonmark
- pip install dataclasses pyvista panel discretize # emg3d
- pip install welly
- conda install gdal
- conda install --yes -c conda-forge python-graphviz
- conda config --set always_yes yes --set changeps1 no
- conda update --all
# Useful for debugging any issues with conda
- conda info -a

# Install and activate environment, install packages
- conda create -q -n tenv python=$TRAVIS_PYTHON_VERSION
- source activate tenv

# Installs from conda-forge
- conda install -c conda-forge python-graphviz emg3d
discretize==0.4.13 pip matplotlib ipython six pytest pytest-cov
pytest-mock gdal pandas seaborn>=0.9 qgrid sphinx-gallery
ipywidgets pyevtk arviz dataclasses scikit-image>=0.17
recommonmark networkx panel setuptools mkl-service

# Installs from anaconda
- conda install -c anaconda libffi
- pip install pymc3
- pip install ipython
# Install untested, non-required code (linter fails without them)
- pip install ipython ipywidgets
- export PATH="./bin:$PATH"

script:
- pytest -v notebooks/ --nbval-lax
- pytest
# Installs from pip
- pip install welly pymc3

# Install
- pip install -e .
# foo
- pip install pyvista==0.24.3 --force-reinstall

- python -c "import pyvista as pv;print(pv.Report())"

stages:
- test
Expand All @@ -51,13 +60,12 @@ jobs:
include:
- stage: test
script:
- pytest
- pytest -v
- stage: deploy
name: Deploy to GitHub Pages
# if: (NOT type IN (pull_request)) AND (branch = sphinx-gallery) # only deploy if merging on master

before_script:
- pip install -e .
- cd docs
script: pipenv run make html
deploy:
Expand All @@ -66,7 +74,7 @@ jobs:
github_token: $travis_doc # defined via the Travis interface
local_dir: docs/build/html
on:
branch: sprint_2.2
branch: release
target_branch: gh-pages
fqdn: docs.gempy.org
cache: pip

1 change: 0 additions & 1 deletion DevelopersGuide.txt
Expand Up @@ -17,7 +17,6 @@ python3 setup.py sdist bdist_wheel
twine upload dist/*



### Type of commits:

ENH: Enhancement, new functionality
Expand Down
3 changes: 2 additions & 1 deletion MANIFEST.in
@@ -1 +1,2 @@
exclude notebooks/ *
exclude notebooks/*
include LICENSE
8 changes: 4 additions & 4 deletions README.md
Expand Up @@ -5,9 +5,9 @@

[![PyPI](https://img.shields.io/badge/python-3-blue.svg)](https://www.python.org/downloads/)
[![PyPI](https://img.shields.io/badge/pypi-1.0-blue.svg)](https://pypi.org/project/gempy/)
[![license: LGPL v3](https://img.shields.io/badge/license-LGPL%20v3-blue.svg)]()
[![license: LGPL v3](https://img.shields.io/badge/license-LGPL%20v3-blue.svg)](https://github.com/cgre-aachen/gempy/blob/master/LICENSE)
[![Documentation Status](https://assets.readthedocs.org/static/projects/badges/passing-flat.svg)](http://docs.gempy.org)
[![Travis Build](https://travis-ci.org/cgre-aachen/gempy.svg?branch=master)]()
[![Travis Build](https://travis-ci.org/cgre-aachen/gempy.svg?branch=master)](https://travis-ci.org/github/cgre-aachen/gempy/branches)
[![Binder](https://mybinder.org/badge.svg)](https://mybinder.org/v2/gh/cgre-aachen/gempy/master)
[![DOI](https://zenodo.org/badge/96211155.svg)](https://zenodo.org/badge/latestdoi/96211155)
[![DOCKER](https://img.shields.io/docker/cloud/automated/leguark/gempy.svg)](https://cloud.docker.com/repository/docker/leguark/gempy)
Expand Down Expand Up @@ -67,7 +67,7 @@ gempy has been used for realistic models! -->
### Interpolation approach

The generation of complex structural settings is based on the powerful
interpolation algorithm underlying `GemPy`, a unviersal cokriging method
interpolation algorithm underlying `GemPy`, a universal cokriging method
devoised by Lajaunie et al. (1997) and extended by Calcagno et al. (2008).
This method is used to interpolate a 3D scalar field, such that geologically
significant interfaces are isosurfces in this field.
Expand Down Expand Up @@ -197,4 +197,4 @@ providing detailed [tutorials](https://www.gempy.org/tutorials) on how to use it
* Lajaunie, C., Courrioux, G., & Manuel, L. (1997). Foliation fields and 3D cartography in geology: principles of a method based on potential interpolation. Mathematical Geology, 29(4), 571-584.
* Wellmann, F., Schaaf, A., de la Varga, M., & von Hagke, C. (2019). [From Google Earth to 3D Geology Problem 2: Seeing Below the Surface of the Digital Earth](
https://www.sciencedirect.com/science/article/pii/B9780128140482000156).
In Developments in Structural Geology and Tectonics (Vol. 5, pp. 189-204). Elsevier.
In Developments in Structural Geology and Tectonics (Vol. 5, pp. 189-204). Elsevier.
8 changes: 8 additions & 0 deletions dev-requirements.txt
@@ -0,0 +1,8 @@
# This are additional libraries necessary to run sphinx and all the test
sphinx
sphinx_gallery
emg3d
ipywidgets
# This shold be installed with conda too: conda install -c conda-forge discretize==0.4.13
welly
requests
7 changes: 7 additions & 0 deletions docs/Makefile
Expand Up @@ -18,3 +18,10 @@ help:
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

html-noplot: export SPHX_GLR_THEME = $(theme)
html-noplot:
$(SPHINXBUILD) -D plot_gallery=0 -b html $(ALLSPHINXOPTS) $(SOURCEDIR) $(BUILDDIR)/html
@echo
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."

5 changes: 2 additions & 3 deletions docs/source/conf.py
Expand Up @@ -36,6 +36,7 @@
pyvista.rcParams['window_size'] = np.array([1024, 768]) * 2
# Save figures in specified directory
pyvista.FIGURE_PATH = os.path.join(os.path.abspath('./images/'), 'auto-generated/')
pyvista.BUILDING_GALLERY = True
if not os.path.exists(pyvista.FIGURE_PATH):
os.makedirs(pyvista.FIGURE_PATH)

Expand Down Expand Up @@ -143,8 +144,6 @@


# -- Sphinx Gallery Options
from sphinx_gallery.sorting import FileNameSortKey

sphinx_gallery_conf = {
# path to your examples scripts
"examples_dirs": [
Expand Down Expand Up @@ -204,7 +203,7 @@
'logo_name': True,
'travis_button': True,
'page_width': '1200px',
'fixed_sidebar': True,
'fixed_sidebar': False,
'show_related': True,
'sidebar_collapse': True,
}
Expand Down
63 changes: 31 additions & 32 deletions docs/source/index.rst
Expand Up @@ -3,31 +3,32 @@
You can adapt this file completely to your liking, but it should at least
contain the root `toctree` directive.

.. image:: ../logos/gempy1.png
.. ../logos/gempy1.png
:width: 30%

about
About
=====
Software for 3D structural geologic implicit modeling in Python.
Open-source software for implicit 3D structural geological modeling in Python.
****************************************************************

Overview
--------

``GemPy`` is a Python-based, **open-source geomodeling library**. It is
capable of constructing complex **3D geological models** of folded
structures, fault networks and unconformities, based on the underlying
powerful **implicit representation** approach. ``GemPy`` was designed from the
ground up to support easy embedding in probabilistic frameworks for the
uncertainty analysis of subsurface structures.
``GemPy`` is a Python-based, community-driven, **open-source geomodeling library**. It is
capable of constructing complex **3D geological models** including various features such as
fold structures, fault networks and unconformities, based on an underlying
powerful **implicit** approach. From the ground up, ``GemPy`` was designed to be easily embedded in probabilistic frameworks for conducting
uncertainty analysis regarding subsurface structures.

Check out the documentation either in `gempy.org <https://www.gempy.org/>`_
.. Check out the documentation either in `gempy.org <https://www.gempy.org/>`_
(better option), or `read the docs <http://gempy.readthedocs.io/>`_.




3D models created with GemPy may look like this:

.. image:: ./images/model_example.png
.. image:: ./images/perth_example.png

Contents:

Expand Down Expand Up @@ -57,8 +58,8 @@ Contents:
Features
--------

Geological objects
^^^^^^^^^^^^^^^^^^
Geological features
^^^^^^^^^^^^^^^^^^^


.. raw:: html
Expand All @@ -67,9 +68,7 @@ Geological objects



``GemPy`` enables the modeling of complex 3D geological settings,
on par with many commercial geomodeling packages, including:

``GemPy`` is capable of modeling complex 3D geological scenarios, including:

* Multiple conformal layers (e.g. sequences of sedimentary layers)
* Several sequences of layers, with conformal continuation or unconformities
Expand All @@ -78,32 +77,32 @@ on par with many commercial geomodeling packages, including:
* Full fault networks (faults affecting faults)
* Folds (affecting single layers or entire layer stacks, including overturned and recumbent folds)

The combination of these elements allows for the generation of realistic
3-D geological models in most typical geological settings.

Combining these elements in GemPy allows for the generation of realistic
3D geological models, on a par with most commercial geomodeling software.

.. raw:: html

<!-- Note: we should inlcude here links to models and/or publications where
gempy has been used for realistic models! -->



Interpolation approach
^^^^^^^^^^^^^^^^^^^^^^

The generation of complex structural settings is based on the powerful
interpolation algorithm underlying ``GemPy``\ , a unviersal cokriging method
devoised by Lajaunie et al. (1997) and extended by Calcagno et al. (2008).
devoised by `Lajaunie et al. (1997)` and extended by `Calcagno et al. (2008)`\ .
This method is used to interpolate a 3D scalar field, such that geologically
significant interfaces are isosurfces in this field.

The algorithm allows for a direct integration of two of the most relevant
geological input data types:


* *Surface contact points*\ : 3D coordinates of points marking the boundaries
* **Surface contact points**\ : 3D coordinates of points marking the boundaries
between different features (e.g. layer interfaces, fault planes, unconformities).
* *Orientation measurements*\ : Orientation of the poles perpendicular to
* **Orientation measurements**\ : Orientation of the poles perpendicular to
the dipping of surfaces at any point in the 3D space.

``GemPy`` also allows for the definition of topological elements such as
Expand All @@ -125,7 +124,7 @@ Models generated with ``GemPy`` can be visualized in several ways:
representation of results;
* interactive 3D visualization and model input manipulation using the
Visualization Toolkit (VTK);
* We also actively develop a link to the fantastic `
* We also actively develop a link to the fantastic
`pyvista <https://www.pyvista.org>`_ project
for even better visualization and model interaction in 3D.

Expand All @@ -137,9 +136,9 @@ in a variety of ways:
software such as ParaView;
* Export of triangulated surface meshes (e.g. for further processing in
meshing programs);
* Export of images (e.g. geological maps) for
* Export of images (e.g. geological maps).

We are also currently working on a tighter integration wtih several
We are also currently working on a tighter integration with several
meshing libraries, notably `CGAL <https://www.cgal.org>`_ and `gmesh <https://gmsh.info>`_. In addition, we have
established links to several other open-source libraries, including `pygiml <https://www.pygimli.org>`_
for geophysical modeling and inversion. In the current state, however, these
Expand All @@ -155,7 +154,7 @@ feel free to contact us.
Stochastic geological modeling
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

One of the most advanced features that sets ``gempy`` also apart from
One of the most advanced features that sets ``GemPy`` also apart from
available commercial packages is the full integration of stochastic
geological modeling methods.
``GemPy`` was designed from the ground up to support stochastic geological
Expand Down Expand Up @@ -187,7 +186,7 @@ via PyMC will then result in different model realizations.

Theano allows the automated computation of gradients, opening the door to
the use of advanced gradient-based sampling methods
coupling *GeMpy* and
coupling ``GemPy`` and
`PyMC3 <https://pymc-devs.github.io/pymc3/notebooks/getting_started.html>`_
for advanced stochastic modeling. Also, the use of Theano allows making
use of GPUs through cuda (see the Theano documentation for more information.
Expand All @@ -197,15 +196,15 @@ Making use of vtk interactivity and `Qgrid <https://github.com/quantopian/qgrid>

For a more detailed elaboration of the theory behind ``GemPy``\ , we refer to the
**open access scientific publication**\ :
`\ *"GemPy 1.0: open-source stochastic geological modeling and inversion"*
by de la Varga et al. (2018) <https://www.geosci-model-dev.net/12/1/2019/gmd-12-1-2019.pdf>`_.
`\ "GemPy 1.0: open-source stochastic geological modeling and inversion"
by de la Varga et al. (2019) <https://www.geosci-model-dev.net/12/1/2019/gmd-12-1-2019.pdf>`_.

References
----------

* de la Varga, M., Schaaf, A., & Wellmann, F. GemPy 1.0: open-source stochastic geological modeling and inversion.
* Calcagno, P., Chilès, J. P., Courrioux, G., & Guillen, A. (2008). Geological modelling from field data and geological knowledge: Part I. Modelling method coupling 3D potential-field interpolation and geological rules. Physics of the Earth and Planetary Interiors, 171(1-4), 147-157.
* Lajaunie, C., Courrioux, G., & Manuel, L. (1997). Foliation fields and 3D cartography in geology: principles of a method based on potential interpolation. Mathematical Geology, 29(4), 571-584.
* de la Varga, M., Schaaf, A., and Wellmann, F.: GemPy 1.0: `open-source stochastic geological modeling and inversion,` Geosci. Model Dev., 12, 1–32, https://doi.org/10.5194/gmd-12-1-2019, 2019.
* Calcagno, P., Chilès, J. P., Courrioux, G., & Guillen, A. (2008). `Geological modelling from field data and geological knowledge: Part I. Modelling method coupling 3D potential-field interpolation and geological rules.` Physics of the Earth and Planetary Interiors, 171(1-4), 147-157.
* `Lajaunie, C., Courrioux, G., & Manuel, L. (1997). `Foliation fields and 3D cartography in geology: principles of a method based on potential interpolation.` Mathematical Geology, 29(4), 571-584.


Indices and tables
Expand Down