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

Change runtime.py to choose tasks with lowest (instead of highest) priority #505

Merged
merged 6 commits into from
Sep 7, 2022

Conversation

justheuristic
Copy link
Member

Found by @GreenFatGuy
Currently, the priority is set to the timestamp of the earliest undispatched task.
Choosing earliest tasks will reduce the maximum waiting time when queue is nonempty

@justheuristic justheuristic requested a review from mryab September 6, 2022 21:17
@codecov
Copy link

codecov bot commented Sep 6, 2022

Codecov Report

Merging #505 (c241505) into master (41587e4) will decrease coverage by 0.16%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master     #505      +/-   ##
==========================================
- Coverage   86.35%   86.19%   -0.17%     
==========================================
  Files          81       81              
  Lines        7887     7887              
==========================================
- Hits         6811     6798      -13     
- Misses       1076     1089      +13     
Impacted Files Coverage Δ
hivemind/moe/server/runtime.py 75.00% <100.00%> (ø)
hivemind/moe/server/task_pool.py 41.33% <100.00%> (ø)
hivemind/dht/node.py 91.46% <0.00%> (-1.19%) ⬇️
hivemind/optim/progress_tracker.py 97.80% <0.00%> (-1.10%) ⬇️
hivemind/averaging/matchmaking.py 87.76% <0.00%> (-0.90%) ⬇️
hivemind/utils/asyncio.py 99.21% <0.00%> (-0.79%) ⬇️
hivemind/averaging/averager.py 87.55% <0.00%> (-0.48%) ⬇️

@justheuristic justheuristic merged commit 6395e89 into master Sep 7, 2022
@justheuristic justheuristic deleted the pool-priority-reverse branch September 7, 2022 15:17
mryab pushed a commit that referenced this pull request Sep 13, 2022
…iority (#505)

Currently, the priority is set to the timestamp of the earliest undispatched task.
Choosing earliest tasks will reduce the maximum waiting time when queue is nonempty

Co-authored-by: Max Ryabinin <[email protected]>
Co-authored-by: Pavel Samygin <[email protected]>
(cherry picked from commit 6395e89)
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