2b32895c3178a412a701aba09dbad821d8acbd1a,test/color/test_hls.py,TestRgbToHls,test_rgb_to_hls,#TestRgbToHls#Any#,19
Before Change
data = torch.rand(3, 5, 5).to(device)
// OpenCV
data_cv = data.cpu().detach().numpy().transpose(1, 2, 0)
expected = cv2.cvtColor(data_cv, cv2.COLOR_RGB2HLS)
expected = torch.from_numpy(expected).to(device)
h_expected = 2 * math.pi * expected[:, :, 0] / 360.
After Change
data = torch.rand(3, 5, 5).to(device)
// OpenCV
data_cv = kornia.tensor_to_image(data.clone())
expected = cv2.cvtColor(data_cv, cv2.COLOR_RGB2HLS)
expected = kornia.image_to_tensor(expected, True).to(device)
expected[0] = 2 * math.pi * expected[0] / 360.
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 5
Instances
Project Name: arraiy/torchgeometry
Commit Name: 2b32895c3178a412a701aba09dbad821d8acbd1a
Time: 2019-11-19
Author: edgar.riba@gmail.com
File Name: test/color/test_hls.py
Class Name: TestRgbToHls
Method Name: test_rgb_to_hls
Project Name: arraiy/torchgeometry
Commit Name: 2b32895c3178a412a701aba09dbad821d8acbd1a
Time: 2019-11-19
Author: edgar.riba@gmail.com
File Name: test/color/test_hsv.py
Class Name: TestHsvToRgb
Method Name: test_hsv_to_rgb
Project Name: arraiy/torchgeometry
Commit Name: 2b32895c3178a412a701aba09dbad821d8acbd1a
Time: 2019-11-19
Author: edgar.riba@gmail.com
File Name: test/color/test_hls.py
Class Name: TestHlsToRgb
Method Name: test_hls_to_rgb