<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>Nan&#039;s Blog</title>
	<atom:link href="http://nan1wang.wordpress.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://nan1wang.wordpress.com</link>
	<description>It is a world of ideas, or nothing</description>
	<lastBuildDate>Fri, 13 Jan 2012 19:33:40 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='nan1wang.wordpress.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://s2.wp.com/i/buttonw-com.png</url>
		<title>Nan&#039;s Blog</title>
		<link>http://nan1wang.wordpress.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://nan1wang.wordpress.com/osd.xml" title="Nan&#039;s Blog" />
	<atom:link rel='hub' href='http://nan1wang.wordpress.com/?pushpress=hub'/>
		<item>
		<title>32位 or 64位?</title>
		<link>http://nan1wang.wordpress.com/2012/01/13/32bit_or_64bi/</link>
		<comments>http://nan1wang.wordpress.com/2012/01/13/32bit_or_64bi/#comments</comments>
		<pubDate>Fri, 13 Jan 2012 19:32:42 +0000</pubDate>
		<dc:creator>Nan.Wang</dc:creator>
				<category><![CDATA[Miscellaneous]]></category>
		<category><![CDATA[OSX]]></category>

		<guid isPermaLink="false">http://nan1wang.wordpress.com/?p=65</guid>
		<description><![CDATA[下了一个python的库，却发现运行不了，返回错误 OSError: dlopen(libcudamat.so, 6): no suitable image found. Did find: libcudamat.so: mach-o, but wrong architecture google了一下，原来是32位和64位平台的原因。mac pro在升级到lion之后，每次就自动进64位系统，而这个python的库是为32位平台编译的。可以通过lipo和uname来查看。 bash-3.2$ lipo -info libcudamat.so Non-fat file: libcudamat.so is architecture: i386 lipo -info targetFile 可以显示 targetFile编译的平台，i386就是32位平台，x86_64对应64位平台。 bash-3.2$ uname -a Darwin WWs-MacBook-Pro.local 11.2.0 Darwin Kernel Version 11.2.0: Tue Aug 9 20:54:00 PDT 2011; root:xnu-1699.24.8~1/RELEASE_X86_64 x86_64 uname -a可以显示当前mac osx运行哪个平台。<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=65&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>下了一个python的库，却发现运行不了，返回错误</p>
<p>OSError: dlopen(libcudamat.so, 6): no suitable image found. Did find:<br />
libcudamat.so: mach-o, but wrong architecture</p>
<p>google了一下，原来是32位和64位平台的原因。mac pro在升级到lion之后，每次就自动进64位系统，而这个python的库是为32位平台编译的。可以通过lipo和uname来查看。</p>
<p>bash-3.2$ lipo -info libcudamat.so<br />
Non-fat file: libcudamat.so is architecture: i386</p>
<p>lipo -info targetFile 可以显示 targetFile编译的平台，i386就是32位平台，x86_64对应64位平台。</p>
<p>bash-3.2$ uname -a<br />
Darwin WWs-MacBook-Pro.local 11.2.0 Darwin Kernel Version 11.2.0: Tue Aug 9 20:54:00 PDT 2011; root:xnu-1699.24.8~1/RELEASE_X86_64 x86_64</p>
<p>uname -a可以显示当前mac osx运行哪个平台。</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/nan1wang.wordpress.com/65/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/nan1wang.wordpress.com/65/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/nan1wang.wordpress.com/65/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/nan1wang.wordpress.com/65/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/nan1wang.wordpress.com/65/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/nan1wang.wordpress.com/65/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/nan1wang.wordpress.com/65/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/nan1wang.wordpress.com/65/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/nan1wang.wordpress.com/65/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/nan1wang.wordpress.com/65/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/nan1wang.wordpress.com/65/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/nan1wang.wordpress.com/65/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/nan1wang.wordpress.com/65/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/nan1wang.wordpress.com/65/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=65&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://nan1wang.wordpress.com/2012/01/13/32bit_or_64bi/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<georss:point>51.482901 7.211810</georss:point>
		<geo:lat>51.482901</geo:lat>
		<geo:long>7.211810</geo:long>
		<media:content url="http://1.gravatar.com/avatar/7f4f8bd3727df963459910c4e86f43b0?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">akismet-7f4f8bd3727df963459910c4e86f43b0</media:title>
		</media:content>
	</item>
		<item>
		<title>svn下配置忽略文件及文件夹</title>
		<link>http://nan1wang.wordpress.com/2012/01/11/svn_ignore_file_and_folder/</link>
		<comments>http://nan1wang.wordpress.com/2012/01/11/svn_ignore_file_and_folder/#comments</comments>
		<pubDate>Wed, 11 Jan 2012 21:22:32 +0000</pubDate>
		<dc:creator>Nan.Wang</dc:creator>
				<category><![CDATA[Miscellaneous]]></category>
		<category><![CDATA[svn]]></category>

		<guid isPermaLink="false">http://nan1wang.wordpress.com/?p=59</guid>
		<description><![CDATA[最近使用svn比较多，发现一个问题就是默认情况下，svn会自动同步所有的文件和文件夹，而往往有些文件是没必要进行版本控制的，比如每次实验的结果和图片、或者缓存文件。所以就需要找个方法让svn把这些文件忽略掉，google了一下，找到了一个ignore命令正好可以帮我们实现这个想法。 下面开始实践，我们的当前的目录结构如下： myCheckOut ├── invisible │   └── ToBeInvisible └── visible 目标：我们希望让svn忽略invisible文件夹里的文件。 首先从svn版本库中删除invisible文件夹里的文件，如果文件还有用，那就暂时保存在别的地方。 ~/tmp/checkOut$ svn delete invisible/* 此时，文件夹结构变为： myCheckOut ├── invisible └── visible 然后设置svn忽略invisible文件夹中的所有文件 ~/tmp/checkOut$ svn propset svn:ignore &#8216;*&#8217; invisible/ ok，提交新的版本到版本库 ~/tmp/checkOut$ svn commit -m &#8220;Let us see.&#8221; 现在可以测试一下，在invisible文件夹里添加新文件invisibleFile后，目录结构变为： myCheckOut ├── invisible │   └── invinsibleFile └── visible 再察看一下svn状态，会发现没有任何修改报告。 进一步我们还可以通过设置ignore属性，实现更多功能。 忽略某一类型文件，例如：忽略TARGET/FOLDER中的所有以.tmp结尾的文件 ~/tmp/checkOut$ svn propset svn:ignore &#8220;*.tmp&#8221; TARGET/FOLDER [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=59&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>最近使用svn比较多，发现一个问题就是默认情况下，svn会自动同步所有的文件和文件夹，而往往有些文件是没必要进行版本控制的，比如每次实验的结果和图片、或者缓存文件。所以就需要找个方法让svn把这些文件忽略掉，google了一下，找到了一个ignore命令正好可以帮我们实现这个想法。</p>
<p><span id="more-59"></span></p>
<p>下面开始实践，我们的当前的目录结构如下：</p>
<p>myCheckOut<br />
├── invisible<br />
│   └── ToBeInvisible<br />
└── visible<br />
目标：我们希望让svn忽略invisible文件夹里的文件。</p>
<p>首先从svn版本库中删除invisible文件夹里的文件，如果文件还有用，那就暂时保存在别的地方。</p>
<p>~/tmp/checkOut$ svn delete invisible/*</p>
<p>此时，文件夹结构变为：</p>
<p>myCheckOut<br />
├── invisible<br />
└── visible</p>
<p>然后设置svn忽略invisible文件夹中的所有文件</p>
<p>~/tmp/checkOut$ svn propset svn:ignore &#8216;*&#8217; invisible/</p>
<p>ok，提交新的版本到版本库</p>
<p>~/tmp/checkOut$ svn commit -m &#8220;Let us see.&#8221;</p>
<p>现在可以测试一下，在invisible文件夹里添加新文件invisibleFile后，目录结构变为：</p>
<p>myCheckOut<br />
├── invisible<br />
│   └── invinsibleFile<br />
└── visible</p>
<p>再察看一下svn状态，会发现没有任何修改报告。</p>
<p>进一步我们还可以通过设置ignore属性，实现更多功能。</p>
<p>忽略某一类型文件，例如：忽略TARGET/FOLDER中的所有以.tmp结尾的文件</p>
<p>~/tmp/checkOut$ svn propset svn:ignore &#8220;*.tmp&#8221; TARGET/FOLDER</p>
<p>忽略文件夹，例如：忽略TARGET/FOLDER中的test文件夹</p>
<p>~/tmp/checkOut$ svn propset svn:ignore test TARGET/FOLDER</p>
<p>忽略多个文件夹和文件， 例如：忽略TARGET/FOLDER中的tmp和bin文件夹以及所有以.bin结尾的文件</p>
<p>新建一个文件键入：</p>
<p>tmp<br />
bin<br />
*.bin</p>
<p>保存为ignoreList.txt,</p>
<p>~/tmp/checkOut$ svn propset svn:ignore -F ignoreList.txt TARGET/FOLDER</p>
<p><span style="text-decoration:underline;">参考资料:</span></p>
<p><a href="http://www.math-linux.com/spip.php?article110">http://www.math-linux.com/spip.php?article110</a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/nan1wang.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/nan1wang.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/nan1wang.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/nan1wang.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/nan1wang.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/nan1wang.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/nan1wang.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/nan1wang.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/nan1wang.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/nan1wang.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/nan1wang.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/nan1wang.wordpress.com/59/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/nan1wang.wordpress.com/59/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/nan1wang.wordpress.com/59/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=59&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://nan1wang.wordpress.com/2012/01/11/svn_ignore_file_and_folder/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<georss:point>51.482901 7.211810</georss:point>
		<geo:lat>51.482901</geo:lat>
		<geo:long>7.211810</geo:long>
		<media:content url="http://1.gravatar.com/avatar/7f4f8bd3727df963459910c4e86f43b0?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">akismet-7f4f8bd3727df963459910c4e86f43b0</media:title>
		</media:content>
	</item>
		<item>
		<title>windows下配置C++编译环境：MinGW+CMake</title>
		<link>http://nan1wang.wordpress.com/2010/08/28/mingw_cmake/</link>
		<comments>http://nan1wang.wordpress.com/2010/08/28/mingw_cmake/#comments</comments>
		<pubDate>Sat, 28 Aug 2010 21:15:48 +0000</pubDate>
		<dc:creator>Nan.Wang</dc:creator>
				<category><![CDATA[C++]]></category>
		<category><![CDATA[cmake]]></category>
		<category><![CDATA[MinGW]]></category>
		<category><![CDATA[windows]]></category>

		<guid isPermaLink="false">http://nan1wang.wordpress.com/?p=51</guid>
		<description><![CDATA[windows下如何配置MinGW+CMake，打造无VS的C++编程环境。<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=51&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>前些天被Visual Studio弄得无语了，去年刚到德国时候，发现MS大发慈悲的把Visual C++ 2010 beta版放在网上免费下载，实验室网速又快，就花了几分钟下来试试。随后受实验室影响，一直在学Linux，所以之后也没怎么用过。昨天想卸载掉才发现，已经过了试用期，心想那我不用了还不行啊，反正现在基本上VS能做的事情，我用vim都可以做到。梦魇降临了&#8230;MS说，你要卸载，必须要升级到正式版之后才可以&#8230;神啊!再花几个小时升级，然后没有用就卸载掉&#8230;于是铁了心的将开源程序进行到底~彻底抛弃VC!</p>
<p>言归正传，还是讲讲windows下如何配置MinGW+CMake，打造无VS的C++编程环境。<br /> <a title="MinGW by nan.wang's photo, on Flickr" href="http://www.flickr.com/photos/53428731@N02/4935948530/"><img src="http://farm5.static.flickr.com/4120/4935948530_b099051778_m.jpg" alt="MinGW" width="157" height="48" /></a><br /> <span id="more-51"></span>参考资料:</p>
<blockquote><p>http://www.mingw.org/</p>
<p>http://www-flc.desy.de/ldcoptimization/documents/talks/CMake_Tutorial.pdf</p>
</blockquote>
<p>首先，安装MinGW，下载连接在<a class="wp-caption-dd" title="MinGW" href="http://freefr.dl.sourceforge.net/project/mingw/Automated%20MinGW%20Installer/MinGW%205.1.6/MinGW-5.1.6.exe" target="_blank">这里</a>。MinGW全称是Minimalistic GNU for Windows，实际上是一套源文件和头文件的集合，旨在满足用户在Windows下使用GNU开源代码的要求。我们在这里主要是借用MinGW中的C++编译程序g++(Linux用户都不陌生吧~)。安装好之后，记得配置环境变量。例如，我安装在C:/MinGW，右击我的电脑-&gt;属性-&gt;高级-&gt;环境变量，Path中添加C:/MinGW/bin(记得不同路径之间用分号“ ; ”分割)。</p>
<p>可以编写个hello.cpp进行下测试, 代码如下：</p>
<blockquote><p>#include &lt;iostream&gt;</p>
<p>using namespace std;</p>
<p>int main()</p>
<p>{</p>
<p style="padding-left:30px;">cout &lt;&lt; &#8220;Hello, World!&#8221; &lt;&lt; endl;</p>
<p style="padding-left:30px;">return 0;</p>
<p>}</p>
</blockquote>
<p>Win+R, 输入cmd，打开windows命令行。cd进入hello.cpp所在的目录，例如，放在c:/test/hello.cpp<br /> <a title="cmd by nan.wang's photo, on Flickr" href="http://www.flickr.com/photos/53428731@N02/4935359683/"><img src="http://farm5.static.flickr.com/4078/4935359683_8ecdaf3fe9.jpg" alt="cmd" width="428" height="239" /></a></p>
<blockquote><p>cd c:/test/hello.cpp</p>
<p>g++ hello.cpp -o hello</p>
</blockquote>
<p>test文件夹中会生成hello.exe. 表明MinGW安装成功。<br /> <a title="hello_before_cmake by nan.wang's photo, on Flickr" href="http://www.flickr.com/photos/53428731@N02/4935948504/"><img src="http://farm5.static.flickr.com/4098/4935948504_c2125b909a.jpg" alt="hello_before_cmake" width="500" height="385" /></a></p>
<p>接下来安装CMake，下载链接在<a class="wp-caption-dd" title="CMake" href="http://www.cmake.org/cmake/resources/software.html" target="_blank">这里</a>。CMake主要是用于实现跨平台编译，免于编写复杂的Makefile，简言之，就是告诉不同的操作系统应当如何编译同一段源代码。CMake的学习资料很多，个人很推荐<a class="wp-caption-dd" title="CMake实践" href="http://sewm.pku.edu.cn/src/paradise/reference/CMake%20Practice.pdf" target="_blank">CMake实践</a>，很不错的入门教程。</p>
<p>就此，编译环境基本完工，继续给出一个小例子。进入C:/tmp，构建如下文件结构：</p>
<p>/tmp</p>
<p>&#8211;/Hello</p>
<p>&#8211;/Test</p>
<p>&#8211;/build</p>
<p>在/tmp文件夹内新建 CMakeLists.txt，加入如下内容：</p>
<blockquote><p>CMAKE_MINIMUM_REQUIRED(VERSION 2.6)<br /> SET(CMAKE_C_COMPILER mingw32-gcc)<br /> SET(CMAKE_CXX_COMPILER mingw32-g++)</p>
<p>PROJECT(HELLO)</p>
<p>ADD_SUBDIRECTORY(Hello)<br /> ADD_SUBDIRECTORY(Test)</p>
</blockquote>
<p>一行行解释，CMAKE_MINIMUM_REQUIRED(VERSION 2.6)定义CMake最低版本要求。<br /> SET(CMAKE_C_COMPILER mingw32-gcc) 定义CMake使用MinGW中的gcc作为C的编译器<br /> SET(CMAKE_CXX_COMPILER mingw32-g++) 定义CMake使用MinGW中的g++作为C++的编译器<br /> PROJECT(HELLO)新建一个Project，名为HELLO<br /> ADD_SUBDIRECTORY(Hello) ADD_SUBDIRECTORY(Test)，为该工程添加文件夹Hello和Test。</p>
<p>进入Hello文件夹，添加hello.cpp，内容如下：</p>
<blockquote><p>#include &#8220;hello.h&#8221;<br /> #include &lt;iostream&gt;</p>
<p>void Hello::Print() {<br /> std::cout &lt;&lt; &#8220;Hello, World!&#8221; &lt;&lt; std::endl;<br /> }</p>
</blockquote>
<p>在添加hello.h</p>
<blockquote><p>#ifndef _hello_h<br /> #define _hello_h</p>
<p>class Hello{<br /> public:<br /> void Print();<br /> };</p>
<p>#endif</p>
</blockquote>
<p>继续为该文件夹添加CMakeLists.txt,</p>
<blockquote><p>ADD_LIBRARY(Hello hello)</p>
</blockquote>
<p>意思是，根据hello.h创建一个动态库，名为Hello。CMake会告诉编译器生成一个名为libHello.a的库文件，之后我们会再次提到这个文件</p>
<p>再继续到Test文件夹中，新建test.cpp</p>
<blockquote><p>#include &lt;iostream&gt;<br /> #include &#8220;hello.h&#8221;</p>
<p>int main(int argc, const char *argv[])<br /> {<br /> Hello().Print();<br /> return 0;<br /> }</p>
</blockquote>
<p>继续为Test文件夹新建CMakeLists.txt</p>
<blockquote><p>INCLUDE_DIRECTORIES(${HELLO_SOURCE_DIR}/Hello)<br /> ADD_EXECUTABLE(helloWorld test)<br /> TARGET_LINK_LIBRARIES(helloWorld Hello)</p>
</blockquote>
<p>继续逐句解释，INCLUDE_DIRECTORIES(${HELLO_SOURCE_DIR}/Hello)将刚才我们在Hello文件夹里生成的库文件目录包含在编译环境中，也就是让编译程序知道我们要使用的动态库在哪里。<br /> ADD_EXECUTABLE(helloWorld test)根据test.cpp生成可执行文件helloWorld<br /> TARGET_LINK_LIBRARIES(helloWorld Hello)连接可执行文件helloWorld和所需的动态库，也就是我们刚才生成的libHello.a。</p>
<p>ok，测试程序编写完毕。</p>
<p>再次打开cmd命令行，进入build文件夹</p>
<blockquote><p>cd C:/tmp/build</p>
<p>cmake -G &#8220;MinGW Makefiles&#8221; ..</p>
<p>mingw32-make</p>
</blockquote>
<p>ok, 看一下build文件夹，多出来很多编译过程中的生成的文件，不管他们，看看/build/Test中是不是已经有了我们需要的helloWorld.exe。</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/nan1wang.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/nan1wang.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/nan1wang.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/nan1wang.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/nan1wang.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/nan1wang.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/nan1wang.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/nan1wang.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/nan1wang.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/nan1wang.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/nan1wang.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/nan1wang.wordpress.com/51/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/nan1wang.wordpress.com/51/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/nan1wang.wordpress.com/51/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=51&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://nan1wang.wordpress.com/2010/08/28/mingw_cmake/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<georss:point>51.482901 7.211810</georss:point>
		<geo:lat>51.482901</geo:lat>
		<geo:long>7.211810</geo:long>
		<media:content url="http://1.gravatar.com/avatar/7f4f8bd3727df963459910c4e86f43b0?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">akismet-7f4f8bd3727df963459910c4e86f43b0</media:title>
		</media:content>

		<media:content url="http://farm5.static.flickr.com/4120/4935948530_b099051778_m.jpg" medium="image">
			<media:title type="html">MinGW</media:title>
		</media:content>

		<media:content url="http://farm5.static.flickr.com/4078/4935359683_8ecdaf3fe9.jpg" medium="image">
			<media:title type="html">cmd</media:title>
		</media:content>

		<media:content url="http://farm5.static.flickr.com/4098/4935948504_c2125b909a.jpg" medium="image">
			<media:title type="html">hello_before_cmake</media:title>
		</media:content>
	</item>
		<item>
		<title>cl.exe+cmake打造免VC的Windows编译环境</title>
		<link>http://nan1wang.wordpress.com/2010/08/17/clexecmake/</link>
		<comments>http://nan1wang.wordpress.com/2010/08/17/clexecmake/#comments</comments>
		<pubDate>Tue, 17 Aug 2010 15:03:25 +0000</pubDate>
		<dc:creator>Nan.Wang</dc:creator>
				<category><![CDATA[C++]]></category>
		<category><![CDATA[cmake]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[Tablet_PC]]></category>
		<category><![CDATA[vim]]></category>

		<guid isPermaLink="false">http://nan1wang.wordpress.com/?p=45</guid>
		<description><![CDATA[周末不幸感冒，还小烧了一阵子，很多年不发烧了，还真的有点儿不适应...听老婆大人的吩咐在家里养病，于是就决定把自己的win7时到一下，以便于自己编程。<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=45&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>周末不幸感冒，还小烧了一阵子，很多年不发烧了，还真的有点儿不适应&#8230;听老婆大人的吩咐在家里养病，于是就决定把自己的win7时到一下，以便于自己编程。</p>
<p><a href="http://www.vim.org/"><img title="Vim" src="http://www.vim.org/images/vim_header.gif" alt="" width="201" height="50" /></a><a href="http://www.cmake.org/"><img title="cmake" src="http://www.cmake.org/opensourcelogos/cmake100.png" alt="" width="150" height="60" /></a><a href="http://www.microsoft.com/visualstudio/_base_v1/images/chrome/visual_studio_logo.png"><img title="Visual Studio" src="http://www.microsoft.com/visualstudio/_base_v1/images/chrome/visual_studio_logo.png" alt="" width="174" height="26" /></a></p>
<p><span id="more-45"></span></p>
<blockquote><p>编外话：来了德国之后，越来越喜欢开源程序了，非常享受各种程序都可以自己订制自己编译的快感~</p></blockquote>
<p>第一步当然是vim~现在越来越喜欢这个牛哄哄的编辑器了。</p>
<p><a href="http://www.vim.org/"><img class="alignleft" title="Vim" src="http://www.vim.org/images/vim_header.gif" alt="" width="180" height="45" /></a>安装好各个插件，可以参见vimer.cn的帖子</p>
<blockquote><p><a class="wp-caption-dd" title="vim插件推荐" href="http://www.vimer.cn/2010/06/%E6%9C%AC%E5%8D%9A%E4%BD%BF%E7%94%A8%E7%9A%84vimgvim%E7%9B%B8%E5%85%B3%E6%8F%92%E4%BB%B6%E6%95%B4%E7%90%86.html" target="_blank">vim插件推荐</a></p></blockquote>
<p>我安装了taglist, omnicppcomplete, a.vim, NERD_commenter, DoxygenToolkit.vim, snipMate, 还要安装exuberant ctags和cscope用于生成tags文件，以实现函数定义和函数实现之间的快速跳转</p>
<p>第二步，安装cmake，</p>
<p><a href="http://www.cmake.org/"><img class="alignleft" title="cmake" src="http://www.cmake.org/opensourcelogos/cmake100.png" alt="" width="171" height="67" /></a>不用多少了，下载之后，一路next。CMake主要用来实现cross-platform compile。无论是OS X, linux, 还是Windows，只要一个CMakeLists.txt文件，就可以生成相应的Makefiles。</p>
<p>第三步，安装编译环境。</p>
<p><a href="http://www.microsoft.com/visualstudio/_base_v1/images/chrome/visual_studio_logo.png"><img class="alignleft" title="Visual Studio" src="http://www.microsoft.com/visualstudio/_base_v1/images/chrome/visual_studio_logo.png" alt="" width="214" height="32" /></a>尝试安装了MinGW，可是与CMake的借口总是出现编译错误。最后还是投向了VC++,但又不愿意安装肥硕的Visual Studio，在网上找到了一个<a class="wp-caption-dd" href="http://dipplum.com/2009/11/13/visualc-compiler-portable/" target="_blank">VC++编译环境面安装命令行版</a>，直接下载vc10.rar和win7.rar解压放在同一文件夹，例如c:/VCcmd, 文件结构如下：</p>
<p>-/VCcmd</p>
<p>&#8211;/vc10</p>
<p>&#8211;/win7</p>
<p>&#8211;start-vc10.bat</p>
<p>&#8211;vc10.bat</p>
<p>至此，如果只希望使用cl.exe编译的话，直接运行start-vc10.bat即可。但是我们的目标是使用cmake生成makefiles之后，再调用MS的nmake生成.exe文件及相应的工程文件。</p>
<p>第四步，编辑环境变量。</p>
<p>右键 我的电脑 -&gt; 属性 -&gt; 高级 -&gt; 环境变量</p>
<p>User variables中 新建</p>
<p>Variable name: INCLUDE</p>
<p>Variable value: c:\VCcmd\vc10\include;c:\VCcmd\win7\include;</p>
<p>Variable name: LIB</p>
<p>Variable value: c:\VCcmd\vc10\lib;c:\VCcmd\win7\lib</p>
<p>编辑path, 添加C:\VCcmd\win7\bin;C:\VCcmd\vc10\bin</p>
<p>ok! 大功告成，测试一下，打开cmd，</p>
<p>md test, 新建一个文件夹/test</p>
<p>vim test.cpp, 新建一个源文件，用vim编辑，添加以下内容</p>
<blockquote><p>#include &lt;iostream&gt;<br />
using namespace std;<br />
int main()<br />
{<br />
cout &lt;&lt; &#8220;hello, world!&#8221; &lt;&lt; endl;<br />
return 0;<br />
}</p></blockquote>
<p>vim CMakeLists.txt，新建CMakeList.txt, 添加以下内容</p>
<blockquote><p>CMAKE_MINIMUM_REQUIRED(VERSION 2.6)<br />
SET(CMAKE_C_COMPILER C:/VCcmd/vc10/bin/cl.exe)<br />
SET(CMAKE_CXX_COMPILER C:/VCcmd/vc10/bin/cl.exe)<br />
PROJECT (HELLO)<br />
ADD_EXECUTABLE(HELLO hello.cpp)</p></blockquote>
<p>在/test文件夹中新建文件夹/build，用于保存编译过程成生成的文件</p>
<p>md build</p>
<p>cd build</p>
<p>cmake ..</p>
<p>nmake</p>
<p>完成，运行hello.exe，一切正常~</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/nan1wang.wordpress.com/45/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/nan1wang.wordpress.com/45/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/nan1wang.wordpress.com/45/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/nan1wang.wordpress.com/45/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/nan1wang.wordpress.com/45/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/nan1wang.wordpress.com/45/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/nan1wang.wordpress.com/45/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/nan1wang.wordpress.com/45/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/nan1wang.wordpress.com/45/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/nan1wang.wordpress.com/45/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/nan1wang.wordpress.com/45/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/nan1wang.wordpress.com/45/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/nan1wang.wordpress.com/45/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/nan1wang.wordpress.com/45/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=45&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://nan1wang.wordpress.com/2010/08/17/clexecmake/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<georss:point>51.482901 7.211810</georss:point>
		<geo:lat>51.482901</geo:lat>
		<geo:long>7.211810</geo:long>
		<media:content url="http://1.gravatar.com/avatar/7f4f8bd3727df963459910c4e86f43b0?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">akismet-7f4f8bd3727df963459910c4e86f43b0</media:title>
		</media:content>

		<media:content url="http://www.vim.org/images/vim_header.gif" medium="image">
			<media:title type="html">Vim</media:title>
		</media:content>

		<media:content url="http://www.cmake.org/opensourcelogos/cmake100.png" medium="image">
			<media:title type="html">cmake</media:title>
		</media:content>

		<media:content url="http://www.microsoft.com/visualstudio/_base_v1/images/chrome/visual_studio_logo.png" medium="image">
			<media:title type="html">Visual Studio</media:title>
		</media:content>

		<media:content url="http://www.vim.org/images/vim_header.gif" medium="image">
			<media:title type="html">Vim</media:title>
		</media:content>

		<media:content url="http://www.cmake.org/opensourcelogos/cmake100.png" medium="image">
			<media:title type="html">cmake</media:title>
		</media:content>

		<media:content url="http://www.microsoft.com/visualstudio/_base_v1/images/chrome/visual_studio_logo.png" medium="image">
			<media:title type="html">Visual Studio</media:title>
		</media:content>
	</item>
		<item>
		<title>Learning and Relearning in Boltzmann Machines (Hinton, 1986)</title>
		<link>http://nan1wang.wordpress.com/2010/08/06/laribm-hinton-1986/</link>
		<comments>http://nan1wang.wordpress.com/2010/08/06/laribm-hinton-1986/#comments</comments>
		<pubDate>Fri, 06 Aug 2010 10:09:01 +0000</pubDate>
		<dc:creator>Nan.Wang</dc:creator>
				<category><![CDATA[Machine learning]]></category>
		<category><![CDATA[boltzmann_machine]]></category>
		<category><![CDATA[notes]]></category>

		<guid isPermaLink="false">http://nan1wang.wordpress.com/?p=37</guid>
		<description><![CDATA[Reading notes of the paper from G. Hinton, Learning and Relearning in Boltzmann Machines (1986).<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=37&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p style="padding-left:30px;"><em><span style="color:#000080;">This week, I finish reading this paper from Hinton. In this paper, Hinton described some basic idea of training Boltzmann machine, from where i can find some prototype of RBM.</span></em></p>
<p><a class="wp-caption-dd" title="Learning and relearning in boltzmann machine" href="http://Learning and Relearning in Boltzmann Machines (Hinton, 1986)" target="_blank">Learning and Relearning in Boltzmann Machines (Hinton, 1986)</a></p>
<p><span id="more-37"></span></p>
<blockquote><p>The basic idea is simple: The weights on the connections between processing units encode knowledge about how things normally fit together in some domain and how the initial states or external inputs to a subset of the units encode some fragments of a structure within the domain.</p></blockquote>
<p><em>Nan: The basic idea behind the networks.<br />
</em></p>
<ul>
<li><em>First, how the weights encode knowledge in different domain. </em></li>
<li><em>Secondly, how the weights (fragments of the structure) encode knowledge in the same domain with the help of initial states or external inputs.</em></li>
</ul>
<blockquote><p>The information in the images is not sufficient to specify the three-dimensional surfaces unless the interpretive process<br />
makes use of additional plausible constraints about the kinds of structures that typically appear.<br />
<em></em></p></blockquote>
<p><em>Nan: Learning systems need <strong>internal structures</strong> in order to solve large constraints-satisfaction problems rapidly, and furthermore, to abstract information from external inputs in a short time.</em></p>
<ol>
<blockquote>
<li>Will the networks settle down or will it oscillate or wander aimlessly?</li>
<li>What does the network compute by settling down? We need some characterization of the computation that the network performs other the network. We would like to be able to say what ought to be computed and then to show that a network can be made to compute it.</li>
<li>How long does the network take to settle on a solution?</li>
<li>How much information does each unit need to convey to its neighbors? &#8230; cortical neurons &#8230; communicate using all-or-none spikes.</li>
<li>How are the weights that encode the knowledge acquired?</li>
</blockquote>
</ol>
<p><em>Nan: Some basic questions regarding neural networks.<br />
</em></p>
<ul>
<li><em>The first question relates to algorithms and structures. Network itself is just a structure. Whether this structure can be settled down or not depends on relative algorithms. </em></li>
<li><em>So as the second and the third question. In RBM, the characterization is likelihood. In Hopfield networks and SFA, it is reconstruction error and slowness respectively. </em></li>
<li><em>To the third question, it is a problem that plague RBM. A better solution maybe a better sampling methods or reuse the past knowledge. </em></li>
<li><em>The fourth question may be the answer to the question why Hinton insists to use binary units for upper layers. While, my concern is <strong>when and where the continuous information is encoded into binary signals</strong>. Besides, does the time information matter? </em></li>
<li><em>The answer to the last question may need a careful look at the weights after learning. Maybe some interesting phenomenons, like those in shift experiment, will emerge.</em></li>
</ul>
<blockquote><p><strong>Relaxation Searches</strong><br />
&#8230; all the constraints are weak and there is no distinction between constraints and costs. The optimal solution is then the one which minimizes the total constraint violation.<br />
&#8230; some relaxation schemes have an associated &#8220;potential&#8221; or cost function&#8230; This idea was used by Hopfield (1982) &#8230; each update reduces the value of a cost function which he called &#8220;energy&#8221;&#8230;<br />
<em></em></p></blockquote>
<p><em>Nan: How <strong>energy</strong> is introduced to networks.</em></p>
<blockquote><p><strong>Using probabilistic decision to escape from local minima</strong><br />
One standard technique is to use gradient descent.<br />
Kirkpatrick, Gelatt, and Vecchi (1983) used another physical analogy to guide the use of occasional uphill steps&#8230; they<br />
named their search method &#8220;simulated annealing&#8221;.<br />
The number of ways of getting from one low-lying state to another is an exponential function of the height of the barrier one is willing to cross.<br />
<em></em></p></blockquote>
<p><em>Nan: The reason why we are using <strong>exponential function of energy </strong>to express possibility.</em></p>
<blockquote><p><strong>Pattern completion</strong><br />
There are strong limitations on the sets of binary vectors that can be learned if the network has one unit for each component of the vector. These limits can be transcended by using extra units &#8230;<br />
<em></em></p></blockquote>
<p><em>Nan: Why <strong>hidden units </strong>are introduced. Besides, it is interesting to regard visible and hidden units as a whole, and regard the problem as a pattern completion.<br />
</em></p>
<blockquote><p><strong>How to train such network</strong><br />
&#8230; the main problem which is to discover appropriate representations for a given task among the hidden units.<br />
&#8230; the weights in the network should be chosen so that the hidden units represent significant underlying features that bear strong, regular relationships to each other and to the states of the visible units.<br />
<em></em></p></blockquote>
<p><em>Nan: Understanding of the hidden units.</em></p>
<blockquote><p><strong>Maximum likelihood</strong><br />
The learning procedure &#8230; has a close relationship to &#8230; Expectation and Maximization (EM) (Dempter, Laird, &amp; Rubin,<br />
1976).<br />
Baum&#8217;s algorithm and EM are able to estimate new values for the probabilities (or weights)&#8230; Our algorithm simply estimates the gradient of the log likelihood with respect to a weight.<br />
<em></em></p></blockquote>
<p><em>Nan: the idea of <strong>Maximum likelihood</strong>. Calculate how likely the observed patterns of activity is given the set of weights that determines when those patterns are active. And use this likelihood to update weights.</em></p>
<blockquote><p><strong>Blotzmann machine learning algorithm</strong><br />
G is actually the distance in bits from the free running distribution to the environmental distribution.<br />
<em></em></p></blockquote>
<p><em>Nan: Use <strong>Kullback-Leibler divergence</strong> to update weights.</em></p>
<blockquote><p><strong>Ways in which the learning algorithm can fail</strong><br />
The first difficulty is that there is nothing to prevent the learning algorithm from generating very large weights.<br />
<em></em></p></blockquote>
<p><em>Nan: the reason why to introduce <strong>weight-decay</strong>.</em></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/nan1wang.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/nan1wang.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/nan1wang.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/nan1wang.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/nan1wang.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/nan1wang.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/nan1wang.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/nan1wang.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/nan1wang.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/nan1wang.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/nan1wang.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/nan1wang.wordpress.com/37/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/nan1wang.wordpress.com/37/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/nan1wang.wordpress.com/37/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=37&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://nan1wang.wordpress.com/2010/08/06/laribm-hinton-1986/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/7f4f8bd3727df963459910c4e86f43b0?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">akismet-7f4f8bd3727df963459910c4e86f43b0</media:title>
		</media:content>
	</item>
		<item>
		<title>Vim</title>
		<link>http://nan1wang.wordpress.com/2010/08/03/vim/</link>
		<comments>http://nan1wang.wordpress.com/2010/08/03/vim/#comments</comments>
		<pubDate>Tue, 03 Aug 2010 11:54:48 +0000</pubDate>
		<dc:creator>Nan.Wang</dc:creator>
				<category><![CDATA[C++]]></category>
		<category><![CDATA[Miscellaneous]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[software]]></category>
		<category><![CDATA[vim]]></category>

		<guid isPermaLink="false">http://nan1wang.wordpress.com/?p=25</guid>
		<description><![CDATA[Recently, I am learning Vim and becoming. It is an amazing editor. <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=25&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<div class="wp-caption alignnone" style="width: 190px"><a href="http://www.vim.org/images/vim_header.gif"><img title="Vim" src="http://www.vim.org/images/vim_header.gif" alt="" width="180" height="45" /></a><p class="wp-caption-text">Vim editor</p></div>
<p>Recently, I am learning <a class="wp-caption-dd" title="Vim" href="http://www.vim.org/index.php" target="_blank">Vim</a> and becoming. It is an amazing editor.</p>
<p><span id="more-25"></span>More important, Vim is orignially designed for programming!!! Although a lot of people argued about the massive key-binding, I think with Vim, there is a big efficiency pay-off. Not mentioning the speedy editing, with Vim plug-ins, I can have everything the IDEs can provide, such as auto-completion, quick commenting, jumping between source and header files, overview of structures, class and function. Most important thing is that, meanwhile, I still have a clear view of what the computer is doing.</p>
<p>Following is the plug-ins I am using now, which are quite convient for programming:</p>
<ul>
<li>taglist: provide overview of functions, structures, and class</li>
<li>omnicppcomplete: provide C++ codes auto-completion</li>
<li>a.vim: provide quick switch between source and header files</li>
<li>NERD_commenter: provide quick commenting and uncommenting</li>
<li>DoxygenToolkit.vim: provide beautiful copy rights and function comments</li>
<li>snipMate: my favourite, provide auto-completion for everyday-use codes, such as <em>for, while, main</em></li>
<li>mark.vim: provide highlights for variables</li>
</ul>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/nan1wang.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/nan1wang.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/nan1wang.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/nan1wang.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/nan1wang.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/nan1wang.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/nan1wang.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/nan1wang.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/nan1wang.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/nan1wang.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/nan1wang.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/nan1wang.wordpress.com/25/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/nan1wang.wordpress.com/25/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/nan1wang.wordpress.com/25/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=25&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://nan1wang.wordpress.com/2010/08/03/vim/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<georss:point>51.482901 7.211810</georss:point>
		<geo:lat>51.482901</geo:lat>
		<geo:long>7.211810</geo:long>
		<media:content url="http://1.gravatar.com/avatar/7f4f8bd3727df963459910c4e86f43b0?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">akismet-7f4f8bd3727df963459910c4e86f43b0</media:title>
		</media:content>

		<media:content url="http://www.vim.org/images/vim_header.gif" medium="image">
			<media:title type="html">Vim</media:title>
		</media:content>
	</item>
		<item>
		<title>Vimperator</title>
		<link>http://nan1wang.wordpress.com/2010/07/31/vimperator/</link>
		<comments>http://nan1wang.wordpress.com/2010/07/31/vimperator/#comments</comments>
		<pubDate>Sat, 31 Jul 2010 21:41:35 +0000</pubDate>
		<dc:creator>Nan.Wang</dc:creator>
				<category><![CDATA[Miscellaneous]]></category>
		<category><![CDATA[Firefox]]></category>
		<category><![CDATA[vim]]></category>
		<category><![CDATA[vimperator]]></category>

		<guid isPermaLink="false">http://nan1wang.wordpress.com/?p=28</guid>
		<description><![CDATA[Vimperator is Firefox browser extension with strong inspiration from the Vim text editor, with a mind towards faster and more efficient browsing.<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=28&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><a href="http://vimperator.org/img/logo-trans.png"><img class="alignleft" title="Vimperator" src="http://f.hatena.ne.jp/images/fotolife/t/tk109/20091118/20091118000841.jpg" alt="Vimperator" width="247" height="48" /></a></p>
<p><a class="wp-caption-dd" title="Vimperator" href="http://vimperator.org/" target="_blank">Vimperator</a> is Firefox browser extension with strong inspiration from the Vim text editor, with a mind towards faster and more efficient browsing.</p>
<p><span id="more-28"></span>As I am learning Vim, Vimperator greatly accelaterate my internet browsing. With customized key-bindings, I can design my own browser. Its hint-model is also quite fascinating, making it possible to click a URL by keyboard!</p>
<p>Hints-model</p>
<p><a href="http://vimperator.org/vimperator"><img class="alignnone" title="vimperator hints-model" src="http://vimperator.org/screenshots/vimperator_hints.png" alt="Hints" width="841" height="699" /></a></p>
<p>Just press &#8220;o&#8221;, then you can open a new website in current tab. Besides, it has auto-completion function, which makes input much easier than you can imagine.</p>
<p><a href="http://vimperator.org/vimperator"><img class="alignnone" title="Vimperator completion" src="http://vimperator.org/screenshots/vimperator_completions.png" alt="completion" width="841" height="699" /></a></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/nan1wang.wordpress.com/28/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/nan1wang.wordpress.com/28/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/nan1wang.wordpress.com/28/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/nan1wang.wordpress.com/28/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/nan1wang.wordpress.com/28/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/nan1wang.wordpress.com/28/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/nan1wang.wordpress.com/28/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/nan1wang.wordpress.com/28/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/nan1wang.wordpress.com/28/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/nan1wang.wordpress.com/28/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/nan1wang.wordpress.com/28/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/nan1wang.wordpress.com/28/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/nan1wang.wordpress.com/28/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/nan1wang.wordpress.com/28/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=28&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://nan1wang.wordpress.com/2010/07/31/vimperator/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<georss:point>51.482901 7.211810</georss:point>
		<geo:lat>51.482901</geo:lat>
		<geo:long>7.211810</geo:long>
		<media:content url="http://1.gravatar.com/avatar/7f4f8bd3727df963459910c4e86f43b0?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">akismet-7f4f8bd3727df963459910c4e86f43b0</media:title>
		</media:content>

		<media:content url="http://f.hatena.ne.jp/images/fotolife/t/tk109/20091118/20091118000841.jpg" medium="image">
			<media:title type="html">Vimperator</media:title>
		</media:content>

		<media:content url="http://vimperator.org/screenshots/vimperator_hints.png" medium="image">
			<media:title type="html">vimperator hints-model</media:title>
		</media:content>

		<media:content url="http://vimperator.org/screenshots/vimperator_completions.png" medium="image">
			<media:title type="html">Vimperator completion</media:title>
		</media:content>
	</item>
		<item>
		<title>Grab and Drag</title>
		<link>http://nan1wang.wordpress.com/2010/07/30/grab-and-drag/</link>
		<comments>http://nan1wang.wordpress.com/2010/07/30/grab-and-drag/#comments</comments>
		<pubDate>Fri, 30 Jul 2010 12:52:19 +0000</pubDate>
		<dc:creator>Nan.Wang</dc:creator>
				<category><![CDATA[Miscellaneous]]></category>
		<category><![CDATA[Firefox]]></category>
		<category><![CDATA[Tablet_PC]]></category>

		<guid isPermaLink="false">http://nan1wang.wordpress.com/?p=6</guid>
		<description><![CDATA[Amazing firefox add-on for Tablet PC!<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=6&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>&#8220;<a class="wp-caption-dd" title="Grab and Drag" href="http://grabanddrag.mozdev.org/index.html" target="_blank">Grab and Drag</a>&#8221; is a wonderful firefox add-on for Tablet PC. I can&#8217;t help to love it. It enable grab and drag scrolling and momentum scrolling like iphone. I am always frustrated when I browse the websites on my Tablet PC. That is what exactly I am looking for.</p>
<p>Here is a demo video:</p>
<p><span id="more-6"></span><span class='embed-youtube' style='text-align:center; display: block;'><iframe class='youtube-player' type='text/html' width='500' height='312' src='http://www.youtube.com/embed/Xp3mQGOQTzk?version=3&amp;rel=1&amp;fs=1&amp;showsearch=0&amp;showinfo=1&amp;iv_load_policy=1&amp;wmode=transparent' frameborder='0'></iframe></span></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/nan1wang.wordpress.com/6/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/nan1wang.wordpress.com/6/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/nan1wang.wordpress.com/6/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/nan1wang.wordpress.com/6/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/nan1wang.wordpress.com/6/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/nan1wang.wordpress.com/6/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/nan1wang.wordpress.com/6/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/nan1wang.wordpress.com/6/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/nan1wang.wordpress.com/6/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/nan1wang.wordpress.com/6/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/nan1wang.wordpress.com/6/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/nan1wang.wordpress.com/6/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/nan1wang.wordpress.com/6/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/nan1wang.wordpress.com/6/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=nan1wang.wordpress.com&amp;blog=14950371&amp;post=6&amp;subd=nan1wang&amp;ref=&amp;feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://nan1wang.wordpress.com/2010/07/30/grab-and-drag/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<georss:point>51.482901 7.211810</georss:point>
		<geo:lat>51.482901</geo:lat>
		<geo:long>7.211810</geo:long>
		<media:content url="http://1.gravatar.com/avatar/7f4f8bd3727df963459910c4e86f43b0?s=96&#38;d=http%3A%2F%2F1.gravatar.com%2Favatar%2Fad516503a11cd5ca435acc9bb6523536%3Fs%3D96&#38;r=G" medium="image">
			<media:title type="html">akismet-7f4f8bd3727df963459910c4e86f43b0</media:title>
		</media:content>
	</item>
	</channel>
</rss>
