Response to Reviewer 6dEW (part-2)
## **Supplement to FA2:**
### **Example of 2D Positional Encoding:**
Assume an input image of size 3x3:
| Patch0 (0, 0) | Patch1 (0, 1) | Patch2 (0, 2) |
| --- | --- | --- |
| Patch3 (1, 0) | Patch4 (1, 1) | Patch5 (1, 2) |
| Patch6 (2, 0) | Patch7 (2, 1) | Patch8 (2, 2) |
In a Vision Transformer (ViT), positional encoding (PosEmb) is based on token indices:
- PosEmb(0, 0) + Patch 0 -> [Final Embedding 0]
- PosEmb(0, 1) + Patch 1 -> [Final Embedding 1]
- PosEmb(0, 2) + Patch 2 -> [Final Embedding 2]
- PosEmb(1, 0) + Patch 3 -> [Final Embedding 3]
- PosEmb(1, 1) + Patch 4 -> [Final Embedding 4]
- PosEmb(1, 2) + Patch 5 -> [Final Embedding 5]
- PosEmb(2, 0) + Patch 6 -> [Final Embedding 6]
- PosEmb(2, 1) + Patch 7 -> [Final Embedding 7]
- PosEmb(2, 2) + Patch 8 -> [Final Embedding 8]
Assume the modified input order is as follows:
| Patch8 (0, 0) | Patch0 (0, 1) | Patch7 (0,2) |
| --- | --- | --- |
| Patch1 (1, 0) | Patch6 (1, 1) | Patch2 (1, 2) |
| Patch5 (2, 0) | Patch3 (2, 1) | Patch4 (2, 2) |
The final features will be:
- **PosEmb(0, 0) + Patch 8** -> [Final Embedding 0]
- **PosEmb(0, 1) + Patch 0** -> [Final Embedding 1]
- **PosEmb(0, 2) + Patch 7** -> [Final Embedding 2]
- **PosEmb(1, 0) + Patch 1** -> [Final Embedding 3]
- **PosEmb(1, 1) + Patch 6** -> [Final Embedding 4]
- **PosEmb(1, 2) + Patch 2** -> [Final Embedding 5]
- **PosEmb(2, 0) + Patch 5** -> [Final Embedding 6]
- **PosEmb(2, 1) + Patch 3** -> [Final Embedding 7]
- **PosEmb(2, 2) + Patch 4** -> [Final Embedding 8]
If the order of the input tokens is changed, the final embeddings will differ, leading to different outcomes.
### **Example of 3D Positional Encoding:**
Assume a point cloud with the following data:
| Point Index | xyz | rgb |
| --- | --- | --- |
| Point 1 | (1.0, 2.0, 3.0) | (255, 0, 0) |
| Point 2 | (4.0, 5.0, 6.0) | (0, 255, 0) |
| Point 3 | (7.0, 8.0, 9.0) | (0, 0, 255) |
| Point 4 | (1.5, 2.5, 3.5) | (255, 255, 0) |
| Point 5 | (4.5, 5.5, 6.5) | (255, 0, 255) |
| Point 6 | (7.5, 8.5, 9.5) | (0, 255, 255) |
| Point 7 | (2.0, 3.0, 4.0) | (128, 128, 128) |
| Point 8 | (5.0, 6.0, 7.0) | (64, 64, 64) |
| Point 9 | (8.0, 9.0, 10.0) | (192, 192, 192) |
**Where:**
- The `xyz` column represents the coordinates (x, y, z) of the point cloud, indicating the three-dimensional spatial positions relative to the scene center (0, 0, 0) in the scene coordinate system.
- The `rgb` column denotes the color (r, g, b) of the point cloud.
An example of the 3D absolute positional encoding is as follows:
| Point Index | xyz | Point Feature | Positional Encoding | Final Embedding |
| --- | --- | --- | --- | --- |
| Point 1 | (1.0, 2.0, 3.0) | PointFeat 1 | PosEmb(1.0, 2.0, 3.0) | PointFeat 1 + PosEmb(1.0, 2.0, 3.0) |
| Point 2 | (4.0, 5.0, 6.0) | PointFeat 2 | PosEmb(4.0, 5.0, 6.0) | PointFeat 2 + PosEmb(4.0, 5.0, 6.0) |
| Point 3 | (7.0, 8.0, 9.0) | PointFeat 3 | PosEmb(7.0, 8.0, 9.0) | PointFeat 3 + PosEmb(7.0, 8.0, 9.0) |
| Point 4 | (1.5, 2.5, 3.5) | PointFeat 4 | PosEmb(1.5, 2.5, 3.5) | PointFeat 4 + PosEmb(1.5, 2.5, 3.5) |
| Point 5 | (4.5, 5.5, 6.5) | PointFeat 5 | PosEmb(4.5, 5.5, 6.5) | PointFeat 5 + PosEmb(4.5, 5.5, 6.5) |
| Point 6 | (7.5, 8.5, 9.5) | PointFeat 6 | PosEmb(7.5, 8.5, 9.5) | PointFeat 6 + PosEmb(7.5, 8.5, 9.5) |
| Point 7 | (2.0, 3.0, 4.0) | PointFeat 7 | PosEmb(2.0, 3.0, 4.0) | PointFeat 7 + PosEmb(2.0, 3.0, 4.0) |
| Point 8 | (5.0, 6.0, 7.0) | PointFeat 8 | PosEmb(5.0, 6.0, 7.0) | PointFeat 8 + PosEmb(5.0, 6.0, 7.0) |
| Point 9 | (8.0, 9.0, 10.0) | PointFeat 9 | PosEmb(8.0, 9.0, 10.0) | PointFeat 9 + PosEmb(8.0, 9.0, 10.0) |
**Where:**
- The **Point Cloud Feature (PointFeat)** column represents the features of the point cloud using `PointFeat`.
- The **Positional Encoding (PosEmb)** column displays the positional encoding for each point in the point cloud, where `PosEmb` denotes the positional encoding function.
- The **Final Feature (PointFeat + PosEmb)** column illustrates the combined result of the point cloud features and the positional encoding, represented as `PointFeat` plus `PosEmb`.
In 3D encoding, even if the input order is changed, each point’s representation remains consistent, and thus, the final output remains unchanged. However, positional information is still inherently embedded within the point cloud. We will incorporate this discussion into the revised supplementary material to make the explanation clearer.