get_model_metadata(request)Send GrpcModelMetadataRequest to the server and return response.
Args:
request:GrpcModelMetadataRequestobject.
Returns:
GrpcModelMetadataResponse object
Raises:
TypeError: if request argument is of wrong type.ValueError: if request argument has invalid contents.ConnectionError: if there was an error while sending request to the server.
Examples:
config = {
"address": "localhost",
"port": 9000
}
client = make_grpc_client(config)
request = make_model_metadata_request("model")
response = client.get_model_metadata(request)get_model_status(request)Send GrpcModelStatusRequest to the server and return response.
Args:
request:GrpcModelStatusRequestobject.
Returns:
GrpcModelStatusResponse object
Raises:
TypeError: if request argument is of wrong type.ValueError: if request argument has invalid contents.ConnectionError: if there was an error while sending request to the server.
Examples:
config = {
"address": "localhost",
"port": 9000
}
client = make_grpc_client(config)
request = make_model_status_request("model")
response = client.get_model_status(request)predict(request)Send GrpcPredictRequest to the server and return response.
Args:
request:GrpcPredictRequestobject.
Returns:
GrpcPredictResponse object
Raises:
TypeError: if request argument is of wrong type.ValueError: if request argument has invalid contents.ConnectionError: if there was an error while sending request to the server.
Examples:
config = {
"address": "localhost",
"port": 9000
}
client = make_grpc_client(config)
request = make_predict_request({"input": [1, 2, 3]}, "model")
response = client.predict(request)