锘??xml version="1.0" encoding="utf-8" standalone="yes"?>久久精品中文无码资源站,中文字幕日本人妻久久久免费,国产精品激情综合久久http://www.shnenglu.com/polly-yang/category/19938.htmlzh-cnTue, 18 Sep 2012 21:46:05 GMTTue, 18 Sep 2012 21:46:05 GMT60銆愯漿杞姐戝湪Ubuntu涓嬪畨瑁匬ython縐戝璁$畻鐜http://www.shnenglu.com/polly-yang/archive/2012/09/18/191093.htmlpollypollyTue, 18 Sep 2012 05:02:00 GMThttp://www.shnenglu.com/polly-yang/archive/2012/09/18/191093.htmlhttp://www.shnenglu.com/polly-yang/comments/191093.htmlhttp://www.shnenglu.com/polly-yang/archive/2012/09/18/191093.html#Feedback0http://www.shnenglu.com/polly-yang/comments/commentRss/191093.htmlhttp://www.shnenglu.com/polly-yang/services/trackbacks/191093.html鍘熸枃鍦板潃錛?a target="_blank">鍦║buntu涓畨瑁匬ython縐戝璁$畻鐜 浣滆?/strong>錛?a target="_blank">HyryStudio


鍦║buntu涓嬪畨瑁匬ython妯″潡閫氬父鍙互浣跨敤apt-get鍜宲ip鍛戒護(hù)銆俛pt-get鍛戒護(hù)鏄疷buntu鑷甫鐨勫寘綆$悊鍛戒護(hù)錛岃宲ip鍒欐槸Python瀹夎鎵╁睍妯″潡鐨勫伐鍏鳳紝閫氬父pip浼?xì)涓嬭浇鎵╁睍妯″潡鐨勬簮浠g爜迤埦~栬瘧瀹夎銆?/p>

Ubuntu 12.04涓己鐪佸畨瑁呬簡Python2.7.3錛岄鍏堥氳繃涓嬮潰鐨勫懡浠ゅ畨瑁卲ip錛宲ip鏄疨ython鐨勪竴涓畨瑁呭拰綆$悊鎵╁睍搴撶殑宸ュ叿銆?/p>

sudo apt-get install python-pip

瀹夎Python寮鍙戠幆澧冿紝鏂逛究浠婂悗緙栬瘧鍏朵粬鎵╁睍搴擄紝鍗犵敤絀洪棿92.8M錛?/p>

sudo apt-get install python-dev

IPython

涓轟簡瀹夎鏈鏂扮増鐨処Python 0.13beta錛岄渶瑕佷笅杞絀Python婧愪唬鐮侊紝騫舵墽琛屽畨瑁呭懡浠ゃ傚湪IPython 0.13beta涓彁渚涗簡鏀硅繘鐗堟湰鐨処Python notebook銆備笅闈㈢殑鍛戒護(hù)棣栧厛瀹夎鐗堟湰綆$悊杞歡git錛岀劧鍚庨氳繃git鍛戒護(hù)浠嶪Python鐨勫紑鍙戜唬鐮佸簱涓笅杞芥渶鏂扮増鏈殑IPython婧愪唬鐮侊紝騫舵墽琛屽畨瑁呭懡浠わ細(xì)

cd
sudo apt-get install git
git clone https://github.com/ipython/ipython.git
cd ipython
sudo python setup.py install

濡傛灉瀹夎鐩墠鐨勬渶鏂扮ǔ瀹氱増鏈紝鍙互杈撳叆:

sudo apt-get install ipython

瀹夎瀹屾瘯涔嬪悗錛岃杈撳叆ipython鍛戒護(hù)嫻嬭瘯鏄惁鑳芥甯稿惎鍔ㄣ?/p>

涓轟簡璁㊣Python notebook宸ヤ綔錛岃繕榪橀渶瑕佸畨瑁卼ornado鍜宲yzmq錛?/p>

sudo pip install tornado
sudo apt-get install libzmq-dev
sudo pip install pyzmq
sudo pip install pygments

涓嬮潰嫻嬭瘯IPython錛?/p>

