Skip to content
Snippets Groups Projects
Commit 871b2ddc authored by Daniel CARRON's avatar Daniel CARRON :b:
Browse files

[doc] Fix typos and clarify docstrings

parent 9ac615b8
No related branches found
No related tags found
1 merge request!15Update documentation
......@@ -202,7 +202,7 @@ def run_binary(
A list of predictions to consider for measurement
threshold_a_priori
A threshold to use, evaluated *a priori*, if must report single values.
If this value is not provided, a *a posteriori* threshold is calculated
If this value is not provided, an *a posteriori* threshold is calculated
on the input scores. This is a biased estimator.
......
......@@ -16,9 +16,10 @@ def _reconcile_metrics(
completeness: list,
interpretability: list,
) -> list[tuple[str, int, float, float, float]]:
"""Summarizes samples into a new table containing most important scores.
"""Summarizes samples into a new table containing the most important
scores.
It returns a list containing a table with completeness and road scorse per
It returns a list containing a table with completeness and ROAD scores per
sample, for the selected dataset. Only samples for which a completness and
interpretability scores are availble are returned in the reconciled list.
......@@ -198,8 +199,7 @@ def _extract_statistics(
name
The name of the variable being analysed
index
Which of the indexes on the tuples containing in ``data`` that should
be extracted.
The index of the tuple contained in ``data`` that should be extracted.
dataset
The name of the dataset being analysed
xlim
......
......@@ -382,8 +382,8 @@ def run(
target_label: int,
datamodule: lightning.pytorch.LightningDataModule,
) -> dict[str, list[typing.Any]]:
"""Applies visualization techniques on input CXR, outputs images with
overlaid heatmaps and csv files with measurements.
"""Computes the proportional energy and average saliency focus for a given
target label in a datamodule.
Parameters
---------
......@@ -399,7 +399,7 @@ def run(
Returns
-------
A dictionary where keys are dataset names in the provide datamodule,
A dictionary where keys are dataset names in the provided datamodule,
and values are lists containing sample information alongside metrics
calculated:
......
......@@ -114,7 +114,7 @@ def evaluate(
raise click.BadParameter(
f"""The value of --threshold=`{threshold}` does not match one
of the database split names ({', '.join(predict_data.keys())})
or can be converted to float. Check your input."""
or can not be converted to a float. Check your input."""
)
results: dict[
......
......@@ -21,7 +21,7 @@ logger = setup(__name__.split(".")[0], format="%(levelname)s: %(message)s")
cls=ConfigCommand,
epilog="""Examples:
1. Calculates the ROAD scores for an existing dataset configuration and stores them in .csv files:
1. Calculates the ROAD scores for an existing dataset configuration and stores them in .json files:
.. code:: sh
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment