More Related Content
Similar to 筑西プロジェクト農業×IT (20)
More from Kaz Furukawa (20)
筑西プロジェクト農業×IT
- 16. #
ツール名
称
説明 アルゴリズム 利用形態 URL
1
Amazon
Machine
Learning
AWS上で稼働する機械学習フレームワーク
S3, Redshiftと連携してGUIで操作
Binary classification(二値分類・二項分類)
Multiclass classification(多値分類・多項分類)
Regression(回帰分析)
クラウド
サービス
https://aws.amazon.com/jp
/machine-learning/
2
MLlib /
Apache
Spark
Apache Sparkに含まれる機械学習ライブラリ
処理が早い、より直近のデータを正確に分析で
きることが特徴
JAVA, Scala, Pythonから利用可能
大量データが扱える、複数ノードでのクラスター
計算に対応
Naive Bayes (NB)
SVM (SVM)
Logistic Regresssion (LR)
Decision Tree (DT)
Random Forest (RF)
Gradient Boosted Tree (GBT)
オープン
ソースソフト
ウェア
http://spark.apache.org/
3 Jubatus C++,JAVA,Ruby,Pythonから利用可能
多値分類(Classifier)
線形回帰(Regression)
クラスタリング(Clustering)
クラスタ分析(Cluster Analysis)
統計分析(Stat)
近傍探索(Nearest Neighbor)
推薦(Recommender)
グラフマイニング(Graph)
異常検知(Anomaly Detection)
オープン
ソースソフト
ウェア
http://jubat.us/ja/#
4 mahout
hadoopベースの分散処理に対応した機械学習
AWS EC2インスタンスあり
Collaborative Filtering
Clustering
Classfier
オープン
ソースソフト
ウェア
http://mahout.apache.org/
5 OpenCV 画像解析ライブラリ、機械学習
Normal Bayes Classifier
K-Nearest Neighbors
Support Vector Machines
Decision Trees
Boosting
Gradient Boosted Trees
Random Trees
Extremely randomized trees
Expectation Maximization
Neural Networks
MLData
オープン
ソースソフト
ウェア
http://docs.opencv.org/2.4
/modules/ml/doc/ml.html
Machine Learning主要フレームワーク・ライブラリー
- 17. Machine Learning主要フレームワーク・ライブラリー
#
ツール名
称
説明 アルゴリズム 利用形態 URL
6
scikit
learn
pythonから利用する機械学習ライブラリ
教師あり学習、教師無し学習に対応する
Generalized Linear Models
Linear and Quadratic Discriminant Analysis
Kernel ridge regression
Support Vector Machines
Stochastic Gradient Descent
Nearest Neighbors
Gaussian Processes
Cross decomposition
Naive Bayes
Decision Trees
Ensemble methods
Multiclass and multilabel algorithms
Feature selection
Semi-Supervised
Isotonic regression
Probability calibration
Gaussian mixture models
Manifold learning
Clustering
Biclustering
Decomposing signals in components
Covariance estimation
Novelty and Outlier Detection
Density Estimation
Neural network models
オープン
ソースソフト
ウェア
http://scikit-
learn.org/stable/
- 18. Machine Learning主要フレームワーク・ライブラリー
#
ツール名
称
説明 アルゴリズム 利用形態 URL
7将軍
Python C++, Java, Rから使える機械学習ライブ
ラリ
SVM,Classifier
Linear Classifier
Distributions
Dimension Reduction
Clustering
Optimization
オープン
ソースソフト
ウェア
http://shogun-toolbox.org/
8WEKA
1997年にワイカト大学で開発された機械学習ラ
イブラリ
開発言語はJava
machine learning
data mining
preprocessing
classification
regression
clustering
association rules
attribute selection
experiments
workflow
visualization
オープン
ソースソフト
ウェア
http://www.cs.waikato.ac.n
z/ml/weka/
9chainer
オープン
ソースソフト
ウェア
https://github.com/pfnet/
chainer
10Azure ML
マイクロソフトのクラウドサービス
最低1GB 1ヶ月 2352.53円
(0.102円/GB + 計算ユニット 744/時間×3.162
円)
Regression
Binary classification
クラウド
サービス
https://azure.microsoft.co
m/ja-jp/
11
IBM
Bluemix
IBM クラウドサービス
インスタンス課金 7円/GB・時間
SQL DB 3,150円/インスタンス
不明
クラウド
サービス
http://www.ibm.com/devel
operworks/jp/bluemix/
- 19. • 開発環境の選択肢
– Webサービスとして実装する場合のフレームワーク
• PHP
– フレームワーク多い、エンジニア多い
– Web系フレームワークは堅牢
• Ruby
– フレームワーク多い、エンジニア育成コストが低い
– 機械学習関連のライブラリが少ない
• Python
– 実質デファクト、情報多い、学術系はほぼこれ
– Webフレームワークは「?」 メジャーではない
• C++
– 大学中心に大規模計算ライブラリ多い、学習コストが高い
– 商用はあまり見当たらない
3.ハンズオン
- 25. 1.LED点灯
• Pythonプログラム
led.py import RPi.GPIO as GPIO
from time import sleep
GPIO.setmode(GPIO.BCM)
GPIO.setup(25, GPIO.OUT)
while True:
GPIO.output(25, GPIO.HIGH)
sleep(1)
GPIO.output(25, GPIO.LOW)
sleep(1)
GPIOの25番を制御します
sudo echo 25 > /sys/class/gpio/export
pythonでGPIOを制御するライブラリをRasberry piインストールします
※要インターネット接続
>sudo apt-get install python-rpi.gpio
- 28. 2.温度データの計測
pi_piperをインストール
> git clone https://github.com/jwhitehorn/pi_piper
> cd pi_piper
> sudo gem build pi_piper.gemspec
> sudo gem install pi_piper-2.0.beta.11.gem
Rubyをインストール
> sudo apt-get install rubygems
SPIを有効にする
sudo vi raspi-conf
- 30. 2.温度データの計測
Rubyプログラム
require 'pi_piper'
loop do
value=0
PiPiper::Spi.begin do |spi|
raw = spi.write [0b01101000,0]
value = ((raw[0]<<8) + raw[1]) & 0x03FF
end
volt = (value * 3300)/1024
degree=(volt - 500)/10
puts Time.now.strftime("%Y-%m-%d,%H:%M:%S") + "," + degree.to_s
sleep(1)
end
sudo ruby temp.rb
2015-09-07,01:54:08,25
2015-09-07,01:54:09,25
2015-09-07,01:54:10,25
2015-09-07,01:54:11,25
2015-09-07,01:54:12,26
- 33. 3.サーボモーターを回す
#include <stdio.h>
#include <wiringPi.h>
int main()
{
pinMode(18,PWM_OUTPUT);
pwmSetMode(PWM_MODE_MS);
pwmSetClock(400);
pwmSetRange(1024);
while(1){
int num;
scanf("%i",&num);
printf("%dn",num);
if(num == -1){
break;
}
pwmWrite(18,num);
}
return 0;
}
コンパイル
> cc -o servo servo.c -lwiringPi –lpthread
実行
> ./servo