Skip to content
This repository has been archived by the owner on Mar 21, 2024. It is now read-only.

ENH: Switch recommonmark to MyST-parser #787

Merged
merged 25 commits into from
Aug 18, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
267d4e8
📝 Create basic for ML API
peterhessey Aug 5, 2022
806f261
📝 Add ML/configs base doc files
peterhessey Aug 5, 2022
0cbd7c7
📝 Finish ML/configs API
peterhessey Aug 8, 2022
f5c82cf
📝 Update augmentations
peterhessey Aug 8, 2022
ac0171a
📝 Add ML/dataset API docs
peterhessey Aug 8, 2022
e9fff6a
📝 Add rst skeleton for ML/models
peterhessey Aug 8, 2022
4fd8de4
📝 Fix docstring missing newlines
peterhessey Aug 8, 2022
6371548
Remove script
peterhessey Aug 8, 2022
27e7784
📝 Finish ML/models API docs
peterhessey Aug 8, 2022
6a1273f
📝 Start ML/SSL API. Fix some formatting issues
peterhessey Aug 9, 2022
562173b
📝 Correct whitespace issues in `:param`
peterhessey Aug 9, 2022
416e907
📝 Fix whitespace errors on `:return` statements
peterhessey Aug 9, 2022
a778dac
📝 Fix :return: statements
peterhessey Aug 9, 2022
33b557c
📝 Finish ML/SSL API
peterhessey Aug 9, 2022
7d4f466
📝 Add ML/utils API docs
peterhessey Aug 9, 2022
19ab5b2
📝 Add visualizer docs, fix `:raise` indents
peterhessey Aug 9, 2022
67169af
📝 Fix more issues with the `:raises:` formatting
peterhessey Aug 9, 2022
7619004
♻️ Restructuring folders
peterhessey Aug 9, 2022
bdc2a51
📝 Limit API `toctree` depth
peterhessey Aug 9, 2022
56c3a52
📝 Add primary InnerEye/ML files API to docs
peterhessey Aug 9, 2022
e9e5ee8
📝 Fix and add `InnerEye/ML/*.py` docs
peterhessey Aug 9, 2022
c1d84a8
⚰️ Remove weird `settings.json` change
peterhessey Aug 9, 2022
933bc7b
📌 Switch recommonmark to MyST-parser
peterhessey Aug 15, 2022
6e610b0
📌 Add myst-parser to `environment.yml`, lock env
peterhessey Aug 16, 2022
a9a5278
Fix conflicts merging main
peterhessey Aug 17, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
📝 Update augmentations
  • Loading branch information
peterhessey committed Aug 8, 2022
commit f5c82cfda53a9388156a65aa2ae0f5ab56f3860e
10 changes: 5 additions & 5 deletions InnerEye/ML/augmentations/augmentation_for_segmentation_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ class among the available classes then samples a center point among the pixels o
class.

:param sample: A set of Image channels, ground truth labels and mask to randomly crop.
:param class_weights: A weighting vector with values [0, 1] to influence the class the center crop
voxel belongs to (must sum to 1), uniform distribution assumed if none provided.
:return numpy int array (3x1) containing patch center spatial coordinates
:param class_weights: A weighting vector with values [0, 1] to influence the class the center crop voxel belongs
to (must sum to 1), uniform distribution assumed if none provided.
:return: numpy int array (3x1) containing patch center spatial coordinates
"""
num_classes = sample.labels.shape[0]

Expand Down Expand Up @@ -70,9 +70,9 @@ def slicers_for_random_crop(sample: Sample,
:param sample: A set of Image channels, ground truth labels and mask to randomly crop.
:param crop_size: The size of the crop expressed as a list of 3 ints, one per spatial dimension.
:param class_weights: A weighting vector with values [0, 1] to influence the class the center crop
voxel belongs to (must sum to 1), uniform distribution assumed if none provided.
voxel belongs to (must sum to 1), uniform distribution assumed if none provided.
:return: Tuple element 1: The slicers that convert the input image to the chosen crop. Tuple element 2: The
indices of the center point of the crop.
indices of the center point of the crop.
:raises ValueError: If there are shape mismatches among the arguments or if the crop size is larger than the image.
"""
shape = sample.image.shape[1:]
Expand Down
1 change: 1 addition & 0 deletions InnerEye/ML/configs/classification/CovidModel.py
Original file line number Diff line number Diff line change
Expand Up @@ -246,6 +246,7 @@ def generate_custom_report(self, report_dir: Path, model_proc: ModelProcessing)
:param report_dir: Directory report is to be written to
:param model_proc: Whether this is a single or ensemble model (model_output.csv will be located in different
paths for single vs ensemble runs.)

"""

label_prefix = LoggingColumns.Label.value
Expand Down
11 changes: 10 additions & 1 deletion docs/source/rst/api/ML/augmentations/index.rst
Original file line number Diff line number Diff line change
@@ -1,8 +1,17 @@
Data augmentation
=================

.. automodule:: InnerEye.ML.augmentations.augmentation_for_segmentation_utils
Image Transformations
----------------------

.. automodule:: InnerEye.ML.augmentations.image_transforms

Transformation Pipeline
-----------------------

.. automodule:: InnerEye.ML.augmentations.transform_pipeline

Utils
-----

.. automodule:: InnerEye.ML.augmentations.augmentation_for_segmentation_utils