diff --git a/frontend/mock/data/plugin/histograms/histograms.js b/frontend/mock/data/plugin/histograms/histograms.js new file mode 100644 index 000000000..68a13a841 --- /dev/null +++ b/frontend/mock/data/plugin/histograms/histograms.js @@ -0,0 +1,774 @@ +/** + * get mock data + * + * @param {string} path request path + * @param {Object} queryParam query params + * @param {Object} postParam post params + * @return {Object} + */ +module.exports = function (path, queryParam, postParam) { + return { + // moock delay + _timeout: 0, + // mock http status + _status: 200, + // mock response data + _data: { + status: 0, + msg: 'SUCCESS', + data: [ + [ + 1514526553.43511, + 80, + [ + [ + -6.444607257843018, + -6.7878525393626115, + 0.0 + ], + [ + -6.7878525393626115, + -6.1707750357841915, + 2.0 + ], + [ + -6.1707750357841915, + -5.609795487076537, + 13.0 + ], + [ + -5.609795487076537, + -5.099814079160488, + 57.0 + ], + [ + -5.099814079160488, + -4.636194617418625, + 190.0 + ], + [ + -4.636194617418625, + -4.214722379471477, + 556.0 + ], + [ + -4.214722379471477, + -3.8315657995195243, + 1451.0 + ], + [ + -3.8315657995195243, + -3.48324163592684, + 2869.0 + ], + [ + -3.48324163592684, + -3.1665833053880363, + 5604.0 + ], + [ + -3.1665833053880363, + -2.8787120958073054, + 9443.0 + ], + [ + -2.8787120958073054, + -2.6170109961884593, + 15297.0 + ], + [ + -2.6170109961884593, + -2.379100905625872, + 21502.0 + ], + [ + -2.379100905625872, + -2.1628190051144287, + 29707.0 + ], + [ + -2.1628190051144287, + -1.9661990955585713, + 38090.0 + ], + [ + -1.9661990955585713, + -1.7874537232350647, + 47226.0 + ], + [ + -1.7874537232350647, + -1.624957930213695, + 56501.0 + ], + [ + -1.624957930213695, + -1.47723448201245, + 64363.0 + ], + [ + -1.47723448201245, + -1.3429404381931362, + 71885.0 + ], + [ + -1.3429404381931362, + -1.220854943811942, + 78935.0 + ], + [ + -1.220854943811942, + -1.109868130738129, + 83805.0 + ], + [ + -1.109868130738129, + -1.0089710279437536, + 87395.0 + ], + [ + -1.0089710279437536, + -0.917246389039776, + 90135.0 + ], + [ + -0.917246389039776, + -0.8338603536725235, + 91389.0 + ], + [ + -0.8338603536725235, + -0.7580548669750213, + 90632.0 + ], + [ + -0.7580548669750213, + -0.6891407881591103, + 89642.0 + ], + [ + -0.6891407881591103, + -0.6264916255991911, + 87854.0 + ], + [ + -0.6264916255991911, + -0.56953784145381, + 84283.0 + ], + [ + -0.56953784145381, + -0.5177616740489182, + 80644.0 + ], + [ + -0.5177616740489182, + -0.47069243095356195, + 76582.0 + ], + [ + -0.47069243095356195, + -0.42790220995778355, + 73035.0 + ], + [ + -0.42790220995778355, + -0.38900200905253046, + 68585.0 + ], + [ + -0.38900200905253046, + -0.35363819004775493, + 63701.0 + ], + [ + -0.35363819004775493, + -0.3214892636797772, + 59533.0 + ], + [ + -0.3214892636797772, + -0.29226296698161564, + 55273.0 + ], + [ + -0.29226296698161564, + -0.2656936063469233, + 51580.0 + ], + [ + -0.2656936063469233, + -0.24153964213356663, + 47415.0 + ], + [ + -0.24153964213356663, + -0.2195814928486969, + 43773.0 + ], + [ + -0.2195814928486969, + -0.19961953895336082, + 40022.0 + ], + [ + -0.19961953895336082, + -0.18147230813941892, + 36944.0 + ], + [ + -0.18147230813941892, + -0.16497482558128992, + 33915.0 + ], + [ + -0.16497482558128992, + -0.14997711416480902, + 30902.0 + ], + [ + -0.14997711416480902, + -0.13634283105891729, + 28312.0 + ], + [ + -0.13634283105891729, + -0.12394802823537933, + 25912.0 + ], + [ + -0.12394802823537933, + -0.11268002566852665, + 23480.0 + ], + [ + -0.11268002566852665, + -0.10243638697138786, + 21555.0 + ], + [ + -0.10243638697138786, + -0.09312398815580714, + 19337.0 + ], + [ + -0.09312398815580714, + -0.08465817105073375, + 17785.0 + ], + [ + -0.08465817105073375, + -0.07696197368248522, + 16308.0 + ], + [ + -0.07696197368248522, + -0.06996543062044111, + 14616.0 + ], + [ + -0.06996543062044111, + -0.06360493692767373, + 13459.0 + ], + [ + -0.06360493692767373, + -0.057822669934248845, + 12260.0 + ], + [ + -0.057822669934248845, + -0.052566063576589855, + 11159.0 + ], + [ + -0.052566063576589855, + -0.04778733052417259, + 10281.0 + ], + [ + -0.04778733052417259, + -0.043443027749247805, + 9328.0 + ], + [ + -0.043443027749247805, + -0.03949366159022527, + 8438.0 + ], + [ + -0.03949366159022527, + -0.035903328718386605, + 7729.0 + ], + [ + -0.035903328718386605, + -0.03263938974398782, + 6956.0 + ], + [ + -0.03263938974398782, + -0.02967217249453438, + 6243.0 + ], + [ + -0.02967217249453438, + -0.026974702267758523, + 5855.0 + ], + [ + -0.026974702267758523, + -0.0245224566070532, + 5160.0 + ], + [ + -0.0245224566070532, + -0.022293142370048362, + 4795.0 + ], + [ + -0.022293142370048362, + -0.02026649306368033, + 4433.0 + ], + [ + -0.02026649306368033, + -0.018424084603345752, + 4002.0 + ], + [ + -0.018424084603345752, + -0.01674916782122341, + 3630.0 + ], + [ + -0.01674916782122341, + -0.01522651620111219, + 3302.0 + ], + [ + -0.01522651620111219, + -0.013842287455556535, + 2944.0 + ], + [ + -0.013842287455556535, + -0.012583897686869577, + 2765.0 + ], + [ + -0.012583897686869577, + -0.01143990698806325, + 2453.0 + ], + [ + -0.01143990698806325, + -0.010399915443693864, + 2196.0 + ], + [ + -0.010399915443693864, + -0.00945446858517624, + 1999.0 + ], + [ + -0.00945446858517624, + -0.008594971441069308, + 1831.0 + ], + [ + -0.008594971441069308, + -0.007813610400972098, + 1699.0 + ], + [ + -0.007813610400972098, + -0.007103282182701907, + 1501.0 + ], + [ + -0.007103282182701907, + -0.006457529257001733, + 1426.0 + ], + [ + -0.006457529257001733, + -0.005870481142728848, + 1235.0 + ], + [ + -0.005870481142728848, + -0.005336801038844407, + 1095.0 + ], + [ + -0.005336801038844407, + -0.00485163730804037, + 1085.0 + ], + [ + -0.00485163730804037, + -0.00441057937094579, + 925.0 + ], + [ + -0.00441057937094579, + -0.004009617609950718, + 869.0 + ], + [ + -0.004009617609950718, + -0.0036451069181370156, + 757.0 + ], + [ + -0.0036451069181370156, + -0.003313733561942741, + 729.0 + ], + [ + -0.003313733561942741, + -0.0030124850563115826, + 648.0 + ], + [ + -0.0030124850563115826, + -0.002738622778465075, + 591.0 + ], + [ + -0.002738622778465075, + -0.0024896570713318863, + 564.0 + ], + [ + -0.0024896570713318863, + -0.0022633246103017147, + 510.0 + ], + [ + -0.0022633246103017147, + -0.0020575678275470133, + 455.0 + ], + [ + -0.0020575678275470133, + -0.001870516206860921, + 412.0 + ], + [ + -0.001870516206860921, + -0.0017004692789644735, + 371.0 + ], + [ + -0.0017004692789644735, + -0.0015458811626949758, + 364.0 + ], + [ + -0.0015458811626949758, + -0.001405346511540887, + 303.0 + ], + [ + -0.001405346511540887, + -0.0012775877377644426, + 273.0 + ], + [ + -0.0012775877377644426, + -0.001161443397967675, + 227.0 + ], + [ + -0.001161443397967675, + -0.001055857634516068, + 218.0 + ], + [ + -0.001055857634516068, + -0.0009598705768327891, + 225.0 + ], + [ + -0.0009598705768327891, + -0.0008726096153025355, + 199.0 + ], + [ + -0.0008726096153025355, + -0.0007932814684568504, + 189.0 + ], + [ + -0.0007932814684568504, + -0.0007211649713244094, + 165.0 + ], + [ + -0.0007211649713244094, + -0.0006556045193858267, + 125.0 + ], + [ + -0.0006556045193858267, + -0.0005960041085325697, + 118.0 + ], + [ + -0.0005960041085325697, + -0.0005418219168477906, + 120.0 + ], + [ + -0.0005418219168477906, + -0.0004925653789525368, + 114.0 + ], + [ + -0.0004925653789525368, + -0.0004477867081386698, + 109.0 + ], + [ + -0.0004477867081386698, + -0.0004070788255806089, + 97.0 + ], + [ + -0.0004070788255806089, + -0.0003700716596187353, + 80.0 + ], + [ + -0.0003700716596187353, + -0.00033642878147157755, + 66.0 + ], + [ + -0.00033642878147157755, + -0.0003058443467923432, + 60.0 + ], + [ + -0.0003058443467923432, + -0.0002780403152657665, + 50.0 + ], + [ + -0.0002780403152657665, + -0.00025276392296887866, + 68.0 + ], + [ + -0.00025276392296887866, + -0.0002297853845171624, + 48.0 + ], + [ + -0.0002297853845171624, + -0.00020889580410651126, + 46.0 + ], + [ + -0.00020889580410651126, + -0.00018990527646046477, + 33.0 + ], + [ + -0.00018990527646046477, + -0.00017264116041860433, + 27.0 + ], + [ + -0.00017264116041860433, + -0.00015694650947145847, + 31.0 + ], + [ + -0.00015694650947145847, + -0.00014267864497405315, + 24.0 + ], + [ + -0.00014267864497405315, + -0.00012970785906732103, + 39.0 + ], + [ + -0.00012970785906732103, + -0.00011791623551574639, + 37.0 + ], + [ + -0.00011791623551574639, + -0.00010719657774158762, + 13.0 + ], + [ + -0.00010719657774158762, + -0.00009745143431053419, + 19.0 + ], + [ + -0.00009745143431053419, + -0.00008859221300957652, + 15.0 + ], + [ + -0.00008859221300957652, + -0.00008053837546325138, + 13.0 + ], + [ + -0.00008053837546325138, + -0.00007321670496659217, + 20.0 + ], + [ + -0.00007321670496659217, + -0.00006656064087872014, + 17.0 + ], + [ + -0.00006656064087872014, + -0.00006050967352610922, + 15.0 + ], + [ + -0.00006050967352610922, + -0.00005500879411464474, + 10.0 + ], + [ + -0.00005500879411464474, + -0.00005000799464967703, + 15.0 + ], + [ + -0.00005000799464967703, + -0.00004546181331788821, + 10.0 + ], + [ + -0.00004546181331788821, + -0.00004132892119808019, + 12.0 + ], + [ + -0.00004132892119808019, + -0.00003757174654370926, + 7.0 + ], + [ + -0.00003757174654370926, + -0.00003415613322155387, + 7.0 + ], + [ + -0.00003415613322155387, + -0.000031051030201412604, + 7.0 + ], + [ + -0.000031051030201412604, + -0.00002822820927401146, + 10.0 + ], + [ + -0.00002822820927401146, + -0.000025662008430919505, + 6.0 + ], + [ + -0.000025662008430919505, + -0.000023329098573563184, + 5.0 + ], + [ + -0.000023329098573563184, + -0.000021208271430511985, + 8.0 + ], + [ + -0.000021208271430511985, + -0.000019280246755010893, + 5.0 + ], + [ + -0.000019280246755010893, + -0.000017527497050009902, + 5.0 + ], + [ + -0.000017527497050009902, + -0.00001593408822728173, + 4.0 + ], + [ + -0.00001593408822728173, + -0.0000144855347520743, + 3.0 + ], + [ + -0.0000144855347520743, + -0.00001316866795643118, + 4.0 + ], + [ + -0.00001316866795643118, + -0.000011971516324028345, + 2.0 + ], + [ + -0.000011971516324028345, + -0.000010883196658207586, + 3.0 + ], + [ + -0.000010883196658207586, + -0.000009893815143825077, + 2.0 + ], + [ + -0.000009893815143825077, + -0.000008994377403477343, + 1.0 + ], + [ + -0.000008994377403477343, + -0.000008176706730433948, + 2.0 + ], + [ + -0.000008176706730433948, + -0.0000074333697549399525, + 2.0 + ], + [ + -0.0000074333697549399525, + -0.000006757608868127229, + 2.0 + ], + [ + -0.000006757608868127229, + -0.000006143280789206572, + 0.0 + ], + [ + -0.000006143280789206572, + -0.000005584800717460519, + 2.0 + ], + [ + -0.000005584800717460519, + -0.000005077091561327744, + 4.0 + ] + ] + ] + ] + } + }; +}; diff --git a/frontend/mock/data/plugin/histograms/tags.js b/frontend/mock/data/plugin/histograms/tags.js new file mode 100644 index 000000000..8a7cad300 --- /dev/null +++ b/frontend/mock/data/plugin/histograms/tags.js @@ -0,0 +1,30 @@ +/** + * get mock data + * + * @param {string} path request path + * @param {Object} queryParam query params + * @param {Object} postParam post params + * @return {Object} + */ +module.exports = function (path, queryParam, postParam) { + return { + // moock delay + _timeout: 0, + // mock http status + _status: 200, + // mock response data + _data: { + status: 0, + msg: 'SUCCESS', + data: { + "test": { + "layer1/Wx_plus_b/pre_activations": + { + "displayName": "layer1/Wx_plus_b/pre_activations", + "description": "" + } + } + } + } + }; +}; diff --git a/frontend/mock/data/plugin/images/images.js b/frontend/mock/data/plugin/images/images.js index 98ee5bc95..c5510f693 100644 --- a/frontend/mock/data/plugin/images/images.js +++ b/frontend/mock/data/plugin/images/images.js @@ -20,8 +20,7 @@ module.exports = function (path, queryParam, postParam) { { "wall_time": 1512549785.061623, "step": 60, - "query": - "sample=0&index=0&tag=input_reshape%2Finput%2Fimage%2F0&run=test", + "query": "sample=0&index=0&tag=input_reshape%2Finput%2Fimage%2F0&run=test", "width": 28, "height": 28 }, diff --git a/frontend/mock/data/plugin/images/tags.js b/frontend/mock/data/plugin/images/tags.js index bf0b3acf5..51b79cdb1 100644 --- a/frontend/mock/data/plugin/images/tags.js +++ b/frontend/mock/data/plugin/images/tags.js @@ -18,8 +18,19 @@ msg: 'SUCCESS', data: { "test": { - "input_reshape/input/image/6": { - "displayName": "input_reshape/input/image/6", "description": "", "samples": 1}, "input_reshape/input/image/7": {"displayName": "input_reshape/input/image/7", "description": "", "samples": 1}, "input_reshape/input/image/4": {"displayName": "input_reshape/input/image/4", "description": "", "samples": 1}, "input_reshape/input/image/5": {"displayName": "input_reshape/input/image/5", "description": "", "samples": 1}, "input_reshape/input/image/2": {"displayName": "input_reshape/input/image/2", "description": "", "samples": 1}, "input_reshape/input/image/3": {"displayName": "input_reshape/input/image/3", "description": "", "samples": 1}, "input_reshape/input/image/0": {"displayName": "input_reshape/input/image/0", "description": "", "samples": 1}, "input_reshape/input/image/1": {"displayName": "input_reshape/input/image/1", "description": "", "samples": 1}, "input_reshape/input/image/8": {"displayName": "input_reshape/input/image/8", "description": "", "samples": 1}, "input_reshape/input/image/9": {"displayName": "input_reshape/input/image/9", "description": "", "samples": 1}}, "train": {"input_reshape/input/image/6": {"displayName": "input_reshape/input/image/6", "description": "", "samples": 1}, "input_reshape/input/image/7": {"displayName": "input_reshape/input/image/7", "description": "", "samples": 1}, "input_reshape/input/image/4": {"displayName": "input_reshape/input/image/4", "description": "", "samples": 1}, "input_reshape/input/image/5": {"displayName": "input_reshape/input/image/5", "description": "", "samples": 1}, "input_reshape/input/image/2": {"displayName": "input_reshape/input/image/2", "description": "", "samples": 1}, "input_reshape/input/image/3": {"displayName": "input_reshape/input/image/3", "description": "", "samples": 1}, "input_reshape/input/image/0": {"displayName": "input_reshape/input/image/0", "description": "", "samples": 1}, "input_reshape/input/image/1": {"displayName": "input_reshape/input/image/1", "description": "", "samples": 1}, "input_reshape/input/image/8": {"displayName": "input_reshape/input/image/8", "description": "", "samples": 1}, "input_reshape/input/image/9": {"displayName": "input_reshape/input/image/9", "description": "", "samples": 1}}} + "input_reshape/input/image/7": { + "displayName": "input_reshape/input/image/7", + "description": "", "samples": 1 + }, + "input_reshape/input/image/4": { + "displayName": "input_reshape/input/image/4", + "description": "", + "samples": 1 + }, + "input_reshape/input/image/5": { + "displayName": "input_reshape/input/image/5", + "description": "", "samples": 1 + }, "input_reshape/input/image/2": {"displayName": "input_reshape/input/image/2", "description": "", "samples": 1}, "input_reshape/input/image/3": {"displayName": "input_reshape/input/image/3", "description": "", "samples": 1}, "input_reshape/input/image/0": {"displayName": "input_reshape/input/image/0", "description": "", "samples": 1}, "input_reshape/input/image/1": {"displayName": "input_reshape/input/image/1", "description": "", "samples": 1}, "input_reshape/input/image/8": {"displayName": "input_reshape/input/image/8", "description": "", "samples": 1}, "input_reshape/input/image/9": {"displayName": "input_reshape/input/image/9", "description": "", "samples": 1}}, "train": {"input_reshape/input/image/6": {"displayName": "input_reshape/input/image/6", "description": "", "samples": 1}, "input_reshape/input/image/7": {"displayName": "input_reshape/input/image/7", "description": "", "samples": 1}, "input_reshape/input/image/4": {"displayName": "input_reshape/input/image/4", "description": "", "samples": 1}, "input_reshape/input/image/5": {"displayName": "input_reshape/input/image/5", "description": "", "samples": 1}, "input_reshape/input/image/2": {"displayName": "input_reshape/input/image/2", "description": "", "samples": 1}, "input_reshape/input/image/3": {"displayName": "input_reshape/input/image/3", "description": "", "samples": 1}, "input_reshape/input/image/0": {"displayName": "input_reshape/input/image/0", "description": "", "samples": 1}, "input_reshape/input/image/1": {"displayName": "input_reshape/input/image/1", "description": "", "samples": 1}, "input_reshape/input/image/8": {"displayName": "input_reshape/input/image/8", "description": "", "samples": 1}, "input_reshape/input/image/9": {"displayName": "input_reshape/input/image/9", "description": "", "samples": 1}}} } }; }; diff --git a/frontend/mock/data/plugin/scalars/tags.js b/frontend/mock/data/plugin/scalars/tags.js index 5ae1acd61..81261ee6d 100644 --- a/frontend/mock/data/plugin/scalars/tags.js +++ b/frontend/mock/data/plugin/scalars/tags.js @@ -165,10 +165,6 @@ module.exports = function (path, queryParam, postParam) { "layer1/biases/summaries/stddev_1": { "displayName": "layer1/biases/summaries/stddev_1", "description": "" - }, - "layer1/biases/summaries/min": { - "displayName": "layer1/biases/summaries/min", - "description": "" } } } diff --git a/frontend/package.json b/frontend/package.json index c131147fc..0f84aa76e 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -13,8 +13,12 @@ }, "dependencies": { "axios": "^0.16.1", + "csshint": "^0.3.3", + "d3-format": "^1.2.1", "echarts": "^3.8.5", "file-saver": "^1.3.3", + "htmlcs": "^0.4.1", + "lesslint": "^1.0.2", "lodash": "^4.17.4", "normalize.css": "^6.0.0", "qs": "^6.5.1", @@ -43,7 +47,7 @@ "css-loader": "^0.28.0", "express": "^4.16.2", "extract-text-webpack-plugin": "^2.1.0", - "fecs": "^1.5.3", + "fecs": "1.5.2", "file-loader": "^0.11.1", "friendly-errors-webpack-plugin": "^1.6.1", "glob": "^7.1.1", diff --git a/frontend/src/App.san b/frontend/src/App.san index 4a7be78e7..3607abac5 100644 --- a/frontend/src/App.san +++ b/frontend/src/App.san @@ -1,6 +1,7 @@