   THCudaTensor *gradOutputWindow;
   THCudaTensor *inputWindow;
   long k, i;
-  
+
   int dimS = 0; // sequence dimension
-  
-  if (gradOutput->nDimension == 3) 
+
+  if (gradOutput->nDimension == 3)
   {
     dimS = 1;
   }
-  
+
   nInputFrame = input->size[dimS];
   nOutputFrame = gradOutput->size[dimS];
 

        long nFrame = (nInputFrame-k*dW-kW)/inputFrameStride + 1;
        nOutputSampleFrame -= nFrame;

        THCudaTensor_setStorage2d(gradOutputWindow, gradOutputSample->storage, 
                                gradOutputSample->storageOffset + k*gradOutputSample->size[1],
                                nFrame, outputFrameStride*gradOutputSample->size[1],
                                gradOutputSample->size[1], 1);


static int cunn_TemporalConvolution_accGradParameters(lua_State *L)
{
  THCudaTensor *input = (THCudaTensor*)luaT_checkudata(L, 2, "torch.CudaTensor");
  THCudaTensor *gradOutput = (THCudaTensor*)luaT_checkudata(L, 3, "torch.CudaTensor");
  float scale = luaL_optnumber(L, 4, 1);
  int kW = luaT_getfieldcheckint(L, 1, "kW");
  int dW = luaT_getfieldcheckint(L, 1, "dW");
