Skip to content

Commit

Permalink
Fix various documentation glitches / warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelosthege committed Oct 13, 2024
1 parent fc2d48f commit ce3eafc
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 12 deletions.
2 changes: 1 addition & 1 deletion docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,4 +73,4 @@
# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ["_static"]
html_static_path: List[str] = []
16 changes: 11 additions & 5 deletions peak_performance/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,19 @@


class ModelType(str, Enum):
"""Class containing all implemented model types."""
"""Enum of default model types."""

Normal = "normal"
"""Shape of a Gaussian Normal PDF."""

SkewNormal = "skew_normal"
"""Shape of a skewed Normal PDF."""

DoubleNormal = "double_normal"
"""Superposition of two ``Normal`` peaks."""

DoubleSkewNormal = "double_skew_normal"
"""Superposition of two ``SkewedNormal`` peaks."""


def guess_noise(intensity):
Expand Down Expand Up @@ -393,10 +400,9 @@ def std_skew_calculation(scale, alpha):
Skewness parameter of the skew normal distribution.
Returns
----------
-------
std
Standard deviation of a skew normal distribution.
-------
"""
return np.sqrt(scale**2 * (1 - (2 * alpha**2) / ((alpha**2 + 1) * np.pi)))

Expand All @@ -415,7 +421,7 @@ def mean_skew_calculation(loc, scale, alpha):
Skewness parameter of the skew normal distribution.
Returns
----------
-------
mean
Arithmetic mean of a skew normal distribution.
"""
Expand Down Expand Up @@ -489,7 +495,7 @@ def height_calculation(area, loc, scale, alpha, mode_skew):
Mode of the skew normal distribution.
Returns
----------
-------
mean
Arithmetic mean of a skew normal distribution.
"""
Expand Down
12 changes: 6 additions & 6 deletions peak_performance/pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -1187,7 +1187,7 @@ def pipeline(
Data format (suffix) of the raw data, default is '.npy'.
Returns
----------
-------
path_results
Path variable pointing to the newly created folder for this batch.
"""
Expand Down Expand Up @@ -1224,7 +1224,7 @@ def pipeline_restart(
Path variable pointing to the directory of the broken PeakPerformance batch
Returns
----------
-------
path_results_new
Path variable pointing to the newly created folder for the restarted batch.
"""
Expand Down Expand Up @@ -1323,7 +1323,7 @@ def parse_files_for_model_selection(signals: pandas.DataFrame) -> Dict[str, str]
DataFrame containing the signals tab of Template.xlsx.
Returns
----------
-------
files_for_selection
Dict with file names as keys and unique identifiers as values.
"""
Expand Down Expand Up @@ -1430,7 +1430,7 @@ def model_selection_check(
to be accepted.
Returns
----------
-------
selected_model
Name of the selected model type.
"""
Expand Down Expand Up @@ -1473,7 +1473,7 @@ def selection_loop(
"waic": widely applicable information criterion)
Returns
----------
-------
result_df
DataFrame containing the ranking and scores of the model selection.
model_dict
Expand Down Expand Up @@ -1565,7 +1565,7 @@ def model_selection(path_raw_data: Union[str, os.PathLike], *, ic: str = "loo"):
"waic": widely applicable information criterion)
Returns
----------
-------
comparison_results
DataFrame containing all rankings from model selection.
model_dict
Expand Down

0 comments on commit ce3eafc

Please sign in to comment.