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

github.com/torch/graph.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSoumith Chintala <soumith@gmail.com>2016-11-21 23:40:19 +0300
committerGitHub <noreply@github.com>2016-11-21 23:40:19 +0300
commit37dac07a19eb3809b8081514bc781206241863a0 (patch)
tree423c36bb499085321105fa1717149cbc795350db
parent47afe90ed1f047ff672deb5416aebcc7db051302 (diff)
parentd1b5a9e63a4a6612c75787b473434d18670f57ae (diff)
Merge pull request #30 from karandwivedi42/patch-1HEADmaster
Update Edge.lua
-rw-r--r--Edge.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/Edge.lua b/Edge.lua
index 1ffd670..bd99af2 100644
--- a/Edge.lua
+++ b/Edge.lua
@@ -4,7 +4,8 @@ No methods, just two fields, from and to.
]]--
local Edge = torch.class('graph.Edge')
-function Edge:__init(from,to)
+function Edge:__init(from,to,weight)
self.from = from
self.to = to
+ self.weight = weight
end