存档

‘大杂烩’ 分类的存档

怀揣激动的心情!启程!

2010年3月9日

终于离开值得我一辈子尊敬的公司了!一切自由了!可以自己为自己干活!可以去实现自己的梦想!感谢我的父母!感谢我的女友!感谢我身边的兄弟!感谢我周围的朋友!感谢我之前的同事!2010.3月!人生路程急转弯!记住!

大杂烩

虎年好兆头

2010年2月14日

当吃完年夜饭出来的一霎那,我迎接了第一粒雪花,短短1分钟内,顿时鹅毛大雪。一切都来的如此奇妙,带有悬念,赋予色彩。2010云体科技到底能否诞生,是否可以生存,一切都是那么迷茫,但是个人的信心又是如此充实,这半年内与日俱增,丝毫没有退烧。2002年到现在刚好8年,这8年,我的成长是曲折的、充实的,充满各种冒险色彩、奋斗精神,之前的失败和磨难将成为璀璨明天的积累。2010是我的人生转折点,厚积薄发一触即发,非常感谢自己这8年来仍旧保持一颗激情的心,乐观面对所有的困难,一直矢志不渝在走自己的路。新的人生正式启程,华为杭研,谢谢再见,云体科技,诞生腾飞。

大杂烩

ESWC 2010 Workshop on Ontology Repositories and Editors for the Semantic Web

2010年1月21日

ORES 2010 – Call for papers and system descriptions -
http://www.ontologydynamics.org/od/index.php/ores2010/
Heraklion, Greece – Deadline: March 1, 2010

The growing number of online ontologies makes the availability of ontology repositories, in which ontology practitioners can easily find, select and retrieve reusable components, a crucial issue. The recent emergence of several ontology repository systems is a further sign of this. However, in order for these systems to be successful, it is necessary to provide a forum for researchers and developers to discuss features and exchange ideas on the realization of ontology repositories in general and to consider explicitly their role in the ontology lifecycle. In addition, it is now critical to achieve interoperability between ontology repositories, through common interfaces, standard metadata formats, etc. ORES10 intends to provide such a forum.

Illustrating the importance of the problem, significant initiatives are now emerging. One example is the Open Ontology Repositories (OOR) working group set up by the Ontolog community. Within this effort regular virtual meetings are organized and actively attended by ontology experts from around the world; The Ontolog OOR 2008 meeting was held at the National Institute for Standards in Technology (NIST), generating a joint communiqué outlining requirements and paving the way for collaborations. Another example is the Ontology Metadata Vocabulary (OMV) Consortium, addressing metadata for describing ontologies. Despite these initial efforts, ontology repositories are hardly interoperable amongst themselves. Although sharing similar aims (providing easy access to Semantic Web resources), they diverge in the methods and techniques employed for gathering these documents and making them available; each interprets and uses metadata in a different manner. Furthermore, many features are still poorly supported, such as modularization and versioning, as well as the relationship between ontology repositories and ontology engineering environments (editors) to support the entire ontology ifecycle.

Submitting papers and system descriptions

We want to bring together researchers and practitioners active in the design, development and application of ontology repositories, repository-aware editors, modularization techniques, versioning systems and issues around federated ontology systems. We therefore encourage the submission of research papers, position papers and system descriptions discussing some of the following questions:

* How can ontology repositories “talk” to each other?
* How can the abundant and complex knowledge contained in an ontology repository be made comprehensible for users?
* What is the role of ontology repositories in the ontology lifecycle?
* How can branching and versioning be managed in and across ontology repositories?
* How can ontology repositories interoperate with ontology editors, and other applications and legacy systems?
* How can connections across ontologies be managed within and across ontology repositories?
* How can modularity be better supported in ontology repositories and editors?
* How can ontology repositories and editors use distributed reasoning?
* How can ontology repositories support corporate, national and domain specific semantic infrastructures?
* How do ontology repositories support novel semantic applications?
* What measurements for describing and comparing ontologies can we use? How could ontology repositories use these?

大杂烩

年初杂谈

2010年1月5日

