Ruby でやってみる『機械学習 はじめよう第3回 ベイジアンフィルタを実装してみよう』メモ - 牌語備忘録 -pygo http://cortyuming.hateblo.jp/entry/20140627/p2

Ruby でやってみる『機械学習 はじめよう第3回 ベイジアンフィルタを実装してみよう』メモ
2017-05-07 07:48:12 zundaの投稿 zundan@mastodon.zunda.ninja
2017-05-07 08:29:46 zundaの投稿 zundan@mastodon.zunda.ninja

$ heroku pg:info DATABASE
=== DATABASE_URL, PG_HOBBY_BASIC_URL
Plan: Hobby-basic
Status: Available
Connections: 8/20
PG Version: 9.6.1
Created: 2017-04-20 18:31 UTC
Data Size: 43.3 MB
Tables: 26
Rows: 46869/10000000 (In compliance)

Starting to use Logentries.

2017-05-07 15:15:51 zundaの投稿 zundan@mastodon.zunda.ninja

そうだ、コード、書こう!

$ git clone https://github.com/rbenv/rbenv.git ~/.rbenv
$ cd ~/.rbenv && src/configure && make -C src
$ git clone https://github.com/rbenv/ruby-build.git ~/.rbenv/plugins/ruby-build
$ tail -2 .bashrc
export PATH=$HOME/.rbenv/bin:$PATH
eval "$(rbenv init -)"
$ rbenv install 2.4.1

そこから

GitHub - rbenv/rbenv: Manage your app''s Ruby environment
GitHub - rbenv/ruby-build: A tool to download, compile, and install Ruby on Unix-like systems.
GitHub - rbenv/rbenv: Manage your app''s Ruby environment
GitHub - rbenv/ruby-build: A tool to download, compile, and install Ruby on Unix-like systems.

Rubyのコンパイルで電池がやばい (久しぶりの環境で本筋にたどりつく前に時間切れになるパターン)

BUILD FAILED (Ubuntu 17.04 using ruby-build 20170405-4-g365dd1f)

ERROR: Ruby install aborted due to missing extensions
Try running `apt-get install -y libreadline-dev` to fetch missing dependencies.

あー

2017-05-07 17:39:07 zundaの投稿 zundan@mastodon.zunda.ninja
2017-05-07 17:39:08 zundaの投稿 zundan@mastodon.zunda.ninja

Redisのコネクションプールの使い方を知らないといけないことに気づいたところでそろそろ時間切れ (Rubyはまだコンパイル中w)

https://github.com/zunda/factorize

GitHub - zunda/factorize: A scalable library to factorize sets of integers

Map Redis types directly to Ruby objects

https://github.com/nateware/redis-objects

GitHub - nateware/redis-objects: Map Redis types directly to Ruby objects

にゃーん

$ heroku pg:info DATABASE
=== DATABASE_URL, PG_HOBBY_BASIC_URL
Plan: Hobby-basic
Status: Available
Connections: 8/20
PG Version: 9.6.1
Created: 2017-04-20 18:31 UTC
Data Size: 44.1 MB
Tables: 26
Rows: 48877/10000000 (In compliance)

「直ちに」の定義