Giter VIP home page Giter VIP logo

Comments (30)

desmond206x avatar desmond206x commented on July 20, 2024 1

If you're scrolling past a large number of photos/videos prior you're probably running into high memory usage in the android app and it's getting killed swiping like this.

No. I can open the app, open the first video of two in a row and after swiping to the second video the app crashes immediately.

from immich.

RaulGw4 avatar RaulGw4 commented on July 20, 2024 1

There is not. I couldn't reproduce this issue yet on Android phone Samsung S23

Call me on discord, I will give you access to my phone to view what logs you need.
raul_gw4

from immich.

alextran1502 avatar alextran1502 commented on July 20, 2024

Hello, what is your phone model?

from immich.

alextran1502 avatar alextran1502 commented on July 20, 2024

Also any logs can you grab from the mobile app?

from immich.

carloslockward avatar carloslockward commented on July 20, 2024

@alextran1502
Is a Samsung S22+. Nothing relevant seems to be happening in the logs.

I set the log level to FINEST, cleared the logs and then reproduced the issue.
Here are the logs produced:

2024-06-17 14:44:15.540878 | FINE     | socket_io_client:engine.Socket | flushing 1 packets in socket |
2024-06-17 14:44:15.539720 | FINE     | socket_io_client:engine.Socket | socket receive: type "ping", data "null" |
2024-06-17 14:43:51.747926 | INFO     | AssetNotifier        | Load assets: 1430ms |
2024-06-17 14:43:51.747902 | INFO     | AlbumService         | Syncing completed. Changes: false |
2024-06-17 14:43:51.747890 | FINE     | SyncService          | 0 assets to delete, 0 to update |
2024-06-17 14:43:51.747869 | FINE     | SyncService          | Syncing all local albums almost done. Collected 0 asset candidates to delete |
2024-06-17 14:43:51.747782 | FINE     | SyncService          | Local album Camera has not changed. Skipping sync. |
2024-06-17 14:43:51.709082 | INFO     | AlbumService         | 'Recents' is not selected, keeping only selected albums |
2024-06-17 14:43:51.708979 | INFO     | AlbumService         | Found 54 device albums |
2024-06-17 14:43:50.910340 | INFO     | AlbumService         | Syncing completed. Changes: false |
2024-06-17 14:43:50.910330 | FINE     | SyncService          | 0 assets to delete, 0 to update |
2024-06-17 14:43:50.910317 | FINE     | SyncService          | Syncing all local albums almost done. Collected 0 asset candidates to delete |
2024-06-17 14:43:50.910243 | FINE     | SyncService          | Local album Camera has not changed. Skipping sync. |
2024-06-17 14:43:50.713579 | FINE     | socket_io_client:engine.Socket | socket receive: type "message", data "2["on_new_release",{"isAvailable":false,"checkedAt":"2024-06-17T17:41:56.209Z","serverVersion":{"major":1,"minor":106,"patch":4},"releaseVersion":{"major":1,"minor":106,"patch":4}}]" |
2024-06-17 14:43:50.653247 | FINE     | socket_io_client:engine.Socket | socket receive: type "message", data "2["on_server_version",{"options":{},"loose":false,"includePrerelease":false,"raw":"1.106.4","major":1,"minor":106,"patch":4,"prerelease":[],"build":[],"version":"1.106.4"}]" |
2024-06-17 14:43:50.644386 | FINE     | socket_io_client:engine.Socket | socket receive: type "message", data "0{"sid":"KzrTxYgt647ZBWafAABZ"}" |
2024-06-17 14:43:50.606617 | INFO     | AlbumService         | 'Recents' is not selected, keeping only selected albums |
2024-06-17 14:43:50.596675 | INFO     | AlbumService         | Found 54 device albums |
2024-06-17 14:43:50.548669 | FINE     | socket_io_client:engine.Socket | flushing 1 packets in socket |
2024-06-17 14:43:50.548657 | FINE     | socket_io:parser.Encoder | encoded {type: 0, data: null, nsp: /} as 0 |
2024-06-17 14:43:50.548623 | FINE     | socket_io:parser.Encoder | encoding packet {type: 0, data: null, nsp: /} |
2024-06-17 14:43:50.548614 | FINE     | socket_io_client:Manager | writing packet {type: 0, data: null, nsp: /} |
2024-06-17 14:43:50.548599 | FINE     | socket_io_client:Socket | transport is open - connecting |
2024-06-17 14:43:50.548498 | FINE     | socket_io_client:Manager | cleanup |
2024-06-17 14:43:50.548490 | FINE     | socket_io_client:Manager | open |
2024-06-17 14:43:50.548478 | FINE     | socket_io_client:engine.Socket | socket open |
2024-06-17 14:43:50.548412 | FINE     | socket_io_client:engine.Socket | socket receive: type "open", data "{"sid":"oXtyEqtojXDT0yDnAABY","upgrades":[],"pingInterval":25000,"pingTimeout":20000,"maxPayload":1000000}" |
2024-06-17 14:43:50.293210 | FINE     | socket_io_client:Manager | readyState opening |
2024-06-17 14:43:50.293083 | FINE     | socket_io_client:Manager | connect attempt will timeout after 20000 |
2024-06-17 14:43:50.292884 | FINE     | socket_io_client:engine.Socket | setting transport websocket |
2024-06-17 14:43:50.291578 | FINE     | socket_io_client:engine.Socket | creating transport "websocket" |
2024-06-17 14:43:50.291366 | FINE     | socket_io_client:Manager | opening REDACTED |
2024-06-17 14:43:50.291284 | FINE     | socket_io_client:Manager | readyState closed |
2024-06-17 14:43:50.291104 | FINE     | socket_io_client     | ignoring socket cache for REDACTED |
2024-06-17 14:43:49.415561 | INFO     | ApiService           | Pinging server with response code 200 |

