(self)
| 41 | assert np.isclose(out_dict['t_far'].detach().cpu().numpy(), 10.) |
| 42 | |
| 43 | def test_3(self): |
| 44 | N = 10000 |
| 45 | stime = timer() |
| 46 | for _ in range(N): |
| 47 | out_dict = utils.ray_aabb_intersection( |
| 48 | ray_origin=torch.zeros(3), |
| 49 | ray_direction=torch.tensor([0,0,1.]), |
| 50 | bbox_min_bounds=torch.tensor([1, 1, 2.]), |
| 51 | bbox_max_bounds=torch.tensor([10, 10, 10.]), |
| 52 | ) |
| 53 | etime = timer() |
| 54 | print(f'v1 takes {(etime - stime) / N} secs per test') |
| 55 | assert out_dict['is_intersected'] == False |
| 56 | |
| 57 | |
| 58 |
nothing calls this directly
no outgoing calls
no test coverage detected