Skip to content

Instantly share code, notes, and snippets.

View koji's full-sized avatar
🔍
I may be slow to respond.

koji koji

🔍
I may be slow to respond.
View GitHub Profile
@koji
koji / librealsense_install_on_ubuntu.md
Last active December 24, 2018 16:17
For installing librealsense from source code on Ubuntu
$ sudo apt-get update && sudo apt-get upgrade && sudo apt-get dist-upgrade
$ sudo apt-get install --install-recommends linux-generic-lts-xenial xserver-xorg-core-lts-xenial xserver-xorg-lts-xenial xserver-xorg-video-all-lts-xenial xserver-xorg-input-all-lts-xenial libwayland-egl1-mesa-lts-xenial
$ sudo update-grub && sudo reboot
$ sudo apt-get install git libssl-dev libusb-1.0-0-dev pkg-config libgtk-3-dev
$ sudo apt-get install libglfw3-dev (16)
@koji
koji / orc_setup.md
Created December 16, 2018 23:25
set up tesseract 4.0 on macOS

OCR_app

OCR App

Install Tesseract 4.0 on MacOS

$ brew install tesseract --HEAD
$ pip install pytesseract
@koji
koji / random_hiragana.py
Created November 18, 2018 22:00
Display Hiraganas randomly
# coding: utf-8
import random
hiragana = ""
for i in range(5):
k = random.randint(ord('あ'),ord('ん'))
hiragana = hiragana + chr(k)
print(hiragana)
@koji
koji / anaconda_commands.md
Created November 16, 2018 17:06
basic commands for anaconda

Anaconda

update
$ conda update conda

create virtual env
$ conda create --name py35 python=3.5 

list env
@koji
koji / sort_array.md
Created November 4, 2018 05:26
sort array
const arr = [100, 0, 45, 66, 89, 200]; 
arr.sort((a,b)=>{ return a-b; }); 
console.log(arr);
@koji
koji / upgrade_ubuntu.md
Created July 23, 2018 01:14
upgrade ubuntu
$ sudo apt-get update
$ sudo apt-get upgrade
$ sudo apt-get dist-upgrade
$ sudo do-release-upgrade
@koji
koji / pip_install_error.md
Created July 22, 2018 17:38
pip install error
$ pip install something
Command "python setup.py egg_info" failed with error code 1

$ sudo pip install --upgrade setuptools
@koji
koji / install_utuntu_wiht_vagrant.md
Last active July 21, 2018 23:44
setup ubuntu for machine learning with vagrant

In this case, I'm using cmder.
Windows machine has Virtual box and vagrant.

setup vagrant

$ vagrant box add ubuntu/trusty64
$ vagrant init ubuntu/trusty64
$ vagrant up
@koji
koji / my_vimrc.md
Created July 17, 2018 20:13
basic vim settings
"#### settings ####
set number " display line numbers
set title
syntax on
set tabstop=4
set shiftwidth=4
set noswapfile

"set matchpairs& matchpairs+=<:>
@koji
koji / pi-and-nginx.md
Last active May 1, 2019 00:31
raspberry pi and nginx
check version
$ cat /etc/debian_version
$ apt-get update
$ apt-get -y install nginx
$ apt-get -y install uwsgi-plugin-python3