Spaces:
Build error
Build error
Download util/lua/nn/test_CrossConvolve.lua from rawanessam/FloorPlanTransformation: direct link, hf CLI and curl.
- Browser
- Download file 255 Bytes
-
https://huggingface.co/spaces/rawanessam/FloorPlanTransformation/resolve/main/util/lua/nn/test_CrossConvolve.lua
- Command line
-
hf download hf://spaces/rawanessam/FloorPlanTransformation/util/lua/nn/test_CrossConvolve.lua
-
curl -L -o test_CrossConvolve.lua https://huggingface.co/spaces/rawanessam/FloorPlanTransformation/resolve/main/util/lua/nn/test_CrossConvolve.lua
255 Bytes
| require 'CrossConvolve' | |
| t = nn.CrossConvolve(1,3) | |
| a = torch.rand(2,1,3,3) | |
| a[1][1] = torch.eye(3) | |
| a[2][1] = torch.eye(3) | |
| b = torch.eye(3) | |
| c = t:forward({a,b}) | |
| d = torch.rand(2,1,3,3) | |
| d[1][1] = torch.eye(3) | |
| d[2][1] = torch.eye(3) | |
| e = t:backward({a,b},d) | |