mirror of
https://github.com/wassname/ray.git
synced 2026-09-09 11:32:43 +08:00
[Dashboard][Bugfix] Fix GPU List Bug (#12666)
* Fix bug where None was passed as the empty value for ActorInfo.gpu_stats instead of an empty list * lint * dashboard/modules/logical_view * fix test * trigger build
This commit is contained in:
@@ -238,7 +238,7 @@ class DataOrganizer:
|
||||
pid = core_worker_stats.get("pid")
|
||||
node_physical_stats = DataSource.node_physical_stats.get(node_id, {})
|
||||
actor_process_stats = None
|
||||
actor_process_gpu_stats = None
|
||||
actor_process_gpu_stats = []
|
||||
if pid:
|
||||
for process_stats in node_physical_stats.get("workers", []):
|
||||
if process_stats["pid"] == pid:
|
||||
@@ -248,14 +248,11 @@ class DataOrganizer:
|
||||
for gpu_stats in node_physical_stats.get("gpus", []):
|
||||
for process in gpu_stats.get("processes", []):
|
||||
if process["pid"] == pid:
|
||||
actor_process_gpu_stats = gpu_stats
|
||||
actor_process_gpu_stats.append(gpu_stats)
|
||||
break
|
||||
if actor_process_gpu_stats is not None:
|
||||
break
|
||||
|
||||
actor["gpus"] = actor_process_gpu_stats
|
||||
actor["processStats"] = actor_process_stats
|
||||
|
||||
return actor
|
||||
|
||||
@classmethod
|
||||
|
||||
Reference in New Issue
Block a user