人,活着,为了什么?
每天都在摆摊卖水果的女人可能为了养活孩子
单位打工的白领可能为了买房、结婚、生子
富裕的人可能为了更多的消遣
立志的人可能为了理想
如果我们用5WHY法则画出鱼骨头,估计归根到底就是人的欲望,说破烂点,就是贪欲,说本质点,就是动物本能。
如果欲望达到了预期的目标,人会开心,会惬意,会去共享,会去文化传承,物质始终会枯竭,只有文化生生不息,文化激发更多的欲望,欲望灿烂出更多的文化。

人,活着,为什么要害怕?
可能因为自身的脆弱,所以会在别人还没有攻击之前,已有了防人意识
可能因为害怕失去,所以会在还没有失去之前拼命捍卫
可能因为达不到目标,所以会无意识将目标砍掉或者虚设

人,活着,为什么要攀比?
可能因为自身触手可及却偏偏没有得到的那份心有不甘
可能因为自身的口德行德激发了他人的欲望
可能因为要发泄压抑已久的欲望

如果将上面那些垃圾言论全部净化,独善其身,大彻大悟,玩转人生,可谓心胸海纳百川之人

=================无语的分割线=====================

什么是本体?

这是哲学的概念……GHJT@#T^#@&*!@!UIGJHJ
某某老外发言……&*@……#IUGH#HG!GIU#Y#*7

话说当年上帝害怕通天塔,于是让人们有了不同的语言,不同的思维,不同的个性,于是,通天塔倒了

人们只有使用统一的语言,才能相互交流,只有使用同一种概念,才能对一个事物达成共识

本体,就是这样的一种工具,让领域与领域之间的人们对一个事物达成共识

如果大家都运用本体对万事万物进行建模,通过相互沟通,达成一致,最终将这些数据朝贡给造物主,那么造物主将会通晓万事万物,如果他愿意为人们提供服务,那么他的脑子就是语义网

终有一天,通天塔再次完工,但这次,人们的本能可能会毁了这一切……

大杂烩

HTML解析模块完成

2009年11月15日

1.根据DTD文件构造HTML树
2.遍历出网页中所有肉眼能看到的东西
3.找出DIV块文本、找出TABLE块文本
4.根据DTD中的实体定义,将HTML转义符转成原有的字符

下一步计划,完成分词模块

大杂烩

HtmlReader模块完成

2009年11月4日

通过2组引擎数组,完成对html网页的粗糙预处理

  1. final String[] blankFilter = {" \t", " \t", "\n", " \t\r\n", "<", " \t"};

意思:如果已经扫描到空格或者tab,那么后面不要出现空格或tab了
“\n”, ” \t\r\n” 同义
“<", " \t" 同义

  1. final String[] tagFilters = {"<!–", "–>", "<script", "</script>", "<style", "</style>", "<!DOCTYPE", ">"};