cd
mkdir notebook
cd notebook
ipython notebook

涓轟簡鍦↖Python涓綰夸嬌鐢↙aTeX鏁板鍏紡錛岄渶瑕佸畨瑁卪athjax錛岄鍏堣緭鍏ヤ笅闈㈢殑鍛戒護(hù)鍚姩ipython notebook錛?/p>

sudo ipython notebook

鍦↖Python notebook鐣岄潰涓緭鍏ワ細(xì)

from IPython.external.mathjax import install_mathjax
install_mathjax()

NumPy錛孲ciPy鍜宮atplotlib

閫氳繃apt-get鍛戒護(hù)鍙互蹇熷畨瑁呰繖涓変釜搴擄細(xì)

sudo apt-get install python-numpy
sudo apt-get install python-scipy
sudo apt-get install python-matplotlib

濡傛灉闇瑕侀氳繃pip緙栬瘧瀹夎錛屽彲浠ュ厛鐢╝pt-get鍛戒護(hù)瀹夎鎵鏈夌紪璇戞墍闇鐨勫簱錛?/p>

sudo apt-get build-dep python-numpy
sudo apt-get build-dep python-scipy

鐒跺悗閫氳繃pip鍛戒護(hù)瀹夎錛?/p>

sudo pip install numpy
sudo pip install scipy
閫氳繃build-dep浼?xì)瀹夎寰堝搴撳Q屽寘鎷琍ython 3.2銆?/div>

PyQt4鍜孲pyder

涓嬮潰鐨勫懡浠ゅ畨瑁匬yQt4錛孮t鐣岄潰璁捐鍣紝PyQt4鐨勫紑鍙戝伐鍏蜂互鍙?qiáng)鏂囨。锛?xì)

sudo apt-get install python-qt4
sudo apt-get install qt4-designer
sudo apt-get install pyqt4-dev-tools
sudo apt-get install python-qt4-doc

瀹夎瀹屾瘯涔嬪悗錛屾枃妗d綅浜庯細(xì)

/usr/share/doc/python-qt4-doc

瀹夎濂絇yQt4涔嬪悗閫氳繃涓嬮潰鐨勫懡浠ゅ畨瑁匰pyder錛?/p>

sudo apt-get install spyder

鐢變簬Spyder緇忓父鏇存柊錛岄氳繃涓嬮潰鐨勫懡浠ゅ彲浠ュ畨瑁呮渶鏂扮増錛?/p>

sudo pip install spyder --upgrade

cython鍜孲WIG

Cython鍜孲WIG鏄紪鍐橮ython鎵╁睍妯″潡鐨勫伐鍏鳳細(xì)

sudo pip install cython
sudo apt-get install swig

杈撳叆 cython --version 鍜?swig -version 鏌ョ湅鐗堟湰銆?/p>

ETS

ETS鏄痚nthought鍏徃寮鍙戠殑涓濂楃瀛﹁綆楄蔣浠跺寘錛屽叾涓殑Mayavi閫氳繃VTK瀹炵幇鏁版嵁鐨勪笁緇村彲瑙嗗寲銆?/p>

棣栧厛閫氳繃涓嬮潰鐨勫懡浠ゅ畨瑁呯紪璇慐TS鎵闇鐨勫簱錛?/p>

sudo apt-get install python-dev libxtst-dev scons python-vtk  pyqt4-dev-tools python2.7-wxgtk2.8 python-configobj
sudo apt-get install libgl1-mesa-dev libglu1-mesa-dev

鍒涘緩ets鐩綍錛屽茍鍦ㄦ鐩綍涓嬩笅杞絜ts.py錛岃繍琛宔ts.py鍙互澶嶅埗鏈鏂扮増鐨凟TS婧愮▼搴忥紝騫跺畨瑁咃細(xì)

mkdir ets
cd ets
wget https://github.com/enthought/ets/raw/master/ets.py
python ets.py clone
sudo python ets.py develop
#sudo python ets.py install 鎴栬呰繍琛宨nstall瀹夎

濡傛灉涓鍒囨甯革紝閭d箞杈撳叆 mayavi2 鍛戒護(hù)鍒欎細(xì)鍚姩mayavi銆?/p>

OpenCV

涓轟簡緙栬瘧OpenCV闇瑕佷笅杞絚make緙栬瘧宸ュ叿錛屽拰涓浜涗緷璧栧簱錛?/p>

sudo apt-get install build-essential
sudo apt-get install cmake
sudo apt-get install cmake-gui
sudo apt-get install libavcodec-dev libavformat-dev libswscale-dev
sudo apt-get install libjpeg-dev libpng-dev libtiff-dev libjasper-dev

鐒跺悗浠?http://sourceforge.net/projects/opencvlibrary/ 涓嬭澆鏈鏂扮増鐨凮penCV婧愪唬鐮侊紝騫惰В鍘嬨傜劧鍚庡垱寤虹紪璇戠敤鐨勭洰褰時elease錛屽茍鍚姩cmake-gui:

mkdir release
cmake-gui

鍦ㄧ晫闈腑閫夋嫨OpenCV婧愪唬鐮佺殑鐩綍錛屽拰緙栬瘧杈撳嚭鐩綍release錛岀劧鍚庢寜Configure鎸夐挳錛屽茍鏍規(guī)嵁闇瑕佽緗悇涓紪璇戦夐」錛屾渶鍚庣偣Generate鎸夐挳錛岄鍑篶make-gui鐣岄潰銆傝繘鍏ョ紪璇戣礬寰勶紝鎵ц涓嬮潰鐨勫懡浠わ細(xì)

cd release
make
sudo make install

瀹夎瀹屾瘯涔嬪悗錛屽惎鍔↖Python錛屽茍杈撳叆 import cv2 嫻嬭瘯OpenCV鏄惁鑳芥甯歌澆鍏ャ?/p>

 



