Skip to content

Instantly share code, notes, and snippets.

@sjs7007
Created January 11, 2017 02:37
Show Gist options
  • Save sjs7007/c9f5fed34a33df3b343f3979ec5b654e to your computer and use it in GitHub Desktop.
Save sjs7007/c9f5fed34a33df3b343f3979ec5b654e to your computer and use it in GitHub Desktop.
Swagger code for API description of MNIST trainer for Deep Cloud
/uploadCompleteScript:
post:
tags:
- MNIST
description: >-
Allows user to upload the [MNIST
dataset](https://drive.google.com/open?id=0B-HwpreJA3WzbnZodkJZVWNfUTg)
and get a trained model based on the parameters specified. Description
about the dataset can be found
[here](http://yann.lecun.com/exdb/mnist/).
operationId: getAqi
produces:
- text
consumes:
- multipart/form-data
parameters:
- name: width
in: formData
description: width of image
default: 28
required: true
type: integer
- name: height
in: formData
description: height of image
default: 28
required: true
type: integer
- name: nClass
in: formData
description: number of classes
default: 10
required: true
type: integer
- name: alpha
in: formData
description: learning rate
default: 0.01
required: true
type: number
- name: upload
in: formData
description: >-
[MNIST
dataset](https://drive.google.com/open?id=0B-HwpreJA3WzbnZodkJZVWNfUTg)
required: true
type: file
responses:
'200':
description: 'JSON with accuracies at different epochs, model path'
schema:
properties:
Accuracy:
type: string
trainedModel:
type: string
'500':
description: process got killed / tensorflow crashed
default:
description: unexpected error
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment