Skip to content

Commit 88fffea

Browse files
committed
moving from SpatialConvolutionCUDA to SpatialConvolution
1 parent 36d75a8 commit 88fffea

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

dqn/convnet.lua

-6
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,6 @@ function create_network(args)
1414
--- first convolutional layer
1515
local convLayer = nn.SpatialConvolution
1616

17-
if args.gpu >= 0 then
18-
net:add(nn.Transpose({1,2},{2,3},{3,4}))
19-
convLayer = nn.SpatialConvolutionCUDA
20-
end
21-
2217
net:add(convLayer(args.hist_len*args.ncols, args.n_units[1],
2318
args.filter_size[1], args.filter_size[1],
2419
args.filter_stride[1], args.filter_stride[1],1))
@@ -35,7 +30,6 @@ function create_network(args)
3530

3631
local nel
3732
if args.gpu >= 0 then
38-
net:add(nn.Transpose({4,3},{3,2},{2,1}))
3933
nel = net:cuda():forward(torch.zeros(1,unpack(args.input_dims))
4034
:cuda()):nElement()
4135
else

0 commit comments

Comments
 (0)