diff options
| author | Jules Laplace <julescarbon@gmail.com> | 2018-06-03 02:25:34 +0200 |
|---|---|---|
| committer | Jules Laplace <julescarbon@gmail.com> | 2018-06-03 02:25:34 +0200 |
| commit | 46fbedf0ad7b167a28daf2030e06f34480576394 (patch) | |
| tree | 81877c97f777a8d705d47bb97ac96e5fa244bd2b /app/client/modules/samplernn/samplernn.loss.js | |
| parent | 2149eb581c35a93d41dbad6e3409c498b4bed804 (diff) | |
add results page
Diffstat (limited to 'app/client/modules/samplernn/samplernn.loss.js')
| -rw-r--r-- | app/client/modules/samplernn/samplernn.loss.js | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/app/client/modules/samplernn/samplernn.loss.js b/app/client/modules/samplernn/samplernn.loss.js index 3900c31..04d16c8 100644 --- a/app/client/modules/samplernn/samplernn.loss.js +++ b/app/client/modules/samplernn/samplernn.loss.js @@ -95,9 +95,15 @@ class SampleRNNLoss extends Component { // if ( (ii % 1) < 0.1) { // ctx.strokeStyle = 'rgba(255,255,255,1.0)' ctx.lineWidth = 2 + ctx.setLineDash([4, 4]) ctx.stroke() + ctx.stroke() ctx.stroke() - ctx.stroke() + ctx.setLineDash([0,0]) + const fontSize = 12 + ctx.font = 'italic ' + (fontSize * devicePixelRatio) + 'px "Georgia"' + ctx.fill = 'black' + ctx.fillText(ii.toFixed(1), w-50, (h-Y) + fontSize + (10 * devicePixelRatio)) // } } ctx.lineWidth = 1 @@ -106,7 +112,7 @@ class SampleRNNLoss extends Component { const loss = lossReport[key] const vf = parseFloat(loss[loss.length-1].training_loss) || 0 const vg = parseFloat(loss[0].training_loss) || 5 - console.log(vf) + // console.log(vf) const vv = 1 - norm(vf, scaleMin, scaleMax/2) ctx.lineWidth = (1-norm(vf, scaleMin, scaleMax)) * 5 ctx.strokeStyle = 'rgba(' + [randrange(30,190), randrange(30,150), randrange(60,120)].join(',') + ',' + 0.8+ ')' |
