Граф коммитов

105 Коммитов

Автор SHA1 Сообщение Дата
Peter Hessey d902e02fc6
ENH: Adapt HelloWorld to run using the Inference Service (#837)
Closes #696.

Changes the HelloWorld model to only use a single channel, as this is
the format that the [Inference
Service](https://github.com/microsoft/InnerEye-Inference/) expects for
its inputs.

As many tests require the 2-channel data, this PR also creates a new
class, `HelloWorld2Channel`, which inherits from `HelloWorld` but uses 2
channels and can be used for testing. This avoids the pain of having to
alter all unit and regression tests that relied on the 2-channel data
and model.

Both models can be trained on the same data, but now the `HelloWorld`
model can be run by the Inference Service.
2022-11-22 11:00:04 +00:00
Peter Hessey 8f9d823101
DEL: Remove `environment_win.yml` (#836)
Closes #822.

Removes the outdated and difficult-to-maintain locked windows
environment and updates documentation accordingly.
2022-11-17 12:24:34 +00:00
Peter Hessey 4aadd0d0f7
DOC: Update sample tasks docs (#833)
Closes #761
2022-11-16 11:11:13 +00:00
Peter Hessey f66c61bb28
DOC: Add documentation on monitoring jobs in AzureML portal (#826)
Closes #254
2022-11-10 22:18:42 +00:00
Peter Hessey ca48126414
DOC: Hotfix doc links (#823)
Some of the doc links in the pre-trained model page are broken, this is
quick hotfix to remedy that.
2022-11-07 13:57:23 +00:00
Peter Hessey 657530439c
ENH: Publish lung segmentation model (#808)
This PR contains the hyperparameter updates for training and running
inference on InnerEye Lung segmentation model on a Standard_NC24rs_v3
Azure cluster (4 x V100).

It also includes all the documentation of the model will be released in
a tagged version in the same fashion as the [hippocampus
model](https://github.com/microsoft/InnerEye-DeepLearning/releases/tag/v0.5).
I will tag and release the model after this PR is merged to ensure that
the source code in the main branch is correct at the time of release
(docs currently include a link to v0.8 which doesn't yet exist).
2022-11-07 13:04:02 +00:00
Peter Hessey 12f78f34f5
DOC: Fix doc typo (#820)
Closes #781
2022-11-02 15:10:59 +00:00
Peter Hessey 33ae7c20e7
DOC: Correct RTD version (#815)
Closes #810
2022-10-28 14:37:01 +01:00
Peter Hessey 7894498635
DOC: Fix dead TRE links (#798)
* 📝 Fix broken link

* 📝 Update TRE documentation
2022-09-13 13:29:24 +01:00
Peter Hessey 57489686c5
DOC: Add `InnerEye/Common` docstrings to RTD (#797)
* 📝 Create basic for ML API

* 📝 Add ML/configs base doc files

* 📝 Finish ML/configs API

* 📝 Update augmentations

* 📝 Add ML/dataset API docs

* 📝 Add rst skeleton for ML/models

* 📝 Fix docstring missing newlines

* Remove script

* 📝 Finish ML/models API docs

* 📝 Start ML/SSL API. Fix some formatting issues

* 📝 Correct whitespace issues in `:param`

* 📝 Fix whitespace errors on `:return` statements

* 📝 Fix :return: statements

* 📝 Finish ML/SSL API

* 📝 Add ML/utils API docs

* 📝 Add visualizer docs, fix `:raise` indents

* 📝 Fix more issues with the `:raises:` formatting

* ♻️ Restructuring folders

* 📝 Limit API `toctree` depth

* 📝 Add primary InnerEye/ML files API to docs

* 📝 Fix and add `InnerEye/ML/*.py` docs

* ⚰️ Remove weird `settings.json` change

* 📌 Switch recommonmark to MyST-parser

* 📌 Add myst-parser to `environment.yml`, lock env

* 🚧 Add Common docs

* 📝 Add common docstrings fixes

* 🐛 Remove git artifacts
2022-09-13 13:20:27 +01:00
Peter Hessey bb0ec8a2d9
DOC: Add `InnerEye/Azure` docstrings to RTD (#788)
* 📝 Create basic for ML API

* 📝 Add ML/configs base doc files

* 📝 Finish ML/configs API

* 📝 Update augmentations

* 📝 Add ML/dataset API docs

* 📝 Add rst skeleton for ML/models

* 📝 Fix docstring missing newlines

* Remove script

* 📝 Finish ML/models API docs

* 📝 Start ML/SSL API. Fix some formatting issues

* 📝 Correct whitespace issues in `:param`

* 📝 Fix whitespace errors on `:return` statements

* 📝 Fix :return: statements

* 📝 Finish ML/SSL API

* 📝 Add ML/utils API docs

* 📝 Add visualizer docs, fix `:raise` indents

* 📝 Fix more issues with the `:raises:` formatting

* ♻️ Restructuring folders

* 📝 Limit API `toctree` depth

* 📝 Add primary InnerEye/ML files API to docs

* 📝 Fix and add `InnerEye/ML/*.py` docs

* ⚰️ Remove weird `settings.json` change

* 📌 Switch recommonmark to MyST-parser

* 📝 Add InnerEye/Azure docstrings to RTD

* 💡 ♻️ Address review comments

* 📝 Update Azure title

* 📝 ♻️ Address review comments
2022-09-12 11:48:03 +01:00
Peter Hessey 879cb5f6ad
DOC: Add scripts to RTD (#793) 2022-09-06 13:19:25 +01:00
Dr Kenji Takeda c7b2051836
DOC: Add AML notes for how ACR is used (#795) 2022-09-06 10:30:59 +00:00
Peter Hessey 8ffab94d46
ENH: Switch recommonmark to MyST-parser (#787)
* 📝 Create basic for ML API

* 📝 Add ML/configs base doc files

* 📝 Finish ML/configs API

* 📝 Update augmentations

* 📝 Add ML/dataset API docs

* 📝 Add rst skeleton for ML/models

* 📝 Fix docstring missing newlines

* Remove script

* 📝 Finish ML/models API docs

* 📝 Start ML/SSL API. Fix some formatting issues

* 📝 Correct whitespace issues in `:param`

* 📝 Fix whitespace errors on `:return` statements

* 📝 Fix :return: statements

* 📝 Finish ML/SSL API

* 📝 Add ML/utils API docs

* 📝 Add visualizer docs, fix `:raise` indents

* 📝 Fix more issues with the `:raises:` formatting

* ♻️ Restructuring folders

* 📝 Limit API `toctree` depth

* 📝 Add primary InnerEye/ML files API to docs

* 📝 Fix and add `InnerEye/ML/*.py` docs

* ⚰️ Remove weird `settings.json` change

* 📌 Switch recommonmark to MyST-parser

* 📌 Add myst-parser to `environment.yml`, lock env
2022-08-18 13:39:49 +01:00
Anton Schwaighofer e6b24063ef
DOC: Add a copy of the software dev document from hi-ml (#789) 2022-08-18 09:02:44 +01:00
Peter Hessey 59214c268e
DOC: Add all `InnerEye/ML` docstrings to ReadTheDocs (#783)
* 📝 Create basic for ML API

* 📝 Add ML/configs base doc files

* 📝 Finish ML/configs API

* 📝 Update augmentations

* 📝 Add ML/dataset API docs

* 📝 Add rst skeleton for ML/models

* 📝 Fix docstring missing newlines

* Remove script

* 📝 Finish ML/models API docs

* 📝 Start ML/SSL API. Fix some formatting issues

* 📝 Correct whitespace issues in `:param`

* 📝 Fix whitespace errors on `:return` statements

* 📝 Fix :return: statements

* 📝 Finish ML/SSL API

* 📝 Add ML/utils API docs

* 📝 Add visualizer docs, fix `:raise` indents

* 📝 Fix more issues with the `:raises:` formatting

* ♻️ Restructuring folders

* 📝 Limit API `toctree` depth

* 📝 Add primary InnerEye/ML files API to docs

* 📝 Fix and add `InnerEye/ML/*.py` docs

* ⚰️ Remove weird `settings.json` change

* ♻️ 💡 Address review comments
2022-08-16 08:58:38 +00:00
Peter Hessey c1b363e158
ENH: Move docs to ReadTheDocs (#768)
* 📝Move docs folder to sphinx-docs

* Trigger build for new URL

* 📝 Fix build to include README + CHANGLOG

* 📝 Add back in link fixing

* 🐛 Fix docs links

* 🚨 📝 Fix markdown linting

* 📝 Change relative links to GitHub ones permanently

* 📝 Replace more relative paths

* 📝 Switch to symlinks

* 📝 Replace README in toctree

* 📝 Update README

* 🐛 Attempt to fix images not rendering

* 🐛 Fix broken links

* Remove IDE settings from gitignore

* ️ Move docs to `docs/` and add Makefile back

* 🙈 Update gitignore

* ♻️ ️ Resolve review comments and change theme

* 📝 🔀 Rebase + markdown linting

* 🔥 Remove build files (again)

* 🙈 Remove pieline-breaking symlink

*  Add furo to sphinx dependencies

* 📌 Move sphinx deps to environment.yml + lock

* 📝 Improve doc folder structure

* Return to copying instead of symlink

* 📝 Update indexing and titles

* 📝 Address review comments
2022-08-04 09:15:19 +01:00
arsenkhy 4e12cec106
DOC: Update installation guide in /docs/WSL.md (#769)
* Update installation guide in WSL.md

- Removed long installation guide
- Included new shorter guide to install WSL

* Update WSL.md with given suggestions

- More clear language

* Update docs/WSL.md

* Update docs/WSL.md

* Update docs/WSL.md

* Trim trailing whitespace in WSL.md

- Trimmed trailing whitespace to pass the CI checks

Co-authored-by: Anton Schwaighofer <antonsc@microsoft.com>
2022-08-01 09:14:33 +01:00
Melissa Bristow e4a0b38c8b
DOC: Improve hippocampus model documentation (#772)
* Add hippocampus docs

* Update docs/building_models.md

* update documentation

* Update docs/hippocampus_model.md

Co-authored-by: Fernando Pérez-García <fperezgarcia@microsoft.com>

* Address PR comments

* Incorporate model card in docu

* update docu

* update documentation

* Update hippocampus docs

Co-authored-by: Anton Schwaighofer <antonsc@microsoft.com>
Co-authored-by: Fernando Pérez-García <fperezgarcia@microsoft.com>
2022-07-26 18:32:11 +01:00
Melissa Bristow aec9e28e3f
DOC: Add hippocampus docs (#756)
Add documentation on evaluating the trained Hippocampus model.
2022-07-25 16:20:37 +00:00
Peter Hessey 69a5e8cd2c
DOC: Update environment documentation (#748)
* 📝 Update environment documentation

* 📝 Add quick setup, add review comment changes
2022-06-22 10:57:30 +00:00
Anton Schwaighofer 106c101ff7
DOC: Improve doc for checkpointing (#747) 2022-06-21 17:09:24 +01:00
Anton Schwaighofer ad9aac5413
DOC: Improve documentation for dataset creation (#723) 2022-06-06 16:12:10 +00:00
Peter Hessey 92d94799f2
ENH: Add Environment Locking (#735)
*  Add environment locking script

* 📝  Finish script, add documentation

* 🐛 Change Windows env file in workflow

* 📝 🐛 Add review changes + fixes

* 🚧 Temporarily alter tests and conda channels

* 🚧 Add logging

*  Fix TestSubmodule env file

* 🔥 Delete env test

* 🧑‍💻 Add warning to environment.yml

* 📝 ⚰️ Update based on review comments

* 📝 Add final changes
2022-06-01 10:05:54 +00:00
Anton Schwaighofer 14b968c282
DOC: Add a smoke-test model for AzureML setup (#708)
- Details how to test AzureML without uploading data.
- Also sneaked in an update of hi-ml to fffbb0f8
2022-04-13 14:05:09 +01:00
Fernando Pérez-García 6aab3b1f93
STYLE: Ensure line breaks at the end of all files (#717)
* Add line breaks at the end of all files

* Handle last line in VS Code settings
2022-04-04 15:08:43 +01:00
Fernando Pérez-García 2edbdc8d64
STYLE: Trim trailing whitespaces with pre-commit (#715) 2022-04-04 10:27:38 +01:00
Fernando Pérez-García 760cbe0305
ENH: Enforce prefixes for pull request titles (#713)
Enforce prefixes for pull request titles

Co-authored-by: Anton Schwaighofer <antonsc@microsoft.com>
2022-03-30 15:18:28 +01:00
Fernando Pérez-García 3eaf2f9053
Deprecate manual changelog (#707) 2022-03-29 13:43:50 +01:00
Fernando Pérez-García 45e7d5ff4d
Fix some Sphinx warnings (#699)
* Fix shell lexer name

* Update CHANGELOG

* Fix CHANGELOG

* Fix "html_static_path entry '_static' does not exist"

* Clean up preprocess script

* Fix link to InnerEye-DataQuality

* Use shutil.copy to copy files

* Remove extra info from CHANGELOG

* Fix broken link to LICENSE

* Fix lexer name for YAML

* Remove colons from headers

* Fix InnerEye module not being found
2022-03-22 09:46:15 +00:00
Anton Schwaighofer f0d2337d1b
Improve setup for running the HelloWorld model in AzureML (#693) 2022-03-15 14:07:28 +00:00
Javier 1606729c7a
Clean up legacy code (#671)
* Remove rnns

* Fix flake8

* Edit README

* Edit README

* Remove sequence

* Remove sequence

* Fix all

* Remove more

* Remove ignore

* Fix tests

* Undo config

* Fix config

* Revert pycharm

* Fix tests

* Undo outputlogger

* Fix flake8

* Fix ignore file

* Revert hi-ml

* Disable fail on alert
2022-03-09 14:53:12 +00:00
Anton Schwaighofer 0bc009e07d
Fixing SSL recovery, attempt 2 (#584)
Add linear head state and linear head optimizer to the checkpoints
2021-11-18 17:30:09 +00:00
maxilse 28d40c1f72
Update hello_world_model.md (#580) 2021-11-09 13:59:06 +00:00
Anton Schwaighofer bf4cb628c6
Switching batch time loading diagnostics to hi-ml (#577)
- Using the BatchTimeCallback from hi-ml
- Switches to trigger PL profiling
2021-11-03 15:48:10 +00:00
Jonathan Tripp 0e50ad58dd
Document Segmentation Model Evaluation (#544) 2021-10-22 11:51:01 +01:00
vale-salvatelli 521c004357
Generalize SSL functionality to work on other datasets (#555)
This PR contains some changes needed to make the SSLContainer compatible with new datasets and allow a user to run by simply creating a new augmentation config or defining a child class

* _get_transforms has been changed to accept new datasets without the need to touch the class
* get_cxr_ssl_transform has been changed to avoid the hidden channel expansion and make that optional. It has been also renamed to get_ssl_transform because it has nothing specific to cxr
* drop_last is now set as parameter of the InnerEyeVisionDataModule and the SSLContainer - that means it can be changed when initializing a new SSLContainer
* documentation about bringing your own SSL model has been updated
2021-09-15 10:48:29 +00:00
Anton Schwaighofer b35399fb84
Moving InnerEye's Azure code to hi-ml package (#548)
Moving InnerEye to use the new HI-ML package. 

See Issue 62 on the HI-ML package
2021-08-26 09:17:09 +01:00
vale-salvatelli c946c689aa
Environment and hello_world_model documentation updated (#546)
* Some additions and fix to the docs describing how to setup the environment. The new version should be a little more clear.
* A small change in the logging info when submitting azureml - the workspace name is now reporte
2021-07-27 09:28:17 +01:00
Shruthi42 9fcc08f6cd
Run inference using checkpoints from registered models (#509) 2021-07-15 14:31:15 +00:00
Tim Regan 3fc71b847e
Timregan/459 partial ground truth missed two things (#522)
* Fixing unit test

My approach was wrong, since it only tested the first time the mocked function was called.
I've swapped to Anton's suggestion by adding return values so that the mock can be called
multiple times in a test execution.

* Missing documentation
2021-07-06 11:18:53 +01:00
Alberto Santamaria-Pang d6d67bda10
Added ability to run segmentation inference module in the test data without or partial ground truth files. (#465)
Inference should become more flexible to work also on datasets where we do not have segmentations yet, or only some of the structures segmented. This will prove especially useful for partners like UCLH. Done by adding `allow_incomplete_labels` to the relevant methods.
2021-07-05 16:22:13 +00:00
Jonathan Tripp cab68ccc61
Split validation and test infer config (#502)
Split validation, test, ensemble inference flags
2021-07-05 16:25:49 +01:00
Tim Regan c2f0d668e8
Allow cross validation with 'bring your own' Lightning models (without ensemble building) (#483)
Allows cross validation with 'bring your own' Lightning models (without ensemble building).

Moved the code dealing with hyperdrive config retrieval from ModelConfigBase into it's base class WorkflowParams
so that it is available (and implemented) in LightningContainer

Removed the exception thrown in runner when trying to use cross validation with LightningContainer.

Added cross validation to HelloContainer (and especially its HelloDataModule) as exemplar code, and documentation to point to this change.

Three new unit tests:
1) That cross validation is handled correctly for LightningContainer in runner
2) That LightningContainer converts ScriptRunConfig into HyperDriveConfig
3) The cross validation functionality in HelloDataModule
2021-06-24 20:53:40 +01:00
Anton Schwaighofer be36e39206
Bug fix for regression test (#496)
- The regresssion test code in #492 missed out files in AzureML, because the wrong function was called in the main workflow.
- Cleaner folder structure for regression test results
2021-06-21 14:39:09 +01:00
Anton Schwaighofer 9749954923
Fix for stuck test set inference for LightningContainer models (#494)
Jobs got stuck if they used PyTorch Lightning built-in metrics objects, which were then trying to synchronize across GPUs. Resolved by shutting down torch.distributed
2021-06-17 17:34:26 +01:00
Jonathan Tripp 0f710dd452
Check bool parameter is either true or false (after lower) (#482)
Add test that a boolean command line parameter is one of: 'on', 't', 'true', 'y', 'yes', '1' (for true) or 'off', 'f', 'false', 'n', 'no', '0' (for false) after lower()
If a flag default is False, then allow --flag to set it to True (so the ==True is unnecessary)
If a flag default is True, then allow --no-flag to set it to False (so the ==False is unnecessary)
2021-06-10 17:11:46 +01:00
Anton Schwaighofer 5af8b01dc1
Update documentation for submodules (#481)
The current documentation uses the submodule setup at many places. However, we found that it can easily mislead users. Switching to suggesting plain forking.
2021-06-09 17:35:51 +01:00
Anton Schwaighofer 5c5687bf61
Extend documentation for fastMRI (#468) 2021-06-01 11:00:33 +01:00
melanibe 51274c8bdc
Update augmentation pipeline (#458)
* Refractor augmentations initial commit

* Test custom transforms and transform pipeline

* Make transforms independent of config

* Add placeholder to doc as reminder

* Update tests

* Update tests

* Add test for affine

* Add tests for color transform

* Add a todo list

* Adding new test and simplifying the transforms API further

* New tests for new custom transforms

* Remove deprecated file

* Update all transforms

* Add test for custom pipeline transform

* Fix the full pipeline test

* Rename

* SImplify feeding in transforms

* Updating CHANGELOG.md

* Updating CHANGELOG.md

* Flake8

* Simplify more

* Fixes

* Fixes

* Flake8

* Fix few things

* Fix few things

* Updating tests for new API

* Simplify image versus sample

* Update

* Update

* Update

* Update

* Error in test copy paste

* Style

* Add augmentation doc

* Add augmentation doc

* Doc strings

* Flake8

* Flake8

* Mypy

* Fix test and docstring

* Put back skipif windows

* flake8

* mypy

* Skip if OOM

* Skip if OOM

* Import was missing

* Separate transform pipeline from ScalarItem management.

* Update documentation to new API

* Accidental commit

* PR suggestion

* Make test for elastic human checkable

* Make test for elastic human checkable

* Update with p=0

* Update with p=0

* Add human readable test output for gamma transform

* Solve OOM, remove duplicate test input definitions

* Flake8

* Mypy

* Fix config

* Add check PR comment

* PR comment
2021-06-01 09:29:57 +01:00