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:
authorSergey Zagoruyko <zagoruyko2@gmail.com>2015-08-06 02:12:08 +0300
committerSergey Zagoruyko <zagoruyko2@gmail.com>2015-08-06 02:12:08 +0300
commite2767544778b6e4a9306aad5a93de655b1f5b3c6 (patch)
treea55b1c93be2b11b329903b151b73afa8dd8b079e /SpatialCrossMapLRN.lua
parent9fe2e3a83c2f51107237a66ec035a303a8ba4141 (diff)
fix cross map lrn
Diffstat (limited to 'SpatialCrossMapLRN.lua')
-rw-r--r--SpatialCrossMapLRN.lua6
1 files changed, 3 insertions, 3 deletions
diff --git a/SpatialCrossMapLRN.lua b/SpatialCrossMapLRN.lua
index cc6faf3..6c8dc4d 100644
--- a/SpatialCrossMapLRN.lua
+++ b/SpatialCrossMapLRN.lua
@@ -15,7 +15,7 @@ end
function LRN:resetDescriptors()
-- create LRN descriptor
- self.LRNDesc = ffi.new('struct cudnnLRNDescriptor_t*[1]')
+ self.LRNDesc = ffi.new('struct cudnnLRNStruct*[1]')
errcheck('cudnnCreateLRNDescriptor', self.LRNDesc)
errcheck('cudnnSetLRNDescriptor', self.LRNDesc[0], self.size,
self.alpha, self.beta, self.K);
@@ -56,7 +56,7 @@ local one = torch.FloatTensor({1});
local zero = torch.FloatTensor({0});
function LRN:updateOutput(input)
- if not self.LRNDesc then self:resetPoolDescriptors() end
+ if not self.LRNDesc then self:resetDescriptors() end
self:createIODescriptors(input)
errcheck('cudnnLRNCrossChannelForward', cudnn.getHandle(),
self.LRNDesc[0],
@@ -75,7 +75,7 @@ function LRN:updateGradInput(input, gradOutput)
self._gradOutput:resizeAs(gradOutput):copy(gradOutput)
gradOutput = self._gradOutput
end
- if not self.LRNDesc then self:resetPoolDescriptors() end
+ if not self.LRNDesc then self:resetDescriptors() end
self:createIODescriptors(input)
errcheck('cudnnLRNCrossChannelBackward',
cudnn.getHandle(), self.LRNDesc[0],