Skip to content

Commit

Permalink
add intro, quick start, and usage guide
Browse files Browse the repository at this point in the history
  • Loading branch information
aerispaha committed Dec 17, 2024
1 parent 72b1938 commit 474b868
Show file tree
Hide file tree
Showing 10 changed files with 1,000 additions and 330 deletions.
Binary file added docs/_static/img/swmm-zoom-graphic.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 9 additions & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@
import os
import sys
import swmmio
import pandas as pd

pd.set_option('display.max_columns', 50)
pd.set_option('display.max_rows', 5)

sys.path.insert(0, os.path.abspath('../../swmmio'))

Expand Down Expand Up @@ -80,7 +84,10 @@
# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
# This pattern also affects html_static_path and html_extra_path.
exclude_patterns = []
exclude_patterns = [
# 'usage/visualizing_models.ipynb',
# 'usage/making_art_with_swmm.ipynb'
]

# The name of the Pygments (syntax highlighting) style to use.
pygments_style = 'sphinx'
Expand All @@ -100,6 +107,7 @@
#
html_theme_options = {
"github_url": "https://github.com/pyswmm/swmmio",
"navbar_align": "content",
}

# Add any paths that contain custom static files (such as style sheets) here,
Expand Down
77 changes: 77 additions & 0 deletions docs/index.ipynb
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# swmmio \n",
"_Programmatic pre and post processing for EPA Stormwater Management Model (SWMM)_\n",
"\n",
"![image](_static/img/swmm-zoom-graphic.png)\n",
"\n",
"\n",
"## Introduction\n",
"`swmmio` is a Python tool for engineers and hydrologists who need to supercharge their ability to modify and analyze EPA SWMM models and results. Using a familiar Pandas interface, users can replace manual procesess that used to live in spreadsheets with scripts and automation.\n",
"\n",
"The core `swmmio.Model` object provides accessors to related elements in the INP and RPT. For example, {py:meth}`swmmio.Model.subcatchments` provides a DataFrame (or GeoDataFrame) joining data from the `[SUBCATCHMENTS]` and `[SUBAREAS]` tables in the model.inp file and, if available, the `Subcatchment Runoff Summary` from the model.rpt file. \n",
"\n",
"Additionally, `swmmio` provides a lower-level API for reading and writing (almost) all of the sections of the model.inp file which is useful for programmatically modifying EPA SWMM models.\n",
"\n",
"\n",
"## Installation\n",
"```bash\n",
"pip install swmmio\n",
"``` "
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"For more examples, see the [Usage](usage/index.ipynb) section."
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"```{toctree}\n",
"---\n",
"hidden:\n",
"maxdepth: 1\n",
"---\n",
"quick_start.ipynb\n",
"installing.md\n",
"usage/index\n",
"reference/index\n",
"```"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "venv",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.11.4"
}
},
"nbformat": 4,
"nbformat_minor": 2
}
41 changes: 0 additions & 41 deletions docs/index.rst

This file was deleted.

Loading

0 comments on commit 474b868

Please sign in to comment.