Last active
April 9, 2019 01:18
-
-
Save SachidanandAlle/9b515d9f969eed9d324bb929c121771c to your computer and use it in GitHub Desktop.
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
openapi: 3.0.0 | |
info: | |
title: AI Annotation Assistance server API | |
description: >- | |
NVIDIA Deep Learning for Medical Imaging. Artificial Intelligence | |
Annotation Assistance server API specification. This specification defines | |
the inferencing and smart polygon API. | |
version: '0.1' | |
paths: | |
/v1/models: | |
get: | |
summary: Retrieve the list of all available models | |
description: >- | |
Retrieve the list of all models currently available from this AIAA | |
server. Multiple models can be instantiated on the same server. | |
tags: | |
- Registry | |
responses: | |
'200': | |
description: OK | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/ListOfModels' | |
/v1/model: | |
get: | |
summary: Retrieve model info | |
description: >- | |
Retrieve detailed model config info currently available from this AIAA | |
server. | |
tags: | |
- Registry | |
parameters: | |
- in: query | |
name: model | |
required: true | |
schema: | |
type: string | |
description: The model name | |
responses: | |
'200': | |
description: OK | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/ModelConfig' | |
/v1/reload: | |
post: | |
summary: Reload a model | |
description: Reload a model for when configuration or model file is updated. | |
tags: | |
- Registry | |
parameters: | |
- in: query | |
name: model | |
required: true | |
schema: | |
type: string | |
description: The model to reload | |
- in: query | |
name: force | |
schema: | |
type: boolean | |
description: Force reload if model is not pre-existing | |
responses: | |
'200': | |
description: OK | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/Model' | |
/v1/load: | |
put: | |
summary: Upload a new model | |
description: Upload a model and run a new model. | |
tags: | |
- Registry | |
parameters: | |
- in: query | |
name: model | |
required: true | |
schema: | |
type: string | |
description: The model to reload | |
requestBody: | |
required: true | |
content: | |
application/json: | |
schema: | |
$ref: '#/components/schemas/ModelConfig' | |
responses: | |
'200': | |
description: OK | |
content: | |
application/json: | |
schema: | |
type: string | |
/v1/dextr3d: | |
post: | |
summary: Request segmentation on 3D NIFTI image | |
description: >- | |
Specify a model to perform segmentation task with the uploaded NIFTI | |
image and related parameters. The server will return segmentation | |
results and associated information. | |
tags: | |
- Inference | |
parameters: | |
- in: query | |
name: model | |
required: true | |
schema: | |
type: string | |
description: The model used for the segmentation task | |
requestBody: | |
required: true | |
content: | |
multipart/form-data: | |
schema: | |
type: object | |
properties: | |
datapoint: | |
type: string | |
format: binary | |
description: The NIFTI image | |
params: | |
type: string | |
description: A json string used by model | |
responses: | |
'200': | |
description: OK | |
content: | |
application/json: | |
schema: | |
type: object | |
properties: | |
points: | |
type: string | |
description: A json string containing associated information | |
filename: | |
type: string | |
format: binary | |
/v1/mask2polygon: | |
post: | |
summary: Convert a 3D mask into slices of 2D polygons | |
description: >- | |
Given a 3D mask in NIFTI file, generate polygons (0 or more) on each 2D | |
slices. | |
tags: | |
- Polygon | |
requestBody: | |
required: true | |
content: | |
multipart/form-data: | |
schema: | |
type: object | |
properties: | |
datapoint: | |
type: string | |
format: binary | |
description: The NIFTI image | |
params: | |
type: string | |
description: A json string used by smart polygon tools | |
responses: | |
'200': | |
description: OK | |
content: | |
application/json: | |
schema: | |
type: string | |
/v1/fixpolygon: | |
post: | |
summary: Adjust polygons to a better-fit polygons | |
tags: | |
- Polygon | |
requestBody: | |
required: true | |
content: | |
multipart/form-data: | |
schema: | |
type: object | |
properties: | |
datapoint: | |
type: string | |
format: binary | |
description: The NIFTI image | |
params: | |
type: string | |
description: A json string used by model | |
responses: | |
'200': | |
description: OK | |
content: | |
application/json: | |
schema: | |
type: object | |
properties: | |
points: | |
type: string | |
description: A json string containing associated information | |
filename: | |
type: string | |
format: binary | |
components: | |
schemas: | |
Model: | |
type: object | |
properties: | |
name: | |
type: string | |
internal name: | |
type: string | |
labels: | |
type: array | |
items: | |
type: string | |
description: | |
type: string | |
roi: | |
type: array | |
items: | |
type: integer | |
sigma: | |
type: number | |
format: double | |
padding: | |
type: number | |
format: double | |
version: | |
type: string | |
example: | |
name: Liver | |
internal name: DExtr3D+Liver | |
labels: | |
- liver | |
description: 3D Liver Segmentation model | |
roi: | |
- 128 | |
- 128 | |
- 128 | |
sigma: 3 | |
padding: 20 | |
version: rc6 | |
ListOfModels: | |
type: array | |
items: | |
$ref: '#/components/schemas/Model' | |
Transforms: | |
type: object | |
properties: | |
name: | |
type: string | |
args: | |
type: object | |
additionalProperties: true | |
ModelConfig: | |
type: object | |
properties: | |
version: | |
type: string | |
labels: | |
type: array | |
items: | |
type: string | |
description: | |
type: string | |
path: | |
type: string | |
format: | |
type: string | |
threshold: | |
type: number | |
format: double | |
roi: | |
type: array | |
items: | |
type: integer | |
sigma: | |
type: number | |
format: double | |
padding: | |
type: number | |
format: double | |
metagraph_tag: | |
type: string | |
signature_tag: | |
type: string | |
input_nodes: | |
type: array | |
items: | |
type: object | |
properties: | |
image: | |
type: string | |
output_nodes: | |
type: array | |
items: | |
type: object | |
properties: | |
model: | |
type: string | |
pre_transforms: | |
type: array | |
items: | |
$ref: '#/components/schemas/Transforms' | |
post_transforms: | |
type: array | |
items: | |
$ref: '#/components/schemas/Transforms' | |
example: | |
version: '' | |
labels: [] | |
description: '' | |
path: '' | |
format: trtmodel | |
threshold: 0.5 | |
crop_size: | |
- 128 | |
- 128 | |
- 128 | |
sigma: 3 | |
padding: 20 | |
metagraph_tag: inference | |
signature_tag: inference_tensors | |
input_nodes: | |
image: cond/Merge | |
output_nodes: | |
model: NV_OUTPUT_LABEL | |
pre_transforms: | |
- name: VolumeTo4DArray | |
args: | |
fields: image | |
- name: ScaleIntensityRange | |
args: | |
field: image | |
a_min: -1024 | |
a_max: 1024 | |
b_min: -1 | |
b_max: 1 | |
clip: true | |
- name: AddExtremePointsChannel | |
args: | |
image_field: image | |
label_field: label | |
sigma: 3 | |
pert: 0 | |
post_transforms: | |
- name: SplitAcrossChannels | |
args: | |
applied_key: model | |
channel_names: | |
- background | |
- prediction |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment