Skip to content

Instantly share code, notes, and snippets.

View jaekookang's full-sized avatar
🎯
Focusing

jkang jaekookang

🎯
Focusing
View GitHub Profile
@jaekookang
jaekookang / ffmpeg.md
Created May 16, 2019 22:12 — forked from protrolium/ffmpeg.md
using ffmpeg to extract audio from video files

ffmpeg

Converting Audio into Different Formats / Sample Rates

Minimal example: transcode from MP3 to WMA:
ffmpeg -i input.mp3 output.wma

You can get the list of supported formats with:
ffmpeg -formats

Convert WAV to MP3, mix down to mono (use 1 audio channel), set bit rate to 64 kbps and sample rate to 22050 Hz:

@jaekookang
jaekookang / git-clearHistory
Created February 24, 2019 17:34 — forked from stephenhardy/git-clearHistory
Steps to clear out the history of a git/github repository
-- Remove the history from
rm -rf .git
-- recreate the repos from the current content only
git init
git add .
git commit -m "Initial commit"
-- push to the github remote repos ensuring you overwrite history
git remote add origin git@github.com:<YOUR ACCOUNT>/<YOUR REPOS>.git
@jaekookang
jaekookang / train.py
Created July 3, 2018 04:16
Task: Fill in the blank in a sentence / training script snippet (in progress)
'''
Train
python 3.6.4
tensorflow 0.12.1
2018-06-30
'''
import ipdb as pdb
import os
import utils
@jaekookang
jaekookang / train.py
Created July 3, 2018 04:14
Task: Fill in the blank in a sentence.
'''
Train
python 3.6.4
tensorflow 0.12.1
2018-06-30
'''
import ipdb as pdb
import os
import utils
@jaekookang
jaekookang / thread.py
Created April 7, 2018 04:19 — forked from ruedesign/thread.py
Python thread sample with handling Ctrl-C
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import sys, time, threading, abc
from optparse import OptionParser
def parse_options():
parser = OptionParser()
parser.add_option("-t", action="store", type="int", dest="threadNum", default=1,
help="thread count [1]")
@jaekookang
jaekookang / min-char-rnn.py
Created December 12, 2016 22:31 — forked from karpathy/min-char-rnn.py
Minimal character-level language model with a Vanilla Recurrent Neural Network, in Python/numpy
"""
Minimal character-level Vanilla RNN model. Written by Andrej Karpathy (@karpathy)
BSD License
"""
import numpy as np
# data I/O
data = open('input.txt', 'r').read() # should be simple plain text file
chars = list(set(data))
data_size, vocab_size = len(data), len(chars)
@jaekookang
jaekookang / autoencoder.py
Created December 3, 2016 22:56 — forked from saliksyed/autoencoder.py
Tensorflow Auto-Encoder Implementation
""" Deep Auto-Encoder implementation
An auto-encoder works as follows:
Data of dimension k is reduced to a lower dimension j using a matrix multiplication:
softmax(W*x + b) = x'
where W is matrix from R^k --> R^j
A reconstruction matrix W' maps back from R^j --> R^k