Skip to content

Commit

Permalink
DOC: create preprocessing section (#393)
Browse files Browse the repository at this point in the history
* DOC: create preprocessing section

* remove _templates from gitignore

* rerun notebook, fix typo

* use rediraffe
  • Loading branch information
martinfleis committed Sep 11, 2022
1 parent b2d8884 commit afcb85b
Show file tree
Hide file tree
Showing 7 changed files with 62 additions and 40 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ instance/

# Sphinx documentation
docs/_build/
docs/_templates/
docs/generated/

# PyBuilder
Expand Down
9 changes: 8 additions & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@
"pandas",
"rtree",
"scipy",
"scipy.spatial" "shapely",
"scipy.spatial",
"shapely",
"shapely.geometry",
"shapely.wkt",
"shapely.ops",
Expand Down Expand Up @@ -76,6 +77,7 @@
"myst_parser",
"sphinx_copybutton",
"sphinx_gallery.load_style",
"sphinxext.rediraffe",
]

# nbsphinx do not use requirejs (breaks bootstrap)
Expand Down Expand Up @@ -231,6 +233,11 @@ def setup(app):
# A list of files that should not be packed into the epub file.
epub_exclude_files = ["search.html"]

# Add redirect for previously existing pages, each item is like `(from_old, to_new)`

rediraffe_redirects = {
"user_guide/elements/preprocessing.ipynb": "user_guide/preprocessing/simple_preprocessing.ipynb", # noqa
}

# -- Extension configuration -------------------------------------------------
# Generate the API documentation when building
Expand Down
3 changes: 2 additions & 1 deletion docs/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,5 @@ nbsphinx
ipython
myst-parser
sphinx_copybutton
sphinx-gallery
sphinx-gallery
sphinxext-rediraffe
1 change: 0 additions & 1 deletion docs/user_guide/elements/elements.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,3 @@ This section covers:
enclosed
blocks
links
preprocessing
1 change: 1 addition & 0 deletions docs/user_guide/intro.rst
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,4 @@ Notebooks cover just a small selection of functions as an illustration of princi
Characters based on multiple GeoDataFrames <combined/combined>
Using spatial weights matrix <weights/weights>
Street network analysis <graph/graph>
Data preprocessing <preprocessing/preprocessing>
12 changes: 12 additions & 0 deletions docs/user_guide/preprocessing/preprocessing.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
Generating morphological elements
=================================

Sometimes we need to preprocess data. `momepy` has a set of tools to edit given geometry
to make it fit for morphological analysis.

This section covers:

.. toctree::
:maxdepth: 2

simple_preprocessing

Large diffs are not rendered by default.

0 comments on commit afcb85b

Please sign in to comment.