diff options
Diffstat (limited to 'tensorflow/tensorboard/components/tf_scalar_dashboard/tf-scalar-dashboard.html')
-rw-r--r-- | tensorflow/tensorboard/components/tf_scalar_dashboard/tf-scalar-dashboard.html | 26 |
1 files changed, 15 insertions, 11 deletions
diff --git a/tensorflow/tensorboard/components/tf_scalar_dashboard/tf-scalar-dashboard.html b/tensorflow/tensorboard/components/tf_scalar_dashboard/tf-scalar-dashboard.html index 1066457421..c994f175bd 100644 --- a/tensorflow/tensorboard/components/tf_scalar_dashboard/tf-scalar-dashboard.html +++ b/tensorflow/tensorboard/components/tf_scalar_dashboard/tf-scalar-dashboard.html @@ -190,16 +190,21 @@ contains vz-line-charts embedded inside tf-panes-helper's. </template> <script> - TF.Dashboard.TfScalarDashboard = Polymer({ + import {DashboardBehavior} from "../tf-dashboard-common/dashboard-behavior"; + import {ReloadBehavior} from "../tf-dashboard-common/reload-behavior"; + import {BackendBehavior} from "../tf-backend/behavior"; + import * as storage from "../tf-storage/storage"; + + Polymer({ is: "tf-scalar-dashboard", factoryImpl: function(backend, router) { this.backend = backend; this.router = router; }, behaviors: [ - TF.Dashboard.DashboardBehavior("scalars"), - TF.Dashboard.ReloadBehavior("tf-chart-scaffold"), - TF.Backend.BackendBehavior, + DashboardBehavior("scalars"), + ReloadBehavior("tf-chart-scaffold"), + BackendBehavior, ], properties: { backend: Object, @@ -215,14 +220,13 @@ contains vz-line-charts embedded inside tf-panes-helper's. _showDownloadLinks: { type: Boolean, notify: true, - value: TF.URIStorage.getBooleanInitializer('_showDownloadLinks', - false, true), + value: storage.getBooleanInitializer('_showDownloadLinks', false, true), observer: '_showDownloadLinksObserver' }, _smoothingWeight: { type: Number, notify: true, - value: TF.URIStorage.getNumberInitializer('_smoothingWeight', 0.6), + value: storage.getNumberInitializer('_smoothingWeight', 0.6), observer: '_smoothingWeightObserver' }, _smoothingEnabled: { @@ -231,7 +235,7 @@ contains vz-line-charts embedded inside tf-panes-helper's. }, _ignoreYOutliers: { type: Boolean, - value: TF.URIStorage.getBooleanInitializer('_ignoreYOutliers', true, true), + value: storage.getBooleanInitializer('_ignoreYOutliers', true, true), observer: '_ignoreYOutliersObserver', }, _xType: { @@ -247,11 +251,11 @@ contains vz-line-charts embedded inside tf-panes-helper's. _getScalarUrl: function() { return this.router.pluginRunTagRoute('scalars', '/scalars'); }, - _showDownloadLinksObserver: TF.URIStorage.getBooleanObserver( + _showDownloadLinksObserver: storage.getBooleanObserver( '_showDownloadLinks', /*default=*/ false, /*useLocalStorage=*/ true), - _smoothingWeightObserver: TF.URIStorage.getNumberObserver( + _smoothingWeightObserver: storage.getNumberObserver( '_smoothingWeight', 0.6), - _ignoreYOutliersObserver: TF.URIStorage.getBooleanObserver( + _ignoreYOutliersObserver: storage.getBooleanObserver( '_ignoreYOutliers', /*default=*/ true, /*useLocalStorage=*/true), _computeSmoothingEnabled: function(_smoothingWeight) { return _smoothingWeight > 0; |