Typedef CustomGetNextInputFn_t

Typedef Documentation

typedef bool (*CustomGetNextInputFn_t)(void *input_context, const char *name, const void **content, uint64_t *content_byte_size)

Type for the CustomGetNextInput callback function.

This callback function is provided in the call to ComputeExecute and is used to get the value of the input tensors. Each call to this function returns a contiguous block of the input tensor value. The entire tensor value may be in multiple non-contiguous blocks and so this function must be called multiple times until ‘content’ returns nullptr. This callback function is not thread safe.


false if error, true if success.

  • input_context: The input context provided in call to CustomExecute.

  • name: The name of the input tensor.

  • content: Returns a pointer to the next contiguous block of content for the named input. Returns nullptr if there is no more content for the input.

  • content_byte_size: Acts as both input and output. On input gives the maximum size expected for ‘content’. Returns the actual size, in bytes, of ‘content’.