Skip to content

Instantly share code, notes, and snippets.

View lxxstc's full-sized avatar

Xiaoxu Lv lxxstc

  • botim.me
  • beijing
View GitHub Profile

Install dlib and face_recognition on a Raspberry Pi

Instructions tested with a Raspberry Pi 2 with an 8GB memory card. Probably also works fine on a Raspberry Pi 3.

Steps

Download the latest Raspbian Jessie Light image. Earlier versions of Raspbian won't work.

Write it to a memory card using Etcher, put the memory card in the RPi and boot it up.

基本是按照文档顺序,此处对INSTALL.md做补充

安装BLAS/LAPACK

Ubuntu

不必按照INSTALL.md里面的编译安装方法,只要安装源里的包即可

$ sudo apt install libopenblas-dev
$ sudo apt install liblapack
$ sudo apt install swig

CentOS7

系统Ubuntu

参考文档

克隆工程

$ git clone 	https://github.com/cmusatyalab/openface
$ cd openface

安装依赖

  • torch
@lxxstc
lxxstc / elk.md
Created March 12, 2016 14:44
elk introduce
@lxxstc
lxxstc / baidu_tunnel.md
Last active December 29, 2015 21:29
如何访问百度内网的链接

环境

  • 外网跳板: 192.241.238.106
  • 百度机和端口:cq02-vs-hotel-test02.cq02.baidu.com:8085
  • 本机:127.0.0.1

步骤

  • 从百度内网建立一个远端转发端口
 ssh -R 2123:cq02-vs-hotel-test02.cq02.baidu.com:8085 shrimp@192.241.238.106  -p80

创建一个:

$ time dd if=/dev/zero of=test bs=128k count=1512 oflag=dsync

用tcpdump以文本形式查看报文内容:

$ sudo tcpdump -p  -i eth0 -s 0 -l -w - dst port 6666 and dst host l-mem1.f.cn1.qunar.com | strings | grep set

概念

Write Ahead Log

  • Why? [Write Ahead Log] 减少磁盘IO 做PITR
  • Location: $PGDATA/pg_xlog
  • Size: 16MB determinated at compile time
  • rotation

概念

Write Ahead Log

  • Why? [Write Ahead Log] 减少磁盘IO 做PITR
  • Location: $PGDATA/pg_xlog
  • Size: 16MB determinated at compile time
  • rotation
@lxxstc
lxxstc / hadoop_script
Last active December 17, 2015 05:19
hadoop streaming script
hadoop jar ./contrib/streaming/hadoop-streaming-0.20.2-cdh3u4.jar -input /home/xiaoxu.lv/publish_fare/raw_data/blacketermmergeresults_zip_2013-05-10.txt -output /home/xiaoxu.lv/publish_fare/rule_detail/ -mapper extract_raw.py -file extract_raw.py -reducer cat -numReduceTasks 41
hadoop jar ./contrib/streaming/hadoop-streaming-0.20.2-cdh3u4.jar -input /home/xiaoxu.lv/publish_fare/rule_detail/ -output /home/xiaoxu.lv/publish_fare/rule_detail_count_finger/ -mapper "cut -f 1" -reducer "uniq -c" -numReduceTasks 41