polly 2012-09-18 13:02 鍙戣〃璇勮
]]>Python鐧婚檰浜轟漢緗戝茍鎶撳彇鏂伴矞浜?/title><link>http://www.shnenglu.com/polly-yang/archive/2012/09/17/190975.html</link><dc:creator>polly</dc:creator><author>polly</author><pubDate>Mon, 17 Sep 2012 06:20:00 GMT</pubDate><guid>http://www.shnenglu.com/polly-yang/archive/2012/09/17/190975.html</guid><wfw:comment>http://www.shnenglu.com/polly-yang/comments/190975.html</wfw:comment><comments>http://www.shnenglu.com/polly-yang/archive/2012/09/17/190975.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.shnenglu.com/polly-yang/comments/commentRss/190975.html</wfw:commentRss><trackback:ping>http://www.shnenglu.com/polly-yang/services/trackbacks/190975.html</trackback:ping><description><![CDATA[<p> </p> <div style="border-bottom: #cccccc 1px solid; border-left: #cccccc 1px solid; padding-bottom: 4px; background-color: #eeeeee; padding-left: 4px; width: 98%; padding-right: 5px; font-size: 13px; word-break: break-all; border-top: #cccccc 1px solid; border-right: #cccccc 1px solid; padding-top: 4px"><img id="Code_Closed_Image_141844" onclick="this.style.display='none'; Code_Closed_Text_141844.style.display='none'; Code_Open_Image_141844.style.display='inline'; Code_Open_Text_141844.style.display='inline';" align="top" src="http://www.shnenglu.com/images/OutliningIndicators/ContractedBlock.gif" width="11" height="16"><img style="display: none" id="Code_Open_Image_141844" onclick="this.style.display='none'; Code_Open_Text_141844.style.display='none'; Code_Closed_Image_141844.style.display='inline'; Code_Closed_Text_141844.style.display='inline';" align="top" src="http://www.shnenglu.com/images/OutliningIndicators/ExpandedBlockStart.gif" width="11" height="16"><span style="border-bottom: #808080 1px solid; border-left: #808080 1px solid; background-color: #ffffff; border-top: #808080 1px solid; border-right: #808080 1px solid" id="Code_Closed_Text_141844"></span><span style="display: none" id="Code_Open_Text_141844"><br /><!--<br /><br />Code highlighting produced by Actipro CodeHighlighter (freeware)<br />http://www.CodeHighlighter.com/<br /><br />--><span style="color: #008080"> 1</span><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" /><span style="color: #0000ff">from</span><span style="color: #000000"> sgmllib </span><span style="color: #0000ff">import</span><span style="color: #000000"> SGMLParser<br /></span><span style="color: #008080"> 2</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" /></span><span style="color: #0000ff">import</span><span style="color: #000000"> sys,urllib2,urllib,cookielib<br /></span><span style="color: #008080"> 3</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" /></span><span style="color: #0000ff">class</span><span style="color: #000000"> spider(SGMLParser):<br /></span><span style="color: #008080"> 4</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />    </span><span style="color: #0000ff">def</span><span style="color: #000000"> </span><span style="color: #800080">__init__</span><span style="color: #000000">(self,email,password):<br /></span><span style="color: #008080"> 5</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        SGMLParser.</span><span style="color: #800080">__init__</span><span style="color: #000000">(self)<br /></span><span style="color: #008080"> 6</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.h3</span><span style="color: #000000">=</span><span style="color: #000000">False<br /></span><span style="color: #008080"> 7</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.h3_is_ready</span><span style="color: #000000">=</span><span style="color: #000000">False<br /></span><span style="color: #008080"> 8</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.div</span><span style="color: #000000">=</span><span style="color: #000000">False<br /></span><span style="color: #008080"> 9</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.h3_and_div</span><span style="color: #000000">=</span><span style="color: #000000">False<br /></span><span style="color: #008080">10</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.a</span><span style="color: #000000">=</span><span style="color: #000000">False<br /></span><span style="color: #008080">11</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.depth</span><span style="color: #000000">=</span><span style="color: #000000">0<br /></span><span style="color: #008080">12</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.names</span><span style="color: #000000">=</span><span style="color: #800000">""</span><span style="color: #000000"><br /></span><span style="color: #008080">13</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.dic</span><span style="color: #000000">=</span><span style="color: #000000">{}   <br /></span><span style="color: #008080">14</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />         <br /></span><span style="color: #008080">15</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.email</span><span style="color: #000000">=</span><span style="color: #000000">email<br /></span><span style="color: #008080">16</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.password</span><span style="color: #000000">=</span><span style="color: #000000">password<br /></span><span style="color: #008080">17</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.domain</span><span style="color: #000000">=</span><span style="color: #800000">'</span><span style="color: #800000">renren.com</span><span style="color: #800000">'</span><span style="color: #000000"><br /></span><span style="color: #008080">18</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        </span><span style="color: #0000ff">try</span><span style="color: #000000">:<br /></span><span style="color: #008080">19</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            cookie</span><span style="color: #000000">=</span><span style="color: #000000">cookielib.CookieJar()<br /></span><span style="color: #008080">20</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            cookieProc</span><span style="color: #000000">=</span><span style="color: #000000">urllib2.HTTPCookieProcessor(cookie)<br /></span><span style="color: #008080">21</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        </span><span style="color: #0000ff">except</span><span style="color: #000000">:<br /></span><span style="color: #008080">22</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            </span><span style="color: #0000ff">raise</span><span style="color: #000000"><br /></span><span style="color: #008080">23</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        </span><span style="color: #0000ff">else</span><span style="color: #000000">:<br /></span><span style="color: #008080">24</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            opener</span><span style="color: #000000">=</span><span style="color: #000000">urllib2.build_opener(cookieProc)<br /></span><span style="color: #008080">25</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            urllib2.install_opener(opener)       <br /></span><span style="color: #008080">26</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" /><br /></span><span style="color: #008080">27</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />    </span><span style="color: #0000ff">def</span><span style="color: #000000"> login(self):<br /></span><span style="color: #008080">28</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        url</span><span style="color: #000000">=</span><span style="color: #800000">'</span><span style="color: #800000">http://www.renren.com/PLogin.do</span><span style="color: #800000">'</span><span style="color: #000000"><br /></span><span style="color: #008080">29</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        postdata</span><span style="color: #000000">=</span><span style="color: #000000">{<br /></span><span style="color: #008080">30</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />                  </span><span style="color: #800000">'</span><span style="color: #800000">email</span><span style="color: #800000">'</span><span style="color: #000000">:self.email,<br /></span><span style="color: #008080">31</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />                  </span><span style="color: #800000">'</span><span style="color: #800000">password</span><span style="color: #800000">'</span><span style="color: #000000">:self.password,<br /></span><span style="color: #008080">32</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />                  </span><span style="color: #800000">'</span><span style="color: #800000">domain</span><span style="color: #800000">'</span><span style="color: #000000">:self.domain  <br /></span><span style="color: #008080">33</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />                  }<br /></span><span style="color: #008080">34</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        req</span><span style="color: #000000">=</span><span style="color: #000000">urllib2.Request(<br /></span><span style="color: #008080">35</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />                            url,<br /></span><span style="color: #008080">36</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />                            urllib.urlencode(postdata)            <br /></span><span style="color: #008080">37</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />                            )<br /></span><span style="color: #008080">38</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        <br /></span><span style="color: #008080">39</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.file</span><span style="color: #000000">=</span><span style="color: #000000">urllib2.urlopen(req).read()<br /></span><span style="color: #008080">40</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        </span><span style="color: #008000">#</span><span style="color: #008000">print self.file</span><span style="color: #008000"><br /></span><span style="color: #008080">41</span><span style="color: #008000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" /></span><span style="color: #000000">    </span><span style="color: #0000ff">def</span><span style="color: #000000"> start_h3(self,attrs):<br /></span><span style="color: #008080">42</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.h3 </span><span style="color: #000000">=</span><span style="color: #000000"> True<br /></span><span style="color: #008080">43</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />    </span><span style="color: #0000ff">def</span><span style="color: #000000"> end_h3(self):<br /></span><span style="color: #008080">44</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.h3</span><span style="color: #000000">=</span><span style="color: #000000">False<br /></span><span style="color: #008080">45</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.h3_is_ready</span><span style="color: #000000">=</span><span style="color: #000000">True<br /></span><span style="color: #008080">46</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        <br /></span><span style="color: #008080">47</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />    </span><span style="color: #0000ff">def</span><span style="color: #000000"> start_a(self,attrs):<br /></span><span style="color: #008080">48</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        </span><span style="color: #0000ff">if</span><span style="color: #000000"> self.h3 </span><span style="color: #0000ff">or</span><span style="color: #000000"> self.div:<br /></span><span style="color: #008080">49</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            self.a</span><span style="color: #000000">=</span><span style="color: #000000">True<br /></span><span style="color: #008080">50</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />    </span><span style="color: #0000ff">def</span><span style="color: #000000"> end_a(self):<br /></span><span style="color: #008080">51</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        self.a</span><span style="color: #000000">=</span><span style="color: #000000">False<br /></span><span style="color: #008080">52</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        <br /></span><span style="color: #008080">53</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />    </span><span style="color: #0000ff">def</span><span style="color: #000000"> start_div(self,attrs):<br /></span><span style="color: #008080">54</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        </span><span style="color: #0000ff">if</span><span style="color: #000000"> self.h3_is_ready </span><span style="color: #000000">==</span><span style="color: #000000"> False:<br /></span><span style="color: #008080">55</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            </span><span style="color: #0000ff">return</span><span style="color: #000000"><br /></span><span style="color: #008080">56</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        </span><span style="color: #0000ff">if</span><span style="color: #000000"> self.div</span><span style="color: #000000">==</span><span style="color: #000000">True:<br /></span><span style="color: #008080">57</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            self.depth </span><span style="color: #000000">+=</span><span style="color: #000000"> </span><span style="color: #000000">1</span><span style="color: #000000"><br /></span><span style="color: #008080">58</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            <br /></span><span style="color: #008080">59</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        </span><span style="color: #0000ff">for</span><span style="color: #000000"> k,v </span><span style="color: #0000ff">in</span><span style="color: #000000"> attrs:<br /></span><span style="color: #008080">60</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            </span><span style="color: #0000ff">if</span><span style="color: #000000"> k </span><span style="color: #000000">==</span><span style="color: #000000"> </span><span style="color: #800000">'</span><span style="color: #800000">class</span><span style="color: #800000">'</span><span style="color: #000000"> </span><span style="color: #0000ff">and</span><span style="color: #000000"> v </span><span style="color: #000000">==</span><span style="color: #000000"> </span><span style="color: #800000">'</span><span style="color: #800000">content</span><span style="color: #800000">'</span><span style="color: #000000">:<br /></span><span style="color: #008080">61</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />                self.div</span><span style="color: #000000">=</span><span style="color: #000000">True;<br /></span><span style="color: #008080">62</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />                self.h3_and_div</span><span style="color: #000000">=</span><span style="color: #000000">True   </span><span style="color: #008000">#</span><span style="color: #008000">h3 and div is connected</span><span style="color: #008000"><br /></span><span style="color: #008080">63</span><span style="color: #008000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" /></span><span style="color: #000000">    </span><span style="color: #0000ff">def</span><span style="color: #000000"> end_div(self):<br /></span><span style="color: #008080">64</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        </span><span style="color: #0000ff">if</span><span style="color: #000000"> self.depth </span><span style="color: #000000">==</span><span style="color: #000000"> 0:<br /></span><span style="color: #008080">65</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            self.div</span><span style="color: #000000">=</span><span style="color: #000000">False<br /></span><span style="color: #008080">66</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            self.h3_and_div</span><span style="color: #000000">=</span><span style="color: #000000">False<br /></span><span style="color: #008080">67</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            self.h3_is_ready</span><span style="color: #000000">=</span><span style="color: #000000">False<br /></span><span style="color: #008080">68</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            self.names</span><span style="color: #000000">=</span><span style="color: #800000">""</span><span style="color: #000000"><br /></span><span style="color: #008080">69</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        </span><span style="color: #0000ff">if</span><span style="color: #000000"> self.div </span><span style="color: #000000">==</span><span style="color: #000000"> True:<br /></span><span style="color: #008080">70</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            self.depth</span><span style="color: #000000">-=</span><span style="color: #000000">1</span><span style="color: #000000"><br /></span><span style="color: #008080">71</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />    </span><span style="color: #0000ff">def</span><span style="color: #000000"> handle_data(self,text):<br /></span><span style="color: #008080">72</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        </span><span style="color: #008000">#</span><span style="color: #008000">record the name</span><span style="color: #008000"><br /></span><span style="color: #008080">73</span><span style="color: #008000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" /></span><span style="color: #000000">        </span><span style="color: #0000ff">if</span><span style="color: #000000"> self.h3 </span><span style="color: #0000ff">and</span><span style="color: #000000"> self.a:<br /></span><span style="color: #008080">74</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            self.names</span><span style="color: #000000">+=</span><span style="color: #000000">text<br /></span><span style="color: #008080">75</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        </span><span style="color: #008000">#</span><span style="color: #008000">record says</span><span style="color: #008000"><br /></span><span style="color: #008080">76</span><span style="color: #008000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" /></span><span style="color: #000000">        </span><span style="color: #0000ff">if</span><span style="color: #000000"> self.h3 </span><span style="color: #0000ff">and</span><span style="color: #000000"> (self.a</span><span style="color: #000000">==</span><span style="color: #000000">False):<br /></span><span style="color: #008080">77</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            </span><span style="color: #0000ff">if</span><span style="color: #000000"> </span><span style="color: #0000ff">not</span><span style="color: #000000"> text:</span><span style="color: #0000ff">pass</span><span style="color: #000000"><br /></span><span style="color: #008080">78</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            </span><span style="color: #0000ff">else</span><span style="color: #000000">: self.dic.setdefault(self.names,[]).append(text)<br /></span><span style="color: #008080">79</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            </span><span style="color: #0000ff">return</span><span style="color: #000000"> <br /></span><span style="color: #008080">80</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        </span><span style="color: #0000ff">if</span><span style="color: #000000"> self.h3_and_div:<br /></span><span style="color: #008080">81</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            self.dic.setdefault(self.names,[]).append(text)<br /></span><span style="color: #008080">82</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            <br /></span><span style="color: #008080">83</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />    </span><span style="color: #0000ff">def</span><span style="color: #000000"> show(self):<br /></span><span style="color: #008080">84</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        type </span><span style="color: #000000">=</span><span style="color: #000000"> sys.getfilesystemencoding()<br /></span><span style="color: #008080">85</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />        </span><span style="color: #0000ff">for</span><span style="color: #000000"> key </span><span style="color: #0000ff">in</span><span style="color: #000000"> self.dic:<br /></span><span style="color: #008080">86</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />            </span><span style="color: #0000ff">print</span><span style="color: #000000"> ( (</span><span style="color: #800000">''</span><span style="color: #000000">.join(key)).replace(</span><span style="color: #800000">'</span><span style="color: #800000"> </span><span style="color: #800000">'</span><span style="color: #000000">,</span><span style="color: #800000">''</span><span style="color: #000000">)).decode(</span><span style="color: #800000">'</span><span style="color: #800000">utf-8</span><span style="color: #800000">'</span><span style="color: #000000">).encode(type), \<br /></span><span style="color: #008080">87</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />                  ( (</span><span style="color: #800000">''</span><span style="color: #000000">.join(self.dic[key])).replace(</span><span style="color: #800000">'</span><span style="color: #800000"> </span><span style="color: #800000">'</span><span style="color: #000000">,</span><span style="color: #800000">''</span><span style="color: #000000">)).decode(</span><span style="color: #800000">'</span><span style="color: #800000">utf-8</span><span style="color: #800000">'</span><span style="color: #000000">).encode(type)<br /></span><span style="color: #008080">88</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" /><br /></span><span style="color: #008080">89</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" /> <br /></span><span style="color: #008080">90</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" /><br /></span><span style="color: #008080">91</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" /><br /></span><span style="color: #008080">92</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />renrenspider</span><span style="color: #000000">=</span><span style="color: #000000">spider(</span><span style="color: #800000">'</span><span style="color: #800000">your email</span><span style="color: #800000">'</span><span style="color: #000000">,</span><span style="color: #800000">'</span><span style="color: #800000">your password</span><span style="color: #800000">'</span><span style="color: #000000">)<br /></span><span style="color: #008080">93</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />renrenspider.login()<br /></span><span style="color: #008080">94</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />renrenspider.feed(renrenspider.file)<br /></span><span style="color: #008080">95</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" />renrenspider.show()<br /></span><span style="color: #008080">96</span><span style="color: #000000"><img align="top" src="http://www.shnenglu.com/images/OutliningIndicators/None.gif" alt="" /></span></span></div> <p> </p> <img src ="http://www.shnenglu.com/polly-yang/aggbug/190975.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.shnenglu.com/polly-yang/" target="_blank">polly</a> 2012-09-17 14:20 <a href="http://www.shnenglu.com/polly-yang/archive/2012/09/17/190975.html#Feedback" target="_blank" style="text-decoration:none;">鍙戣〃璇勮</a></div>]]></description></item></channel></rss> <footer> <div class="friendship-link"> <p>感谢您访问我们的网站,您可能还对以下资源感兴趣:</p> <a href="http://www.shnenglu.com/" title="精品视频久久久久">精品视频久久久久</a> <div class="friend-links"> </div> </div> </footer> <a href="http://www.kq58.cn" target="_blank">亚洲香蕉网久久综合影视</a>| <a href="http://www.ahzyjlr.cn" target="_blank">国产巨作麻豆欧美亚洲综合久久</a>| <a href="http://www.kbsfrp.cn" target="_blank">国产农村妇女毛片精品久久</a>| <a href="http://www.sj0524.cn" target="_blank">99久久国产综合精品成人影院</a>| <a href="http://www.noahmachine.com.cn" target="_blank">99久久精品免费看国产一区二区三区</a>| <a href="http://www.xiewanliang.cn" target="_blank">久久播电影网</a>| <a href="http://www.goldquote.cn" target="_blank">奇米影视7777久久精品</a>| <a href="http://www.bclife.cn" target="_blank">色综合久久久久</a>| <a href="http://www.brill-sh.com.cn" target="_blank">久久久www免费人成精品</a>| <a href="http://www.gyvgllqc.cn" target="_blank">香蕉久久一区二区不卡无毒影院</a>| <a href="http://www.laopaiwaihui.cn" target="_blank">四虎影视久久久免费观看</a>| <a href="http://www.nlzm.net.cn" target="_blank">久久er国产精品免费观看2</a>| <a href="http://www.4060262.cn " target="_blank">色青青草原桃花久久综合</a>| <a href="http://www.054q.cn" target="_blank">99久久国产综合精品五月天喷水</a>| <a href="http://www.fnhihs.cn" target="_blank">亚洲精品97久久中文字幕无码</a>| <a href="http://www.bjhswt.com.cn" target="_blank">久久久久99精品成人片直播</a>| <a href="http://www.vcyw.cn" target="_blank">日韩欧美亚洲国产精品字幕久久久</a>| <a href="http://www.hfpump.com.cn" target="_blank">亚洲AV无码久久精品狠狠爱浪潮</a>| <a href="http://www.hkzkzs.com.cn" target="_blank">久久久精品国产亚洲成人满18免费网站</a>| <a href="http://www.dqep.cn" target="_blank">亚洲人成精品久久久久</a>| <a href="http://www.lglmhdf.cn" target="_blank">欧美精品福利视频一区二区三区久久久精品 </a>| <a href="http://www.e-ben.cn" target="_blank">99久久精品免费国产大片</a>| <a href="http://www.ltak.cn" target="_blank">久久亚洲精品成人av无码网站</a>| <a href="http://www.raythai.com.cn" target="_blank">精品一久久香蕉国产线看播放 </a>| <a href="http://www.swangxinwen.cn" target="_blank">亚洲中文字幕无码久久精品1</a>| <a href="http://www.566wan.cn" target="_blank">国内精品久久久久久久涩爱</a>| <a href="http://www.japjoy.cn" target="_blank">久久久无码一区二区三区</a>| <a href="http://www.dripnews.cn" target="_blank">精品国产乱码久久久久软件</a>| <a href="http://www.i33b.cn" target="_blank">精品视频久久久久</a>| <a href="http://www.zhangmengm.cn" target="_blank">国产精品内射久久久久欢欢</a>| <a href="http://www.xjdht.cn" target="_blank">久久99精品国产麻豆宅宅 </a>| <a href="http://www.zsputian.com.cn" target="_blank">一本久道久久综合狠狠爱</a>| <a href="http://www.nbblack.cn" target="_blank">怡红院日本一道日本久久 </a>| <a href="http://www.qenw.cn" target="_blank">四虎亚洲国产成人久久精品</a>| <a href="http://www.numakj.cn" target="_blank">久久精品这里热有精品</a>| <a href="http://www.motorbook.com.cn" target="_blank">久久精品亚洲中文字幕无码麻豆</a>| <a href="http://www.u33g.cn" target="_blank">亚洲中文久久精品无码</a>| <a href="http://www.kygg.net.cn" target="_blank">天堂久久天堂AV色综合</a>| <a href="http://www.kongqueyuhn.cn" target="_blank">亚洲va中文字幕无码久久</a>| <a href="http://www.yaojk.cn" target="_blank">久久www免费人成看片</a>| <a href="http://www.jimoge.cn" target="_blank">香蕉久久av一区二区三区</a>| <script> (function(){ var bp = document.createElement('script'); var curProtocol = window.location.protocol.split(':')[0]; if (curProtocol === 'https') { bp.src = 'https://zz.bdstatic.com/linksubmit/push.js'; } else { bp.src = 'http://push.zhanzhang.baidu.com/push.js'; } var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(bp, s); })(); </script> </body>