Today I recommend a tool for managing your papers that store in you mind. Mendeley, an all-platform tool for managing your references.

  • It is web-based, and provide apps for Mac OSX, Linux, Windows and iOS and syncs your library across them.
  • It’s free for personal use with a limit of 2GB, which should be enough for most users.

    Pay if you need more storage or group cooperations.

  • Another feature I love most is that it can analysis pdf files automatically.

  • Of course, you can highlight and annotate interesting sections and record your thoughts, and they are part of your library and will syncs across all your devices.
  • It is kind of academic searching engine itself. You can discover more or search by your knowledge.

I won’t say Mendeley is the best one, but it’s much better than keeping everything in mind and downloading some paper every time you want to read it again:)

Now you’ve get your new toy from the delivery man. Unbox your Jetson TX1 and attach a monitor and a keyboard.
You will see that your TX1 comes with Ubuntu 14.04.
Default Username and Passwd are: ubuntu and ubuntu.

  • Install the package that comes with your TX1 in ~
1
2
sudo NVIDIA-INSTALLER/installer.sh
sudo reboot
  • Download and install cuda for TX1
1
2
3
4
5
6
7
sudo dpkg -i cuda-repo-l4t-r23.1-7-0-local_7.0-71_armhf.deb
sudo apt-get install cuda-toolkit-7-0
sudo usermod -a -G video $USER
echo "# Add CUDA bin & library paths:" >> ~/.bashrc
echo "export PATH=/usr/local/cuda/bin:$PATH" >> ~/.bashrc
echo "export LD_LIBRARY_PATH=/usr/local/cuda/lib:$LD_LIBRARY_PATH" >> ~/.bashrc
source ~/.bashrc

If everything’s installed correctly, running ‘nvcc -V’ should give you a compiler version message.

  • Download and install opencv for TX1
1
sudo dpkg -i libopencv4tegra-repo_2.4.12.3_armhf_l4t-r23.deb
  • Download and install cudnn for TX1
    cudnn-7.0-linux-armv7-v3.0-prod.tgz
1
tar -xvf cudnn-7.0-linux-armv7-v3.0-prod.tgz

The files are in ./cuda now. Then copy the cudnn files into cuda path.

