MCPcopy Create free account
hub / github.com/alpha2phi/python-apps / predict

Function predict

sagemaker-serverless/test_inference_dash.py:40–44  ·  view source on GitHub ↗
(contents)

Source from the content-addressed store, hash-verified

38
39
40def predict(contents):
41 payload = contents[contents.find(",") + 1:]
42 data = {"data": payload}
43 response = requests.post(API_URL, data=json.dumps(data))
44 return response.text
45
46
47@app.callback(Output('output', 'children'), [Input('upload', 'contents')])

Callers 1

update_outputFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected