Base#
Provides the most basic view into the model. This view will
simply apply the model to the provided data and return the
model-output along with the model-output
- gordo.server.blueprints.base.delete_model_revision(gordo_name: str, revision: str, **kwargs)[source]#
Delete provided model revision from the disk.
- gordo.server.blueprints.base.get(gordo_project: str)[source]#
Returns list of models for this project. Those models are expected to be built.
- gordo.server.blueprints.base.get_download_model()[source]#
Download the trained model
Responds with a serialized copy of the current model being served.
- Return type:
Results from
gordo.serializer.dumps()
- gordo.server.blueprints.base.get_metadata()[source]#
Serve model / server metadata
Get metadata about this endpoint, also serves as /healthcheck endpoint
- gordo.server.blueprints.base.get_model_list(gordo_project: str)[source]#
List the current models capable of being served by the server
- gordo.server.blueprints.base.get_revision_list(gordo_project: str)[source]#
List the available revisions the model can serve.
- gordo.server.blueprints.base.post_prediction()[source]#
Process a POST request by using provided user data
A typical response might look like this
{ 'data': [ { 'end': ['2016-01-01T00:10:00+00:00'], 'model-output': [0.0005317790200933814, -0.0001525811239844188, 0.0008310950361192226, 0.0015755111817270517], 'original-input': [0.9135588550070414, 0.3472517774179448, 0.8994921857179736, 0.11982773108991263], 'start': ['2016-01-01T00:00:00+00:00'], }, ... ], 'tags': [ {'asset': None, 'name': 'tag-0'}, {'asset': None, 'name': 'tag-1'}, {'asset': None, 'name': 'tag-2'}, {'asset': None, 'name': 'tag-3'} ], 'time-seconds': '0.1937' }