锘??xml version="1.0" encoding="utf-8" standalone="yes"?>色综合久久久久综合体桃花网,国产精品99久久久久久董美香,97久久天天综合色天天综合色hdhttp://m.shnenglu.com/cdy20/category/20044.htmlqq錛?86402937 weibo錛?http://weibo.com/caidongyun 鏋舵瀯-寮婧愪氦嫻?167813458 lomox緹わ細41830909 鏇村璧勬枡錛氬井鍒? http://t.cn/zT53Ryw zh-cnWed, 14 Oct 2015 10:44:28 GMTWed, 14 Oct 2015 10:44:28 GMT60Deep Learning (Spark, Caffe, GPU) http://m.shnenglu.com/cdy20/archive/2015/10/14/212013.html钄′笢璧?/dc:creator>钄′笢璧?/author>Wed, 14 Oct 2015 09:25:00 GMThttp://m.shnenglu.com/cdy20/archive/2015/10/14/212013.htmlhttp://m.shnenglu.com/cdy20/comments/212013.htmlhttp://m.shnenglu.com/cdy20/archive/2015/10/14/212013.html#Feedback0http://m.shnenglu.com/cdy20/comments/commentRss/212013.htmlhttp://m.shnenglu.com/cdy20/services/trackbacks/212013.html

from http://docs.continuum.io/anaconda-cluster/examples/spark-caffe

Deep Learning (Spark, Caffe, GPU)

Description

To demonstrate the capability of running a distributed job in PySpark using a GPU, this example uses a neural network library, Caffe. Below is a trivial example of using Caffe on a Spark cluster; although this is redundant, it demonstrates the capability of training neural networks with GPUs.

For this example, we recommend the use of the AMI ami-2cbf3e44 and the instance type g2.2xlarge. An example profile (to be placed in ~/.acluster/profiles.d/gpu_profile.yaml) is shown below:

name: gpu_profile
node_id: ami-2cbf3e44 # Ubuntu 14.04 - IS HVM - Cuda 6.5
user: ubuntu
node_type: g2.2xlarge
num_nodes: 3
provider: aws
plugins:
  - spark-yarn
  - notebook

Download

To execute this example, download the: spark-caffe.py example script or spark-caffe.ipynbexample notebook.

Installation

The Spark + YARN plugin can be installed on the cluster using the following command:

$ acluster install spark-yarn

Once the Spark + YARN plugin is installed, you can view the YARN UI in your browser using the following command:

$ acluster open yarn

Dependencies

First, we need to bootstrap Caffe and its dependencies on all of the nodes. We provide a bash script that will install Caffe from source: bootstrap-caffe.sh. The following command can be used to upload the bootstrap-caffe.sh script to all of the nodes and execute it in parallel:

$ acluster submit bootstrap-caffe.sh --all

After a few minues, Caffe and its dependencies will be installed on the cluster nodes and the job can be started.

Running the Job

Here is the complete script to run the Spark + GPU with Caffe example in PySpark:

# spark-caffe.py from pyspark import SparkConf from pyspark import SparkContext  conf = SparkConf() conf.setMaster('yarn-client') conf.setAppName('spark-caffe') sc = SparkContext(conf=conf)   def noop(x):     import socket     return socket.gethostname()  rdd = sc.parallelize(range(2), 2) hosts = rdd.map(noop).distinct().collect() print hosts   def caffe_process(x):     import os     os.environ['PATH'] = '/usr/local/cuda/bin' + ':' + os.environ['PATH']     os.environ['LD_LIBRARY_PATH'] = '/usr/local/cuda/lib64:/home/ubuntu/pombredanne-https-gitorious.org-mdb-mdb.git-9cc04f604f80/libraries/liblmdb'     import subprocess     proc = subprocess.Popen('cd /home/ubuntu/caffe && bash ./examples/mnist/train_lenet.sh', shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE)     out, err = proc.communicate()     return proc.returncode, out, err  rdd = sc.parallelize(range(2), 2) ret = rdd.map(caffe_process).distinct().collect() print ret 

You can submit the script to the Spark cluster using the submit command.

$ acluster submit spark-caffe.py 

