This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import gzip | |
import hashlib | |
import json | |
import multiprocessing | |
import os | |
import shutil | |
import time | |
import re | |
from pathlib import Path |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
import multiprocessing as mp | |
import re | |
from collections import defaultdict | |
from functools import partial | |
from typing import Dict, List, Optional, Set, Tuple, Type | |
from datasets import Dataset | |
from tqdm import tqdm |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
db.currentOp().inprog.forEach( | |
function(op) { | |
if(op.secs_running > 5) printjson(op); | |
} | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# coding: utf-8 | |
from sklearn.feature_extraction.text import TfidfVectorizer, CountVectorizer | |
from sklearn.base import BaseEstimator | |
import MeCab | |
import numpy as np | |
from itertools import chain | |
class JpTfidfVectorizer(TfidfVectorizer): | |
tagger = MeCab.Tagger("-Owakati") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 1: Use node 6 as base: | |
FROM node:6-alpine | |
# 2: Download+Install PhantomJS, as the npm package 'phantomjs-prebuilt' won't work on alpine! | |
# See https://github.com/dustinblackman/phantomized | |
RUN set -ex \ | |
&& apk add --no-cache --virtual .build-deps ca-certificates openssl \ | |
&& wget -qO- "https://github.com/dustinblackman/phantomized/releases/download/2.1.1/dockerized-phantomjs.tar.gz" | tar xz -C / \ | |
&& npm install -g phantomjs \ | |
&& apk del .build-deps |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
# | |
# Author: oldj | |
# Email: oldj.wu@gmail.com | |
# Blog: http://oldj.net | |
# | |
import os | |
import re | |
import StringIO |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* usbreset -- send a USB port reset to a USB device | |
* | |
* Compile using: gcc -o usbreset usbreset.c | |
* | |
* | |
* */ | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[user] | |
name = Pavan Kumar Sunkara | |
email = pavan.sss1991@gmail.com | |
username = pksunkara | |
[init] | |
defaultBranch = master | |
[core] | |
editor = nvim | |
whitespace = fix,-indent-with-non-tab,trailing-space,cr-at-eol | |
pager = delta |