1
2
3
4
5
6
cd cuda
sudo cp include/cudnn.h /usr/local/cuda/include/
sudo cp lib/* /usr/local/cuda/lib/
cd /usr/local/cuda/lib/
ln -fs libcudnn.so.7.0.64 libcudnn.so.7.0
ln -fs libcudnn.so.7.0 libcudnn.so
  • Install caffe dependencies

This part is mostly the same with Caffe official installation guide for Ubuntu 14.04, except the opencv. You should be safe with the following guide, if not, please refer to Caffe official installation guide

1
2
3
4
sudo add-apt-repository universe
sudo apt-get update
sudo apt-get install libprotobuf-dev libleveldb-dev libsnappy-dev libhdf5-serial-dev protobuf-compiler
sudo apt-get install --no-install-recommends libboost-all-dev
  • Install atlas as blas
1
sudo apt-get install libatlas-base-dev

or install OpenBLAS or MKL for better CPU performance.

  • Install remain dependencies in ubuntu 14.04
1
sudo apt-get install libgflags-dev libgoogle-glog-dev liblmdb-dev
  • Install caffe
1
2
3
4
sudo apt-get install -y git
git clone https://github.com/BVLC/caffe.git
cd caffe
cp Makefile.config.example Makefile.config

now compile caffe, remember Do NOT use all the cores by make all -j, or it hangs the system. Instead use the following.

1
make -j 3 all
1
2
# just to make sure everything is fine, leave this if you are in a rush
make -j 3 runtest

Finally you can run Caffe’s benchmarking code to measure the GPU performance.

1
build/tools/caffe time --model=models/bvlc_alexnet/deploy.prototxt --gpu=0

you may run into error: libcudart.so.7.0: cannot open shared object file: No such file or directory, to solve this, execute
sudo ldconfig /usr/local/cuda/lib

本文告诉你如何 go beyond wall,以及建立个人网站。我觉得有必要分享一下我在用的一些互联网服务,给像我一样的人。

Github Student Developer Pack

这是 Github 联合多家优秀的互联网公司为学生党提供的一项优惠服务集合。下面我介绍 go beyond wall 和建站要用的。

DigitalOcean

100 美金充值卡,足够你用 5 美金的服务 20 个月。5 美金的服务足够你正常的 go beyond wall 和 VPS 等需求。
搞定这家 VPS 后,用 shadowsocks (github 上自己找吧)在你的 VPS 上建好 Server,然后在你本地机器上启动 Client. Win 和 Mac 推荐 UI 客户端,Linux 推荐脚本.
我在 linux 上是这么启动 go beyond wall 的服务的:

1
~/fuckgfw.sh

里面是这么写的

1
sudo sslocal -c /etc/shadowsocks.json -d start

或者你可以这么干:

1
alias fuckgfw="sudo sslocal -c /etc/shadowsocks.json -d start"

然后这个优雅的命令

1
fuckgfw

就出去了,哇爽歪歪有没有。
然后再用上 Chrome 的 SwitchyOmega 插件之类的,该出去的时候出去,不该出去的时候不出去。
另外,移动端上网用 vpn 比较方便,如何在你的 vps 上搭建 vpn 服务,参见我的另一篇博客Ubuntu 上配置 VPN 服务.

namecheep

一年免费的 .me 域名和一年的 SSL 证书 (就是酷酷的https://)。
申请好域名,然后用 Github 的建站服务,用 hexo 管理你的网站。

好了,有些东西也不能说太细,不然有一天我的网站也许就 beyond the wall 了。有需求的人自然懂。

最后,说一句。我们生活在伟大的互联网时代,有很多优质的收费服务,可以很好地改善你的生活。如果你也是以互联网服务谋生的人,请养成付费习惯吧。

如果觉得对你有启发,打赏一下吧!

我现在要讲的故事,开的脑洞有点大。

有一天中午,我在桃李园吃面条。 大盘鸡拌面,我觉得并不好吃。然而前一天刚吃过一次,觉得特别好吃,才又来吃的。
这让我想起来小灰灰讲的一个故事。说高中的时候,语文老师讲一个故事,说他有一天吃到一份特别好吃的面。于是叫来第二碗,却不觉得好吃了。

我讲这个拗口的故事,真是讲的太烂了。然而,我知道你大概能够体会那位中学语文老师的意思。我要讲的,却是另外一层。这个普通的中学语文老师,通过影响他的学生,影响到了我这个与他毫不相干的老博士生在桃李园吃一碗面时的感受。

中小学老师是最应该精挑细选的,这个阶段的学生是最容易受老师影响的。然而,中国的实际情况是,人们普遍认为只有那些水平一般的大学毕业生去高中教书,次之初中,再次小学。在一些超级城市,这样的情况正在改变,我身边就有几位优的清华毕业生去高中任教。

我想,一种理想的方式是,在我这一生的某些阶段,我去做一个中小学老师,与他们共同学习,从零到一,并用他们能理解的方式分享阅历。

有一回,大神说当老师多好,能够影响很多人。我觉得很有道理。

然而,这件事该怎么去做呢, 倒是个可以慢慢琢磨的问题。首先选地方,我觉得青海不错,然后是甘肃,河南,云南,广西。

我希望带我的学生去户外,去登山,去骑行,或者是他们带我。

Ubuntu 配置 VPN 服务器

用于在你的 VPS 上搭建 VPN 服务器。对我来说,主要原因是 shadowsocks 在移动端不好用,所以换成 vpn。

  • login
  • 安装 PPTPD
1
sudo apt-get install pptpd
  • 编辑 pptpd.conf 文件
1
sudo vim /etc/pptpd.conf
取消注释下面内容
1
2
localip 192.168.0.1
remoteip 192.168.0.234-238,192.168.0.245
这几句的意思是:当外部计算机通过 pptp 联接到 vpn 后所能拿到的 ip 地址范围和服务器的 ip 地址设置。
  • 添加用于登陆的账户
1
sudo vim /etc/ppp/chap-secrets
格式如下:
1
myusername pptpd mypasswd *
从左到右依次是你的用户名。服务器,填写 pptpd。你的密码。IP,填 * 即可。中间用空格分别隔开。
可以填写多个,另写一行即可。
  • 设置 DNS 解析,编辑 pptpd-options 文件
1
sudo vim /etc/ppp/pptpd-options
找到 ms-dns,取消掉注释,并修改 DNS 地址,推荐用 Google DNS 8.8.8.8 和 8.8.4.4
1
2
ms-dns 8.8.8.8
ms-dns 8.8.4.4
  • 开启转发
1
sudo vim /etc/sysctl.conf
取消注释以下内容
1
net.ipv4.ip_forward=1
这句话意思是:打开内核 IP 转发
然后更新一下配置:
1
sudo sysctl -p
  • 安装 iptables 并设置
1
2
sudo apt-get install iptables
sudo iptables -t nat -A POSTROUTING -s 192.168.0.0/24 -o eth0 -j MASQUERADE
后面这句话作用是:立刻让 LINUX 支持NAT(platinum)
  • 重新启动服务
1
sudo /etc/init.d/pptpd restart
done!
在 vpn 客户端,选择 pptp 类型,填写你的 vps 地址,VPN 账号和密码,就可以连你的 VPN 啦。

如果觉得帮到了你,打赏一下吧!

Isn’t it funny how day by day nothing change but when you look back, everything is different? by The Big Bang Theory

太阳升起的时候,我常常想起林清玄的《与时间赛跑》。

时间过得飞快,使我的小心眼里不只是着急,还有悲伤。

生活的方式

对于2015年,我设想过很多种情形。最终走了其中的一种,当然和设想的也是有很大的不同,主要是惊喜。

Read More

国庆长假去广东北部骑行,路线从韶关到广州。

计划

xhh的车子放在了广州,我的车在深圳,为方便起见,我们先空身从深圳到广州,然后我在广州租一辆车。

Read More

Vim

Spell check

use :set spell for checking spell errors.
use :set nospell for closing.

Programming Syntastic check

  • Install Syntastic addon.
  • Then use :SyntasticInfo to check the checkers.
  • Take matlab code for example:
    add mlint to Path (or system link to /usr/local/bin/)
  • use :Errors (:lopen) to check; :w to auto check.
  • Enjoy coding.

Un-block Google Scholar for DigitalOcean vps

DigitalOcean’s ipv4 addresses are blocked by Google Scholar. We can solve this with ipv6.
To make it work:

  • Enable ipv6 support in DigitalOcean online setting;
  • SSH vps, add Google Scholar ipv6 addresses in /etc/hosts:
1
2
3
4
2607:f8b0:4007:805::100f scholar.google.cn
2607:f8b0:4007:805::100f scholar.google.com
2607:f8b0:4007:805::100f scholar.google.com.hk
2607:f8b0:4007:805::100f scholar.l.google.com
  • In vps, restart shadowsocks:
1
2
sudo ssserver -c /etc/shadowsocks.json -d stop
sudo ssserver -c /etc/shadowsocks.json -d start
  • update on Jul. 18, 2016. If Google Search is blocked, you may want to add two more lines in /etc/hosts:
1
2
2607:f8b0:4005:801::200e google.com
2607:f8b0:4005:801::200e www.google.com
  • Enjoy.
    如果觉得帮到了你,打赏一下吧!

她不在
置身千万人之中
孤独袭来

今天说说五道口。
有一回骑行妙峰山,回来的路上,看到交通标志牌,有一个方向指向“北京市区”。当时我们应该是已经进了石景山区了,所以看到北京市区还是觉得有点奇怪。同行的小悦悦笑了:北京市区是东城区西城区这些地方啊,这地方只能算北京郊区。我们也笑了,圆明园地处北京西北郊,而清华园就在圆明园边上,自然也是北京郊区了。
清华的东门出去,是五道口。这个地方二十年前据说还是一片农田。所以,李健写过一首歌《风吹麦浪》,就是他在清华的宿舍楼里发呆的时候,看窗外的麦浪而作。
然而,中关村一夜之间就成了中国的 IT 中心,信息时代把中关村带上了不亚于深圳的发展速度。
五道口对于大清的学生,是校外的娱乐中心,娱乐主要是吃。各种各样的主题是吃在五道口的帖子屡见不鲜了。

宇宙中心

五道口被戏称为宇宙中心,我搞不清楚这个称呼存在于清华学生口中,还是五道口人们口中,还是整个北京。我旁敲侧击地做过测试,司机师傅对把五道口称为宇宙中心并不感到奇怪。这个绰号怎么来的呢?据我猜测有多种可能:

  1. 五道口拥堵程度是宇宙中最高的;
  2. 五道口购物中心,即华联大厦,英文名字叫 Uni-Center,大大的标志在楼顶,遥遥可见;
  3. 五道口韩国人多,韩国人认为整个宇宙中,他们是中心。

我在五道口

在清华学习,在科技园搬砖,整个生活都是在五道口转的。
每天必过的繁忙路口,每天必吃的五道口美食。到了 6 点半左右,下班时间,从东往西走是很困难的,因为你会觉得自己在巨大的人流中“逆行”。各种各样的人,都是年轻人,女性居多,因为男工程师还在加班吧,我猜。
走在这样的人流里,我就消失在人流里。有一回经过赛乐堡,汪峰的北京北京在空中飘扬。要是再来一首存在,气氛就恰到好处了。
最近两个月在五道口,我有两大爱好,必须要在五道口完成,一是健身,一是看电影。绝大部分时候都是一个人,所以我有充分的时间发呆。刚才在健身房,我突然想:

我在川流不息的人群中死去,又在健身房重生。

这句话容不得品,因为它俗不可耐。健身房本就是都市生活和健康需求的折衷。所以你不能在健身房重生,要在一个豪迈的地方重生,比如山巅。
五道口的美食我吃过的却并不多,因为我觉得吃东西很麻烦,必须要有人带我。所以我一个人吃饭是一点也不美好的事情。可是并没有人陪我……
煎饼侠里有个镜头给的是搜狐大厦,我在健身房又看到搜狐大厦。有时候我觉得离张学长很近,有时候很远。
五道口啊,五道口。