Skip to content

Instantly share code, notes, and snippets.

🌴
On vacation

catindog/nardtree GINK03

🌴
On vacation
Block or report user

Report or block GINK03

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 config.md

よく忘れるのでメモ

.ssh/config

Host github.com                                  
  User git  
  Port 22                                   
  HostName github.com                            
  IdentityFile ~/.ssh/id_github
@GINK03
GINK03 / F2DB.md
Created Jun 29, 2019
F2DB (Filesystem based Database, key-value store)
View F2DB.md

Code

from hashlib import sha256
import pickle
import gzip
from pathlib import Path
import json
import pickle
View ハッカーになった気分.md

reqs

pip install termcolor

snippet

import os
import random
import time
View 自分の公開鍵.md

ssh

ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDAxXP4jOi5TI87WCNVfoJjUJdY57MJbtfDW2DTaQG8FOsf4PGp/qjwBscvhd7iCyViM3mmxabTlX9AlkxkBSrxKokl1vVS+FmY71oY8eoHbqkkxnQUC6L4MT8UyEL1Pcic+zSiO/as6DOMpHEECyCltcTDt36tX2GvCh/wRJaVFL6H0VuwHTbsxFmt9ieURgcHXapC1MXPt+sJibmVlTLDEOC1PW291LEVxLWjRWH2Jxv76JMMYd2ZuTodFUsonHQn9nhZo+cIgV/GAPpnij+QacH7bJk/NpEyTo4zhsb4z2RT2VAEy/frTN2ose2ka1QLOSTu7uVAC+JkzgMiedGd gimpei@Hibiki
@GINK03
GINK03 / combination_pattern.md
Last active May 11, 2019
combinationのパターンを計算するやつ
View combination_pattern.md
MOD = 10 ** 9 + 7 # これがないと計算できない
def cmb_gen(n):
    fac = [0] * n
    inv = [0] * n
    fac[0] = fac[1] = 1
    inv[0] = inv[1] = 1
    for i in range(2, n):
View chrome-extation.md
@GINK03
GINK03 / seaborn_matplot.md
Last active Jun 12, 2019
seaborn-matplot
View seaborn_matplot.md
View pytorch_matrix_factorize_model.py
class MF(nn.Module):
def __init__(self, input_items, input_users):
super(MF, self).__init__()
print('item size', input_items)
self.l_b1 = nn.Embedding(num_embeddings=input_items, embedding_dim=768)
self.l_b2 = nn.Linear(
in_features=768, out_features=512, bias=True)
self.l_a1 = nn.Embedding(num_embeddings=input_users, embedding_dim=768)
self.l_a2 = nn.Linear(
in_features=768, out_features=512, bias=True)
@GINK03
GINK03 / python_logger.md
Last active Feb 20, 2019
python-logger
View python_logger.md

基本入れるべき

import logging
import sys

logger = logging.getLogger(__name__)
logger.setLevel(logging.INFO)
# create a file handler
handler = logging.FileHandler('work.log')
@GINK03
GINK03 / bert-pretrained-example.md
Created Nov 20, 2018
bert-pretrained-example.md
View bert-pretrained-example.md
You can’t perform that action at this time.