You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
where = np.where((torch.cumsum(S[reverse], dim=0).detach().cpu() <= delta**2))[0]
If S is located on the device, np.where causes a cpu/gpu conflict.
Replacing np.where with torch.where and removing the cpu() call allows both CPU and GPU compressed tensors to work. Unclear if detach is necessary or if it causes resource leaks.
Cool code!
The text was updated successfully, but these errors were encountered:
https://github.com/rballester/tntorch/blob/master/tntorch/round.py#L139
If S is located on the device, np.where causes a cpu/gpu conflict.
Replacing np.where with torch.where and removing the cpu() call allows both CPU and GPU compressed tensors to work. Unclear if detach is necessary or if it causes resource leaks.
Cool code!
The text was updated successfully, but these errors were encountered: