Skip to content

Commit

Permalink
Sort list first
Browse files Browse the repository at this point in the history
  • Loading branch information
szutenberg committed Feb 20, 2025
1 parent 10340ac commit 1f86446
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions vllm/worker/hpu_model_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -733,6 +733,7 @@ def __init__(
affinity = list(os.sched_getaffinity(pid))

if len(affinity) == 224:
affinity.sort()
affinity = affinity[::2] # no threads
mod_id_to_cpu = {0:2, 1:3, 2:6, 3:7, 4:0, 5:1, 6:4, 7:5}
cpu = mod_id_to_cpu[rank]
Expand Down

0 comments on commit 1f86446

Please sign in to comment.