MIOpen
MIOpen copied to clipboard
[softmax] Store full info about unpacked tensors in the problem descriptor
Originated from: https://github.com/ROCm/MIOpen/pull/2782#discussion_r1515323515
Currently we do not store full information about unpacked tensors, only the flag. Also we do not store information about tensor layouts, at all. The above means that we'll need to extend the network config when support for unpacked tensors or support for different layouts is required.
If this is not done, then, for example, MIOpen won't be able to distinguish between two invokers when unpacked tensors are used (same NCHW but different strides).
Right now this only a potential problem. However, it will become real when/if we will support upacked tensors, or when/if or serialized softmax PD will be used as a key for the persistent databases (as this change in the db key will lead to backward incompatibility of the databases).
This could be resolved automatically by implementing #2812.
[Attribution] @junliume @JehandadKhan
- https://github.com/ROCm/MIOpen/labels/correctness (potentially)
- https://github.com/ROCm/MIOpen/labels/urgency_low
- https://github.com/ROCm/MIOpen/labels/value_high
- Proposed assignees:
- @CAHEK7
- @Vsevolod1983
- Just to stay in the loop: @averinevg @atamazov @DrizztDoUrden
Hey HI team, I was reading about our documentation and ended up checking this. how are we finding out whether tensor is packed or unpacked , is by doing profiling or we are defining it when we are initializing the tensor, i mean like metadata . could you let me know ..
@Pavanmahaveer7 An unpacked tensor has "holes" in its layout, which is defined by its strides. Right now the easiest way to check for that in the existing code is to compare the "size" of tensor (its dimensions multiplied) to its "space" (the total length of continuous memory required to store it). Both of them have existing methods in TesnsorDescriptor
. If they are not equal, a tensor is considered unpacked. IIRC this is the exact way it is usually check in the library.
Thank you Filippov for explaining.