from immich.

alextran1502 avatar alextran1502 commented on July 20, 2024

Thank you, does it crash on every video or just that one specific video?

from immich.

desmond206x avatar desmond206x commented on July 20, 2024

Also happens on my Pixel 7 Android 14.

Only happens while switching from one video to another for me. But every time.

screen-20240617-222215.mp4.2.mp4

from immich.

carloslockward avatar carloslockward commented on July 20, 2024

@alextran1502 I can confirm it only happens when swipping from video to video. I also noticed that this only happens if the videos are on device, if the videos are only on the Immich server it seems it doesnt happen.

from immich.

kt368 avatar kt368 commented on July 20, 2024

I see same bug, Pixel 7* Android 14.
When I sliding from one vide file to another (both files are in my phone locally) Immich app is crashing.
App version 1.106.4,
Server version 1.106.4.
Server run in docker at Centos stream 9.

from immich.

RealJohnGalt avatar RealJohnGalt commented on July 20, 2024

In logcat are you seeing a crash, or is it being lmkd killed? If you're scrolling past a large number of photos/videos prior you're probably running into high memory usage in the android app and it's getting killed swiping like this.

This has been a known issue for me on multiple devices as long as I can remember. Here I can easily hit 6.5-7G app memory usage before it gets killed. As a workaround I only use the app for backups and the website for browsing on android.

from immich.

RealJohnGalt avatar RealJohnGalt commented on July 20, 2024

If you're scrolling past a large number of photos/videos prior you're probably running into high memory usage in the android app and it's getting killed swiping like this.

No. I can open the app, open the first video of two in a row and after swiping to the second video the app crashes immediately.

I'd still check logcat to see if you get a crash trace or if it is killed. It is very inefficient, so killings occur easily and often.

from immich.

desmond206x avatar desmond206x commented on July 20, 2024

Any progress on this? It is really annoying to use the app with this bug

from immich.

alextran1502 avatar alextran1502 commented on July 20, 2024

There is not. I couldn't reproduce this issue yet on Android phone Samsung S23

from immich.

alextran1502 avatar alextran1502 commented on July 20, 2024

Can you guys go into the app settings > advanced > toggle preferences remote image and see if it fixes the issue?

Also, do you guys access your instance over reverse proxy or local IP? Can it be reproduced on local IP?

from immich.

kt368 avatar kt368 commented on July 20, 2024

from immich.

desmond206x avatar desmond206x commented on July 20, 2024

Yeah, same for me. Still chrashing.
Maybe it has something to do with the type of the video? Codec, HDR, ... something like this?

from immich.

alextran1502 avatar alextran1502 commented on July 20, 2024

Do you guys have default encoding options? Can you post your encoding settings if you modified them?

from immich.

kt368 avatar kt368 commented on July 20, 2024

from immich.

RaulGw4 avatar RaulGw4 commented on July 20, 2024

I also have this issue.
I use the default encoding options.

I am running the latest version of Immich both on my server and the phone.

I got a Nothing Phone 2 with Android 14

8mb.video-lrN-1W4r8Xlx.mp4

from immich.

RealJohnGalt avatar RealJohnGalt commented on July 20, 2024

Do you guys have default encoding options? Can you post your encoding settings if you modified them?

