Skip to content

Instantly share code, notes, and snippets.

View ytakashina's full-sized avatar
🌊

Yuya Takashina ytakashina

🌊
View GitHub Profile
@ytakashina
ytakashina / model-building-example-5-2.ipynb
Created April 17, 2022 05:17
model-building-example-5.2.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
git branch --merged| grep -vE "(^\*|master|main|dev)" | xargs git branch -d
@ytakashina
ytakashina / tasks.json
Created April 2, 2021 02:46
楽をする用の snippet 集。See also: https://go.microsoft.com/fwlink/?LinkId=733558
{
"version": "2.0.0",
"tasks": [
{
"label": "Clean up local branches",
"type": "shell",
"command": "git branch --merged | grep -vE '(^\\*|master|main|dev)' | xargs git branch -d",
},
]
}
#include <iostream>
#include <iomanip>
int main()
{
int a, b;
std::cin >> a >> b;
std::cout << a / b << ' ';
std::cout << a % b << ' ';
std::cout << std::fixed << std::setprecision(8);
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
$ if [ -e "a" ]; then echo "a"; fi
$ sphinx-quickstart
$ cd docs
$ sphinx-apidoc -ef -o source ../depynd # e: separete, f: overwrite
$ make html
  • IO
N = int(input())
l = len(str(N))-1
print(l*9 + ((N+1)//(10**l)-1))
  • 全組み合わせ列挙
np.hstack([np.repeat(X, len(Y), axis=0), np.tile(Y, [len(X), 1])])
  • マハラノビス距離計算
@ytakashina
ytakashina / gao2017estimating.ipynb
Last active April 8, 2018 02:36
追試: Gao, Weihao, et al. "Estimating mutual information for discrete-continuous mixtures." Advances in Neural Information Processing Systems. 2017.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.