Skip to content

Instantly share code, notes, and snippets.

View r9y9's full-sized avatar
:shipit:
( ˘ω˘ ) zzz

Ryuichi Yamamoto r9y9

:shipit:
( ˘ω˘ ) zzz
View GitHub Profile
@r9y9
r9y9 / b.sh
Created September 13, 2017 07:39
cd ~/Desktop/nnmnkwii_gallery
python ./scripts/prepare_features.py ./data/NIT-ATR503/ --use_phone_alignment --question_path="./data/questions_jp.hed"
@r9y9
r9y9 / a.sh
Created September 13, 2017 06:57
#!/bin/bash
set -e
script_dir=$(cd $(dirname ${BASH_SOURCE:-$0}); pwd)
data_root=$script_dir/../data
cd $data_root
HTS_DEMO_ROOT=$1
@r9y9
r9y9 / gmm_vc.py
Created September 12, 2017 17:23
GMM voice conversion using https://github.com/r9y9/nnmnkwii
"""GMM-based voice conversion"""
from nnmnkwii.datasets import FileSourceDataset
from nnmnkwii.datasets.cmu_arctic import CMUArcticWavFileDataSource
from nnmnkwii.preprocessing.alignment import DTWAligner
from nnmnkwii.util import apply_each2d_trim
from nnmnkwii.preprocessing import remove_zeros_frames, delta_features
from nnmnkwii.metrics import melcd
from nnmnkwii.baseline.gmm import MLPG
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@r9y9
r9y9 / a.py
Created June 27, 2017 11:53
Faster version of __construct_weight_matrix in https://gist.github.com/r9y9/88bda659c97f46f42525#file-gmmmap-py
import scipy.sparse
import numpy as np
# From my previous code
def __construct_weight_matrix(T, D):
# Construct Weight matrix W
# Eq.(25) ~ (28)
tmp = np.zeros(D)
@r9y9
r9y9 / gist:b619022c5d2413503cc6029e5704d006
Created June 1, 2017 07:11
opencv 3.2.0 for anaconda3, ubuntu 16.04 with CUDA
cmake -DCMAKE_BUILD_TYPE=Release -DWITH_QT=ON -DWITH_OPENGL=ON -DOPENCV_EXTRA_MODULES_PATH=$HOME/opencv_contrib/modules -DENABLE_AVX=ON -DENABLE_AVX2=ON -DENABLE_SSE41=ON -DENABLE_SSE42=ON -DBUILD_EXAMPLES=OFF -DBUILD_opencv_apps=OFF -DBUILD_DOCS=OFF -DBUILD_SHARED_LIBS=ON -DBUIDL_opencv_python3=ON -DBUILD_PERF_TESTS=OFF -DBUILD_TESTS=OFF -DENABLE_SSSE3=ON -DWITH_OPENMP=ON -DPYTHON3_EXECUTABLE=~/anaconda3/bin/python -DWITH_CUDA=ON -DWITH_CUBLAS=ON -DWITH_CUFFT=ON -DCUDA_ARCH_BIN="6.1" -DCUDA_FAST_MATH=ON -DCMAKE_INSTALL_PREFIX=$(~/anaconda3/bin/python -c "import sys; print(sys.prefix)") ..
@r9y9
r9y9 / Demonstration-of-pyreaper.ipynb
Created May 17, 2017 15:50
Demonstration of pyreaper
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@r9y9
r9y9 / spectral_param.ipynb
Last active July 23, 2020 10:33
Comparison of spectral envelope parametrization methods (http://nbviewer.jupyter.org/gist/r9y9/ca05349097b2a3926ec77a02e62c6632)
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@r9y9
r9y9 / test.jl
Last active January 10, 2017 03:54
@time using PCLCommon,PCLVisualization,PCLIO,PCLFilters,Cxx
@time using CVCore, CVHighGUI, CVImgProc
# IR camera parameters of Kinect v2
fx = 365.1177
fy = 365.1177
cx = 256.0793 + 74
cy = 204.4635 + 100
function getDepthFromPointCloud!(depth, cloud)