Home
last modified time | relevance | path

Searched refs:tensor_like (Results 1 – 3 of 3) sorted by relevance

/external/executorch/devtools/bundled_program/
Dbundled_program.cpp45 at::Tensor tensor_like(bundled_program_flatbuffer::Tensor* bundled_tensor) { in tensor_like() function
284 Tensor t = tensor_like(bundled_input_tensor); in load_bundled_input()
377 Tensor t = tensor_like(bundled_expected_output_tensor); in verify_method_outputs()
/external/pytorch/torch/testing/
D_comparison.py680 def _to_tensor(self, tensor_like: Any) -> torch.Tensor:
681 if isinstance(tensor_like, torch.Tensor):
682 return tensor_like
685 return torch.as_tensor(tensor_like)
/external/pytorch/torch/testing/_internal/
Dcommon_utils.py3751 def compare_with_numpy(self, torch_fn, np_fn, tensor_like, argument
3755 if isinstance(tensor_like, torch.Tensor):
3758 t_cpu = tensor_like.detach().cpu()
3762 t = tensor_like
3766 a = np.array(tensor_like, dtype=d[dtype])
3767 t = torch.tensor(tensor_like, device=device, dtype=dtype)