This repository was archived by the owner on Apr 16, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathCpuEffPerNode.html
More file actions
53 lines (50 loc) · 1.53 KB
/
CpuEffPerNode.html
File metadata and controls
53 lines (50 loc) · 1.53 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
## -*- coding: utf-8 -*-
<%inherit file="/module_base.html" />
<%def name="content()">
<style>
#${module.instance_name}_histogram {
position: relative;
height: ${height}px;
width: *;
z-index: 0;
}
#${module.instance_name}_histogram span {
position: absolute;
height: 14px;
width: ${width-1}px;
z-index: 6;
border-left: 1px solid #000;
border-right: 1px solid #000;
border-top: 1px solid #000;
border-bottom: 1px solid #000;
}
#${module.instance_name}_histogram a {
height: 14px;
width: 85.2%;
position: absolute;
z-index: 5;
font-size: small;
display: block;
padding-bottom: 1px;
color: black;
}
</style>
<div id="${module.instance_name}_histogram">
%for cols in node_list:
<span style="top:${15*cols['y']+50}px; left:${width*cols['x']+201}px; background:${cols['color']};"
title="node: ${cols['node']} 
efficiency: ${cols['efficiency']}">
</span>
%endfor
%for site in sites:
<a style="top:${15*site['y']+49}px; padding-bottom:2px;">${site['site']}</a>
%endfor
%for y in lines:
<a style="top:${15*y+49}px; border-bottom: 1px solid #000;"></a>
%endfor
%for i, col in enumerate(color):
<span style="top:${15*(max(node_list, key=lambda node: node['y'])['y']+3)+50}px; left:${width*i+301}px; background:${col};"></span>
%endfor
<a style="top:${15*(max(node_list, key=lambda node: node['y'])['y']+3)+49}px; left:${-2*width+301}px;">0%</a>
<a style="top:${15*(max(node_list, key=lambda node: node['y'])['y']+3)+49}px; left:${10*width+301}px;">100%</a>
</div>
</%def>