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

github.com/soumith/cudnn.torch.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'Pointwise.lua')
-rw-r--r--Pointwise.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/Pointwise.lua b/Pointwise.lua
index aecfe08..56a374c 100644
--- a/Pointwise.lua
+++ b/Pointwise.lua
@@ -50,7 +50,8 @@ end
function Pointwise:updateGradInput(input, gradOutput)
assert((gradOutput:dim() == 4 or gradOutput:dim() == 3));
if not gradOutput:isContiguous() then
- self._gradOutput = self._gradOutput or gradOutput.new():resizeAs(gradOutput)
+ self._gradOutput = self._gradOutput
+ or gradOutput.new():resizeAs(gradOutput)
self._gradOutput:copy(gradOutput)
gradOutput = self._gradOutput
end