Skip to content

Commit

Permalink
More detailed script-level docstrings.
Browse files Browse the repository at this point in the history
  • Loading branch information
christofs committed Feb 7, 2021
1 parent 41ecdff commit 40bba77
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 5 deletions.
2 changes: 2 additions & 0 deletions HOWTO.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ This document explains the installation requirements, installation procedure and

See also the general information on coleto in the [README](https://github.com/dh-trier/coleto/blob/main/README.md).

For a detailed documentation of all functions, please open the [API reference](/docs/index.html) in your browser.

## Requirements

Python 3. This package has been tested with Python 3.7. It should also work with Python 3.6+
Expand Down
4 changes: 3 additions & 1 deletion coleto/meta_documentation.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
# Author: Christof Schöch, 2016-2019.

"""
Script to save settings and parameters to disk for documentation.
Script to save settings and parameters to disk for documentation.
Each time coleto is run, a timestamped file is created with this information.
The purpose is to document, for any results, the parameters used.
Part of coleto, see: https://github.com/dh-trier/coleto.
"""
Expand Down
6 changes: 5 additions & 1 deletion coleto/meta_parameters.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,11 @@
# Author: Christof Schöch, 2016-2021.


"""Script to define and generate parameters, such as paths and filenames.
"""
Script to collect and generate parameters, such as paths and filenames.
The user-defined parameters from the config.yaml file are included here.
Additional parameters are generated based on them.
All parameters are packaged-up in the 'params' variable.
The parameters are then used by the various coleto modules.
Part of coleto, see: https://github.com/dh-trier/coleto.
Expand Down
6 changes: 4 additions & 2 deletions coleto/run_coleto.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,10 @@


"""
Script that runs the coleto text collation pipeline.
Please see the readme.md file and the documentation.
This is the main script that controls the coleto text collation pipeline.
For more information, please see the README.md and HOTWO.md files.
An API reference can be found in the docs folder.
"""


Expand Down
3 changes: 2 additions & 1 deletion coleto/stats_distribution.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@

"""
Script to create some statistics from the diff analysis data.
These statistics focus on the edit types.
These statistics focus on the frequency of the various edit types.
Based on these statistics, several barcharts can be generated.
Part of coleto, see: https://github.com/dh-trier/coleto.
"""
Expand Down
4 changes: 4 additions & 0 deletions coleto/text_wdiff.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@
"""
Uses subprocess to call wdiff from the command line.
You need to have wdiff installed.
Based on the input texts split into sentences,
wdiff first aligns the text, identifying insertions and deletions.
It then identifies each location of difference between two aligned sentences.
A sanity check is included to make sure wdiff has run correctly.
"""


Expand Down
2 changes: 2 additions & 0 deletions coleto/viz_distribution.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

"""
Script to visualize some basic collation statistics.
The key information visualized is frequency of edit types.
Uses the pygal library to create several barcharts in SVG.
Part of coleto, see: https://github.com/dh-trier/coleto.
"""
Expand Down
4 changes: 4 additions & 0 deletions coleto/viz_progression.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@
"""
Visualize edit intensity over textual progression.
Relies on cumulated Levenshtein distances per sentence.
Uses the pygal library to create a barchart.
Uses scipy for some smoothing.
Input: The distribution statistics.
Ouptut: Saves an SVG file to disk.
Part of coleto, see: https://github.com/dh-trier/coleto.
"""
Expand Down

0 comments on commit 40bba77

Please sign in to comment.