CV-CUDA
CV-CUDA copied to clipboard
[FEATURE] How to handle 5D tensors like NTHWC in cvcuda?
HI, I would like to expand one more dim to the nvcv::tensor in cpp, but I mentioned that the nvcv only supports 3D formats like RGB, thus I can only build 4D tensors like NHWC. So is there a way to expand the Time dim of my data tensor?
We do not have a current plan for supporting higher rank (rank > 4) tensors at this moment. However, we can investigate this feature for future releases.
@WangChyanhassth-2say, can you provide some use cases you foresee for higher rank tensors?
Yes, what I meet here is a video action classification model, which has a 5D input dims as [batchsize, 8, 3, 224, 224](8 is the timestep) and the output as [batchsize, classes]. Since we only got methods for 4D tensors, I try to modify my model with a squeeze and an unsqueeze layer to the input and output, thus the input is modified to [8, 3, 224, 224] while the output as [classes] so I can use 4D methods to preprocess my data, seeing the timestep 8 as batchsize.
It can run but the data between batchsizes seems to be unsorted, so it may influence the performance of the model : (
So I hope that cvcuda can give the plan to handle with 5D tensors with a correct method.
To me it's basicly NTHWC data, thx a lot.