You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It accept image bytes and decode it for next process steps, I use dali because dali can utilize GPU to accelerate decode process. The pipelne will be loaded by triton server, the config.pbtxt file is like below:
For all same images, I can use np.vstack to compose batch image to one input, because they have same bytes length, for example 4 image, each image have bytes length 430226, so I can compose it to one input which size is [4,4330226]. However, the reality is that not all images have the same dimensions, so they cannot be stacked together.So is there any way can post batch image data for one request in this situation?
The text was updated successfully, but these errors were encountered:
Hello @DequanZhu
Triton accepts only requests with batches of uniformly sized samples.
The trick to batch together encoded images of different lengths is to pad them with zeros to equal size. The zeroed suffix will be ignored by the decoder.
Triton server can also take advantage of dynanmic_batching. It's enabled by default for DALI models and it accepts so called ragged_batches, so it can batch together samples of different shapes. This way, even when sending images of different lengths, server can batch them together if they arrive in a time window that is short enough (time window can be configured, see https://github.com/triton-inference-server/server/blob/main/docs/user_guide/model_configuration.md#dynamic-batcher)
I hava a dali pipeline like below:
It accept image bytes and decode it for next process steps, I use dali because dali can utilize GPU to accelerate decode process. The pipelne will be loaded by triton server, the config.pbtxt file is like below:
because each image bytes length is different, so input data dimension is [-1]. I use triton-client to exec infer request for my model:
For all same images, I can use np.vstack to compose batch image to one input, because they have same bytes length, for example 4 image, each image have bytes length 430226, so I can compose it to one input which size is [4,4330226]. However, the reality is that not all images have the same dimensions, so they cannot be stacked together.So is there any way can post batch image data for one request in this situation?
The text was updated successfully, but these errors were encountered: