This file contains hidden or 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
// Copyright 2009 Google Inc. All Rights Reserved. | |
// Author: keni | |
#ifndef MOZC_DICTIONARY_POS_MAP_H_ | |
#define MOZC_DICTIONARY_POS_MAP_H_ | |
// POS conversion rules | |
const POSMap kPOSMap[] = { | |
{ "\x31", "\xE5\x90\x8D\xE8\xA9\x9E" }, | |
{ "\x31\x30", "\xE5\x90\x8D\xE8\xA9\x9E\xE3\x82\xB5\xE5\xA4\x89" }, |
This file contains hidden or 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
diff --git a/Makefile b/Makefile | |
index c8b7257..01950be 100644 | |
--- a/Makefile | |
+++ b/Makefile | |
@@ -8,15 +8,15 @@ CXX = g++ | |
RM = rm -f | |
INSTALL = /usr/bin/install | |
-MOZC_SRC = .. | |
+MOZC_SRC = ../mozc-2.23.2815.102+dfsg/src |
This file contains hidden or 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 sqlite3 | |
import os | |
import sys | |
fname = "wnjpn.db" # get from http://compling.hss.ntu.edu.sg/wnja/jpn/detail.html | |
conn = sqlite3.connect(fname) | |
def id2word(wordid): | |
w = conn.execute("select * from word where wordid = %s" % wordid) |
This file contains hidden or 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
# refer to https://github.com/yagays/pretrained_doc2vec_ja/blob/master/src/parse_cirrus.py | |
# | |
import json | |
import gzip | |
import bz2 | |
import subprocess | |
from tqdm import tqdm | |
p = subprocess.Popen(["java", "-jar", "sudachi-0.3.2.jar", "-s", |
This file contains hidden or 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
/usr/lib/mecab/mecab-dict-index -d . -o . -f utf8 -t utf8 | |
reading ./unk.def ... 35 | |
emitting double-array: 100% |###########################################| | |
./model.def is not found. skipped. | |
reading ./lex.csv ... context_id.cpp(96) [it != left_.end()] cannot find LEFT-ID for 100,名詞,数詞,*,*,*,*,*,* | |
Makefile:613: recipe for target 'char.bin' failed | |
make: *** [char.bin] Error 255 |
This file contains hidden or 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
<!doctype html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<title>不正アクセスとは?被害事例、被害有無のチェック方法と有効な対策</title | |
> | |
<style> | |
.container { | |
width: 60%; | |
margin: 10% auto 0; |
This file contains hidden or 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 os | |
import sys | |
import re | |
import json | |
import numpy as np | |
from PIL import Image | |
import chainer | |
import chainer.cuda |
This file contains hidden or 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 bs4 import BeautifulSoup | |
import urllib.request | |
import urllib.parse | |
import time | |
import os | |
wait_sec = 5 |
This file contains hidden or 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
$ pip install -r requirements.txt | |
$ curl -L https://github.com/nicolov/segmentation_keras/releases/download/model/nicolov_segmentation_model.tar.gz \ | |
| tar xvf - | |
$ python predict.py --weights_path \ | |
conversion/converted/dilation8_pascal_voc.npy \ | |
images/cat.jpg |
This file contains hidden or 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
#!/usr/nogpu/bin/python | |
# -*- coding: utf-8 -*- | |
import argparse | |
import chainer | |
from chainercv.datasets import voc_detection_label_names | |
from chainercv.links import SSD300 | |
from chainercv import utils | |
import os |
NewerOlder