MCPcopy Create free account
hub / github.com/AiuniAI/Unique3D / tensor

Function tensor

mesh_reconstruction/render.py:9–10  ·  view source on GitHub ↗
(*args, **kwargs)

Source from the content-addressed store, hash-verified

7 device = 'cuda' if device is None else device
8 #windows workaround for https://github.com/NVlabs/nvdiffrast/issues/59
9 def tensor(*args, **kwargs):
10 return torch.tensor(*args, device=device, **kwargs)
11 pos = tensor([[[-0.8, -0.8, 0, 1], [0.8, -0.8, 0, 1], [-0.8, 0.8, 0, 1]]], dtype=torch.float32)
12 tri = tensor([[0, 1, 2]], dtype=torch.int32)
13 dr.rasterize(glctx, pos, tri, resolution=[256, 256])

Callers 1

_warmupFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected