DeepLearning4J 环境搭建【转】

2018/04/10 10:54
阅读数 321

深度学习Deeplearning4j eclipse 开发环境搭建

eclipse设置deeplearning4j开发环境:手动添加jar包

https://deeplearning4j.org/cn/eclipse

 

 

eclipse maven设置deeplearning4j开发环境

https://depiesml.wordpress.com/2015/08/26/dl4j-gettingstarted/

准备:首先要配置eclipse  maven  以及maven插件

 

1.      创建maven工程:

点击eclipse File->new->other 弹出对话框输入maven

 

点击 Maven Preject  next  选择maven-archtype-quickstart1.1 选择项输入grouptid : com.test  ArtifactID :dl4j  点击finish

2.      修改pom文件

将下边pom内容复制到原来pom中 :

         https://github.com/deeplearning4j/dl4j-examples/blob/master/pom.xml

 pom中添加依赖:

 

[plain] view plain copy
  1. <dependencyManagement>  
  2.         <dependencies>  
  3.             <dependency>  
  4.                 <groupId>org.nd4j</groupId>  
  5.                 <artifactId>nd4j-native-platform</artifactId>  
  6.                 <version>${nd4j.version}</version>  
  7.             </dependency>  
  8.             <dependency>  
  9.                 <groupId>org.nd4j</groupId>  
  10.                 <artifactId>nd4j-cuda-7.5-platform</artifactId>  
  11.                 <version>${nd4j.version}</version>  
  12.             </dependency>  
  13.             <dependency>  
  14.                 <groupId>org.nd4j</groupId>  
  15.                 <artifactId>nd4j-cuda-8.0-platform</artifactId>  
  16.                 <version>${nd4j.version}</version>  
  17.             </dependency>  
  18.         </dependencies>  
  19.     </dependencyManagement>  
  20.   
  21.   
  22.     <dependencies>  
  23.         <!-- ND4J backend. You need one in every DL4J project. Normally define   
  24.             artifactId as either "nd4j-native-platform" or "nd4j-cuda-7.5-platform" -->  
  25.         <dependency>  
  26.             <groupId>org.nd4j</groupId>  
  27.             <artifactId>${nd4j.backend}</artifactId>  
  28.         </dependency>  
  29.   
  30.         <!-- Core DL4J functionality -->  
  31.         <dependency>  
  32.             <groupId>org.deeplearning4j</groupId>  
  33.             <artifactId>deeplearning4j-core</artifactId>  
  34.             <version>${dl4j.version}</version>  
  35.         </dependency>  
  36.   
  37.         <dependency>  
  38.             <groupId>org.deeplearning4j</groupId>  
  39.             <artifactId>deeplearning4j-nlp</artifactId>  
  40.             <version>${dl4j.version}</version>  
  41.         </dependency>  
  42.   
  43.         <!-- deeplearning4j-ui is used for HistogramIterationListener + visualization:   
  44.             see http://deeplearning4j.org/visualization -->  
  45.         <dependency>  
  46.             <groupId>org.deeplearning4j</groupId>  
  47.             <artifactId>deeplearning4j-ui_${scala.binary.version}</artifactId>  
  48.             <version>${dl4j.version}</version>  
  49.         </dependency>  
  50.   
  51.         <!-- Force guava versions for using UI/HistogramIterationListener -->  
  52.         <dependency>  
  53.             <groupId>com.google.guava</groupId>  
  54.             <artifactId>guava</artifactId>  
  55.             <version>${guava.version}</version>  
  56.         </dependency>  
  57.   
  58.         <!-- datavec-data-codec: used only in video example for loading video data -->  
  59.         <dependency>  
  60.             <artifactId>datavec-data-codec</artifactId>  
  61.             <groupId>org.datavec</groupId>  
  62.             <version>${datavec.version}</version>  
  63.         </dependency>  
  64.   
  65.         <!-- Used in the feedforward/classification/MLP* and feedforward/regression/RegressionMathFunctions   
  66.             example -->  
  67.         <dependency>  
  68.             <groupId>jfree</groupId>  
  69.             <artifactId>jfreechart</artifactId>  
  70.             <version>${jfreechart.version}</version>  
  71.         </dependency>  
  72.         <dependency>  
  73.             <groupId>org.jfree</groupId>  
  74.             <artifactId>jcommon</artifactId>  
  75.             <version>${jcommon.version}</version>  
  76.         </dependency>  
  77.   
  78.         <!-- Used for downloading data in some of the examples -->  
  79.         <dependency>  
  80.             <groupId>org.apache.httpcomponents</groupId>  
  81.             <artifactId>httpclient</artifactId>  
  82.             <version>4.3.5</version>  
  83.         </dependency>  
  84.   
  85.     </dependencies>  

3.      更新

右击项目名->Maven ->Update Project

展开阅读全文
打赏
0
0 收藏
分享
加载中
更多评论
打赏
0 评论
0 收藏
0
分享
返回顶部
顶部