意思,删除script开头,script结尾的所有内容

  1. private Reader reader;
  2.     public void setReader(Reader reader){this.reader = new BufferedReader(reader);}
  3.  
  4.     char[] buf = null;
  5.     int bufEnd = 0;
  6.    
  7.     /* 
  8.      *  将reader中的内容存入500K的缓存中,如果不够采取加倍策略
  9.      *  read all content from reader into buf and update the bufEnd,
  10.      *  finally will close the reader */
  11.     boolean readyData() throws IOException, NotSetReaderException
  12.     {
  13.         if(reader == null)
  14.         {
  15.             throw new NotSetReaderException();
  16.         }
  17.        
  18.         /* for most page 500K is enough */
  19.         int MOST_PAGE_SIZE = 500 * 1024;
  20.        
  21.         /* do not bigger than 5M */
  22.         int MAX_PAGE_SIZE = 5 * 1024 * 1024;
  23.        
  24.         buf = new char[MOST_PAGE_SIZE];
  25.        
  26.         try {
  27.             int actualRead;
  28.             while((actualRead = reader.read(buf, bufEnd, MOST_PAGE_SIZE-bufEnd)) != -1)
  29.             {
  30.                 /* oh, fill all space, so there are something remain in stream */
  31.                 if(actualRead == MOST_PAGE_SIZEbufEnd)
  32.                 {
  33.                     /* update the bufEnd */
  34.                     bufEnd += actualRead;
  35.                    
  36.                     /* it’s enough */
  37.                     if(bufEnd >= MAX_PAGE_SIZE)
  38.                         break;
  39.                    
  40.                     /* assign bigger array */
  41.                     char[] tempBuf = new char[MOST_PAGE_SIZE * 2];
  42.                     MOST_PAGE_SIZE = MOST_PAGE_SIZE * 2;
  43.                     System.arraycopy(buf, 0, tempBuf, 0, bufEnd);
  44.                     buf = tempBuf;
  45.                 }
  46.                 /* nothing to read */
  47.                 else
  48.                 {
  49.                     /* update the bufEnd */
  50.                     bufEnd += actualRead;
  51.                 }
  52.             }
  53.  
  54.         } catch (IOException e) {
  55.             System.out.println("God said: something wrong when read the page in initialize");
  56.             throw e;
  57.         } finally {
  58.             reader.close();
  59.         }
  60.        
  61.         /* test for the buff
  62.         FileWriter writer = new FileWriter("11");
  63.         writer.write(buf,0, bufEnd);
  64.         writer.close();
  65.         */
  66.        
  67.         return true;
  68.     }
  69.    
  70.    
  71.     void removeUselessContent()
  72.     {
  73.         int saved = 0, reading = 0;
  74.        
  75.         /* 前者为条件(空格tab),后者为删除对象(空格tab) */
  76.         final String[] blankFilter = {" \t", " \t", "\n", " \t\r\n", "<", " \t"};
  77.        
  78.         /* 准备删除的无用标签,提供首末信息 */
  79.         final String[] tagFilters = {"<!–", "–>", "<script", "</script>", "<style", "</style>", "<!DOCTYPE", ">"};
  80.        
  81.         /* 无回溯高效扫描整个文档 */
  82.         while(true)
  83.         {
  84.             if(reading >= bufEnd)
  85.                 break;
  86.  
  87.             /* 一直扫描到没有过滤为止 */
  88.             while(true)
  89.             {
  90.                 /* 监控是否有符合的过滤,只有当没有什么可以过滤了,
  91.                  * 才退出循环,标志为reading是否有读 */
  92.                 int checkFilter = reading;
  93.                
  94.                 /* 过滤篇首的所有空格 */
  95.                 while(saved == 0 && reading < bufEnd &&
  96.                         (buf[reading] ==   || buf[reading] == \t ||
  97.                                 buf[reading] == \r || buf[reading] == \n))
  98.                 {
  99.                     reading++;
  100.                 }
  101.  
  102.                 reading = removeUselessBlank(blankFilter, reading, saved);           
  103.                
  104.                 reading = removeHtmlTag(tagFilters, reading);
  105.                
  106.                 /* 如果有reading有遇到过滤的条件,让其继续扫描过滤 */
  107.                 if(checkFilter == reading)
  108.                     break;
  109.             }
  110.            
  111.             if(reading < bufEnd)
  112.                 buf[saved++] = buf[reading++];
  113.  
  114.         }
  115.        
  116.         bufEnd = saved;
  117.        
  118.         ///* test for the buff
  119.         try{
  120.         FileWriter writer = new FileWriter("11");
  121.         writer.write(buf,0, bufEnd);
  122.         writer.close();
  123.         //*/
  124.         }catch(IOException e){}
  125.     }
  126.  
  127.  
  128.     private int removeUselessBlank(String[] filterString, int reading, int saved) 
  129.     {
  130.         char[] condition, forbidance;
  131.         for(int i = 0; i < filterString.length;)
  132.         {
  133.             condition = filterString[i++].toCharArray();
  134.             forbidance = filterString[i++].toCharArray();
  135.             while (saved1 >= 0 && equalAny(condition, buf[saved - 1])
  136.                     && equalAny(forbidance, buf[reading])) {
  137.                 reading++;
  138.             }
  139.         }
  140.         return reading;
  141.     }
  142.  
  143.     private boolean equalAny(char[] condition, char aim) {
  144.         boolean bool = false;
  145.         for (char c : condition) {
  146.             bool = bool || (c == aim);
  147.         }
  148.         return bool;
  149.     }
  150.  
  151.       private int removeHtmlTag(String[] filterString, int reading) {
  152.  
  153.         char[] styleBegin, styleEnd;
  154.         for (int i = 0; i < filterString.length;) {
  155.             styleBegin = filterString[i++].toCharArray();
  156.             styleEnd = filterString[i++].toCharArray();
  157.  
  158.             while (reading + styleBegin.length < bufEnd    && compareCharArray(buf, reading, styleBegin)) 
  159.             {
  160.                 reading = reading + styleBegin.length;
  161.                 while (reading + styleEnd.length < bufEnd && !compareCharArray(buf, reading, styleEnd)) 
  162.                 {
  163.                     reading++;
  164.                 }
  165.                 reading = reading + styleEnd.length;
  166.             }
  167.         }
  168.  
  169.         return reading;
  170.     }
  171.  
  172.     private boolean compareCharArray(char[] src, int from, char[] des) {
  173.         int i = 0;
  174.         while (i < des.length
  175.                 && (src[from] == des[i] || (src[from] + 32) == des[i])) {
  176.             from++;
  177.             i++;
  178.         }
  179.         return i == des.length;
  180.     }

大杂烩

my birthday gift from my GF

2009年9月29日

      

       

                                     

大杂烩

转载:中美印日四国程序员比较(自己也亲身体会)

2009年7月16日

最近以裁判的身份参加了公司举办的编程大赛,发现高手云集,对公司内部的程序员能力也有了更深入的了解。我觉得编程能力对程序员而言,虽然很重要,但并不是全部。那么作为一个程序员,到底应该具备什么样的能力呢?这个话题显然太大。不过我觉得可以看看其它国家的程序员,也许可以得到一些借鉴。我有幸和中国,美国,印度和日本四国程序员有比较深入的合作过。虽然他们不一定有代表性,但我觉得他们的共性还是比较明显的。以下的比较纯属个人见解,欢迎指正。

阅读全文…

大杂烩

iphone 2.X固件令人惊叹

2009年5月1日

iphone已经用了一年半了,自从1.13版本以来就再也没有刷机过了,感觉硬件水平不变的情况下,软件平台本身是不会有质的飞跃的,但是前几天刷机到2.21之后,我发现自己真的落伍了,没想到这个一代的老iphone还是能发挥的如此出色,现在的3方软件也是五花八门,层出不穷,比起以前每用一个软件就失望一次比起来,这次真是给我带来太多的惊喜,下面是截图。

首先是主页面
img_0001img_0030

地图导航,能找到我在哪个位置,要去哪里,怎么走…居然把GPS模仿的这么好
img_0006img_0004

另外,UCWEB,飞信,QQ,同花顺,彩信等常用软件都用的非常爽
img_0027img_0008img_0010img_0012img_0023img_0034

最大的进步莫过于游戏了,想1年半之前,iphone刚推出那会儿,啥游戏都没有,装个GBA、PS2模拟器就乐呵乐呵了,看看现在这么多的游戏,真是再次令人惊叹。感谢网龙公司为大家贡献的这些,呵呵。

大杂烩

一人周末

2009年4月30日

一个人的周末,自由也很寂寞;
手机为你,变成最依赖的玩具;

一个人的周末,期待变成泡沫;
思念暴走,像热带鱼一样游过;

一个人的摩卡,想象两个人的焦糖;
without爱装哲学的你,何处去流放我的幻想。

你说那边,忙忙碌碌风和日丽;
却不知道,我这里风大心也凉;

要你在身边,让雨停出太阳;
要你躺在肚皮上,让它告诉你,没有你我有多么的坚强。

悄悄许个愿望,变成拇指姑娘;
躲进你的口袋,陪你四处流浪;

你说要做我的muscle man,要我乖乖,等你归来;
我说我要许你一个未来,做你永远的only one。

此刻才明白,你对我的温柔,是我永远无法割舍的依赖。

Liz 作词于杭州下沙
CRAB 谱词于深圳龙岗

大杂烩