Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PERF: set text size on resize event, not on paint event, to avoid 100% cpu #604

Merged
merged 5 commits into from
Jun 4, 2024

Conversation

ZLLentz
Copy link
Member

@ZLLentz ZLLentz commented Apr 23, 2024

Description

Move the dynamic text resizing to resize event so it doesn't happen every frame and use the entire cpu

Motivation and Context

https://jira.slac.stanford.edu/browse/ECS-5143

How Has This Been Tested?

Interactively to observe the usage
Tests slightly adjusted so they still pass (previously was looking for the paint event)

Where Has This Been Documented?

Here and in release notes

Pre-merge checklist

  • Code works interactively
  • Code contains descriptive docstrings, including context and API
  • New/changed functions and methods are covered in the test suite where possible
  • Code has been checked for threading issues (no blocking tasks in GUI thread)
  • Test suite passes locally
  • Test suite passes on GitHub Actions
  • Ran docs/pre-release-notes.sh and created a pre-release documentation page
  • Pre-release docs include context, functional descriptions, and contributors as appropriate

@ZLLentz
Copy link
Member Author

ZLLentz commented Apr 23, 2024

This is a draft for now
Robert and I figured this out together
deploying in dev_conda

@ZLLentz ZLLentz changed the title WIP: PERF: set text size on resize event, not on paint event, to avoid 100% cpu PERF: set text size on resize event, not on paint event, to avoid 100% cpu May 31, 2024
@ZLLentz ZLLentz marked this pull request as ready for review May 31, 2024 17:24
@ZLLentz
Copy link
Member Author

ZLLentz commented May 31, 2024

If the tests pass here, then something in #606 is breaking the suite. I have at least one guess already.
If the tests fail here, then there's a more fundamental issue.

@ZLLentz
Copy link
Member Author

ZLLentz commented May 31, 2024

I guess I'll be taking a stab at an independent "fix atef CI tests" PR. I'll start by comparing package versions.

@tangkong
Copy link
Contributor

I guess I'll be taking a stab at an independent "fix atef CI tests" PR. I'll start by comparing package versions.

Do you mean typhos here? Or did something about atef die without me knowing?

@ZLLentz
Copy link
Member Author

ZLLentz commented May 31, 2024

I meant typhos

@ZLLentz ZLLentz requested review from tangkong June 4, 2024 18:17
Copy link
Contributor

@tangkong tangkong left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@ZLLentz ZLLentz merged commit baedbb8 into pcdshub:master Jun 4, 2024
11 checks passed
@ZLLentz ZLLentz deleted the perf_resize_text branch June 4, 2024 19:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants