Commit 02c320a
committed
Add CVCUDA backend for horizontal and vertical flip transforms
Summary:
Implemented _horizontal_flip_image_cvcuda and _vertical_flip_image_cvcuda
kernels using cvcuda.flip operator. The kernels are automatically registered
when CVCUDA is available and route cvcuda.Tensor inputs appropriately.
Test Plan:
- Added test_functional_cvcuda and test_image_correctness_cvcuda tests
- Verified parity between PyTorch and CVCUDA implementations
- All tests pass with CVCUDA backend
Reviewers:
Subscribers:
Tasks:
Tags:1 parent 617079d commit 02c320a
File tree
2 files changed
+56
-2
lines changed- test
- torchvision/transforms/v2/functional
2 files changed
+56
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1249 | 1249 | | |
1250 | 1250 | | |
1251 | 1251 | | |
| 1252 | + | |
| 1253 | + | |
| 1254 | + | |
| 1255 | + | |
1252 | 1256 | | |
1253 | 1257 | | |
1254 | 1258 | | |
| |||
1291 | 1295 | | |
1292 | 1296 | | |
1293 | 1297 | | |
| 1298 | + | |
| 1299 | + | |
| 1300 | + | |
| 1301 | + | |
| 1302 | + | |
| 1303 | + | |
| 1304 | + | |
| 1305 | + | |
| 1306 | + | |
| 1307 | + | |
| 1308 | + | |
| 1309 | + | |
| 1310 | + | |
| 1311 | + | |
1294 | 1312 | | |
1295 | 1313 | | |
1296 | 1314 | | |
| |||
1865 | 1883 | | |
1866 | 1884 | | |
1867 | 1885 | | |
| 1886 | + | |
| 1887 | + | |
| 1888 | + | |
| 1889 | + | |
1868 | 1890 | | |
1869 | 1891 | | |
1870 | 1892 | | |
| |||
1905 | 1927 | | |
1906 | 1928 | | |
1907 | 1929 | | |
| 1930 | + | |
| 1931 | + | |
| 1932 | + | |
| 1933 | + | |
| 1934 | + | |
| 1935 | + | |
| 1936 | + | |
| 1937 | + | |
| 1938 | + | |
| 1939 | + | |
| 1940 | + | |
| 1941 | + | |
1908 | 1942 | | |
1909 | 1943 | | |
1910 | 1944 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | | - | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
30 | 36 | | |
31 | 37 | | |
32 | 38 | | |
| |||
61 | 67 | | |
62 | 68 | | |
63 | 69 | | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
64 | 76 | | |
65 | 77 | | |
66 | 78 | | |
| |||
150 | 162 | | |
151 | 163 | | |
152 | 164 | | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
153 | 173 | | |
154 | 174 | | |
155 | 175 | | |
| |||
0 commit comments