multi_armed_bandit 0.2.0 → 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ad5425a07617c9d5751a037c73e3aa65cceb8bee
4
- data.tar.gz: 1a06c8077da76fe19d9f03f2fcb2b686c416e66d
3
+ metadata.gz: 0ffdbe1749d41f4df55c0dba3223391e762d3eea
4
+ data.tar.gz: 739a82ab2b4f7122c8ef10668a88638f7e228afd
5
5
  SHA512:
6
- metadata.gz: 7ec3c6c029b9838baf3456c00617cb9b536be95fe6324ab1a86b6760912e6b792ce7933ca1bddbad343f52119ae055353af7a7f015f1c3444be202e756365a9a
7
- data.tar.gz: d3cba9d4509715242d1a8068701e46062661f30b30c54877be499595b6725178ddc2b723c47fad52c6331a39d988ba4d1ffbebb1a94a609a31f18a3306402a1b
6
+ metadata.gz: bde94f911c19f94f6efa3e2b39a54e3c6d5aed43af90bc2943123622cf210cab68ef30dbaffa337d016277285aecfee4ccaaa9cf414b1ca1438cb1c239149d6c
7
+ data.tar.gz: 37881e19f8596712b1840a94434813e276025d40d7db9418a0cbf5e42b38f8c8222888f2cfa6b8caa496aede5f9af1c37319320d66d0f9bc2fd5f96e81906689
data/README.md CHANGED
@@ -4,16 +4,15 @@ This repo contains Ruby code for solving Multi-Armed Bandit problems. This inclu
4
4
 
5
5
  * Epsilon-Greedy
6
6
  * Softmax
7
- * Thomson Sampling with Multiple Play
7
+ * Multiple-play Thomson Sampling
8
8
 
9
9
  Othrer major algorithms such as UCB and Bayesian Bandit will be forthcoming.
10
10
 
11
11
  ## Installation
12
12
 
13
- By executing the following line, you can install the gem from the GitHub repo.
14
-
15
- $ gem specific_install -l 'git://github.com/vasilyjp/multi_armed_bandit.git'
13
+ By executing the following line, you can install the gem from RubyGems.
16
14
 
15
+ $ gem install multi_armed_bandit
17
16
 
18
17
  ## Usage
19
18
 
@@ -8,12 +8,12 @@ module MultiArmedBandit
8
8
 
9
9
  # k: num of arms
10
10
  # l: num of selected arms
11
- def initialize(k, l, setseed=TRUE)
11
+ def initialize(k, l, setseed=true)
12
12
  @k = k
13
13
  @l = l
14
14
  @r = SimpleRandom.new
15
15
  # By default the same random seed is used, so we change it
16
- @r.set_seed if setseed==TRUE
16
+ @r.set_seed if setseed==true
17
17
  reset
18
18
  end
19
19
 
@@ -1,3 +1,3 @@
1
1
  module MultiArmedBandit
2
- VERSION = "0.2.0"
2
+ VERSION = "0.2.1"
3
3
  end
@@ -16,11 +16,11 @@ Gem::Specification.new do |spec|
16
16
 
17
17
  # Prevent pushing this gem to RubyGems.org by setting 'allowed_push_host', or
18
18
  # delete this section to allow pushing this gem to any host.
19
- if spec.respond_to?(:metadata)
20
- spec.metadata['allowed_push_host'] = "TODO: Set to 'http://mygemserver.com'"
21
- else
22
- raise "RubyGems 2.0 or newer is required to protect against public gem pushes."
23
- end
19
+ # if spec.respond_to?(:metadata)
20
+ # spec.metadata['allowed_push_host'] = "TODO: Set to 'http://mygemserver.com'"
21
+ # else
22
+ # raise "RubyGems 2.0 or newer is required to protect against public gem pushes."
23
+ # end
24
24
 
25
25
  spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
26
26
  spec.bindir = "exe"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: multi_armed_bandit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - kndt84
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-04-14 00:00:00.000000000 Z
11
+ date: 2016-04-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -90,8 +90,7 @@ files:
90
90
  homepage: https://github.com/vasilyjp/multi_armed_bandit
91
91
  licenses:
92
92
  - MIT
93
- metadata:
94
- allowed_push_host: 'TODO: Set to ''http://mygemserver.com'''
93
+ metadata: {}
95
94
  post_install_message:
96
95
  rdoc_options: []
97
96
  require_paths:
@@ -108,7 +107,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
108
107
  version: '0'
109
108
  requirements: []
110
109
  rubyforge_project:
111
- rubygems_version: 2.0.14
110
+ rubygems_version: 2.4.8
112
111
  signing_key:
113
112
  specification_version: 4
114
113
  summary: multi-armed bandit algorithms