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

github.com/torch/nn.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlfredo Canziani <alfredo.canziani@gmail.com>2016-09-22 02:02:57 +0300
committerAlfredo Canziani <alfredo.canziani@gmail.com>2016-09-22 02:14:42 +0300
commitcbf6ccd6c98a4ed6d71661338db7b5ddbe31bc15 (patch)
treee757b0edddaf41f1e5e1a22102565df192723d6c /Parallel.lua
parentad4a4a1ed7ed8fddc9014c8af8474686c31cab5b (diff)
Remove extra | and bug fix ConcatTable
Diffstat (limited to 'Parallel.lua')
-rw-r--r--Parallel.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/Parallel.lua b/Parallel.lua
index 7d2b4f1..58cb974 100644
--- a/Parallel.lua
+++ b/Parallel.lua
@@ -97,6 +97,7 @@ function Parallel:__tostring__()
local tab = ' '
local line = '\n'
local next = ' |`-> '
+ local lastNext = ' `-> '
local ext = ' | '
local extlast = ' '
local last = ' ... -> '
@@ -104,7 +105,7 @@ function Parallel:__tostring__()
str = str .. ' {' .. line .. tab .. 'input'
for i=1,#self.modules do
if i == #self.modules then
- str = str .. line .. tab .. next .. '(' .. i .. '): ' .. tostring(self.modules[i]):gsub(line, line .. tab .. extlast)
+ str = str .. line .. tab .. lastNext .. '(' .. i .. '): ' .. tostring(self.modules[i]):gsub(line, line .. tab .. extlast)
else
str = str .. line .. tab .. next .. '(' .. i .. '): ' .. tostring(self.modules[i]):gsub(line, line .. tab .. ext)
end