diff --git a/.idea/codeStyles/Project.xml b/.idea/codeStyles/Project.xml
index 455250fa..9624886b 100644
--- a/.idea/codeStyles/Project.xml
+++ b/.idea/codeStyles/Project.xml
@@ -6,6 +6,115 @@
+
+
+
+
+
+
+
+ xmlns:android
+
+ ^$
+
+
+
+
+
+
+
+
+ xmlns:.*
+
+ ^$
+
+
+ BY_NAME
+
+
+
+
+
+
+ .*:id
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ .*:name
+
+ http://schemas.android.com/apk/res/android
+
+
+
+
+
+
+
+
+ name
+
+ ^$
+
+
+
+
+
+
+
+
+ style
+
+ ^$
+
+
+
+
+
+
+
+
+ .*
+
+ ^$
+
+
+ BY_NAME
+
+
+
+
+
+
+ .*
+
+ http://schemas.android.com/apk/res/android
+
+
+ ANDROID_ATTRIBUTE_ORDER
+
+
+
+
+
+
+ .*
+
+ .*
+
+
+ BY_NAME
+
+
+
+
+
diff --git a/.idea/misc.xml b/.idea/misc.xml
index 25f24431..dcecd355 100644
--- a/.idea/misc.xml
+++ b/.idea/misc.xml
@@ -33,7 +33,7 @@
-
+
diff --git a/README.md b/README.md
index d38729da..efbabb9d 100644
--- a/README.md
+++ b/README.md
@@ -2,7 +2,7 @@
[](https://jitpack.io/#devzwy/open_nsfw_android) [](https://github.com/devzwy/open_nsfw_android) [](https://www.apache.org/licenses/LICENSE-2.0)
[](https://github.com/devzwy/open_nsfw_android) [](https://github.com/devzwy/KUtils) [](https://github.com/devzwy/open_nsfw_android) [](https://github.com/devzwy/open_nsfw_android) 
-### 色情图片离线识别,基于TensorFlow实现。识别只需200ms,可断网测试,成功率99%,调用只要一行代码,从雅虎的开源项目open_nsfw移植,tflite(6M)为训练好的模型(已量化),该模型文件可用于iOS、java、C++等平台,Python使用生成的tfLite文件检测图片的速度远远快于实用原模型.
+### 色情图片离线识别,基于TensorFlow实现。识别只需200ms,可断网测试,成功率99%,调用只要一行代码,从雅虎的开源项目open_nsfw移植,tflite(6M)为训练好的模型(已量化),该模型文件可用于iOS、java、C++等平台,Python使用生成的tfLite文件检测图片的速度远远快于使用原模型.
### 页面最底部有测试Demo和效果图片,请勿在公共场所打开。
### 使用
diff --git a/app/build.gradle b/app/build.gradle
index 37c250ee..9f417ea2 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -8,7 +8,7 @@ android {
compileSdkVersion 28
defaultConfig {
applicationId "com.example.open_nsfw_android"
- minSdkVersion 15
+ minSdkVersion 19
targetSdkVersion 28
versionCode 5
versionName "1.2.8"
@@ -23,6 +23,12 @@ android {
aaptOptions {
noCompress "tflite"
}
+
+ //添加
+ compileOptions {
+ sourceCompatibility JavaVersion.VERSION_1_8
+ targetCompatibility JavaVersion.VERSION_1_8
+ }
}
dependencies {
@@ -36,8 +42,8 @@ dependencies {
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
- implementation 'com.github.CymChad:BaseRecyclerViewAdapterHelper:2.9.30'
- implementation 'com.github.LuckSiege.PictureSelector:picture_library:v2.2.3'
+ implementation 'com.github.CymChad:BaseRecyclerViewAdapterHelper:2.9.50'
+ implementation 'com.github.LuckSiege.PictureSelector:picture_library:2.2.5'
implementation project(path: ':nsfw')
// implementation 'com.github.devzwy:open_nsfw_android:1.2.7'
}
diff --git a/build.gradle b/build.gradle
index 157668c3..71d0b7fc 100644
--- a/build.gradle
+++ b/build.gradle
@@ -1,14 +1,14 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
- ext.kotlin_version = '1.3.41'
+ ext.kotlin_version = '1.3.50'
repositories {
google()
jcenter()
}
dependencies {
- classpath 'com.android.tools.build:gradle:3.4.2'
+ classpath 'com.android.tools.build:gradle:3.5.1'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties
index 4e6cfee8..e3ed1cb0 100644
--- a/gradle/wrapper/gradle-wrapper.properties
+++ b/gradle/wrapper/gradle-wrapper.properties
@@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
-distributionUrl=https\://services.gradle.org/distributions/gradle-5.1.1-all.zip
+distributionUrl=https\://services.gradle.org/distributions/gradle-5.4.1-all.zip
diff --git a/nsfw/build.gradle b/nsfw/build.gradle
index f5b95b8b..8e75d05d 100644
--- a/nsfw/build.gradle
+++ b/nsfw/build.gradle
@@ -6,7 +6,7 @@ android {
compileSdkVersion 28
defaultConfig {
- minSdkVersion 15
+ minSdkVersion 19
targetSdkVersion 28
versionCode 5
versionName "1.2.8"
@@ -32,8 +32,8 @@ dependencies {
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
- implementation 'org.tensorflow:tensorflow-lite:+'
- implementation 'org.tensorflow:tensorflow-lite-gpu:+'
+ implementation 'org.tensorflow:tensorflow-lite:1.14.0'
+ implementation 'org.tensorflow:tensorflow-lite-gpu:1.14.0'
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
}
repositories {