MotoJapan's Tech-Memo

技術めも

【行動認識 #1】機械学習/深層学習で人間行動認識 ~事始め~

人間行動認識 ( Human Activity Recognition ) の領域の話。
去年の3月頃にやっていたが途中になっていたこともあったので、追試も兼ねて再開。
(tensorflowの勉強もしたいし)

人間行動認識 ( Human Activity Recognition ) とは

私の認識では、カメラやセンサ等、様々な機器から得られた情報を基に、人間の行動を学習/推定する認識技術テーマ。

f:id:motojapan:20170801234935p:plain



既存で様々な研究が進んでいて、
データであれば、

  • RGB画像、デプスなどの光学系
  • 加速度、角速度、気圧などのセンサ系

などがある。

行動であれば、

  • Standing, Sittingなどの姿勢系
  • Walking, Runningなどの遷移系
  • その他、より特徴的な動き

など多岐にわたる。

詳しくは後々まとめる。

やりたいこと

  • 行動認識のデータセットをいじり倒したい
  • tensorflowを勉強したい
  • 機械学習やら深層学習の知見を深めたい

データセット

個人的なモチベとしては、スマホでとれるセンサ系データを扱いたい(去年は扱っていた)

まず触ってみるのにいろいろ探したが、一番簡単に扱えそうなUCIから提供されるデータセットを利用。
UCI Machine Learning Repository: Human Activity Recognition Using Smartphones Data Set

一応、日本のデータセットも探した。
特に、大きいところだと、Human Activity Sensing Consortium(HASC)というコミュニティもあるが、簡単にアクセスできるデータが少なかったので今回は諦める。

ちなみに、UCIから提供される上記のデータセットは、2015年のUpdate版もある。
UCI Machine Learning Repository: Smartphone-Based Recognition of Human Activities and Postural Transitions Data Set

An updated version of this dataset can be found at [Web Link]. It includes labels of postural transitions between activities and also the full raw inertial signals instead of the ones pre-processed into windows.


「Human Activity Recognition Using Smartphones Data Set」『UCI Machine Learning Repository』より。
URL: https://archive.ics.uci.edu/ml/datasets/human+activity+recognition+using+smartphones

データについて

重要なことを書き残し

被験者 ボランティア 30人
年齢 19-48歳
行動種類 WALKING, WALKING_UPSTAIRS, WALKING_DOWNSTAIRS, SITTING, STANDING, LAYING
データ収集デバイス smartphone (Samsung Galaxy S II)
バイス上のセンサ 3軸加速度、3軸角速度
サンプリングレート 50 [Hz]
ラベリング手法 同時に撮影した映像からラベルを手動生成
データセット 学習データ:テストデータ=7:3 (被験者単位で分割)

データセットについては次の記載がある。

The sensor signals (accelerometer and gyroscope) were pre-processed by applying noise filters and then sampled in fixed-width sliding windows of 2.56 sec and 50% overlap (128 readings/window). The sensor acceleration signal, which has gravitational and body motion components, was separated using a Butterworth low-pass filter into body acceleration and gravity. The gravitational force is assumed to have only low frequency components, therefore a filter with 0.3 Hz cutoff frequency was used. From each window, a vector of features was obtained by calculating variables from the time and frequency domain.


「Human Activity Recognition Using Smartphones Data Set」『UCI Machine Learning Repository』より。
URL: https://archive.ics.uci.edu/ml/datasets/human+activity+recognition+using+smartphones

つまりこういうこと(だよね?)

  1. 加速度/角速度には、ノイズフィルタを適用
  2. 各データ(各軸)は128samplesのウィンド、オーバーラップは50%
  3. 加速度には、バターワスフィルタで重力成分を分離
  4. 特徴量ベクトルを時間/周波数領域から取得

今日は以上、次回は実際にデータを眺めたりしたい。