Skip to content

Commit

Permalink
graph: Fix JSE when switching node selection (#2232)
Browse files Browse the repository at this point in the history
Repro steps:
1. Select a run that has more than one tags
2. Select a tag with RunMetadata
3. Select a node
4. Select the default tag
5. Click nodes around and see JSEs

We have nested dom-ifs to prevent `getTotalMicros` from being called.
However, this is only effective when the DOM is not mounted but this
assumption does not hold after first render (if=true).

JSE = JavaScript Exception
  • Loading branch information
stephanwlee authored May 15, 2019
1 parent cc01bc1 commit 38749e7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tensorboard/plugins/graph/tf_graph_info/tf-node-info.html
Original file line number Diff line number Diff line change
Expand Up @@ -489,7 +489,7 @@
return null;
},
_getTotalMicros: function(stats) {
return stats.getTotalMicros();
return stats ? stats.getTotalMicros() : 0;
},
_getHasDisplayableNodeStats: function(stats) {
return tf.graph.util.hasDisplayableNodeStats(stats);
Expand Down

0 comments on commit 38749e7

Please sign in to comment.