LoginSignup
1

More than 3 years have passed since last update.

posted at

Ubuntu 18.04・Anaconda環境にNuPICをインストールする

NuPICとは

numenta社がgithub上でhttps://github.com/numenta/nupic公開しているHTM学習アルゴリズムのPython実装です。今はやりのディープラーニングとは異なり、生物学的なアプローチでニューラルネットワークの学習を行います。

どんなことができるの?

HTMは、Hierarchical Temporal Memoryの頭字語です。日本語で言えば階層的時間記憶です。
HTMアルゴリズムは、時間的なパターンを記憶し、これまでの入力の時系列的な文脈に基づいて次の入力を予測することができます。

Hot Gym Prediction Tutorial

https://www.youtube.com/watch?v=S-0thrzOHTc
Youtubeのビデオチュートリアルです。
こちらの例ではスポーツジムの電力消費量を予測しています。

インストール方法

  1. Anacondaをインストールする
    https://www.anaconda.com/distribution/からlinux用のAnacondaをインストールしてください。詳細は他記事にお譲りします。。

  2. Python2.7の仮想環境を作成する
    余計なパッケージを入れるとエラーが出るので、入れるのはpipだけです。

$ conda create -n [仮想環境名] python=2.7 pip
  1. pipでnupicをインストール
$ pip install nupic

デモを動かしてみる

元githubhttps://github.com/numenta/nupicにあるデモ(cpu.py)を動かしてみます。まずはgit cloneします。

$ git clone https://github.com/numenta/nupic
$ cd nupic
$ cd examples/opf/clients/cpu
$ python cpu.py

このようなデモが走れば成功です。このデモではCPU使用率をリアルタイムで予測しています。
Screenshot from 2019-06-20 09-57-53.png

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
What you can do with signing up
1