You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: results/Readme.md
+4-3Lines changed: 4 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -9,17 +9,18 @@ Two functions are provided which are called by the training routine:
9
9
#### `results.startRun`
10
10
This is called before any training, and stores information about the run for future reference. It also creates the database file (by default `results.sqlite`) if it doesn't exist.
11
11
12
-
The supplied information I store for each run are pretty much the arguments of this function and the columns of the table RUNS. Exception: `callerFilePath` is a list of filenames whose contents we store - e.g. the code. I use the nonemptiness of `continuation` to indicate that the model was not trained from scratch, but from the saved weights of the previous run. `architecture` and `solver` are basically assumed in diffRuns and describeRun to be long JSON strings. You can change any of this.
12
+
`attribs` is a dictionary of properties to store for the run, `callerFilePath` is a list of filenames whose contents we store - e.g. the code.`continuation` is a string - I use the nonemptiness of `continuation` to indicate that the model was not trained from scratch, but from the saved weights of the previous run. `architecture` and `solver` are basically assumed in diffRuns and describeRun to be long JSON strings. You can change any of this.
13
13
14
14
#### `results.step`
15
15
This stores the reported training and test objective and accuracy from each step of training.
16
16
These are stored in the STEPS table.
17
-
The time for the first 10 steps is remembered in the steps table.
17
+
The time for the first 10 steps (excluding the first) is remembered in the steps table.
18
18
19
-
These functions are also available in lua after something like this
19
+
Similar functions are also available in lua after something like this.
20
20
```
21
21
results = require 'results'
22
22
```
23
+
23
24
##warning
24
25
Only one process should modify the database at any one time; you cannot train two models to the same database. But you can have as many processes as you like connected to the database and using the query functions, even during training.
raiseRuntimeError("runList1 not available in the new format")
135
164
b=c.execute("select repnlength, repn, count(step), min(objective), max(trainacc), max(testacc) from runs r left join steps s on r.count=s.run group by count").fetchall()
136
165
forjinb:
137
166
print(j)
138
167
168
+
def_listAttribs(wantRes):
169
+
c=con.cursor()
170
+
ifwantResisNone:
171
+
a=c.execute("select distinct(name) from ATTRIBS").fetchall()
172
+
else:
173
+
a=c.execute("select distinct(name) from ATTRIBS where ISRESULT = ?", (wantRes,)).fetchall()
174
+
b=sorted([i[0] foriina])
175
+
returnb
176
+
177
+
def_getAttribAsStr(run,name):
178
+
c=con.cursor()
179
+
a=c.execute("select value from ATTRIBS where run = ? and name = ?",(run,name)).fetchall()
180
+
foriina:#there should only be one if there are any
181
+
returnstr(i[0])
182
+
return""
183
+
139
184
#architectureLike: if set to 5, only print info for runs with the same network as the one used in run 5
140
-
defrunList2(avgLength=None, doPrint=True, runFrom=None, architectureLike=None): #with times
185
+
#doAttribs: None means all attribs are included, a list means those attributes are included,
186
+
# True or False mean only the result or nonresult ones.
187
+
defrunList2(avgLength=None, doPrint=True, runFrom=None, architectureLike=None, doAttribs=None): #with times
archClause=archClause+" and count >= "+str(runFrom)
155
205
runFrom=None
156
-
masterQuery="select count, repnlength, repn, case when length(continuation)>0 then '+' else '' end || count(step), (select time from times where run = r.count) from runs r left join steps s on r.count=s.run %s group by count"% (archClauseifrunFromisNoneelse ("where count>= "+str(runFrom)))
206
+
masterQuery="select count, "+("repnlength, repn,"ifoldColumnselse"") +" case when length(continuation)>0 then '+' else '' end || count(step), (select time from times where run = r.count) from runs r left join steps s on r.count=s.run %s group by count"% (archClauseifrunFromisNoneelse ("where count>= "+str(runFrom)))
0 commit comments