-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDecisionNode.py
78 lines (53 loc) · 1.81 KB
/
DecisionNode.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
from BayesianNode import BayesianNode
class DecisionNode(BayesianNode):
def __init__(self):
super.__init__(self)
def finalize(self):
finalized = True
return
def setName(self, name):
self.name = name
def getName(self):
return self.name
def setNetwork(self, network):
if(self.finalized):
er("[Node]: Node is already finalized. Can not perform setNetwork.")
return
self.network = network
def addValue(self, value):
if(self.finalized):
er("[Node]: Node is already finalized. Can not perform addValue.")
return
self.values.append(value)
def getValues(self):
return self.values
def getCurrentValue(self):
er("[DecisionNode]: This is a DecisionNode....")
def setCurrentValue(self, value):
er("[DecisionNode]: This is a DecisionNode....")
def addParent(self, parent):
er("[DecisionNode]: This is a DecisionNode....")
def addParents(self, parents):
er("[DecisionNode]: This is a DecisionNode....")
def removeParent(self, parent):
er("[DecisionNode]: This is a DecisionNode....")
def getParents(self):
er("[DecisionNode]: This is a DecisionNode....")
def getListPossibleValues(self, cpt, i, j, rootTuple, currentSetValues, remainingList):
er("[DecisionNode]: This is a DecisionNode....")
def definalize(self):
er("[DecisionNode]: This is a DecisionNode....")
def setObservable(self, boolean):
er("[DecisionNode]: This is a DecisionNode....")
def getProbabilityOfValue(self, value):
return 1
def getProbabilityOfTuple(self, value):
return 1
def addConnection(self, connection):
er("[DecisionNode]: This is a DecisionNode....")
def removeConnection(self, connection):
er("[DecisionNode]: This is a DecisionNode....")
def removeConnectionTo(self, parent):
er("[DecisionNode]: This is a DecisionNode....")
def getConnections(self):
return self.connections