After the script completes, the trained Caffe model can be found at/home/ubuntu/caffe/examples/mnist/lenet_iter_10000.caffemodel on all of the compute nodes.



]]>
鐘舵佹満-銆嬫櫤鑳?璁炬兂1http://m.shnenglu.com/cdy20/archive/2013/01/22/197464.html钄′笢璧?/dc:creator>钄′笢璧?/author>Tue, 22 Jan 2013 05:11:00 GMThttp://m.shnenglu.com/cdy20/archive/2013/01/22/197464.htmlhttp://m.shnenglu.com/cdy20/comments/197464.htmlhttp://m.shnenglu.com/cdy20/archive/2013/01/22/197464.html#Feedback0http://m.shnenglu.com/cdy20/comments/commentRss/197464.htmlhttp://m.shnenglu.com/cdy20/services/trackbacks/197464.html
鏄ㄦ櫄蹇欏畬鏃犺亰鐨勪簨鎯咃紝鎯沖埌浜嗙姸鎬佹満錛屽拰鏅鴻兘銆?br />鍏充簬浣庣瓑鏅鴻兘榪涘寲鐨勪竴涓綋緋葷粨鏋勩傚彲鑳芥湁鐐瑰噷涔憋紝鍏堣涓嬫潵銆?br />

鎴戜滑鐢ㄧ被鏉ユ弿榪?br />
Class
{
鏁版嵁錛?br />銆銆鐘舵佽鍒欍係tate  map or tree
銆銆鐘舵佹満鏈哄埗淇濆瓨銆侲ach State 錛坉ata錛?nbsp;rule錛?nbsp;function錛?br />銆銆
鎿嶄綔錛?br />銆銆
銆銆SateAction(鐜鍙橀噺)
銆銆{
Switch錛坰tate錛?br />{
Case state1錛?br />State1_function();
Break:
Case state2錛?br />State2_function();
Break:
銆銆Defualt:
}
銆銆
銆銆//璁板綍 琛屼負鐘舵?br />銆銆//榪涘寲鎿嶄綔
銆銆}
銆銆
銆銆
銆銆//杈撳叆涓猴細澶栭儴瑙嗛噹 鍐呮垨鑰呮槸 鎰熺煡鑼冨洿 鐜 椹卞姩鏁翠釜瀵硅薄 
銆銆Update()
銆銆{
銆銆}
銆銆
榪涘寲鎿嶄綔錛?br />銆銆//涓嶆柇鍚炲櫖鍏朵粬瀵硅薄鐨?nbsp;鐘舵佹満鎺ュ叆榪涙潵錛岃繛鎺ョ偣涓?nbsp;鍏卞悓鐨勫閮ㄧ幆澧冨彉閲?/span>
銆銆Void Eat(other);
銆銆
銆銆//鑷垜瑙掕壊 鍜岀幆澧?nbsp;璇勪及
銆銆Void Evolution(); //鑷垜鎵╁睍錛屽悇縐嶈繘鍖?nbsp;鏂瑰紡
銆銆
銆銆
//鐘舵佹満鑷垜鎵╁睍鎿嶄綔
銆銆Void EvolutionGo();
銆銆
}



]]>
鍏充簬鏅鴻兘 浜轟笌浜轟箣闂?璇█鍙嶉http://m.shnenglu.com/cdy20/archive/2012/12/26/196676.html钄′笢璧?/dc:creator>钄′笢璧?/author>Wed, 26 Dec 2012 06:25:00 GMThttp://m.shnenglu.com/cdy20/archive/2012/12/26/196676.htmlhttp://m.shnenglu.com/cdy20/comments/196676.htmlhttp://m.shnenglu.com/cdy20/archive/2012/12/26/196676.html#Feedback0http://m.shnenglu.com/cdy20/comments/commentRss/196676.htmlhttp://m.shnenglu.com/cdy20/services/trackbacks/196676.html鍏充簬鏅鴻兘 浜轟笌浜轟箣闂?璇█鍙嶉
鏃╀笂鍏氦杞︿笂闈紝鏀墮煶鏈哄惉鍒板湪璁茶繖涓瘝

淇℃伅錛?/div>
“浣犺繖縐嶄漢”
   
