Skip to content

Developer mode

ShiftHackZ edited this page Aug 13, 2024 · 2 revisions

❗️ Introduced since version 0.6.3

Features

Debugging

  • View logs: allows to view logs of SDAI app without adb/Android Studio.
  • Clear all logs: removes logs file from SDAI app internal storage.

Work Manager API

Contains functions related to managing SDAI app Workers.

Documentation: https://developer.android.com/topic/libraries/architecture/workmanager

  • Restart last txt2img task: schedules new work request of TextToImageTask with last cached binary payload.
  • Restart last img2img task: schedules new work request of ImageToImageTask with last cached binary payload.
  • Cancel all workers: cancels all work requests.

Local Diffusion

Contains functions related to managing Local Diffusion.

  • Restart last txt2img task: if enabled will show "Cancel" button for loading modal (foreground mode) or on push-notification (background mode).
❗️ Canceling Local Diffusion generation leads to memory leaks / fatal crashes in libc library in onnx-runtime library.
Can not be handled in Java/Kotlin code.
  • Process scheduler: selects scheduler thread that is used by Local Diffusion to operate on.
    • Main Thread: should never be used with Local Diffusion ❗️
    • I/O Thread: Input/Output background thread.
    • Computation: default option, used for high-workload tasks.
    • Single Thread: allows to operate on a single synchronized thread.

QA Actions

Contains set of functions to test some runtime behavior scenarios that SDAI app should handle.

  • Insert bad Base64 in DB: adds generation result to gallery with base64 value that can not be parsed, expected that gallery does not crash and displays fallback bitmap in this case.

How to enter developer mode

  • Open SDAI application.
  • Navigate to the "Settings" tab.
  • Scroll to the bottom of the page.
  • Click "Version" text 7 times.

Screenshots

image image

Clone this wiki locally