Skip to content

Instantly share code, notes, and snippets.

View nyk510's full-sized avatar
🤒
Out sick

Yamaguchi Takahiro nyk510

🤒
Out sick
View GitHub Profile
@nyk510
nyk510 / file0.txt
Last active October 14, 2015 00:36
PRML 第5章 ニューラルネットの実装 ref: http://qiita.com/nykergoto/items/a6bd77b198814699a843
\begin{align}
y_n&=f(\sum_{j=1}^M w_{kj}^{(2)} \tanh(\sum_{i=1}^D w_{ji}^{(1)}x_i+w_{j0}^{(0)})+w_{k0}^{(2)})\\
&=\sum_{j=1}^M w_{kj}^{(2)} \tanh(\sum_{i=1}^D w_{ji}^{(1)}x_i+w_{j0}^{(0)})+w_{k0}^{(2)}
\end{align}
# coding: utf-8
import numpy as np
import matplotlib.pyplot as plt
import seaborn as sns
import pandas as pd
sns.set(context='notebook', style='white')
sns.set_palette(sns.color_palette(palette='Set1')[:])
# coding: utf-8
# In[3]:
from chainer import Chain
from chainer import Variable,optimizers
import chainer.functions as F
import chainer.links as L
@nyk510
nyk510 / highschoollike_plot.py
Last active December 4, 2016 09:25
高校生っぽいグラフ
import matplotlib.pyplot as plt
import numpy as np
import seaborn as sns
def decorate_arrows(plotting):
def inner(x, y,figsize=(6,4), delete_labels=True, fontdict='default',xlim='default',ylim='default'):
fig, ax = plotting(x, y, figsize)
incs = fig.get_size_inches()
incs = np.array(incs)
@nyk510
nyk510 / nikkei.ipynb
Created May 10, 2017 20:43
日経株価っぽいデータ作成
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@nyk510
nyk510 / Gpy_vs_sklearn.ipynb
Last active January 12, 2023 10:18
GPy と Scikit-learn のガウス過程の比較
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@nyk510
nyk510 / bias_variance.py
Created November 10, 2019 10:43
PRML Section3 Figure3.5
import numpy as np
import matplotlib.pyplot as plt
def gaussian_kernel(x, basis=None):
if basis is None:
basis = np.linspace(-1.2, 1.2, 101)
# parameter is my choice >_<
phi = np.exp(- (x.reshape(-1, 1) - basis) ** 2 * 250)
@nyk510
nyk510 / main-component.vue
Created December 30, 2019 04:36
method status
<template>
<div class="pa-4">
<v-chip
v-for="item in sortedItems"
:class="itemClass(item)"
:key="item.value"
@click="onClickItem(item)">
{{ item.text }}
</v-chip>
@nyk510
nyk510 / lifegame.vue
Created April 20, 2020 17:38
Vue.js Lifegame (220 lines)
<template>
<v-container>
<v-layout align-center>
<v-btn
:disabled="!!taskId"
depressed
class="ma-0"
@click="onClickPlay">
<v-icon>play_arrow</v-icon>
</v-btn>
@nyk510
nyk510 / logging_recording.ipynb
Last active August 1, 2020 07:54
Logging Recording
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.