Marcel-Rodekamp / NSL

Nanosystem Simulation Library (NSL) implements statistical simulations for systems on the nanoscale
Other
2 stars 0 forks source link

Check that tensor types are correct #153

Open Chrisgant opened 11 months ago

Chrisgant commented 11 months ago

https://github.com/Marcel-Rodekamp/NSL/blob/4a32d0cbf04f8052381f761d60bb565aa0664d81/src/NSL/Tensor/Impl/base.tpp#L133C9-L133C9

>>>t = nsl.Tensor_int(torch.rand(3,4))
>>> t.to_torch()
tensor([[0.1307, 0.5874, 0.1818, 0.7885],
        [0.0867, 0.9225, 0.0650, 0.9214],
        [0.5660, 0.1690, 0.2450, 0.2273]])