-
Notifications
You must be signed in to change notification settings - Fork 50
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix breast density example application to make it work with SDK v0.6+ (…
…#491) * Fix this example application to make it work with SDK v0.6+ Signed-off-by: M Q <[email protected]> * Fix the example app errors and corrected folder name Signed-off-by: M Q <[email protected]> --------- Signed-off-by: M Q <[email protected]>
- Loading branch information
Showing
8 changed files
with
62 additions
and
34 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
## A MONAI Application Package to deploy breast density classification algorithm | ||
This MAP is based on the Breast Density Model in MONAI [Model-Zoo](https://github.com/Project-MONAI/model-zoo). This model is developed at the Center for Augmented Intelligence in Imaging at the Mayo Clinic, Florida. | ||
For any questions, feel free to contact Vikash Gupta ([email protected]) | ||
Sample data and a torchscript model can be downloaded from https://drive.google.com/drive/folders/1Dryozl2MwNunpsGaFPVoaKBLkNbVM3Hu?usp=sharing | ||
|
||
|
||
## Run the application code with Python interpreter | ||
``` | ||
python app.py -i <input_dir> -o <out_dir> -m <breast_density_model> | ||
``` | ||
|
||
## Package the application as a MONAI Application Package (contianer image) | ||
In order to build the MONAI App Package, go a level up and execute the following command. | ||
``` | ||
monai-deploy package breast_density_classification_app -m <breast_density_model> -c breast_density_classifer_app/app.yaml --tag breast_density:0.1.0 --platform x64-workstation -l DEBUG | ||
``` | ||
|
||
## Run the MONAI Application Package using MONAI Deploy CLI | ||
``` | ||
monai-deploy run breast_density-x64-workstation-dgpu-linux-amd64:0.1.0 -i <input_dir> -o <output_dir> | ||
``` | ||
|
||
Once the container exits successfully, check the results in the output directory. There should be a newly creeated DICOM instance file and a `output.json` file containing the classification results. |
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
%YAML 1.2 | ||
# SPDX-FileCopyrightText: Copyright (c) 2022-2023 MONAI. All rights reserved. | ||
# SPDX-License-Identifier: Apache-2.0 | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
--- | ||
application: | ||
title: MONAI Deploy App Package - Spleen Seg Inference | ||
version: 1.0 | ||
inputFormats: ["file"] | ||
outputFormats: ["file"] | ||
|
||
resources: | ||
cpu: 1 | ||
gpu: 1 | ||
memory: 1Gi | ||
gpuMemory: 2Gi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
highdicom>=0.18.2 | ||
monai>=1.2.0 | ||
pydicom>=2.3.0 | ||
torch>=1.12.0 |