-
Notifications
You must be signed in to change notification settings - Fork 57
Packaging app
In this step, the MONAI SDK application can now be built into a deployable Docker image using the MONAI Application Packager
The MONAI Application Packager (Packager) is a utility for building an application developed with the MONAI SDK into a structured MONAI application package (MAP).
The MAP produced by the Packager is a deployable and reusable docker image that can be launched locally or remotely
monai-deploy package [Path of MONAI Application Code] -t [Tag for resulting Docker image of MONAI App Package]
-
<MONAI application path>
Path of MONAI Application Code -
--tag, -t
Tag for resulting Docker image of MONAI App Package
The following arguments have default values or are provided through the SDK if not specified. However, the user has the option to override these values if the choose to invoke the following flags
-
--base
Base Application Image (overrides default"nvcr.io/nvidia/pytorch:21.07-py3"
) -
--input-dir, -i
Directory mounted in container for Application Input (overrides default"input"
) -
--models-dir
Directory mounted in container for Models Path (overrides default"/opt/monai/models"
) -
--model, -m
Path to local directory containing all application models (will override utilizing models provided within application SDK code) -
--output-dir, -o
Directory mounted in container for Application Output (overrides default"output"
) -
--timeout
Timeout (overrides default0
) -
--version
Version of the Application (overrides default"0.0.0"
) -
--working-dir, -w
Directory mounted in container for Application (overrides default"/var/monai"
)
Given an example MONAI SDK application with its code residing in a directory ./spleen_segmentation_app
, packaging this application with the Packager to create an Docker image tagged monaispleen:latest
would look like this:
$ monai-deploy package ./spleen_segmentation_app -t monaispleen:latest
Building MONAI Application Package...
Successfully built monaispleen:latest
INTRODUCTION
GETTING STARTED
DEVELOPING WITH SDK
- Core concepts
- Creating Operator classes
- Creating Application class
- Executing app locally
- Packaging app
- Executing packaged app locally
- Deploy to the remote server - coming soon
MODULES