9

When I load a vector with a large number of features into QGIS, the rendering time can become extremely slow. But when I look at my system resources, they all have plenty of excess capacity.

What is the bottleneck that makes the rendering take so long? Is it a question of system resources that for some reason are not being allocated to QGIS?

If it matters I'm currently using an Intel i7 quad core / 16gb ram / NVIDIA gaming GPU / Windows 10.

What I'm trying to figure out is whether it may be possible to speed things up by upgrading hardware?

  • 1
    Not much you can do beside the index (like ahmadhanb answered)as Qgis won´t use your full system resources. It uses only a single core to calculate your data, with little help of the graphic card (don´t no how exactly the tasks are devided but i get around 1-2% load on the graphics processor when loading features). You can set Qgis to use more then one core, but this is only used when you have several layers, as one core is used per layer. – Matte Sep 15 '16 at 5:52
  • 2
    Which dataformat are you using? Where is it stored? – Matthias Kuhn Sep 15 '16 at 10:07
  • Can you do into more detail about which "system resources" you looked at? Does it max out anything? A CPU? I/O? – bugmenot123 Sep 15 '16 at 12:38
  • which version of QGIS are you using? – Steven Kay Sep 15 '16 at 18:02
  • I'm currently using QGIS 2.14.2, but I've found the same to be true for prior versions (at least back to the early 2's). To look at resources, I just opened resource manager and looked at % of CPU, Memory, and Disk usage (not sure how to check GPU or any others I'm missing). The CPU spikes to about 50% on each of the processors while it's rendering. Not sure if that is some sore of allocation limit (in which case, more processsing power might help) or if the bottleneck is something else. – mgalka Sep 22 '16 at 1:07
8

There are two issues you have to consider:

  1. Whether your data has spatial index or not. If not, then try to create a spatial index to your data. The spatial index can improve the speed of rendering your data in QGIS. To create spatial index, go to layer properties -> General tab -> Create Spatial Index, as you can see below:

enter image description here

OR:

You can create spatial index directly from OSGEO4W Shell by adding the following command:

ogrinfo C:\Temp\SHP\TestFeatureName.shp -sql "CREATE SPATIAL INDEX ON TestFeatureName"
  1. Another issue to consider that if you are loading your data from network. Normally loading data from network reduce the rendering time and decrease the performance.
| improve this answer | |
8

Make sure that under Settings -> Options -> Rendering you have "Render layers in parallel" checked.

| improve this answer | |
  • This seems to be a Top Tip, but I wonder, before I email this out to the users that I support, are there drawbacks to checking this? I am presuming that there must be something otherwise this would be switched on as default? – Martin Hügi Mar 25 '17 at 16:17
1

In addition to the other answers, the feature filter legend by map content has serious impacts. From experience, it seems that both the amount of displayed features and the total number of features in the layer have impacts. Using a nation-wide road network classified by "type" (5 values) but displaying a dozen street segments, it is instantaneous when all feature types are displayed and takes a couple of seconds should they are filtered.

--> if it is enabled, try disabling it to improve performances.

Filter legend by map content option is enabled

| improve this answer | |
0

In case you are loading data from a shapefile, a very simple tip, quite obvious but not for me, is to store your files locally.

I was experiencing painful slowness, tried to fix with many of the useful tips I found here and on the internet, but the turning point was to move the folder from the network to my local computer.

Not good practice, but effective.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.