pwrake 2.1.0 → 2.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 91439940b04a74b462713ec03d5f5bd4f282965f
4
- data.tar.gz: 06a86ba801618144354c31957a73430a3cb00725
3
+ metadata.gz: 5e0d716aa3c0635e1f7f5d2d909be08c11111d16
4
+ data.tar.gz: 83fee38f2963525d1b14e08da03cece13560805a
5
5
  SHA512:
6
- metadata.gz: 8b9ce53904fa158730c7b0a58e68b70fc18e6df5bd73b2114b04064376bce3cfd02de3b36ac7996a077a969e0790dd6ce5c9006344307950fef9fe42e2255512
7
- data.tar.gz: a8e8ba98341678f4a9a4744236a31a7b6769287fc6dc5554a1408d960d7b915c1397e88f8d957e0b39f9331d73df2a6dc50696bd4972c048257c543d214e9cc4
6
+ metadata.gz: 81ba08ad059954bfb25e0146ad9ec0adbfce7aaf05072b745c69a1e071ee7ec1a6ff3b673f38256e9e0875b0aaceb3d75802e5a1d2451576483d53213758dbed
7
+ data.tar.gz: 3cb1c4c934b3a72ab318768fd68247726974186404956b461999420df14fe68daa24736556a299c137d45a48eb8f3415810c177c07e46599ceaa5912a9bab3c2
@@ -28,6 +28,7 @@ module Pwrake
28
28
  attr_reader :hist, :hist_min, :hist_max, :bin
29
29
 
30
30
  def make_logx_histogram(bin)
31
+ if @min>0
31
32
  @bin = bin # 1.0/10
32
33
  @i_max = (Math.log10(@max)/@bin).floor
33
34
  @i_min = (Math.log10(@min)/@bin).floor
@@ -39,6 +40,7 @@ module Pwrake
39
40
  raise "invalid index i=#{i}" if i<0 || i>@i_max-@i_min
40
41
  @hist[i] += 1
41
42
  end
43
+ end
42
44
  end
43
45
 
44
46
  def hist_each
@@ -89,9 +91,18 @@ module Pwrake
89
91
  [@n, @mean, @median, @min, @max, @sdev||0]
90
92
  end
91
93
 
94
+ def fmt(x)
95
+ case x
96
+ when Numeric
97
+ "%g"%x
98
+ else
99
+ x.to_s
100
+ end
101
+ end
102
+
92
103
  def html_td
93
- "<td>%i</td><td>%g</td><td>%g</td><td>%g</td><td>%g</td><td>%g</td>" %
94
- [@n, @mean, @median, @min, @max, @sdev||0]
104
+ "<td>%i</td><td>%s</td><td>%s</td><td>%s</td><td>%s</td><td>%s</td>" %
105
+ [@n, fmt(@mean), fmt(@median), fmt(@min), fmt(@max), fmt(@sdev)]
95
106
  end
96
107
 
97
108
  def self.html_th
@@ -13,7 +13,7 @@ module Pwrake
13
13
  shell_id = {}
14
14
  @task_table.each do |row|
15
15
  if id=row['shell_id']
16
- shell_id[id.to_i] = true
16
+ shell_id[[row['exec_host'],id].join(":")] = true
17
17
  end
18
18
  end
19
19
  @ncore = shell_id.size
@@ -1,3 +1,3 @@
1
1
  module Pwrake
2
- VERSION = "2.1.0"
2
+ VERSION = "2.1.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pwrake
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0
4
+ version: 2.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Masahiro TANAKA
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-05-31 00:00:00.000000000 Z
11
+ date: 2016-07-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: parallel