Skip to content

Commit

Permalink
+ Changed ML DownloadType
Browse files Browse the repository at this point in the history
  • Loading branch information
null2264 committed Jun 9, 2022
1 parent ced6bf4 commit 880c8d0
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,11 @@ class ScannerActivity : AppCompatActivity() {

private fun doPrediction(bitmap: Bitmap) {
FirebaseModelDownloader.getInstance()
.getModel("CancerDetector", DownloadType.LATEST_MODEL, CustomModelDownloadConditions.Builder().build())
.getModel(
"CancerDetector",
DownloadType.LOCAL_MODEL_UPDATE_IN_BACKGROUND,
CustomModelDownloadConditions.Builder().build(),
)
.addOnSuccessListener { model ->
val modelFile = model?.file ?: return@addOnSuccessListener
val interpreter = Interpreter(modelFile)
Expand Down

0 comments on commit 880c8d0

Please sign in to comment.