Skip to content

Instantly share code, notes, and snippets.

View chakkritte's full-sized avatar
🇦🇺
Working from Australia

Chakkrit Termritthikun chakkritte

🇦🇺
Working from Australia
View GitHub Profile
@chakkritte
chakkritte / openfile.cpp
Created June 4, 2015 17:46
Example OpenCV
#include<opencv2\core\core.hpp>
#include<opencv2\highgui\highgui.hpp>
#define TEST_IMAGE "D:\\opencv.png"
int main(){
// Open the file.
cv::Mat img = cv::imread(TEST_IMAGE);
// Display the image.
cv::namedWindow("Image:", CV_WINDOW_AUTOSIZE);
@chakkritte
chakkritte / dp1.txt
Created December 30, 2016 21:39
Deep learning Part 1
1.Install python
https://www.python.org/downloads/release/python-352/
2.To install the CPU-only version of TensorFlow
C:\> pip install --upgrade https://storage.googleapis.com/tensorflow/windows/cpu/tensorflow-0.12.1-cp35-cp35m-win_amd64.whl
3.Test your installation
$ python
name: "CReLU-conv1-4"
input: "data"
input_shape {
dim: 1
dim: 3
dim: 224
dim: 224
}
layer {
name: "conv1"
1.Install Keras
git clone git://github.com/fchollet/keras.git
cd keras
python setup.py develop
2.Demo training data on keras with gpu
from __future__ import print_function
from keras.datasets import cifar10
from keras.models import Sequential
from keras.layers import Dense, Dropout, Activation, Flatten
from keras.layers import Convolution2D, MaxPooling2D
from keras.utils import np_utils
batch_size = 128
nb_classes = 10
nb_epoch = 20
@chakkritte
chakkritte / readme
Created February 21, 2017 08:37
Deep learning Ep. 4 : Install TensorFlow 1.0 on Windows (with CUDA) https://www.youtube.com/watch?v=BnQzAXnGma0
#Install tensorflow 1.0 on windows 10
we’re announcing TensorFlow 1.0:
-It’s faster
-It’s more flexible
-It’s more production-ready than ever
#Step 1 install
##CPU-only
@chakkritte
chakkritte / readme
Created March 30, 2017 13:05
Deep learning Ep. 5 : [New] Install Tensorflow with CUDA, CUDNN and Keres on Windows : https://www.youtube.com/watch?v=Rmjp1yFi9Ok
1. Install CUDA v8.0 toolkit --> https://developer.nvidia.com/cuda-downloads
2. Install cuDNN v5.1 for CUDA 8.0 --> https://developer.nvidia.com/rdp/cudnn-download
3. Install GIT 64-bit -> https://git-scm.com/download/win
4. Install Anaconda3-4.2.0 --> https://repo.continuum.io/archive/Anaconda3-4.2.0-Windows-x86_64.exe
5. Open windows command terminal
- conda create -n tensorflow
- activate tensorflow
- pip install --ignore-installed --upgrade https://storage.googleapis.com/tensorflow/windows/gpu/tensorflow_gpu-1.0.1-cp35-cp35m-win_amd64.whl
6. Validate your installation (Open windows command terminal )
-- Xception model
-- a Torch7 implementation of: https://arxiv.org/abs/1610.02357
-- E. Culurciello, October 2016
require 'nn'
local nClasses = 1000
function nn.SpatialSeparableConvolution(nInputPlane, nOutputPlane, kW, kH)
local block = nn.Sequential()
block:add(nn.SpatialConvolutionMap(nn.tables.oneToOne(nInputPlane), kW,kH, 1,1, 1,1))
pragma solidity ^0.5.0;
// ----------------------------------------------------------------------------
// 'FIXED' 'Example Fixed Supply Token' token contract
//
// Symbol : FIXED
// Name : Example Fixed Supply Token
// Total supply: 1,000,000.000000000000000000
// Decimals : 18
//
#!/bin/sh
# base image docker
BASE=ufoym/deepo
# name of container
NAME=$1
# directory
DIR=/home/$(whoami)
export UID=$(id -u)