I do not use encoding at all. My videos are 80-130mbps h265. I use a reverse proxy but I can recreate on direct local IP also. Here on swiping on videos app memory usage goes crazy and it eventually gets killed (doesn't actually crash). Similar to the memory usage issue from scrolling down photo view in some cases (though that issue seems to be tied to waiting for thumbnails to load, was mostly solved by moving my thumbnails to a nvme).

from immich.

alextran1502 avatar alextran1502 commented on July 20, 2024

I wonder if this is related to your video recording settings. Can you share it so that I can reproduce it?

from immich.

carloslockward avatar carloslockward commented on July 20, 2024

@RealJohnGalt I also use a reverse proxy and I get the issue. I think the reverse proxy is unrelated.

@alextran1502

To recap:

  • My encoding options are the following:
    • CRF: 23
    • Preset: ultrafast
    • Audio codec: AAC
    • Accepted audio codecs: AAC, MP3, and Opus
    • Video codec: H.264
    • Accepted video codec: H.264
    • Target resolution: 720p
    • Max bitrate: 0
    • Threads: 0
    • Transcode policy: Only not in accepted format
    • Tone mapping: Hable
    • Two-pass encoding: off
    • Hardware acceleration:
      • Acc. API: NVENC (I have an NVIDIA GPU)
      • Hardware decoding: off
      • Constant quality mode: auto
      • Temporal AQ: off
      • Preferred hardware device: auto
    • Advanced:
      • Tone mapping NPL: 0
      • Max B-Frames: -1
      • Reference frames: 0
      • Max keyframe interval: 0
  • Something we might have overlooked are Asset Viewer Settings, so here they are:
    • Videos looping: On
    • Load preview image: On
    • Load original image: Off
  • App Version 1.106.3 build.143. Server Version 1.106.4
  • My videos are FHD 60fps.
  • To reproduce the issue:
    • Videos must be backed up on Immich but present on the device (AKA little cloud with checkmark icon)
    • Videos must be adjacent (right next to each other in the timeline)
    • One needs to swipe from one video to the other.

from immich.

RaulGw4 avatar RaulGw4 commented on July 20, 2024

I wonder if this is related to your video recording settings. Can you share it so that I can reproduce it?

Quite interesting.

I have recorded 2 videos with my phone.

When i swipe between them in the immich app it crashes.
But if i delete the files from my phone and use the cloud video it works without issues.

from immich.

RaulGw4 avatar RaulGw4 commented on July 20, 2024

Update

I have installed the latest version of the android app on my phone (1.107.1).
I have recorded 2 new videos and it doesn't seem to happen to those anymore.

BUT!
The old ones still are the same.
I have used the exact same phone, app, settings to record.

screen.mp4

from immich.

carloslockward avatar carloslockward commented on July 20, 2024

Update

I have installed the latest version of the android app on my phone (1.107.1). I have recorded 2 new videos and it doesn't seem to happen to those anymore.

BUT! The old ones still are the same. I have used the exact same phone, app, settings to record.

screen.mp4

@RaulGw4 I think the video might be too short to reproduce the issue! Try recording a longer video maybe 20 seconds at least?

from immich.

RaulGw4 avatar RaulGw4 commented on July 20, 2024

Update

I have installed the latest version of the android app on my phone (1.107.1). I have recorded 2 new videos and it doesn't seem to happen to those anymore.

BUT! The old ones still are the same. I have used the exact same phone, app, settings to record.

screen.mp4

@RaulGw4 I think the video might be too short to reproduce the issue! Try recording a longer video maybe 20 seconds at least?

You are right.

I have recorded 2 new videos that are 20 seconds long and it is happening.

from immich.

desmond206x avatar desmond206x commented on July 20, 2024

I copied two videos from the WhatsApp video folder to my camera folder which syncs with immich.
The videos are on my device and on remote and I can switch between without problems.

So it seems like it really has something to do with the video encoding or something like this.

from immich.

carloslockward avatar carloslockward commented on July 20, 2024

I copied two videos from the WhatsApp video folder to my camera folder which syncs with immich. The videos are on my device and on remote and I can switch between without problems.

So it seems like it really has something to do with the video encoding or something like this.

Whatsapp videos are compressed heavily.

Perhaps is not the video encoding but its size. Which would explain why very short videos also don't have the issue.

from immich.

desmond206x avatar desmond206x commented on July 20, 2024

My app crashed again. But now after 10 minutes of scrolling and viewing images and videos.. I had some issues with not playing videos sometimes and later the app crashed while starting a video. I think there are some major memory leaks and the "fix" here just delays the problem.

from immich.

RealJohnGalt avatar RealJohnGalt commented on July 20, 2024

Maybe just recycler? 🤷‍♂️

Apps like Glimpse don't use more memory no matter period of scrolling. And more loading assets increases memory usage here.

I also still suspect these users aren't getting crashes, rather lmkd kills like me (when app reached ~6G memory usage from scrolling). No logcat excerpts shared though.

from immich.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.