On 7/30/2022 6:36 PM, Greg Troxel via Qgis-user wrote:
I do understand that threads could help parallelization, eitehr using
multiple cores, or just allowing IO in parallel.

chris hermansen <clherman...@gmail.com> writes:

Does it seem like you have one thread per layer for reading plus one for
rendering plus one for user  input?
I don't know how many layers I have :-)    I can experiment with some
smaller projects.

When I noticed this, I had not tried to use qgis in at least a day.


I did a little bit of quick experimentation using Qgis 3.26 (Buenos Aires) on Windows 10. The number of threads is all over the place. It does not seem to be tied to the number of layers in the map, at least in the sense of steady state (ie, let the app sit idle for a while). Adding layers bumps the thread count, with shapefiles adding more threads than files in a geopkg. Locally stored geotiffs are more like a geopkg vector file in terms of threads. But once things settle down I end up around 20 threads. Interestingly, Help->About bumped the thread count by 8. Closing a project (not saving) and then opening a "new" project (no template) bumped another 8 threads for about 30 seconds, then settled back down.Launching Qgis peaked at 30 threads, then after about it minute settles down to 14. I suspect this is dependent on which plug-ins I'm running.

Note these numbers are non-deterministic - Help->About on a fresh start of Qgis with an empty project jumped from 13 threads to 33, then settled down to 22, which is different from the previous attempt where there were open layers in the map.

I'll be interested to hear what drives the thread count to > 150 . None of my very limited test involved database connections or connections to remote data. Those might have something to do with it. Maybe layer filters? Complex rendering (eg, geometry generators)?
_______________________________________________
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

Reply via email to