Skip to content

Latest commit

 

History

History
52 lines (28 loc) · 2.33 KB

README.md

File metadata and controls

52 lines (28 loc) · 2.33 KB

GPflux documentation

The API reference (generated from docstrings) and Jupyter Notebook tutorials are automatically built by a Github action (see .github/workflows/deploy.yaml) on commit to develop and published to https://secondmind-labs.github.io/GPflux/.

Jupyter Notebooks

If you want to run the Jupyter Notebook tutorials interactively, install additional dependencies in the docs directory:

pip install -r docs_requirements.txt

...and then run the appropriate Notebook:

jupyter-notebook notebooks/<name-of-notebook>

If you want to create a new Notebook tutorial for inclusion in the doc set, see notebooks/README.md.

API reference

If you want to build the documentation locally:

  1. Make sure you have a Python 3.7 virtualenv and gpflux is installed as per the instructions in ../README.md)

  2. In the docs directory, install dependencies:

    pip install -r docs_requirements.txt

    If pandoc does not install via pip, or step 3) fails with a 'Pandoc' error, download and install Pandoc separately from https://github.com/jgm/pandoc/releases/ (e.g. pandoc-<version>-amd64.deb for Ubuntu), and try running step 2) again.

  3. Compile the documentation:

    make html

  4. Run a web server:

    python -m http.server

  5. Check documentation locally by opening (in a browser):

    http://localhost:8000/_build/html/

Intersphinx and TensorFlow/Probability

TensorFlow and TensorFlow Probability have their own custom API docs system. We have manually produced (web-scraped) intersphinx inventories to be able to cross-reference tf and tfp classes and functions. They are now hosted on the GPflow/tensorflow-intersphinx GitHub.

TF/P provides a lot of aliases for accessing objects. However, the intersphinx inventories only contain some of them. You can find the correct way of referencing by looking through the list generated by python -msphinx.ext.intersphinx tf2_py_objects.inv or python -msphinx.ext.intersphinx tfp_py_objects.inv Note that this requires you to have local copies, e.g. downloaded from GitHub (TF/TFP).