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.






Monday, October 9, 2017

Jewish Problem by Tanya Khovanova

This is a special collection of problems that were given to select applicants during oral entrance exams to the math department of Moscow State University.  These problems were designed to prevent Jewish people and other undesirables from getting a passing grade.  Among problems that were used by the department to blackball unwanted candidate students, these problems are distinguished by having a simple solution that is difficult to find.  Using problems with a simple solution protected the administration from extra complaints and appeals. 

https://arxiv.org/pdf/1110.1556.pdf

Monday, August 7, 2017

P8Z77 Hackintosh macOS Sierra 10.12.6

[Hardware]
Intel i7 3770S
ASUS P8Z77-V LX
Nvidia GTX 970

[Download]
Download Sierra 10.12.6
Download NVDA WebDriver-378.05.05.25f01.pkg (support 10.12.6)
Download cudadriver-8.0.90-macos.dmg
Download Unibeast 7.1.1
Download Multibeast - Sierra 9.1.0
Download Clover Configurator 4.46.0
https://drive.google.com/drive/folders/0B11ZqB11tZ92VlRhNHAtS3ZBdE0?resourcekey=0-edAfG24v4pvrhL7utLVDwA&usp=sharing

[USB]
Prepare a 16GB USB key.  Use Disk Utility to erase it with Mac OS Extended (Journaled) format and GUID Partition Map scheme.

[Unibeast creates installer USB]
Run Unibeast
- choose USB
- choose Sierra
- choose UEFI Boot Mode
- No NVDA injection

It takes a few minutes or up to 30 min to create USB install media.  Copy the reset downloaded packages to the USB media.

[BIOS change]
P8Z77 BIOS: Boot->Safe Boot->change Windows to Other OS
Boot #1 -> the USB media

[Clover Boot Args]
When Clover is up, go to setting,
Boot Args: -v dart=0 kext-dev-mode=1

[Install Sierra]
Boot up and install Sierra.

[Multibeast]
After installation and boot up to newly installed EFI Sierra through USB clover

Run Multibeast.
Driver -> Network -> RealtekRTL8111 v2.2.1
Bootloaders->Clover v2.4k r4063 UEFI Boot Mode
Then, build and install.

[Make hard drive bootable]
Reboot to Sierra through USB clover.

Run Clover Configurator
Mount EFI-> mount both EFI on hard driver and on installer USB.

In Finder,
For EFI on hard driver, rename EFI folder to EFI_
Copy EFI folder on USB EFI partition to the EFI partition on hard driver.

Use Clover Configurator opens EFI/CLOBER/config.plist
Boot-> check Verbose, dart=0, kext-dev-mode=1
System Parameters -> check NvidiaWeb

Save config.plist

[NVDA drivers]
Install both NVDA WebDriver and cudadriver

Remove Installer USB.  Reboot.

P8Z77 BIOS: Boot from the new hard drive.

[Multiple Monitor]
In config.plist, add
<key>VideoPorts</key>
<integer>3</integer>
3 Monitors will be lit up.

[Dual Boot with Windows 10]
Power off. 
Detach all hard drives except the one Windows 10 will be installed. 

Power on and install Windows 10. 

After installation, plug in back other hard drives.