Posts tagged ‘Programming’

Using MPICH2 on Debian

1. apt-get install mpich2 (remove other implementation to prevent trouble)
2. create .mpd.conf file under home dir ~/ , add a line “password=qwert” (replace qwert with any other texts)
3. create a hostfile or machine file (e.g. mpd.hosts) with node names listed one per line. (this file can be in any folder)
4. start mpd. There is a script shipped with mpich2 “mpdboot”. It accept some options. “mpdboot -f mpd.hosts -n #” with #<= number of nodes listed in mpd.hosts file. This command will start mpd on all the nodes if ssh or rsh is set correctly (without password).
5 use mpdtrace to verify the node names (nodes having been added to the mpd ring, ready to be used in the following mpirun calls).
6 mpirun -np N -host node1,node2 ./program (it’s not necessary to use all the nodes in the ring, but some of them is fine)

用VC和gcc同时编译unicode编码的c++源程序

经常在C++程序中加入中文注释,但是如果使用不同的编辑器,编码识别或转换不当,会导致非ASCII字符乱码。

Continue reading ‘用VC和gcc同时编译unicode编码的c++源程序’ »

免费Python IDE的首选

Python的集成开发环境不少,有商业的WingIDE(不要用它们那个缩水的免费版,没有语法提示),也有很多免费的。我使用过一些,现在直接告诉你最好用的。如果你不想自己费力气去测试你自己最喜欢的一款,那么请直接选择Eclipse+PyDev(各种平台)或者PyScripter(Windows平台)。它们不会让你失望,因为无论调试,语法加亮,自动提示,配色方案,外挂工具,命令行窗口,todo,帮助等功能一应俱全,而且免费!希望我的推荐可以省去您一点时间。如果哪位朋友发现更好的(综合品质),请推荐给我。

Continue reading ‘免费Python IDE的首选’ »