鍋囪緇欎粬涓涓姘?/span>
鑱旀兂鍒扮殑鍏充簬鏅鴻兘涔嬮棿鐨勪氦浜掋?/div>
璇█搴旀縺鎬?/div>
->鍘嗗彶鑳屾櫙 浜х敓鐨勫畾涔?-銆嬪畾涔夋帹鍑哄嚭鏉ョ殑璐箟
->璐箟浜х敓鐨勫巻鍙茶蹇?鎺ㄥ-銆嬭韓浣撳姩鐗╂у彉鍖?/div>
->鍖栧鐗╄川鍙樺寲->鎶戝埗鍒烘縺嬋鍔?娌熼氭帓鏂ワ紝韜綋鍣ㄥ畼媧誨姩絳?鍖呮嫭璇█鍙嶉 澶ц剳鍙嶉 鍏朵粬鍐呰剰鍙嶉
->璁板繂瀛樺偍錛屽巻鍙插簱


]]>鏈哄櫒瀛︿範鐩稿叧鏁版嵁搴?澶囦喚http://m.shnenglu.com/cdy20/archive/2012/10/10/193134.html钄′笢璧?/dc:creator>钄′笢璧?/author>Wed, 10 Oct 2012 11:53:00 GMThttp://m.shnenglu.com/cdy20/archive/2012/10/10/193134.htmlhttp://m.shnenglu.com/cdy20/comments/193134.htmlhttp://m.shnenglu.com/cdy20/archive/2012/10/10/193134.html#Feedback1http://m.shnenglu.com/cdy20/comments/commentRss/193134.htmlhttp://m.shnenglu.com/cdy20/services/trackbacks/193134.html

璧勬枡搴?/h3>

]]>鍏充簬鏅鴻兘鏈鍒濈殑鎯蟲硶http://m.shnenglu.com/cdy20/archive/2012/10/08/192995.html钄′笢璧?/dc:creator>钄′笢璧?/author>Mon, 08 Oct 2012 05:30:00 GMThttp://m.shnenglu.com/cdy20/archive/2012/10/08/192995.htmlhttp://m.shnenglu.com/cdy20/comments/192995.htmlhttp://m.shnenglu.com/cdy20/archive/2012/10/08/192995.html#Feedback0http://m.shnenglu.com/cdy20/comments/commentRss/192995.htmlhttp://m.shnenglu.com/cdy20/services/trackbacks/192995.html
鏈鍒濇病鏈夌煡璇嗚繖涓笢瑗匡紝鏈鍒濅篃娌℃湁浠涔堢煡璇嗕綋緋匯佷漢綾諱駭鍝併?br />
鏈鍒濆氨鏄簲嬋鎬э紝鍚庨潰鐪嬪浜嗭紝鍙戠幇浜嗕竴涓嬪皬鐜╂剰鐨勭幇璞¤寰嬶紝瑙勫緥璁╀綘婊¤凍浜嗘渶鍒濈殑闇姹傜洰鏍囥傚垵鏈熸櫤鑳藉繀欏繪槸綆鍗曠殑鐩爣銆傚湪榪欎釜鑾峰彇綆鍗曠洰鏍囷紝妯′豢銆?br />鍒濇湡宸ュ叿鎻愪緵銆傚浜烘墜鑴氱溂鐫涳紝鏈哄櫒閭d箞灝辨槸鐭ヨ瘑搴撱佺綉緇滄暟鎹噰闆嗐佸垎綾匯佺洰鏍囪В鍐蟲柟妗堢Н绱瓑綆鍗曞伐鍏楓?br />
鍦ㄦ弧瓚寵繖浜涢渶姹傚悗錛屽氨褰㈡垚浜嗗熀紜宸ヤ綔鑳藉姏錛屽熀紜鑾峰彇鐭ヨ瘑鑳藉姏錛屽熀紜杈懼埌綆鍗曠洰鏍囩殑鑳藉姏銆?br />
鍚庨潰灝嗕細鎷ユ湁涓涓簽澶х殑鐜拌薄搴撱傚垎鏋愯繖浜涳紝鎶借薄鍑鴻嚜宸辯殑姒傚康錛屽湪姒傚康鍏寵仈閲岄潰瀵繪壘姒傚康鐨勫叧緋匯?br />鎷ユ湁鏁翠釜涓栫晫鐨勮嫻嬭兘鍔涳紝瀹屽杽鏁翠釜姒傚康鍏崇郴鐨勫艦鎴愩傚彲浠ヤ粠灝忕殑鍒板ぇ鐨勩?br />榪欎釜鏃跺欓渶瑕佷漢綾誨弬涓庡埗瀹氱洰鏍囷紝鎴栬呯敱鏈鍒濈殑鐩爣褰㈡垚澶氫釜瀛愮洰鏍囥傞氳繃榪欎簺鐜拌薄鎺ㄥ瑙e喅鏂規銆傝繃紼嬩笉綆★紝鍙互鏄昏緫鐨勩佷篃鍙互鏄ā緋婄殑絳夌瓑銆?br />
鍏充簬姒傚康鎶借薄鐨勫伐鍏鋒暟鎹寲鎺樼殑宸ュ叿鑱氱被鍒嗙被鐩稿叧鐨勬妧鏈佹蹇靛寲涓緇勭幇璞℃槸鍙互鐨勩?br />鑷充簬姒傚康鍖栧嚭鏉ョ殑錛岃仛綾誨嚭鏉ョ殑姒傚康錛屼綘鍙互闅忔剰鏍囨槑鑻規灉浣犲彲浠ヨ〃紺轟負“X1234”浠繪剰鐨勫敮涓瀹氫箟錛屼綘鍙互璁╀漢綾昏寰楁噦錛屼綘閫氳繃瑙傚療錛岄氳繃浜掕仈緗戞暟鎹垎鏋愩佸浘鍍忓紩鎿庛佷漢綾葷煡璇嗗簱銆傚尮閰嶄綘鐨勭壒寰侊紝鎶借薄鍑烘潵鐨勪笢瑗匡紝鐒跺悗鍙戠幇鏄竴鏍風殑鏈哄櫒浜虹煡閬撶殑x1234 鍘熸潵灝辨槸浜虹被鐨勮嫻鏋溿傘傘傘傘?br />

