| Summary: | Bad performance on XY plot with ~200k data points | ||
|---|---|---|---|
| Product: | [Applications] LabPlot2 | Reporter: | chrismettal |
| Component: | frontend | Assignee: | Alexander Semke <alexander.semke> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | martin.marmsoler |
| Priority: | NOR | ||
| Version First Reported In: | unspecified | ||
| Target Milestone: | --- | ||
| Platform: | Arch Linux | ||
| OS: | Linux | ||
| Latest Commit: | https://invent.kde.org/education/labplot/-/merge_requests/407/diffs?commit_id=4c81e0e6ad93bce0bcc3248fcc48498d260ce01b | Version Fixed/Implemented In: | 2.11 |
| Sentry Crash Report: | |||
| Attachments: |
Raw, unmodified source data example
"Broken" plot with infinite ticks |
||
Created attachment 162945 [details]
"Broken" plot with infinite ticks
When I follow your steps it looks fine for me, I have 4 ticks. Did you change also the MajorTicks Type or did it happen automatically? Steps to reproduce: 1) Create Data in Spreadsheet: 200.000 rows, 2 columns 2) Fill first column with rownumber 3) Fill second column with random numbers 4) Create Plot (Plot range is 0...1) 5) Change Axis Spacing to 0.1 6) Add curve to plot Expected: No hang Observed: Hangs (In reply to Martin from comment #2) > When I follow your steps it looks fine for me, I have 4 ticks. Did you > change also the MajorTicks Type or did it happen automatically? This is a fresh install with no changes made to any settings other than changing the default theme to DarkPastels. Reading the theme files, it seems it sets grid/tick styles automatically. Maybe the auto tick limiting doesn't apply after the themes correctly? |
Created attachment 162944 [details] Raw, unmodified source data example SUMMARY Creating an XY plot of a ~200,000 double data points kills performance of LabPlot. One CPU core will get stuck on 100% and almost no interaction will be possible. This seems to be caused by the automatic Y ticks being set to 10 major ticks and 1 minor tick, resulting in one tick per data point, as turning off ticks results in great performance. STEPS TO REPRODUCE 1. Load in example source data as a spreadsheet 2. Remove columns 1 2 and 4 as they contain garbage data 3. Remove lines 1-4 as they contain garbage data 4. Create a new column with row numbers 5. Create an XY Plot with the row numbers on X and the double values on Y OBSERVED RESULT The plot is generated, but is fully "highlighted" with infinite ticks in Y. Labplot basically hardlocks with 100% CPU usage. EXPECTED RESULT The plot is generated and performance stays good. SOFTWARE/OS VERSIONS ``` Debug build Sep 30 2023, 22:50:57 System: Arch Linux Locale: C,Default (Decimal point '.', Group separator ',' Number settings: Decimal point '.', Group separator ',', Exponential 'e', Zero digit '0', Percent '%', Positive/Negative sign '+'/'-' (Updated on restart) Architecture: x86_64-little_endian-lp64 Kernel: linux 6.5.9-arch2-1 C++ Compiler: GNU 13.2.1 C++ Compiler Flags: -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/labplot/src=/usr/src/debug/labplot -flto=auto -fno-operator-names -fno-exceptions -Wall -Wextra -Wcast-align -Wchar-subscripts -Wformat-security -Wno-long-long -Wpointer-arith -Wundef -Wnon-virtual-dtor -Woverloaded-virtual -Werror=return-type -Werror=init-self -Wvla -Wdate-time -Wsuggest-override -Wlogical-op -Wall -Wextra -Wundef -Wpointer-arith -Wunreachable-code -Wunused -Wdeprecated-declarations -fno-omit-frame-pointer -fstack-protector -fexceptions -std=c++11 -O2 -Wcast-align -Wswitch-enum -fvisibility=default -pedantic -Wzero-as-null-pointer-constant ``` ``` -` chrismettal@mainframe .o+` --------------------- `ooo/ OS: Arch Linux x86_64 `+oooo: Host: X670E Steel Legend `+oooooo: Kernel: 6.5.9-arch2-1 -+oooooo+: Uptime: 23 hours, 49 mins `/:-:++oooo+: Packages: 1367 (pacman), 102 (flatpak) `/++++/+++++++: Shell: bash 5.2.15 `/++++++++++++++: Resolution: 3440x1440 `/+++ooooooooooooo/` DE: Plasma 5.27.9 ./ooosssso++osssssso+` WM: KWin .oossssso-````/ossssss+` WM Theme: Breeze -osssssso. :ssssssso. Theme: [Plasma], Dracula [GTK2/3] :osssssss/ osssso+++. Icons: breeze-dark [Plasma], breeze-dark [GTK2/3] /ossssssss/ +ssssooo/- Terminal: konsole `/ossssso+/:- -:/+osssso+- CPU: AMD Ryzen 9 7950X (32) @ 5.881GHz `+sso+:-` `.-/+oso: GPU: AMD ATI 18:00.0 Raphael `++:. `-/+/ GPU: AMD ATI Radeon RX 7900 XT/7900 XTX .` `/ Memory: 10676MiB / 63410MiB ```