Jump to content

Photos thumbnails slow to generate


Recommended Posts

Posted (edited)

Hi,

 

I try to use emby 4.0.0.2 to access my photo library, but the UI is very slow to display thumbnail (web or android) make it unusable. I run it on a ds216+. I tried to put data folder to another drive and cache folder also. It seems emby generate thumbnail on demand when an UI want one. 

 

Is it possible to pre-generate all thumbnails?

 

Thanks,

Edited by matlaf
Posted

Hi there, can you please attach the emby server log? Thanks !

Posted

Hi there, if you go back and browse the same folders as you did earlier, from the same browser, are they still slow?

Posted

Hello @@matlaf

 

Thanks for the logs, nothing is jumping out immediately.

 

Were you running Emby Server prior to version 4.0 on this system? If so, was it working ok then?

 

Best

- James

Posted

Hi,

 

I tried the same setup with 3.6 but stop my test because the same problem. I was waiting version 4 for the performance improvement you announce.

 

If I go to a folder for the first time, no thumbnail are displayed. I see synology working and thumbnail display after some time. With my test, for 10 thumbnails, the time is between 30s to 1m. If I scroll down the page the next 10 thumbnails are generated with the same time. If I return to the same folder some of the thumbnails are displayed instantly but not all. 

 

This behavior can be ok for small photo collection but my folder have 2000 photos and 40 000 for all my collection. 30s per 10 photos, 2000 photos, so 1h and more to be able to scroll down without lag.

 

Have you a solution?

Posted

What kind of photos are these?

Posted

Kind? It is 2 to 6 MP photo from digital camera. 2MP photos are faster than 6 MP to display.

Posted (edited)

Hello @@matlaf

 

I've trawled through the logs again and for the most part, images are being processed reasonably quickly (i.e. tens of milliseconds) and in line with expectations for the processor in your system.

 

However, there are the occasional images that take significantly longer - around 30s, and I suspect it is these that are causing the overall lack of responsiveness being reported.

 

e.g.

2019-01-17 19:15:05.473 Info HttpServer: HTTP GET http://192.168.1.189:8096/emby/Items/13465/Images/Primary?maxWidth=900&tag=57eaddbb9a1754a3db1fc4b6d7a2d061&quality=90. UserAgent: Mozilla/5.0 (Linux; Android 8.0.0; SM-G935W8 Build/R16NW; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/71.0.3578.99 Safari/537.36

2019-01-17 19:15:33.947 Info HttpServer: HTTP Response 200 to 192.168.1.230. Time: 28474ms. http://192.168.1.189:8096/emby/Items/13465/Images/Primary?maxWidth=900&tag=57eaddbb9a1754a3db1fc4b6d7a2d061&quality=90
2019-01-17 19:15:05.474 Info HttpServer: HTTP GET http://192.168.1.189:8096/emby/Items/13467/Images/Primary?maxWidth=900&tag=712299f5115a8fc926b12ac617eba5f9&quality=90. UserAgent: Mozilla/5.0 (Linux; Android 8.0.0; SM-G935W8 Build/R16NW; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/71.0.3578.99 Safari/537.36

2019-01-17 19:15:34.880 Info HttpServer: HTTP Response 200 to 192.168.1.230. Time: 29399ms. http://192.168.1.189:8096/emby/Items/13467/Images/Primary?maxWidth=900&tag=712299f5115a8fc926b12ac617eba5f9&quality=90

Is there anything you can tell us about these images? How do they differ from other images in the folder?

 

To see an example image in question, put the following in your web browser:-

http://192.168.1.189:8096/emby/Items/13467/Images/Primary?maxWidth=900&tag=712299f5115a8fc926b12ac617eba5f9&quality=90

Best

- James

Edited by solabc16
Posted

Hi,

 

I check some images but see no difference.

 

I check this example :

 

HTTP Response 200 to 192.168.1.99. Time: 36700ms. http://lafsto:8096/emby/Items/13500/Images/Primary?maxWidth=336&tag=3063c5669a3c8aec5f23ffbd2227f737&quality=90

HTTP Response 200 to 192.168.1.99. Time: 2754ms. http://lafsto:8096/emby/Items/13522/Images/Primary?maxWidth=336&tag=f40c12afc71f962c2164dcfaf9f19e06&quality=90

 

These two images are exactly the same format take on same camera same moment.

 

I suspect the number of thumbnail processed in parallel to have an impact but it's not clear because the NAS processor and ram not go to 100%.

 

I made another test and 20 images take 5 minutes to get thumbnails generated.

 

The problem is really that this process is live when browsing photo. I understand that the NAS processor have limits. But these limits are far less important if thumbnail get generated on background task.

 

Is there an API to force thumbnail generation?

Posted

There's no API to do that. We will look into improving this, thanks.

Posted

Hello @@matlaf

 

Thanks for the additional information, there is certainly something we need to understand and get to the bottom of here.

 

Your system should be able to handle this in a timely fashion and there must be a reason for the significant variations in the times taken.

 

I made another test and 20 images take 5 minutes to get thumbnails generated.

 

 

Can you attached the Emby Server log that contains this test, as that's an average of 15s per image and again, clearly not in line with expectation.

 

I also understand your point about having this done in the background, it's a good suggestion.

 

Best

- James

Posted

Here the logs. You can see the test around 10:40.

Posted

Hi there, did you forget to attach the logs?

Posted

What CPU does this have?

Posted

Thanks for the logs @@matlaf. I see the entries your referring to, at 90+ seconds something else must be at play here.

 

Are you seeing the CPU pegged at 100% whilst this is happening?

 

Also, are there a handful of non-personal images you could share via a PM, so I can run some tests here?

2019-01-20 21:12:02.383 Info HttpServer: HTTP GET http://lafsto:8096/emby/Items/13574/Images/Primary?maxWidth=336&tag=fc037afd60649af59e57594198374781&quality=90. UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36
2019-01-20 21:13:32.953 Info HttpServer: HTTP Response 200 to 192.168.1.99. Time: 90570ms. http://lafsto:8096/emby/Items/13574/Images/Primary?maxWidth=336&tag=fc037afd60649af59e57594198374781&quality=90

2019-01-20 21:12:02.386 Info HttpServer: HTTP GET http://lafsto:8096/emby/Items/13575/Images/Primary?maxWidth=336&tag=a5ea6f7cf5df2f02c7a43c371a8501ca&quality=90. UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36
2019-01-20 21:13:32.963 Info HttpServer: HTTP Response 200 to 192.168.1.99. Time: 90577ms. http://lafsto:8096/emby/Items/13575/Images/Primary?maxWidth=336&tag=a5ea6f7cf5df2f02c7a43c371a8501ca&quality=90

2019-01-20 21:12:02.390 Info HttpServer: HTTP GET http://lafsto:8096/emby/Items/13576/Images/Primary?maxWidth=336&tag=31fa1afb563b1fcc438836bae1f3d0b2&quality=90. UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36
2019-01-20 21:13:32.984 Info HttpServer: HTTP Response 200 to 192.168.1.99. Time: 90595ms. http://lafsto:8096/emby/Items/13576/Images/Primary?maxWidth=336&tag=31fa1afb563b1fcc438836bae1f3d0b2&quality=90

2019-01-20 21:12:02.394 Info HttpServer: HTTP GET http://lafsto:8096/emby/Items/13577/Images/Primary?maxWidth=336&tag=4b3a0172ede1e40c418cbeefe544edbe&quality=90. UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36
2019-01-20 21:13:32.900 Info HttpServer: HTTP Response 200 to 192.168.1.99. Time: 90488ms. http://lafsto:8096/emby/Items/13577/Images/Primary?maxWidth=336&tag=4b3a0172ede1e40c418cbeefe544edbe&quality=90

2019-01-20 21:12:02.395 Info HttpServer: HTTP GET http://lafsto:8096/emby/Items/13578/Images/Primary?maxWidth=336&tag=6542a86e3f1491921b2f82799094d3da&quality=90. UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36
2019-01-20 21:13:35.889 Info HttpServer: HTTP Response 200 to 192.168.1.99. Time: 93494ms. http://lafsto:8096/emby/Items/13578/Images/Primary?maxWidth=336&tag=6542a86e3f1491921b2f82799094d3da&quality=90

2019-01-20 21:12:02.397 Info HttpServer: HTTP GET http://lafsto:8096/emby/Items/13579/Images/Primary?maxWidth=336&tag=9264dc6fd36fda728172e7a413c57cf3&quality=90. UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/71.0.3578.98 Safari/537.36
2019-01-20 21:13:32.954 Info HttpServer: HTTP Response 200 to 192.168.1.99. Time: 90557ms. http://lafsto:8096/emby/Items/13579/Images/Primary?maxWidth=336&tag=9264dc6fd36fda728172e7a413c57cf3&quality=90

The processor in the DS216+ is an Intel Celeron N3050, so that shouldn't be a factor here; at least not with respect to processing times we're seeing reported here.

 

Best

- James

Posted

I sent you private mesage.

 

Thanks,

Posted

Thanks @@matlaf, I will look at this further next week.

 

Best

- James

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...