榪欐牱鐨勭郴緇熻繃浜庡簽澶э紝鍒濇湡鍙兘瑕侀潬宸ㄥ瀷鐨勭緇忕綉緇滈仐浼犵畻娉曠瓑鐢ㄦ潵澶ц妯℃暟鎹仛綾誨垎鏋愶紝褰掔被銆?br />鑷充簬鍏崇郴寤虹珛錛屾殏鏃惰繕娌℃湁濂界殑鍔炴硶錛屽繀欏誨鏌愪竴綾婚昏緫銆佹垚鏋滆繘琛屽叧鑱斿鐞嗐傝繖鏄釜鎸戞垬銆?br />鍏舵瀹炴柦鍙互閫氳繃錛屽皬鐩爣璁懼畾錛岄愭鏋舵瀯澶у瀷緋葷粺鐨勬柟寮忋傚涔犳祴璇曞綊綾伙紝鍙互浠庡皬棰嗗煙鍙戝睍銆?br />



]]>
精品久久久久香蕉网| 婷婷久久精品国产| 97久久国产亚洲精品超碰热| 国产精品久久久久影视不卡 | 久久久久综合中文字幕| 合区精品久久久中文字幕一区| 久久天天躁夜夜躁狠狠| 国产精品99精品久久免费| 久久99国产精品成人欧美| 久久精品中文字幕一区| 精品久久人人爽天天玩人人妻| 亚洲愉拍99热成人精品热久久| 韩国三级大全久久网站| 久久伊人精品一区二区三区| 国产精品久久久久久一区二区三区 | 久久亚洲国产最新网站| 99国产精品久久| 中文字幕热久久久久久久| 国内精品久久久久久久影视麻豆 | 丁香狠狠色婷婷久久综合| 亚洲国产成人久久一区久久| 66精品综合久久久久久久| 亚洲国产精品无码久久久蜜芽| 久久久久99精品成人片牛牛影视| 久久超乳爆乳中文字幕| 亚洲中文字幕无码久久综合网| 亚洲国产香蕉人人爽成AV片久久| 亚洲精品高清久久| 久久精品国产亚洲av日韩| 久久精品亚洲AV久久久无码| 久久久黄色大片| 热久久视久久精品18| 久久午夜综合久久| 久久精品国产国产精品四凭 | 国产巨作麻豆欧美亚洲综合久久| 潮喷大喷水系列无码久久精品| 国产69精品久久久久9999APGF | 色诱久久久久综合网ywww | 国产A三级久久精品| 老色鬼久久亚洲AV综合| 久久精品无码一区二区无码 |