1 tokenize
2 remove stop words
3 Part of Speech tagging
4 word sense diambiguation
5 calculate path between word-pair in wordnet
6 accumulate the path lengths
a simple implementation
Posted in Sentence Similarity.
公元前西方帝国简明征战史
埃及 巴比伦 打啊打 夹在中间的犹太人的耶路撒冷受尽折磨 最后被巴比伦人抓去做了奴隶
波斯帝国nb起来了 把巴比伦灭了 同时也解放了犹太人 波斯帝国越来越nb 把埃及灭了 中东统一了
这时希腊半岛上的各个城邦也建立了璀璨的文明 波斯帝国胃口很大 把小亚细亚的雅典殖民地给吞并了
雅典人反抗 惹恼了波斯人 于是来了三次波斯远征希腊 第一次舰队触礁沉默 第二次被打败在马拉松
第三次海陆两路进攻 斯巴达300勇士的故事诞生 最后雅典人躲在岛上 又是通过消灭了波斯舰队而获胜
希腊半岛上各个城邦打啊打 闹内讧 结果被北边一点的马其顿人给灭了 亚历山大大帝越来越nb 从波斯手里
夺走了埃及 又把波斯帝国给灭了 一路打到印度 士兵们不想继续前进于是回国了 可惜 亚历山大大帝32岁就死了
结果马其顿帝国四分五裂 这时候在意大利,一群自称是特洛伊后裔的两兄弟建立了罗马,罗马越来越nb 统一了意大利
半岛 向北灭了高卢人(法国)和条顿人(德国),然后想吞并西西里岛,可这时候西西里岛是在腓尼基人建立的城邦迦太基人的
手中,于是两者打啊打,迦太基出了个nb人叫汉尼拔,率兵攻占了西班牙并从西班牙横跨欧洲大陆去意大利攻打罗马,
虽然打赢了罗马军团 缺没能完全灭掉罗马,结果被罗马军队把迦太基城给平了。
公元前基本结束
Posted in Military & History.
重大节目预告
凤凰卫视
一虎一席谈
面对南海危机
首播: 周六20:00-21:00
回放: 周日03:10-04:05 /周日13:00-14:00
Posted in Military & History.
GRE argument 概述
1 陈述题干中的论点
who recommend …… To support his recommendation, he cites the following facts : ……. Close scrutiny of each of these facts, however,
reveals that none of them lend credible support to the recommendation.
2 一二三四五六七八
一:瞎jb推论 他因
First and foremost,
A do not necessarily indicate B
The argument unfairly claims that A is the result of bbb rather than some other phenomenon.
The author ignores a host of other possible reasons for AAA
In short, without ruling out all other possible reasons for the ….., the author can not convince me that …, let alone
二:调查不充分
the survey must be shown to be reliable before I can accept any conclusion that the author reaches upon it
However the author fails to prove that the responses are accurate and the respondents are statistically significant in number
Additionally, whether the sample is representative enough to reflect the overall attitudes in terms of …. deserves to doubt
without evidence of the survey’s reliability, it is impossible to draw any firm conclusion based upon it.
三:错误类比
Even if ….., the author commits a false analogy in assuming that by the same means AAA will achieve the same results as BBB does.
The author fails to consider possible differences between AAA and BBB, which might help to bring out a different result for AAA
Perhaps ….., or perhaps …
Without accounting for these and other possible dissimilarities, any analogy between the two …. is premature and the author can not assume that AAA would bring the same results in xxxx as BBB did.
四:Post hoc, ergo propter hoc
The author commits a fallacy of “post hoc, ergo propter hoc” in assuming that BBB is the very cause of AAA.
Although BBB occurred before AAA, the only evidence is insufficient to prove a casual relationship.
In order to establish a general casual relationship between AAA and BBB, other factors that might lead to AAA should be considered and eliminated.
The author’s failure to investigate or even take into account other possible reasons for AAA renders the conclusion based upon it highly suspect.
五:并不是唯一解决途径
Even if that …. may to some extend help to solve the problems. the author unfairly assumes that … is the only means of achieving the desired result.
The author overlooked other possible means of ensuring that …., such as … and …., and so forth.
Without weighing the proposal against and ruling out alternative means of achieving the same goal, the author can not convince me that ….
is needed.
3 In sum, the … relies on certain doubtful assumptions that render it unconvincing as it stands. To substantiate the …., the author must provide …… and …… To better assess the …., I would need to know …… and ….
Posted in English.
Learning Sed
sed 's/day/night/' |
s Substitute command
/../../ Delimiter
day Regular Expression Pattern Search Pattern
night Replacement string
Using & as the matched string
% echo "123 abc" | sed 's/[0-9]*/& &/' 123 123 abc |
Using \1 to keep part of the pattern
sed 's/\([a-z]*\) \([a-z]*\)/\2 \1/' |
/g – Global replacement
sed 's/[^ ][^ ]*/(&)/g' <old >new |
Multiple commands with -e command
sed -e 's/a/A/' -e 's/b/B/' <old >new |
Passing arguments into a sed script
#!/bin/sh sed -n 's/'"$1"'/&/p' |
notice :
{} () has to be escaped as \{\} \(\)
Posted in Linux.
How to make Debian package
$ dh_make -n -s -e email@domain.com Maintainer name : Someone Email-Address : email@domain.com Date : Tue, 20 Dec 2005 10:28:12 +0100 Package Name : test Version : 0.1 License : blank Type of Package : Single Hit to confirm: Done. Please edit the files in the debian/ subdirectory now. You should also check that the test Makefiles install into $DESTDIR and not in / . |
The file tree :
$ find debian/ debian/ debian/changelog debian/compat debian/dirs debian/README.Debian debian/copyright debian/control debian/rules debian/docs debian/README |
Edit the debian/DEBIAN/control file :
Source: test
Section: devel
Priority: optional
Maintainer: someone
Build-Depends: debhelper (>= 4.0.0), libapr0-dev, libsvn0-dev
Standards-Version: 3.6.1
Package: test
Architecture: any
Depends: ${shlibs:Depends}, ${misc:Depends}
Description: report the youngest revision of a svn repository path
test is a small tool |
Notice: there is a white space before the long Description.
Copy your binary executable file to debian/usr/bin
Edit the debian/rules to modify the instructions to be invoked for compilation.
$dpkg-deb --build debian/ |
rename the generated debian.deb
Posted in 1g1g Linux Desktop App.
亦歌Linux桌面版发布啦!
Linux下终于可以不用开浏览器就能听亦歌(1g1g.com)啦!
http://linux1g1g.mrcongwang.com
作者: 小包(silwings@gmail.com), ericyosho(ericyosho@gmail.com) 鸣谢: wks为我们打包了fedroa11的rpm包
特性:
1. 全局快捷键 (需要安装xbindkeys 然后运行bindkeys.sh)
2. 状态同步更新到流行的博客、微博客和IM软件 (未来)
3. 歌词与歌名提示条 (未来)
下载:
linux1g1g-0.9.2-1.fc11.i386.rpm
安装:
程序依赖:libqt4-core, libqt4-gui, libqt4-network, libqt4-webkit(>=4.5.0)
| Linux发行版 | Deb安装包 | RPM安装包 | 源码包 |
| Ubuntu 9.04 | OK | OK | |
| Ubuntu 8.10 | OK | OK | |
| Ubuntu 8.04 | OK | OK | |
| Debian 5.0 | 未测试 | 未测试 | |
| CentOS 5.3 | 未测试 | 未测试 | |
| Fedora 11 | OK | OK |
1. Deb安装包测试通过的linux用户可直接下载deb安装包进行安装。
2. 使用低于9.04版本Ubuntu的用户在安装deb包后需要安装qt sdk以获得qt 4.5的lib,不然运行时
将找不到libQtWebkit
3. 欲下载源码包自行编译的用户同样须下载qt sdk并配置路径。编译指南在此
Posted in 1g1g Linux Desktop App.