Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/torch/cutorch.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Fidjeland <andreas.fidjeland@gmail.com>2013-06-11 21:11:53 +0400
committerAndreas Fidjeland <andreas.fidjeland@gmail.com>2013-06-11 21:36:34 +0400
commitb82a30b14172048b03b17314ae7d5e01913bb8e6 (patch)
treef180227b1f0daeafc946d1fadc2ce580bd9cb1fb /Tensor.lua
parent2460a357002cc1ad4ff72d9634829302b53333a3 (diff)
Added CudaTensor.expand and CudaTensor.expandAs
Diffstat (limited to 'Tensor.lua')
-rw-r--r--Tensor.lua7
1 files changed, 7 insertions, 0 deletions
diff --git a/Tensor.lua b/Tensor.lua
index fc4f283..c8e74e8 100644
--- a/Tensor.lua
+++ b/Tensor.lua
@@ -53,3 +53,10 @@ for _,func in ipairs({'addmv',
end
end
end
+
+do
+ local metatable = torch.getmetatable('torch.CudaTensor')
+ for _,func in pairs{'expand', 'expandAs'} do
+ rawset(metatable, func, torch[func])
+ end
+end