morpheus.messages.multi_inference_message.InferenceMemoryNLP

class InferenceMemoryNLP(*args, **kwargs)[source]

Bases: morpheus.messages.multi_inference_message.InferenceMemory

This is a container class for data that needs to be submitted to the inference server for NLP category usecases.

Parameters
input_idscupy.ndarray

The token-ids for each string padded with 0s to max_length.

input_maskcupy.ndarray

The mask for token-ids result where corresponding positions identify valid token-id values.

seq_idscupy.ndarray

Ids used to index from an inference input to a message. Necessary since there can be more inference inputs than messages (i.e., if some messages get broken into multiple inference requests).

Attributes
input_ids
input_mask
seq_ids
© Copyright 2023, NVIDIA. Last updated on Feb 3, 2023.