Function TRTSERVER_InferenceResponseOutputData

Function Documentation

TRTSERVER_Error *TRTSERVER_InferenceResponseOutputData(TRTSERVER_InferenceResponse *response, const char *name, const void **base, size_t *byte_size, TRTSERVER_Memory_Type *memory_type, int64_t *memory_type_id)

Get the results data for a named output.

The result data is returned as the base pointer to the data and the size, in bytes, of the data. The caller does not own the returned data and must not modify or delete it. The lifetime of the returned data extends only as long as ‘response’ and must not be accessed once ‘response’ is deleted.

Return

a TRTSERVER_Error indicating success or failure.

Parameters
  • response: The response object.

  • name: The name of the output.

  • base: Returns the result data for the named output.

  • byte_size: Returns the size, in bytes, of the output data.

  • memory_type: Returns the memory type of the output data.

  • memory_type_id: Returns the memory type id of the output data.