mirror of
https://github.com/geekwenjie/SmartJavaAI.git
synced 2026-09-11 04:08:55 +00:00
人脸识别demo
This commit is contained in:
141
README.md
Normal file
141
README.md
Normal file
@@ -0,0 +1,141 @@
|
|||||||
|
# SmartJavaAI:JAVA深度学习算法工具包
|
||||||
|
|
||||||
|
**SmartJavaAI**是基于 **DJL(Deep Java Library)** 封装的轻量级深度学习算法库,依托DJL的自动模型管理和跨框架特性,**无需安装Python环境**且无需手动下载模型文件(模型由DJL内部自动从云端加载),该库致力于构建Java生态与AI模型之间的高效桥梁。针对Java开发者面临的两大痛点:
|
||||||
|
|
||||||
|
- 🐍 主流AI框架(PyTorch/TensorFlow)的Python生态与Java工程体系割裂
|
||||||
|
|
||||||
|
- ⚙️ 直接使用DJL需处理模型加载、预处理、后处理等复杂技术细节
|
||||||
|
|
||||||
|
我们实现了:
|
||||||
|
✅ **开箱即用** - 两行代码完成人脸检测/识别
|
||||||
|
✅ **多模型支持** - 集成RetinaFace/Ultra-Light-Fast-Generic-Face-Detector双检测模型(即将支持OCR/目标检测)
|
||||||
|
✅ **跨平台兼容** - 完美支持Windows/Linux/macOS系统(x86 & ARM架构)
|
||||||
|
|
||||||
|
## 🌟 核心优势
|
||||||
|
| 维度 | Python生态 | 原生DJL | 本工具包 |
|
||||||
|
|------------|---------------------|-----------------|----------------|
|
||||||
|
| 开发效率 | 需搭建Python环境 | 需实现完整AI Pipeline | 提供即用API |
|
||||||
|
| 学习成本 | 需掌握Python/C++混合编程 | 需深入理解AI框架机制 | Java语法即可调用 |
|
||||||
|
| 部署复杂度 | 需维护多语言服务 | 需处理底层资源调度 | 单一Jar包集成 |
|
||||||
|
| 性能表现 | 原生高性能 | 依赖开发者优化经验 | 内置生产级调优 |
|
||||||
|
|
||||||
|
## 📌 支持功能
|
||||||
|
|
||||||
|
### ✅ 已实现功能
|
||||||
|
|
||||||
|
- **人脸检测**
|
||||||
|
支持图片/视频流中的多面孔定位与质量评估
|
||||||
|
|
||||||
|
- **人脸特征提取**
|
||||||
|
基于深度学习算法生成512维特征向量
|
||||||
|
|
||||||
|
- **人脸特征比对**
|
||||||
|
|
||||||
|
- **人证核验**
|
||||||
|
人脸照片与实时人脸画面特征比对
|
||||||
|
|
||||||
|
### ⌛ 规划中功能
|
||||||
|
|
||||||
|
- **OCR文字识别**
|
||||||
|
即将支持身份证/银行卡/车牌等关键信息提取,适配复杂背景与模糊文本
|
||||||
|
|
||||||
|
- **目标检测**
|
||||||
|
计划集成YOLOv9模型,支持车辆检测/安全帽识别/工业质检等场景
|
||||||
|
|
||||||
|
- **图像分割**
|
||||||
|
|
||||||
|
- **语音识别**
|
||||||
|
基于Transformer的语音转文本引擎,支持中文/英文多语种识别
|
||||||
|
|
||||||
|
|
||||||
|
## 人脸算法模型
|
||||||
|
|
||||||
|
- server模型-**RetinaFace 模型**[[GitHub]](https://github.com/deepinsight/insightface/tree/master/detection/retinaface):一个高效的深度学习人脸检测模型,支持高精度的人脸检测。
|
||||||
|
- 轻量模型-**Ultra-Light-Fast-Generic-Face-Detector-1MB ** [[GitHub\]](https://github.com/Linzaer/Ultra-Light-Fast-Generic-Face-Detector-1MB):一个轻量级的人脸检测模型,适用于需要较低延迟和较小模型尺寸的应用场景。
|
||||||
|
|
||||||
|
## 环境要求
|
||||||
|
|
||||||
|
- Java 版本:**JDK 11或更高版本**
|
||||||
|
- 操作系统:支持的操作系统(如 Windows、Linux 或 macOS)
|
||||||
|
|
||||||
|
## 使用步骤
|
||||||
|
|
||||||
|
📌 **运行提示**:首次启动时将自动完成模型下载及依赖项配置,建议保持网络畅通。初始化完成后,后续启动将恢复毫秒级响应速度。
|
||||||
|
|
||||||
|
无网络环境下可指定本地模型路径(需提前预下载模型包)
|
||||||
|
|
||||||
|
### 1. 安装人脸算法依赖
|
||||||
|
|
||||||
|
在 Maven 项目的 `pom.xml` 中添加 SmartJavaAI的人脸算法依赖:
|
||||||
|
|
||||||
|
```xml
|
||||||
|
<dependencies>
|
||||||
|
<dependency>
|
||||||
|
<groupId>ink.numberone</groupId>
|
||||||
|
<artifactId>smartjavaai-face</artifactId>
|
||||||
|
<version>1.0.0</version>
|
||||||
|
</dependency>
|
||||||
|
</dependencies>
|
||||||
|
```
|
||||||
|
|
||||||
|
### 2. 人脸检测代码示例
|
||||||
|
|
||||||
|
```java
|
||||||
|
//创建人脸算法
|
||||||
|
FaceAlgorithm currentAlgorithm = FaceAlgorithmFactory.createFaceAlgorithm();
|
||||||
|
//使用图片路径检测
|
||||||
|
FaceDetectedResult result = currentAlgorithm.detect("src/main/resources/largest_selfie.jpg");
|
||||||
|
```
|
||||||
|
|
||||||
|
### 3. 轻量人脸检测代码示例
|
||||||
|
|
||||||
|
```java
|
||||||
|
//创建人脸算法
|
||||||
|
FaceAlgorithm currentAlgorithm = FaceAlgorithmFactory.createLightFaceAlgorithm();
|
||||||
|
//使用图片路径检测
|
||||||
|
FaceDetectedResult result = currentAlgorithm.detect("src/main/resources/largest_selfie.jpg");
|
||||||
|
```
|
||||||
|
|
||||||
|
### 4. 使用图片输入流检测
|
||||||
|
|
||||||
|
```java
|
||||||
|
//支持各种输入流方式检测图片
|
||||||
|
File input = new File("src/main/resources/largest_selfie.jpg");
|
||||||
|
FaceDetectedResult result = currentAlgorithm.detect(new FileInputStream(input));
|
||||||
|
```
|
||||||
|
|
||||||
|
### 5. 人证核验
|
||||||
|
|
||||||
|
人证核验步骤:
|
||||||
|
|
||||||
|
(1)提取身份证人脸特征,
|
||||||
|
|
||||||
|
(2)提取实时人脸特征
|
||||||
|
|
||||||
|
(3)特征比对
|
||||||
|
|
||||||
|
```java
|
||||||
|
//创建脸算法
|
||||||
|
FaceAlgorithm currentAlgorithm = FaceAlgorithmFactory.createFaceAlgorithm();
|
||||||
|
//提取身份证人脸特征(图片仅供测试)
|
||||||
|
float[] featureIdCard = currentAlgorithm.featureExtraction("src/main/resources/kana1.jpg");
|
||||||
|
//提取身份证人脸特征(从图片流获取)
|
||||||
|
//File input = new File("src/main/resources/kana1.jpg");
|
||||||
|
//float[] featureIdCard = currentAlgorithm.featureExtraction(new FileInputStream(input));
|
||||||
|
logger.info("身份证人脸特征:{}", JSONObject.toJSONString(featureIdCard));
|
||||||
|
//提取实时人脸特征(图片仅供测试)
|
||||||
|
float[] realTimeFeature = currentAlgorithm.featureExtraction("src/main/resources/kana2.jpg");
|
||||||
|
logger.info("实时人脸特征:{}", JSONObject.toJSONString(realTimeFeature));
|
||||||
|
if(realTimeFeature != null){
|
||||||
|
if(currentAlgorithm.calculSimilar(featureIdCard, realTimeFeature) > 0.8){
|
||||||
|
logger.info("人脸核验通过");
|
||||||
|
}else{
|
||||||
|
logger.info("人脸核验不通过");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
## 快速体验指南
|
||||||
|
|
||||||
|
▌**人脸识别快速运行**
|
||||||
|
`📁 examples/src/main/java/smartai/examples/face`
|
||||||
|
└── 📄[FaceDemo.java](https://github.com/geekwenjie/SmartJavaAI/blob/master/examples/src/main/java/smartai/examples/face/FaceDemo.java) <sub>*(基于JDK11构建的完整可执行示例)*</sub>
|
||||||
@@ -16,6 +16,7 @@
|
|||||||
<exec.mainClass>ai.djl.examples.inference.cv.ObjectDetection</exec.mainClass>
|
<exec.mainClass>ai.djl.examples.inference.cv.ObjectDetection</exec.mainClass>
|
||||||
</properties>
|
</properties>
|
||||||
|
|
||||||
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>commons-cli</groupId>
|
<groupId>commons-cli</groupId>
|
||||||
@@ -42,7 +43,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>ink.numberone</groupId>
|
<groupId>ink.numberone</groupId>
|
||||||
<artifactId>smartjavaai-face</artifactId>
|
<artifactId>smartjavaai-face</artifactId>
|
||||||
<version>1.0.0</version>
|
<version>1.0.1</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ public class FaceDemo {
|
|||||||
|
|
||||||
public static void main(String[] args) {
|
public static void main(String[] args) {
|
||||||
try {
|
try {
|
||||||
//detectFace();
|
detectFace();
|
||||||
//verifyIDCard();
|
//verifyIDCard();
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
@@ -52,9 +52,9 @@ public class FaceDemo {
|
|||||||
FaceDetectedResult result = currentAlgorithm.detect("src/main/resources/largest_selfie.jpg");
|
FaceDetectedResult result = currentAlgorithm.detect("src/main/resources/largest_selfie.jpg");
|
||||||
logger.info("人脸检测结果:{}", JSONObject.toJSONString(result));
|
logger.info("人脸检测结果:{}", JSONObject.toJSONString(result));
|
||||||
//使用图片流检测
|
//使用图片流检测
|
||||||
//File imageFile = new File("/Users/wenjie/Downloads/djl-master/examples/src/test/resources/largest_selfie.jpg");
|
//File input = new File("src/main/resources/largest_selfie.jpg");
|
||||||
//FaceDetectedResult result = currentAlgorithm.detect(new FileInputStream(imageFile));
|
//FaceDetectedResult result = currentAlgorithm.detect(new FileInputStream(input));
|
||||||
File input = new File("src/main/resources/largest_selfie.jpg");
|
//logger.info("人脸检测结果:{}", JSONObject.toJSONString(result));
|
||||||
BufferedImage image = ImageIO.read(input);
|
BufferedImage image = ImageIO.read(input);
|
||||||
//创建保存路径
|
//创建保存路径
|
||||||
Path imagePath = Paths.get("output").resolve("retinaface_detected.jpg");
|
Path imagePath = Paths.get("output").resolve("retinaface_detected.jpg");
|
||||||
@@ -96,8 +96,8 @@ public class FaceDemo {
|
|||||||
//提取身份证人脸特征(图片仅供测试)
|
//提取身份证人脸特征(图片仅供测试)
|
||||||
float[] featureIdCard = currentAlgorithm.featureExtraction("src/main/resources/kana1.jpg");
|
float[] featureIdCard = currentAlgorithm.featureExtraction("src/main/resources/kana1.jpg");
|
||||||
//提取身份证人脸特征(从图片流获取)
|
//提取身份证人脸特征(从图片流获取)
|
||||||
//File imageFile = new File("/Users/wenjie/Downloads/djl-master/examples/src/test/resources/largest_selfie.jpg");
|
//File input = new File("src/main/resources/kana1.jpg");
|
||||||
//float[] featureIdCard = currentAlgorithm.featureExtraction(new FileInputStream(imageFile));
|
//float[] featureIdCard = currentAlgorithm.featureExtraction(new FileInputStream(input));
|
||||||
logger.info("身份证人脸特征:{}", JSONObject.toJSONString(featureIdCard));
|
logger.info("身份证人脸特征:{}", JSONObject.toJSONString(featureIdCard));
|
||||||
//提取实时人脸特征(图片仅供测试)
|
//提取实时人脸特征(图片仅供测试)
|
||||||
float[] realTimeFeature = currentAlgorithm.featureExtraction("src/main/resources/kana2.jpg");
|
float[] realTimeFeature = currentAlgorithm.featureExtraction("src/main/resources/kana2.jpg");
|
||||||
|
|||||||
137
pom.xml
137
pom.xml
@@ -6,8 +6,9 @@
|
|||||||
|
|
||||||
<groupId>ink.numberone</groupId>
|
<groupId>ink.numberone</groupId>
|
||||||
<artifactId>smartjavaai-parent</artifactId>
|
<artifactId>smartjavaai-parent</artifactId>
|
||||||
<version>1.0.0</version>
|
<version>1.0.1</version>
|
||||||
<packaging>pom</packaging>
|
<packaging>pom</packaging>
|
||||||
|
<description>SmartJavaAI</description>
|
||||||
<modules>
|
<modules>
|
||||||
<module>smartjavaai-face</module>
|
<module>smartjavaai-face</module>
|
||||||
<module>smartjavaai-common</module>
|
<module>smartjavaai-common</module>
|
||||||
@@ -16,10 +17,8 @@
|
|||||||
<properties>
|
<properties>
|
||||||
<maven.compiler.source>11</maven.compiler.source>
|
<maven.compiler.source>11</maven.compiler.source>
|
||||||
<maven.compiler.target>11</maven.compiler.target>
|
<maven.compiler.target>11</maven.compiler.target>
|
||||||
<!-- <maven.compiler.source>8</maven.compiler.source>
|
|
||||||
<maven.compiler.target>8</maven.compiler.target>-->
|
|
||||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||||
<djl.version>0.32.0-SNAPSHOT</djl.version>
|
<djl.version>0.32.0</djl.version>
|
||||||
</properties>
|
</properties>
|
||||||
|
|
||||||
<dependencyManagement>
|
<dependencyManagement>
|
||||||
@@ -31,7 +30,20 @@
|
|||||||
<type>pom</type>
|
<type>pom</type>
|
||||||
<scope>import</scope>
|
<scope>import</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>ink.numberone</groupId>
|
||||||
|
<artifactId>smartjavaai-common</artifactId>
|
||||||
|
<version>1.0.1</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>ink.numberone</groupId>
|
||||||
|
<artifactId>smartjavaai-face</artifactId>
|
||||||
|
<version>1.0.1</version>
|
||||||
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
</dependencyManagement>
|
</dependencyManagement>
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<dependency>
|
<dependency>
|
||||||
@@ -52,46 +64,56 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>ai.djl</groupId>
|
<groupId>ai.djl</groupId>
|
||||||
<artifactId>api</artifactId>
|
<artifactId>api</artifactId>
|
||||||
|
<version>${djl.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>ai.djl</groupId>
|
<groupId>ai.djl</groupId>
|
||||||
<artifactId>basicdataset</artifactId>
|
<artifactId>basicdataset</artifactId>
|
||||||
|
<version>${djl.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>ai.djl</groupId>
|
<groupId>ai.djl</groupId>
|
||||||
<artifactId>model-zoo</artifactId>
|
<artifactId>model-zoo</artifactId>
|
||||||
|
<version>${djl.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>ai.djl.timeseries</groupId>
|
<groupId>ai.djl.timeseries</groupId>
|
||||||
<artifactId>timeseries</artifactId>
|
<artifactId>timeseries</artifactId>
|
||||||
|
<version>${djl.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>ai.djl.huggingface</groupId>
|
<groupId>ai.djl.huggingface</groupId>
|
||||||
<artifactId>tokenizers</artifactId>
|
<artifactId>tokenizers</artifactId>
|
||||||
|
<version>${djl.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>ai.djl.audio</groupId>
|
<groupId>ai.djl.audio</groupId>
|
||||||
<artifactId>audio</artifactId>
|
<artifactId>audio</artifactId>
|
||||||
|
<version>${djl.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<!-- MXNet -->
|
<!-- MXNet -->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>ai.djl.mxnet</groupId>
|
<groupId>ai.djl.mxnet</groupId>
|
||||||
<artifactId>mxnet-model-zoo</artifactId>
|
<artifactId>mxnet-model-zoo</artifactId>
|
||||||
|
<version>${djl.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<!-- Pytorch -->
|
<!-- Pytorch -->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>ai.djl.pytorch</groupId>
|
<groupId>ai.djl.pytorch</groupId>
|
||||||
<artifactId>pytorch-model-zoo</artifactId>
|
<artifactId>pytorch-model-zoo</artifactId>
|
||||||
|
<version>${djl.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<!-- TensorFlow -->
|
<!-- TensorFlow -->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>ai.djl.tensorflow</groupId>
|
<groupId>ai.djl.tensorflow</groupId>
|
||||||
<artifactId>tensorflow-model-zoo</artifactId>
|
<artifactId>tensorflow-model-zoo</artifactId>
|
||||||
|
<version>${djl.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<!-- ONNXRuntime -->
|
<!-- ONNXRuntime -->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>ai.djl.onnxruntime</groupId>
|
<groupId>ai.djl.onnxruntime</groupId>
|
||||||
<artifactId>onnxruntime-engine</artifactId>
|
<artifactId>onnxruntime-engine</artifactId>
|
||||||
|
<version>${djl.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.testng</groupId>
|
<groupId>org.testng</groupId>
|
||||||
@@ -107,4 +129,111 @@
|
|||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
|
<url>https://github.com/geekwenjie/SmartJavaAI</url>
|
||||||
|
<licenses>
|
||||||
|
<license>
|
||||||
|
<name>The Apache Software License, Version 2.0</name>
|
||||||
|
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
|
||||||
|
</license>
|
||||||
|
</licenses>
|
||||||
|
|
||||||
|
<build>
|
||||||
|
<plugins>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.sonatype.central</groupId>
|
||||||
|
<artifactId>central-publishing-maven-plugin</artifactId>
|
||||||
|
<version>0.4.0</version>
|
||||||
|
<extensions>true</extensions>
|
||||||
|
<configuration>
|
||||||
|
<publishingServerId>dengwenjie</publishingServerId>
|
||||||
|
<tokenAuth>true</tokenAuth>
|
||||||
|
<deploymentName>${project.groupId}:${project.artifactId}:${project.version}</deploymentName>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-source-plugin</artifactId>
|
||||||
|
<version>3.1.0</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>attach-sources</id>
|
||||||
|
<goals>
|
||||||
|
<goal>jar-no-fork</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-javadoc-plugin</artifactId>
|
||||||
|
<version>3.1.0</version>
|
||||||
|
<configuration>
|
||||||
|
<javadocExecutable>${java.home}/bin/javadoc</javadocExecutable>
|
||||||
|
<doclint>none</doclint>
|
||||||
|
<additionalJOptions>
|
||||||
|
<additionalJOption>-Xdoclint:none</additionalJOption>
|
||||||
|
</additionalJOptions>
|
||||||
|
</configuration>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>attach-javadocs</id>
|
||||||
|
<goals>
|
||||||
|
<goal>jar</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-gpg-plugin</artifactId>
|
||||||
|
<version>3.1.0</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>sign-artifacts</id>
|
||||||
|
<phase>verify</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>sign</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
</build>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<!-- 必须添加:SCM信息 -->
|
||||||
|
<scm>
|
||||||
|
<connection>scm:git:git://github.com/geekwenjie/SmartJavaAI.git</connection>
|
||||||
|
<developerConnection>scm:git:ssh://github.com/geekwenjie/SmartJavaAI.git</developerConnection>
|
||||||
|
<url>http://github.com/geekwenjie/SmartJavaAI/tree/master</url>
|
||||||
|
</scm>
|
||||||
|
|
||||||
|
|
||||||
|
<distributionManagement>
|
||||||
|
<snapshotRepository>
|
||||||
|
<id>dengwenjie</id>
|
||||||
|
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
|
||||||
|
</snapshotRepository>
|
||||||
|
<repository>
|
||||||
|
<id>dengwenjie</id>
|
||||||
|
<url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
|
||||||
|
</repository>
|
||||||
|
</distributionManagement>
|
||||||
|
|
||||||
|
<developers>
|
||||||
|
<developer>
|
||||||
|
<name>dengwenjie</name>
|
||||||
|
<email>775747758@qq.com</email>
|
||||||
|
<roles>
|
||||||
|
<role>Project Manager</role>
|
||||||
|
<role>Architect</role>
|
||||||
|
</roles>
|
||||||
|
</developer>
|
||||||
|
</developers>
|
||||||
|
|
||||||
</project>
|
</project>
|
||||||
|
|||||||
@@ -6,10 +6,18 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>ink.numberone</groupId>
|
<groupId>ink.numberone</groupId>
|
||||||
<artifactId>smartjavaai-parent</artifactId>
|
<artifactId>smartjavaai-parent</artifactId>
|
||||||
<version>1.0.0</version>
|
<version>1.0.1</version>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
<artifactId>smartjavaai-common</artifactId>
|
<artifactId>smartjavaai-common</artifactId>
|
||||||
|
<description>SmartJavaAI</description>
|
||||||
|
<url>https://github.com/geekwenjie/SmartJavaAI</url>
|
||||||
|
<licenses>
|
||||||
|
<license>
|
||||||
|
<name>The Apache Software License, Version 2.0</name>
|
||||||
|
<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
|
||||||
|
</license>
|
||||||
|
</licenses>
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<maven.compiler.source>8</maven.compiler.source>
|
<maven.compiler.source>8</maven.compiler.source>
|
||||||
@@ -17,4 +25,99 @@
|
|||||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||||
</properties>
|
</properties>
|
||||||
|
|
||||||
|
<build>
|
||||||
|
<plugins>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.sonatype.central</groupId>
|
||||||
|
<artifactId>central-publishing-maven-plugin</artifactId>
|
||||||
|
<version>0.4.0</version>
|
||||||
|
<extensions>true</extensions>
|
||||||
|
<configuration>
|
||||||
|
<publishingServerId>dengwenjie</publishingServerId>
|
||||||
|
<tokenAuth>true</tokenAuth>
|
||||||
|
<deploymentName>${project.groupId}:${project.artifactId}:${project.version}</deploymentName>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-source-plugin</artifactId>
|
||||||
|
<version>3.1.0</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>attach-sources</id>
|
||||||
|
<goals>
|
||||||
|
<goal>jar-no-fork</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-javadoc-plugin</artifactId>
|
||||||
|
<version>3.1.0</version>
|
||||||
|
<configuration>
|
||||||
|
<javadocExecutable>${java.home}/bin/javadoc</javadocExecutable>
|
||||||
|
<doclint>none</doclint>
|
||||||
|
<additionalJOptions>
|
||||||
|
<additionalJOption>-Xdoclint:none</additionalJOption>
|
||||||
|
</additionalJOptions>
|
||||||
|
</configuration>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>attach-javadocs</id>
|
||||||
|
<goals>
|
||||||
|
<goal>jar</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-gpg-plugin</artifactId>
|
||||||
|
<version>3.1.0</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>sign-artifacts</id>
|
||||||
|
<phase>verify</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>sign</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
</build>
|
||||||
|
|
||||||
|
<!-- 必须添加:SCM信息 -->
|
||||||
|
<scm>
|
||||||
|
<connection>scm:git:git://github.com/geekwenjie/SmartJavaAI.git</connection>
|
||||||
|
<developerConnection>scm:git:ssh://github.com/geekwenjie/SmartJavaAI.git</developerConnection>
|
||||||
|
<url>http://github.com/geekwenjie/SmartJavaAI/tree/master</url>
|
||||||
|
</scm>
|
||||||
|
|
||||||
|
|
||||||
|
<distributionManagement>
|
||||||
|
<snapshotRepository>
|
||||||
|
<id>dengwenjie</id>
|
||||||
|
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
|
||||||
|
</snapshotRepository>
|
||||||
|
<repository>
|
||||||
|
<id>dengwenjie</id>
|
||||||
|
<url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
|
||||||
|
</repository>
|
||||||
|
</distributionManagement>
|
||||||
|
|
||||||
|
<developers>
|
||||||
|
<developer>
|
||||||
|
<name>dengwenjie</name>
|
||||||
|
<email>775747758@qq.com</email>
|
||||||
|
<roles>
|
||||||
|
<role>Project Manager</role>
|
||||||
|
<role>Architect</role>
|
||||||
|
</roles>
|
||||||
|
</developer>
|
||||||
|
</developers>
|
||||||
|
|
||||||
</project>
|
</project>
|
||||||
|
|||||||
@@ -6,11 +6,11 @@
|
|||||||
<parent>
|
<parent>
|
||||||
<groupId>ink.numberone</groupId>
|
<groupId>ink.numberone</groupId>
|
||||||
<artifactId>smartjavaai-parent</artifactId>
|
<artifactId>smartjavaai-parent</artifactId>
|
||||||
<version>1.0.0</version>
|
<version>1.0.1</version>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
<artifactId>smartjavaai-face</artifactId>
|
<artifactId>smartjavaai-face</artifactId>
|
||||||
<version>1.0.0</version>
|
<version>1.0.1</version>
|
||||||
<name>smartjavaai-face</name>
|
<name>smartjavaai-face</name>
|
||||||
<description>SmartJavaAI</description>
|
<description>SmartJavaAI</description>
|
||||||
<url>https://github.com/geekwenjie/SmartJavaAI</url>
|
<url>https://github.com/geekwenjie/SmartJavaAI</url>
|
||||||
@@ -36,5 +36,107 @@
|
|||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
|
<build>
|
||||||
|
<plugins>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.sonatype.central</groupId>
|
||||||
|
<artifactId>central-publishing-maven-plugin</artifactId>
|
||||||
|
<version>0.4.0</version>
|
||||||
|
<extensions>true</extensions>
|
||||||
|
<configuration>
|
||||||
|
<publishingServerId>dengwenjie</publishingServerId>
|
||||||
|
<tokenAuth>true</tokenAuth>
|
||||||
|
<deploymentName>${project.groupId}:${project.artifactId}:${project.version}</deploymentName>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-source-plugin</artifactId>
|
||||||
|
<version>3.1.0</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>attach-sources</id>
|
||||||
|
<goals>
|
||||||
|
<goal>jar-no-fork</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-javadoc-plugin</artifactId>
|
||||||
|
<version>3.1.0</version>
|
||||||
|
<configuration>
|
||||||
|
<javadocExecutable>${java.home}/bin/javadoc</javadocExecutable>
|
||||||
|
<doclint>none</doclint>
|
||||||
|
<additionalJOptions>
|
||||||
|
<additionalJOption>-Xdoclint:none</additionalJOption>
|
||||||
|
</additionalJOptions>
|
||||||
|
</configuration>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>attach-javadocs</id>
|
||||||
|
<goals>
|
||||||
|
<goal>jar</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-gpg-plugin</artifactId>
|
||||||
|
<version>3.1.0</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>sign-artifacts</id>
|
||||||
|
<phase>verify</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>sign</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
</build>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<!-- 必须添加:SCM信息 -->
|
||||||
|
<scm>
|
||||||
|
<connection>scm:git:git://github.com/geekwenjie/SmartJavaAI.git</connection>
|
||||||
|
<developerConnection>scm:git:ssh://github.com/geekwenjie/SmartJavaAI.git</developerConnection>
|
||||||
|
<url>http://github.com/geekwenjie/SmartJavaAI/tree/master</url>
|
||||||
|
</scm>
|
||||||
|
|
||||||
|
|
||||||
|
<distributionManagement>
|
||||||
|
<snapshotRepository>
|
||||||
|
<id>dengwenjie</id>
|
||||||
|
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
|
||||||
|
</snapshotRepository>
|
||||||
|
<repository>
|
||||||
|
<id>dengwenjie</id>
|
||||||
|
<url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
|
||||||
|
</repository>
|
||||||
|
</distributionManagement>
|
||||||
|
|
||||||
|
<developers>
|
||||||
|
<developer>
|
||||||
|
<name>dengwenjie</name>
|
||||||
|
<email>775747758@qq.com</email>
|
||||||
|
<roles>
|
||||||
|
<role>Project Manager</role>
|
||||||
|
<role>Architect</role>
|
||||||
|
</roles>
|
||||||
|
</developer>
|
||||||
|
</developers>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</project>
|
</project>
|
||||||
|
|||||||
Reference in New Issue
Block a user