Monday, November 27, 2017

Reproduce IPFS YJS demo on Ubuntu 16.04

https://www.youtube.com/watch?v=-kdx8rJd8rQ

All source code from here.
git clone https://github.com/ipfs-shipyard/shared-editing-demo


ubuntu 16.04.

DO NOT USE apt install nodejs

wget https://nodejs.org/dist/v8.9.1/node-v8.9.1.tar.gz
tar xf node-v8.9.1.tar.gz
cd node-v8.9.1
./configure
make -j8
sudo make install

mkdir ipfs-yjs-demo
cd ipfs-yjs-demo
npm init
sudo npm install http-server -g
npm install browserify --save
npm install ipfs --save
npm install serve-favicon --save
npm install yjs y-memory y-array y-test --save
npm install y-ipfs-connector --save

mkdir -p public/js
mkdir src

====
On MacOS

curl -O https://nodejs.org/dist/v8.9.1/node-v8.9.1.tar.gz

A Year in Computer Vision

http://www.themtank.org/a-year-in-computer-vision

Sunday, November 26, 2017

Movidius NCSDK installation on Raspberry Pi 3

The installation script is not good for ubuntu 16.04 any more.
https://developer.movidius.com/start

With the official ubuntu 16.04.3 image (https://wiki.ubuntu.com/ARM/RaspberryPi), you will hit an error when "make install".

...
Successfully installed Cython-0.26 PyWavelets-0.5.2 graphviz-0.8 numpy-1.13.3 protobuf-3.4.0 scikit-image-0.13.0
You are using pip version 8.1.1, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
The directory '/home/xx/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/xx/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting Enum34>=1.1.6
  Downloading enum34-1.1.6-py2-none-any.whl
Installing collected packages: Enum34
Successfully installed Enum34-1.1.6
You are using pip version 8.1.1, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
Checking whether tensorflow is installed...
looking for tensorflow CPU version...
The directory '/home/xx/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
You are using pip version 8.1.1, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
looking for tensorflow GPU version...
The directory '/home/xx/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
You are using pip version 8.1.1, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
Couldn't find a supported tensorflow version, installing tensorflow v1.3.0
The directory '/home/xx/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/xx/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting tensorflow==1.3.0
  Could not find a version that satisfies the requirement tensorflow==1.3.0 (from versions: )
No matching distribution found for tensorflow==1.3.0
You are using pip version 8.1.1, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
Installation failed. Error on line 310

After 4 failures on RPI3 installation (~10 hrs), I found this page.
https://movidius.github.io/blog/ncs-apps-on-rpi/

The very first package installation will fail on ubuntu 16.04 since python3-protobuf does not exist at all.  This hints that they do NOT use the official ubuntu 16.04 on RPI3.

Switch to Raspbian Stretch!  The first package installation is very smooth.

I am crossing my finger for a smooth installation now...

... OK, still need 'sudo make install'.

There is no tensorflow included in this build.  Still, I have tensorflow 1.0 installed on a card.  Will try it later.