-
Notifications
You must be signed in to change notification settings - Fork 44
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
24 changed files
with
495 additions
and
18 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
common/person-profile.txt* | ||
old-result | ||
report/output | ||
|
||
*.py[cod] | ||
|
||
|
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
#!../../manage/exec-in-virtualenv.sh | ||
# -*- coding: UTF-8 -*- | ||
# File: __init__.py | ||
# Date: 二 6月 10 02:55:19 2014 +0000 | ||
# Date: Tue Jun 10 22:44:13 2014 +0800 | ||
# Author: Yuxin Wu <[email protected]> | ||
|
||
from lib.downloader import direct_download, ProgressPrinter | ||
from lib.textutil import title_beautify | ||
from ukutil import check_pdf, import_all_modules, ensure_unicode | ||
from lib.ukutil import check_pdf, import_all_modules, ensure_unicode | ||
from uklogger import * | ||
from job import SearchResult | ||
from lib.exc import RecoverableErr | ||
|
File renamed without changes.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
#!../manage/exec-in-virtualenv.sh | ||
# -*- coding: UTF-8 -*- | ||
# File: pdfprocess.py | ||
# Date: 二 6月 10 03:25:40 2014 +0000 | ||
# Date: Tue Jun 10 22:44:22 2014 +0800 | ||
# Author: Yuxin Wu <[email protected]> | ||
|
||
import tempfile | ||
|
@@ -10,7 +10,7 @@ | |
|
||
from uklogger import * | ||
from ukdbconn import get_mongo | ||
from ukutil import check_pdf, pdf_compress | ||
from lib.ukutil import check_pdf, pdf_compress | ||
from lib.pdf2html import PDF2Html | ||
from lib.textutil import parse_file_size | ||
import contentsearch | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
#!/usr/bin/env python2 | ||
# -*- coding: UTF-8 -*- | ||
# File: __init__.py | ||
# Date: Mon May 26 20:01:28 2014 +0800 | ||
# Date: Tue Jun 10 22:44:33 2014 +0800 | ||
# Author: Yuxin Wu <[email protected]> | ||
|
||
from ukutil import import_all_modules | ||
from lib.ukutil import import_all_modules | ||
from uklogger import * | ||
from functools import wraps | ||
|
||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
#!/usr/bin/env python2 | ||
# -*- coding: UTF-8 -*- | ||
# File: gscholar.py | ||
# Date: 一 6月 09 16:40:44 2014 +0000 | ||
# Date: Tue Jun 10 22:44:29 2014 +0800 | ||
# Author: Yuxin Wu <[email protected]> | ||
|
||
|
||
from . import register_searcher | ||
from job import SearchResult | ||
from uklogger import * | ||
from lib.textutil import title_correct, filter_title_fileformat, title_beautify | ||
from ukutil import ensure_unicode, ensure_bin_str | ||
from lib.ukutil import ensure_unicode, ensure_bin_str | ||
|
||
import re | ||
import requests | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
#!/usr/bin/env python2 | ||
# -*- coding: UTF-8 -*- | ||
# File: indexer.py | ||
# Date: 一 6月 09 16:47:56 2014 +0000 | ||
# Date: Tue Jun 10 22:44:06 2014 +0800 | ||
# Author: Yuxin Wu <[email protected]> | ||
|
||
__all__ = ['xapian_indexer'] | ||
|
@@ -12,7 +12,7 @@ | |
import xappy | ||
from xappy import IndexerConnection, FieldActions, UnprocessedDocument, Field | ||
from xappy import errors | ||
from ukutil import ensure_unicode_anytype as ensure_unicode | ||
from lib.ukutil import ensure_unicode_anytype as ensure_unicode | ||
|
||
from xpcommon import FIELD_NUM, STOPWORDS | ||
|
||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
#!/usr/bin/env python2 | ||
# -*- coding: UTF-8 -*- | ||
# File: paper-downloader.py | ||
# Date: 二 5月 27 04:47:56 2014 +0000 | ||
# Date: Tue Jun 10 22:44:54 2014 +0800 | ||
# Author: Yuxin Wu <[email protected]> | ||
|
||
# Command line script to use paper-downloader | ||
|
@@ -21,7 +21,7 @@ | |
from job import JobContext | ||
import fetcher | ||
from fetcher import do_fetcher_download | ||
from ukutil import pdf_compress | ||
from lib.ukutil import pdf_compress | ||
from uklogger import * | ||
import ukconfig | ||
ukconfig.download_method = 'wget' | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
TARGET=report | ||
TEX=xelatex -interaction=nonstopmode -shell-escape | ||
BIBTEX=bibtex | ||
READER=mupdf | ||
|
||
all: rebuild | ||
|
||
rebuild output/$(TARGET).pdf: *.tex *.bib output | ||
cd output && rm -f *.tex *.bib && ln -s ../*.tex ../*.bib . | ||
cd output && $(TEX) $(TARGET).tex | ||
cp output/$(TARGET).pdf ../ -f | ||
cp output/$(TARGET).pdf ./ -f | ||
|
||
|
||
output: | ||
mkdir output -p | ||
cd output && rm -f img src && ln -s ../img ../src ./ | ||
|
||
view: output/$(TARGET).pdf | ||
$(READER) output/$(TARGET).pdf & | ||
|
||
clean: | ||
rm -rf output | ||
|
||
# compile twice to get cross reference right | ||
final : *.tex *.bib output | ||
cd output && rm -f *.tex *.bib && ln -s ../*.tex ../*.bib . | ||
cd output && $(TEX) $(TARGET).tex && $(BIBTEX) $(TARGET).aux && \ | ||
$(TEX) $(TARGET).tex && $(TEX) $(TARGET).tex | ||
|
||
count: | ||
@word_count *.tex | ||
|
||
run: view | ||
|
||
.PHONY: all view clean rebuild run |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.