Skip to content

Commit 5a7d5a5

Browse files
committed
Issue #1555: solve ui-problem with weight- and bias-history
1 parent 6971fc3 commit 5a7d5a5

File tree

9 files changed

+16
-20
lines changed

9 files changed

+16
-20
lines changed

OpenRobertaServer/staticResources/css/libraries/bootstrap/bootstrap-grid.css.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

OpenRobertaServer/staticResources/css/libraries/bootstrap/bootstrap-reboot.css.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

OpenRobertaServer/staticResources/css/libraries/bootstrap/bootstrap-utilities.css.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

OpenRobertaServer/staticResources/css/libraries/bootstrap/bootstrap.css.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

OpenRobertaServer/staticResources/css/roberta.css.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

OpenRobertaServer/staticResources/css/style.css.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

OpenRobertaServer/staticResources/js/app/neuralnetwork/neuralnetwork.ui.js

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

OpenRobertaWeb/src/app/neuralnetwork/neuralnetwork.ui.ts

+6-3
Original file line numberDiff line numberDiff line change
@@ -877,6 +877,8 @@ export function drawNetworkUIForTabLearn(redrawNetwork: boolean = true) {
877877
moveSvgDown: true,
878878
showAllWeightLinks: true,
879879
weightsBiasesLinechartDisplay: true,
880+
weightsBiasesEditable: false,
881+
neuronNamesEditable: false,
880882
});
881883
}
882884

@@ -1221,8 +1223,9 @@ function drawTheNetwork(tabType: TabType, tabSuffix: string, options: object) {
12211223
.attr('d', diagonal(datum, 0))
12221224
.attr('class', cssForPath)
12231225
.on('click', function () {
1226+
(D3.event as any).stopPropagation();
12241227
options['weightsBiasesEditable'] && runEditCard(link, D3.mouse(this));
1225-
options['weightsBiasesLinechartDisplay'] && displayLineChart(link, D3.mouse(this));
1228+
options['weightsBiasesLinechartDisplay'] && link.weightHistory.length > 0 && displayLineChart(link, D3.mouse(this));
12261229
});
12271230
}
12281231
return line;
@@ -1268,7 +1271,7 @@ function drawTheNetwork(tabType: TabType, tabSuffix: string, options: object) {
12681271
biasRect.on('click', function () {
12691272
(D3.event as any).stopPropagation();
12701273
options['weightsBiasesEditable'] && runEditCard(node, D3.mouse(container.node()));
1271-
options['weightsBiasesLinechartDisplay'] && displayLineChart(node, D3.mouse(container.node()));
1274+
options['weightsBiasesLinechartDisplay'] && node.biasHistory.length > 0 && displayLineChart(node, D3.mouse(container.node()));
12721275
});
12731276
}
12741277
} else {
@@ -1284,7 +1287,7 @@ function drawTheNetwork(tabType: TabType, tabSuffix: string, options: object) {
12841287
biasRect.on('click', function () {
12851288
(D3.event as any).stopPropagation();
12861289
options['weightsBiasesEditable'] && runEditCard(node, D3.mouse(container.node()));
1287-
options['weightsBiasesLinechartDisplay'] && displayLineChart(node, D3.mouse(container.node()));
1290+
options['weightsBiasesLinechartDisplay'] && node.biasHistory.length > 0 && displayLineChart(node, D3.mouse(container.node()));
12881291
});
12891292
}
12901293
}

README.md

+3-10
Original file line numberDiff line numberDiff line change
@@ -210,17 +210,10 @@ Furthermore, the project OpenRobertaServer contains in directory staticResources
210210
* javascript resources for [blockly](https://developers.google.com/blockly)
211211
* controller and models written in Javascript, which implement the GUI
212212

213-
**The TypeScript and Javascript _sources_ can be found in `OpenRobertaWeb/`**
214-
To work with the frontend (e.g. compiling the sources) we use the following npm scripts:
213+
**The TypeScript and Javascript _sources_ can be found in `OpenRobertaWeb/`**
215214

216-
* `npm run build` - build the sources
217-
* `npm run build:sourceMap` - build the sources and generated source maps for debugging
218-
* `npm run watch` - build the sources on change
219-
* `npm run watch:sourceMap` - build the sources on change and generate source maps for debugging
220-
* `npm run format` - formats all javascript and typescript source files
221-
* `npm run format:check` - check if all javascript and typescript files are formatted
222-
223-
**Attention:** Only check in those generated files build with `npm run build` or `npm run watch`!
215+
To work with the frontend (e.g. compiling the sources), please read the `README.md` of the
216+
directory `OpenRoertaWeb` and follow the instructions.
224217

225218
#### Testing
226219

0 commit comments

Comments
 (0)