Get the App
SLTechnology News&Howtos  ›  Development  › 

How to implement a photo translation Mini Program in Android

Shulou Source: shulou.com Published: 2022-05-31 23:51:03 09月21日 Update

Today, the editor will share with you the relevant knowledge points about how to achieve a photo translation of Mini Program in Android. The content is detailed and the logic is clear. I believe most people still know too much about this knowledge, so share this article for your reference. I hope you can get something after reading this article. Let's learn about it together.

1 Development preparation

Due to the use of cloud-side services,    needs to register a developer account with Huawei's developer Alliance and activate these services in the cloud. We will not go into details here, just follow the official AppGallery Connect configuration and activation steps:

   is a registered developer. For more information on activating the service, please click:

1.1 add Huawei maven warehouse to project-level gradle

Open the AndroidStudio project-level build.gradle file.

  

Incrementally add the following maven address:

Buildscript {repositories {maven {url 'http://developer.huawei.com/repo/'} allprojects {repositories {maven {url' http://developer.huawei.com/repo/'} 1.2 add SDK dependencies to the application-level build.gradle

   integrates SDK. (due to the use of cloud-side capabilities, only the SDK basic package can be introduced)

Dependencies {implementation 'com.huawei.hms:ml-computer-vision:1.0.2.300' implementation' com.huawei.hms:ml-computer-translate:1.0.2.300'} 1.3 apply for camera and storage permissions in the AndroidManifest.xml file

   to enable the application to automatically update the latest machine learning model to the user device after the user installs your application from Huawei App Store, add the following statement to the application's AndroidManifest.xml file:

Tags: Text program application development file knowledge article service content analyzer application developer permission translator Huawei analysis detection can pass method step Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno OPPO Reno Shulou Technology Shulou Information Microsoft Redmi