Skip to content

Commit

Permalink
Update module descriptions
Browse files Browse the repository at this point in the history
  • Loading branch information
Dobson committed Mar 21, 2024
1 parent 6f216e3 commit 0b502a6
Show file tree
Hide file tree
Showing 9 changed files with 29 additions and 34 deletions.
5 changes: 1 addition & 4 deletions swmmanywhere/geospatial_utilities.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
# -*- coding: utf-8 -*-
"""Created 2024-01-20.
"""Geospatial utilities module for SWMManywhere.
A module containing functions to perform a variety of geospatial operations,
such as reprojecting coordinates and handling raster data.
@author: Barnaby Dobson
"""
import itertools
import json
Expand Down
6 changes: 3 additions & 3 deletions swmmanywhere/graph_utilities.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
"""Created on 2024-01-26.
"""Graph utilities module for SWMManywhere.
@author: Barney
A module to contain graphfcns, the graphfcn registry object, and other graph
utilities (such as save/load functions).
"""
import json
import os
Expand Down
15 changes: 12 additions & 3 deletions swmmanywhere/logging.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,16 @@
# -*- coding: utf-8 -*-
"""Created on 2024-03-04.
"""Logging module for SWMManywhere.
@author: Barney
Example:
>>> import os
>>> os.environ["SWMMANYWHERE_VERBOSE"] = "true"
>>> # logging is now enabled in any swmmanywhere module
>>> from swmmanywhere.logging import logger # You can now log yourself
>>> logger.info("This is an info message.") # Write to stdout
This is an info message.
>>> logger.add("file.log") # Add a log file
>>> logger.info("This is an info message.") # Write to stdout and file.log
This is an info message.
>>> os.environ["SWMMANYWHERE_VERBOSE"] = "false" # Disable logging
"""
import os
import sys
Expand Down
6 changes: 3 additions & 3 deletions swmmanywhere/metric_utilities.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
"""Created 2023-12-20.
"""Metric utilities module for SWMManywhere.
@author: Barnaby Dobson
A module for metrics, the metrics registry object and utilities for calculating
metrics (such as NSE or timeseries data alignment) used in SWMManywhere.
"""
from collections import defaultdict
from inspect import signature
Expand Down
6 changes: 1 addition & 5 deletions swmmanywhere/parameters.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
# -*- coding: utf-8 -*-
"""Created on 2024-01-26.
@author: Barney
"""
"""Parameters and file paths module for SWMManywhere."""

from pathlib import Path

Expand Down
7 changes: 2 additions & 5 deletions swmmanywhere/post_processing.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
# -*- coding: utf-8 -*-
"""Created 2024-01-22.
"""Post processing module for SWMManywhere.
A module containing functions to format and write processed data into SWMM .inp
A module containing functions to format and write processed data into SWMM .inp
files.
@author: Barnaby Dobson
"""
import re
import shutil
Expand Down
5 changes: 2 additions & 3 deletions swmmanywhere/prepare_data.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
# -*- coding: utf-8 -*-
"""Created 2023-12-20.
"""Prepare data module for SWMManywhere.
@author: Barnaby Dobson
A module to download data needed for SWMManywhere.
"""

import shutil
Expand Down
7 changes: 4 additions & 3 deletions swmmanywhere/preprocessing.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# -*- coding: utf-8 -*-
"""Created on 2024-01-26.
"""Preprocessing module for SWMManywhere.
@author: Barney
A module to call downloads, preprocess these downloads into formats suitable
for graphfcns, and some other utilities (such as creating a project folder
structure or create the starting graph from rivers/streets).
"""

import json
Expand Down
6 changes: 1 addition & 5 deletions swmmanywhere/swmmanywhere.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
# -*- coding: utf-8 -*-
"""Created on 2024-01-26.
@author: Barney
"""
"""The main SWMManywhere module to generate and run a synthetic network."""
import os
from pathlib import Path

Expand Down

0 comments on commit 0b502a6

Please sign in to comment.