From 036565e8a4b93f713a7f9ad0ab910c66ad1cb893 Mon Sep 17 00:00:00 2001 From: Jagadeesh J Date: Tue, 20 Dec 2022 10:58:33 +0530 Subject: [PATCH 1/2] Bump Pytorch to 1.13.0 Signed-off-by: Jagadeesh J --- QuestionAnswering/app/build.gradle | 9 +++++++-- QuestionAnswering/app/src/main/AndroidManifest.xml | 3 ++- QuestionAnswering/build.gradle | 3 +++ 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/QuestionAnswering/app/build.gradle b/QuestionAnswering/app/build.gradle index 6c889bfe..02819626 100644 --- a/QuestionAnswering/app/build.gradle +++ b/QuestionAnswering/app/build.gradle @@ -2,13 +2,13 @@ apply plugin: 'com.android.application' apply plugin: 'kotlin-android' android { - compileSdkVersion 30 + compileSdkVersion 33 buildToolsVersion "30.0.2" defaultConfig { applicationId "org.pytorch.demo.questionanswering" minSdkVersion 28 - targetSdkVersion 30 + targetSdkVersion 33 versionCode 1 versionName "1.0" @@ -35,7 +35,12 @@ dependencies { implementation "androidx.core:core-ktx:1.6.0" implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" + implementation 'com.facebook.fbjni:fbjni-java-only:0.0.3' + implementation 'org.pytorch:pytorch_android_lite:1.10.0' + + // Uncomment below line for using libs built from src + // implementation(name:'pytorch_android-release', ext:'aar') } repositories { mavenCentral() diff --git a/QuestionAnswering/app/src/main/AndroidManifest.xml b/QuestionAnswering/app/src/main/AndroidManifest.xml index a9c59339..d41a6340 100644 --- a/QuestionAnswering/app/src/main/AndroidManifest.xml +++ b/QuestionAnswering/app/src/main/AndroidManifest.xml @@ -9,7 +9,8 @@ android:roundIcon="@mipmap/ic_launcher_round" android:supportsRtl="true" android:theme="@style/AppTheme"> - + diff --git a/QuestionAnswering/build.gradle b/QuestionAnswering/build.gradle index d39eb695..43837892 100644 --- a/QuestionAnswering/build.gradle +++ b/QuestionAnswering/build.gradle @@ -18,6 +18,9 @@ allprojects { repositories { google() jcenter() + flatDir { + dirs 'libs' + } } } From cf6a3ba5bc71fb8e69fe402611c4ece788f71238 Mon Sep 17 00:00:00 2001 From: Jagadeesh J Date: Mon, 30 Jan 2023 08:05:04 +0530 Subject: [PATCH 2/2] change pt version Signed-off-by: Jagadeesh J --- QuestionAnswering/README.md | 2 +- QuestionAnswering/app/build.gradle | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/QuestionAnswering/README.md b/QuestionAnswering/README.md index 8b503615..415648c8 100644 --- a/QuestionAnswering/README.md +++ b/QuestionAnswering/README.md @@ -10,7 +10,7 @@ In this demo app, written in Kotlin, we'll show how to quantize and convert the * PyTorch 1.10.0 or later (Optional) * Python 3.8 (Optional) -* Android Pytorch library org.pytorch:pytorch_android_lite:1.10.0 +* Android Pytorch library org.pytorch:pytorch_android_lite:1.13.0 * Android Studio 4.0.1 or later ## Quick Start diff --git a/QuestionAnswering/app/build.gradle b/QuestionAnswering/app/build.gradle index 02819626..e5d47ad2 100644 --- a/QuestionAnswering/app/build.gradle +++ b/QuestionAnswering/app/build.gradle @@ -37,7 +37,7 @@ dependencies { implementation 'com.facebook.fbjni:fbjni-java-only:0.0.3' - implementation 'org.pytorch:pytorch_android_lite:1.10.0' + implementation 'org.pytorch:pytorch_android_lite:1.13.0' // Uncomment below line for using libs built from src // implementation(name:'pytorch_android-release', ext:'aar')