Skip to content

Instantly share code, notes, and snippets.

🦊
hi

Yuki Okuda yagays

🦊
hi
Block or report user

Report or block yagays

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View 20181227marisa_trie_experiment.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View api_test.py
import json
from http.server import HTTPServer, SimpleHTTPRequestHandler
class CustomHandler(SimpleHTTPRequestHandler):
def do_GET(self):
SimpleHTTPRequestHandler.do_GET(self)
print("===headers===\n", self.headers)
print("===path===\n", self.path)
def do_POST(self):
View autodiff_impl.py
# Ref. http://www.cs.cmu.edu/~wcohen/10-605/notes/autodiff.pdf
from collections import namedtuple
Assignment = namedtuple("Item", ("z", "g", "y_list"))
# f(x_1, x_2) = (2x_1 + x_2)^2
l = [Assignment(z="z1", g="add", y_list=["x1", "x1"]),
Assignment(z="z2", g="add", y_list=["z1", "x2"]),
Assignment(z="f", g="square", y_list=["z2"])]
@yagays
yagays / nfkc_compare.txt
Last active May 25, 2018 — forked from ikegami-yukino/nfkc_compare.txt
Pythonのunicodedata.normalize('NFKC')で正規化される文字の一覧
View nfkc_compare.txt
# for Python 3.6
import unicodedata
# from 0 through 1,114,111 (https://docs.python.org/3.6/library/functions.html#chr)
for unicode_id in range(1114111):
char = chr(unicode_id)
normalized_char = unicodedata.normalize("NFKC", char)
if char != normalized_char:
if len(normalized_char) == 1:
code_point = ord(normalized_char)
View benchmark_pr58.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View kaggle_kernel_package.py
ImageHash 3.1
arrow 0.9.0
altair 1.2.0
tqdm 4.10.0
mlxtend 0.5.1.dev0
PyWavelets 0.5.0
pyLDAvis 2.0.0
TPOT 0.6.7
traitlets 4.3.1
funcy 1.7.2
View coincheckJPY.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View pca_tsne.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View recipe.apib
FORMAT: 1A
# レシピサイトWebAPIドキュメント
http://gotofritz.net/blog/weekly-challenge/restful-python-api-bottle/
## すべてのレシピのXMLを表示する [/recipes/]
### recipes_list [GET]
すべてのレシピのリストを返します。
View iris_xgboost.py
import numpy as np
import scipy as sp
import xgboost as xgb
from sklearn import datasets
from sklearn.metrics import confusion_matrix
from sklearn.grid_search import GridSearchCV
from sklearn.grid_search import RandomizedSearchCV
iris = datasets.load_iris()
trainX = iris.data[0::2,:]
You can’t perform that action at this time.