Skip to content

Instantly share code, notes, and snippets.

View chrinide's full-sized avatar

Chrinide chrinide

View GitHub Profile
library(foreach)
library(iterators)
library(doParallel)
library(tcltk)
# Choose number of iterations
n <- 1000
cl <- makeCluster(8)
1. Install Environment (All Hosts)
1.1. Install CentOS-6.5-x86_64-minimal 1 master and 3 slave (static ip: 192.168.10.100 - 192.168.10.103)
# yum install wget -y
1.2. Setup hosts
# vi /etc/hosts
192.168.10.100 master.kxlab.org
192.168.10.101 slave1.kxlab.org
192.168.10.102 slave2.kxlab.org
192.168.10.103 slave3.kxlab.org
# hostname -f
@chrinide
chrinide / Caffe + Ubuntu 12.04 64bit + CUDA 6.5 配置说明.md
Created November 19, 2015 02:49 — forked from bearpaw/Caffe + Ubuntu 12.04 64bit + CUDA 6.5 配置说明.md
Caffe + Ubuntu 12.04 / 14.04 64bit + CUDA 6.5 / 7.0 配置说明

Caffe + Ubuntu 12.04 64bit + CUDA 6.5 配置说明

本步骤能实现用Intel核芯显卡来进行显示, 用NVIDIA GPU进行计算。

1. 安装开发所需的依赖包

安装开发所需要的一些基本包

sudo apt-get install build-essential
sudo apt-get install vim cmake git
sudo apt-get install libprotobuf-dev libleveldb-dev libsnappy-dev libopencv-dev libboost-all-dev libhdf5-serial-dev
@chrinide
chrinide / readme.md
Created March 10, 2017 06:08 — forked from baraldilorenzo/readme.md
VGG-16 pre-trained model for Keras

##VGG16 model for Keras

This is the Keras model of the 16-layer network used by the VGG team in the ILSVRC-2014 competition.

It has been obtained by directly converting the Caffe model provived by the authors.

Details about the network architecture can be found in the following arXiv paper:

Very Deep Convolutional Networks for Large-Scale Image Recognition

K. Simonyan, A. Zisserman

@chrinide
chrinide / basic_query.csv
Created March 10, 2017 08:19 — forked from mdeland/basic_query.csv
Summarizing Data in SQL
date num_customers distinct_customers total_bananas total_revenue revenue_per_sale
2016-01-01 345 287 564 3689 6.54
2016-01-02 364 299 582 4080 7.01
... ... ... ... ... ...
@chrinide
chrinide / adjacency_list.py
Created March 27, 2017 06:39 — forked from rik0/adjacency_list.py
Snippets on graph & network theory
class AdjacencyListGraph(object):
def __init__(self):
self.node = {}
self.adj = {}
def add_node(self, node, **attrs):
if node not in self.adj:
self.adj[node] = {}
self.node[node] = attrs
import cntk
import cntk.ops as C
import numpy as np
from sklearn.preprocessing import OneHotEncoder
from cntk.blocks import default_options, Input # Building blocks
from cntk.initializer import glorot_uniform
from cntk.layers import Dense # Layers
from cntk.learner import sgd, learning_rate_schedule, UnitType
import dshelper as dsh
import instrumentdb as idb
import logging
import numpy as np
import os
import pandas as pd
import psutil
import sys
import tensorflow as tf
import time
@chrinide
chrinide / mlloop.py
Created April 19, 2017 06:15 — forked from ivannp/mlloop.py
Walk-Forward Machine Learning Loop
import dshelper as dsh
import numpy as np
import os
import pandas as pd
import sys
import time
from sklearn.discriminant_analysis import QuadraticDiscriminantAnalysis as QDA
from sqlalchemy import create_engine, MetaData