Commit 06cdc31
PyTorch3D - Avoid flip in TexturesAtlas
Summary: Performance improvement: Use torch.lerp to map uv coordinates to the range needed for grid_sample (i.e. map [0, 1] to [-1, 1] and invert the y-axis)
Reviewed By: bottler
Differential Revision: D51961728
fbshipit-source-id: db19a5e3f482e9af7b96b20f88a1e5d0076dac431 parent 94da884 commit 06cdc31
File tree
2 files changed
+13
-5
lines changed- pytorch3d/renderer/mesh
- tests
2 files changed
+13
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
995 | 995 | | |
996 | 996 | | |
997 | 997 | | |
998 | | - | |
| 998 | + | |
| 999 | + | |
| 1000 | + | |
| 1001 | + | |
| 1002 | + | |
| 1003 | + | |
999 | 1004 | | |
1000 | | - | |
1001 | 1005 | | |
1002 | 1006 | | |
1003 | 1007 | | |
| |||
1035 | 1039 | | |
1036 | 1040 | | |
1037 | 1041 | | |
1038 | | - | |
1039 | | - | |
| 1042 | + | |
| 1043 | + | |
| 1044 | + | |
| 1045 | + | |
| 1046 | + | |
| 1047 | + | |
1040 | 1048 | | |
1041 | 1049 | | |
1042 | 1050 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
932 | 932 | | |
933 | 933 | | |
934 | 934 | | |
935 | | - | |
| 935 | + | |
936 | 936 | | |
937 | 937 | | |
938 | 938 | | |
| |||
0 commit comments