Skip to content

Commit

Permalink
docs: add table of models (#99)
Browse files Browse the repository at this point in the history
* add list of useful links

* add page with available models table

* make table with link to binder examples

* move installation to install

* add __slots__ to grids for new Dataset

* add script for creating model table

* add link to the notebooks

* rename notebooks

* resolve cross-references with more than one target

* create symbolic link to each notebook

* add grid attributes to __slots__
  • Loading branch information
mcflugen committed Oct 18, 2019
1 parent ba6862b commit 8d9371e
Show file tree
Hide file tree
Showing 14 changed files with 286 additions and 35 deletions.
9 changes: 6 additions & 3 deletions README.rst
Expand Up @@ -29,15 +29,13 @@
<img src="https://ci.appveyor.com/api/projects/status/bf8g17c05ugvhvfe/branch/master"></a>
<a href="https://coveralls.io/github/csdms/pymt?branch=master">
<img alt="Coverage Status" src="https://coveralls.io/repos/github/csdms/pymt/badge.svg?branch=master"></a>
<a href="https://landscape.io/github/csdms/pymt/master">
<img alt="Code Health" src="https://landscape.io/github/csdms/pymt/master/landscape.svg"></a>
<a href="https://opensource.org/licenses/MIT">
<img alt="License: MIT" src="https://img.shields.io/badge/License-MIT-yellow.svg"></a>
<a href="https://github.com/csdms/pymt">
<img alt="Code style: black" src="https://img.shields.io/badge/code%20style-black-000000.svg"></a>
<a href="https://www.codacy.com/app/mcflugen/pymt?utm_source=github.com&amp;utm_medium=referral&amp;utm_content=csdms/pymt&amp;utm_campaign=Badge_Grade">
<img src="https://api.codacy.com/project/badge/Grade/e8e273131ecb4d7d981fe9f4cf3e83d9"/></a>
<a href="https://mybinder.org/v2/gh/csdms/pymt.git/master?filepath=notebooks%2FWelcome.ipynb">
<a href="https://mybinder.org/v2/gh/csdms/pymt.git/master?filepath=notebooks%2Fwelcome.ipynb">
<img alt="Launch Binder" src="https://static.mybinder.org/badge_logo.svg"></a>
</p>

Expand All @@ -62,6 +60,11 @@ that expose the
* A plug-in framework for adding additional BMI-enabled models to
the framework

Quick links:
* `Installation instructions <https://pymt.readthedocs.io/install>`_
* `User documentation <https://pymt.readthedocs.io/>`_
* `List of available models <https://pymt.readthedocs.io/models>`_

This material is based upon work
supported by the National Science Foundation
under Grant No. `1831623`_,
Expand Down
13 changes: 13 additions & 0 deletions docs/conf.py
Expand Up @@ -23,6 +23,19 @@

# sys.path.insert(0, os.path.abspath('..'))
from unittest.mock import MagicMock
from sphinx.domains.python import PythonDomain


class PatchedPythonDomain(PythonDomain):
def resolve_xref(self, env, fromdocname, builder, typ, target, node, contnode):
if 'refspecific' in node:
del node['refspecific']
return super(PatchedPythonDomain, self).resolve_xref(
env, fromdocname, builder, typ, target, node, contnode)


def setup(sphinx):
sphinx.override_domain(PatchedPythonDomain)


class Mock(MagicMock):
Expand Down
61 changes: 36 additions & 25 deletions docs/examples.rst
Expand Up @@ -18,49 +18,60 @@ have to install Jupyter Notebook:
Single Models
-------------
* Frost Number Model |binder-frost_number|

======================================================= =====================
Model Notebook
======================================================= =====================
:doc:`Frost Number Model <notebooks/frost_number>` |binder-frost_number|
:doc:`Kudryavtsev Model <notebooks/ku>` |binder-ku|
:doc:`GIPL Model <notebooks/gipl>` |binder-GIPL|
:doc:`ECSimpleSnow Model <notebooks/ecsimplesnow>` |binder-ECSnow|
:doc:`Coastline Evolution Model <notebooks/cem>` |binder-cem|
:doc:`Hydrotrend <notebooks/hydrotrend>` |binder-hydrotrend|
:doc:`Sedflux3D <notebooks/sedflux3d>` |binder-sedflux3d|
:doc:`Flexural Subsidence <notebooks/subside>` |binder-subside|
======================================================= =====================

.. |binder-frost_number| image:: https://mybinder.org/badge_logo.svg
:target: https://mybinder.org/v2/gh/csdms/pymt.git/master?filepath=notebooks%2Ffrost_number.ipynb

* Kudryavtsev Model |binder-ku|
.. |binder-ku| image:: https://mybinder.org/badge_logo.svg
:target: https://mybinder.org/v2/gh/csdms/pymt.git/master?filepath=notebooks%2Fku.ipynb

* GIPL Model |binder-GIPL|
.. |binder-GIPL| image:: https://mybinder.org/badge_logo.svg
:target: https://mybinder.org/v2/gh/csdms/pymt.git/master?filepath=notebooks%2FExample_01_Basic_Use_GIPL.ipynb
:target: https://mybinder.org/v2/gh/csdms/pymt.git/master?filepath=notebooks%2Fgipl.ipynb

* ECSimpleSnow Model |binder-ECSnow|
.. |binder-ECSnow| image:: https://mybinder.org/badge_logo.svg
:target: https://mybinder.org/v2/gh/csdms/pymt.git/master?filepath=notebooks%2FECSnow_PyMT.ipynb
:target: https://mybinder.org/v2/gh/csdms/pymt.git/master?filepath=notebooks%2Fecsimplesnow.ipynb

* Coastline Evolution Model |binder-cem|
.. |binder-cem| image:: https://mybinder.org/badge_logo.svg
:target: https://mybinder.org/v2/gh/csdms/pymt.git/master?filepath=notebooks%2Fcem.ipynb

* Hydrotrend |binder-hydrotrend|
.. |binder-hydrotrend| image:: https://mybinder.org/badge_logo.svg
:target: https://mybinder.org/v2/gh/csdms/pymt.git/master?filepath=notebooks%2Fhydrotrend.ipynb

* Sedflux3D |binder-sedflux3d|
.. |binder-sedflux3d| image:: https://mybinder.org/badge_logo.svg
:target: https://mybinder.org/v2/gh/csdms/pymt.git/master?filepath=notebooks%2Fsedflux3d.ipynb

* Flexural Subsidence |binder-subside|
.. |binder-subside| image:: https://mybinder.org/badge_logo.svg
:target: https://mybinder.org/v2/gh/csdms/pymt.git/master?filepath=notebooks%2Fsubside.ipynb


Coupled Models
--------------

* Coastline Evolution Model + Waves |binder-cem_and_waves|
========================================================================== ========================
Models Notebook
========================================================================== ========================
:doc:`Coastline Evolution Model + Waves <notebooks/cem_and_waves>` |binder-cem_and_waves|
:doc:`GIPL + ECSimpleSnow Models <notebooks/gipl_and_ecsimplesnow>` |binder-GIPL_and_ECSnow|
========================================================================== ========================

.. |binder-cem_and_waves| image:: https://mybinder.org/badge_logo.svg
:target: https://mybinder.org/v2/gh/csdms/pymt.git/master?filepath=notebooks%2Fcem_and_waves.ipynb

* GIPL + ECSimpleSnow Models |binder-GIPL_and_ECSnow|
.. |binder-GIPL_and_ECSnow| image:: https://mybinder.org/badge_logo.svg
:target: https://mybinder.org/v2/gh/csdms/pymt.git/master?filepath=notebooks%2FExample_02_GIPL_ECSimpleSnow.ipynb
:target: https://mybinder.org/v2/gh/csdms/pymt.git/master?filepath=notebooks%2Fgipl_and_ecsimplesnow.ipynb


..
Expand All @@ -71,15 +82,15 @@ Coupled Models
:maxdepth: 1
:hidden:

<demos/frost_number>
<demos/ku>
<demos/Example_01_Basic_Use_GIPL>
<demos/cem>
<demos/hydrotrend>
<demos/sedflux3d>
<demos/subside>
<demos/child>
<demos/cem_and_waves>
<demos/Example_02_GIPL_ECSimpleSnow>
<demos/sedflux3d_and_child>
<demos/ECSnow_PyMT>
<notebooks/frost_number>
<notebooks/ku>
<notebooks/gipl>
<notebooks/cem>
<notebooks/hydrotrend>
<notebooks/sedflux3d>
<notebooks/subside>
<notebooks/child>
<notebooks/cem_and_waves>
<notebooks/gipl_and_ecsimplesnow>
<notebooks/sedflux3d_and_child>
<notebooks/ecsimplesnow>
3 changes: 2 additions & 1 deletion docs/index.rst
Expand Up @@ -57,8 +57,9 @@ this part of the documentation is for you.
:maxdepth: 2

quickstart
installation
install
usage
models
examples
glossary

Expand Down
File renamed without changes.

0 comments on commit 8d9371e

Please sign in to comment.