Skip to content
Snippets Groups Projects

Adjust size of figure according to the plots inside to improve performance

Merged Lan Dam requested to merge figure_size_adjustable into master

closes #195 (closed)

closes #158 (closed)

Testing showing that the big starting figure size can slow down performance. This MR will scale down the size of figure by:

  • Using width of screen to be the starting width of figure
  • Using 25 as maximum height of SOH and waveform. This number is selected to make sure all channels are plotted and the height of main_widget is covered to avoid artifact.
  • For TPS, the figure will be created after the figure's height is calculated. This way we don't have to be afraid to set a too big starting height which slow down the processing performance or a too small starting height with cut off plotting data for a long time range (many years) Size of TPS will be adjust based on request to improve performance, and avoid the case TPS is cut off when plotting data for long time range (many years).

Decide to remove ratio_w from label's font size so the font size keep the same for any resolution.

The new method improve the performance for the data set with short time like RT130-sample

old new
SOH 6.9s 2.6s
WF 5.2s 1.3s
TPS 3.2s 0.77s

For the dataset which lasts for many years like 6407.sdr, it has less impact

old new
SOH 39.53s 18.56s
WF 37.26s 16.03s
TPS 44.69s 41.55s
47.73s 45.32s
50.86s 48.93s
Edited by Lan Dam

Merge request reports

Pipeline #3549 passed

Pipeline passed for dc8192cc on figure_size_adjustable

Merged by Lan DamLan Dam 1 year ago (Feb 20, 2024 6:59pm UTC)

Loading

Pipeline #3551 passed

Pipeline passed for 79fa33c6 on master

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
Please register or sign in to reply
Loading