Skip to content

Commit

Permalink
Merge pull request google-ai-edge#23 from googlesamples/alpha4
Browse files Browse the repository at this point in the history
Updated dependencies to alpha-4, updated options for image classifica…
  • Loading branch information
PaulTR committed Dec 2, 2022
2 parents 10b15cb + f99aecc commit 7501ba3
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 10 deletions.
2 changes: 1 addition & 1 deletion examples/gesture_recognizer/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -98,5 +98,5 @@ dependencies {
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'

// Mediapipe Library
implementation 'com.google.mediapipe:tasks-vision:0.1.0-alpha-3'
implementation 'com.google.mediapipe:tasks-vision:0.1.0-alpha-4'
}
2 changes: 1 addition & 1 deletion examples/hand_landmarker/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -95,5 +95,5 @@ dependencies {
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'

// MediaPipe Library
implementation 'com.google.mediapipe:tasks-vision:0.1.0-alpha-3'
implementation 'com.google.mediapipe:tasks-vision:0.1.0-alpha-4'
}
2 changes: 1 addition & 1 deletion examples/image_classification/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -107,5 +107,5 @@ dependencies {
androidTestImplementation 'androidx.test.ext:junit:1.1.3'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'

implementation 'com.google.mediapipe:tasks-vision:0.1.0-alpha-3'
implementation 'com.google.mediapipe:tasks-vision:0.1.0-alpha-4'
}
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,6 @@ class ImageClassifierHelper(
// the GPU delegate needs to be used on the thread that initialized the
// classifier
fun setupImageClassifier() {
val classifierOptions = ClassifierOptions.builder()
.setMaxResults(maxResults)
.setScoreThreshold(threshold)
.build()

val baseOptionsBuilder = BaseOptions.builder()
when (currentDelegate) {
DELEGATE_CPU -> {
Expand Down Expand Up @@ -112,7 +107,8 @@ class ImageClassifierHelper(
val baseOptions = baseOptionsBuilder.build()
val optionsBuilder =
ImageClassifier.ImageClassifierOptions.builder()
.setClassifierOptions(classifierOptions)
.setScoreThreshold(threshold)
.setMaxResults(maxResults)
.setRunningMode(runningMode)
.setBaseOptions(baseOptions)

Expand Down
2 changes: 1 addition & 1 deletion examples/object_detection/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -116,5 +116,5 @@ dependencies {
androidTestImplementation "androidx.test:runner:1.4.0"
androidTestImplementation "androidx.test.espresso:espresso-core:3.4.0"

implementation 'com.google.mediapipe:tasks-vision:0.1.0-alpha-2'
implementation 'com.google.mediapipe:tasks-vision:0.1.0-alpha-4'
}

0 comments on commit 7501ba3

Please sign in to comment.