-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathInputOutputBeforeLearningScript.py
36 lines (28 loc) · 1.07 KB
/
InputOutputBeforeLearningScript.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
import os
import threeWay
import numpy as np
if __name__ == "__main__":
argDict = threeWay.getArgs()
print argDict
numTestingExamples = 1
testingNoise = 0
argDict['numExamples'] = numTestingExamples
argDict['testMode'] = True
argDict['weightPath'] = os.getcwd()+'/random/'
argDict['noise'] = testingNoise
argDict['inputType'] = 'InputOutput'
argDict['inputWeight'] = 0.12
argDict['recurrentWeight'] = 0.001
argDict['singleExampleTime'] = 60.0
inputStrengths = np.logspace(-0.5, 2.3, 20, base=10)
inputStrengths = [20]
for inputStrength in inputStrengths:
argDict['targetPath'] = os.getcwd()+'/InputOutputBeforeLearning/in_'+str(inputStrength)+'/'
argDict['gaussianPeak'] = inputStrength
relNet = threeWay.RelationalNetwork(**argDict)
relNet.createNetwork()
relNet.run()
del relNet
activityDataPath = os.getcwd()+'/InputOutputBeforeLearning/'
import InputOutputBeforeLearningUtil
InputOutputBeforeLearningUtil.plotActivity(activityDataPath, inputStrengths)