Sorry for not installing Sogou Pinyin on TX1.
Firstly, after I have flashed the Ubuntu16.04 system and some other software(etc. cuda) into TX1, the rest space of the TX1
is only about 2GB. When I try to install opencv like the website:
http://blog.csdn.net/pjq_pjq/article/details/78345421
I got an error like this "no enough space".
So I bought a SD card from JD.com, it spent me 79 RMB.
(1)After I got the SD card. I did some things like the following commands:
sudo fdisk -l
The command is to ensure the SD card is actually recognized by your TX1. If you see like this info, congratulations, your SD card have been recognized by your TX1:
Device Boot Start End Sectors Size Id Type
/dev/mmcblk1p1 8192 62521343 62513152 29.8G c W95 FAT32 (LBA)
(2) Then you should unmount the SD card because the SD card have been mount by the Ubuntu system.
umount /dev/mmcblk1p1
(3) Then format the SD card to ext4
sudo mkfs.ext4 /dev/mmcblk1p1
(4) make a new dir to mount the SD card
mkdir /media/nvidia/SD
(5) mount the SD card
sudo mount /dev/mmcblk1p1 /media/nvidia/SD
OK, the SD card is mounted successfully.
(6) Then I will install opencv with the SD card. Firstly, we should install the dependencies.
sudo apt-get install build-essential
sudo apt-get install cmake git libgtk2.0-dev pkg-config libavcodec-dev libavformat-dev libswscale-dev
sudo apt-get install libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev
sudo apt-get install python2.7-dev
sudo apt-get install python-dev python-numpy libtbb2 libtbb-dev libjpeg-dev libpng-dev libtiff-dev libjasper-dev libdc1394-22-dev
sudo apt-get install libgtkglext1 libgtkglext1-dev
sudo apt-get install qtbase5-dev
sudo apt-get install libv4l-dev v4l-utils qv4l2 v4l2ucp
(7) Then I will git the opencv code from the github website
git clonehttps://github.com/opencv/opencv.git
(8) then I will cmake the opencv. Be careful! the last parameter is the location of the opencv source code which is git by you in the previous step. My opencv source code is located in ~/Experiments/opencv-3.2.0, you can adjust the dir according to your situation.
cd /media/nvidia/SD
cmake -D WITH_CUDA=ON -D CUDA_ARCH_BIN=”5.3” -D CUDA_ARCH_PTX=”” -D WITH_OPENGL=ON -DWITH_LIBV4L=ON -D CMAKE_BUILD_TYPE=RELEASE -D BUILD_TESTS=OFF -D BUILD_PERF_TESTS=OFF -D BUILD_EXAMPLES=OFF -D CMAKE_INSTALL_PREFIX=/usr/local ~/Experiments/opencv-3.2.0/
In this step, because I enter into the SD card and install the opencv. So the intermediate files will be located in the SD card. After you finished the installing, you can delete all the intermediate files in the SD card.
(9) make and make install the opencv
sudo make -j4
sudo make install