class_docstr: AMD GPU accelerators.
class_docstr_tok: ["AMD","GPU","accelerators","."]
docstr: Get the list of GPUs IDs in JSON format
  Example:
      On a node with 2x MI210 GPUs
      return: {"card0": {"GPU ID": "0x740f"}, "card1": {"GPU ID": "0x740f"}}
  Returns:
      A json string contain a list of GPU IDs
docstr_tok: ["Get","the","list","of","GPUs","IDs","in","JSON","format","Example",":","On","a","node","with","2x","MI210","GPUs","return",":","{","``","card0","''",":","{","``","GPU","ID","''",":","``","0x740f","''","}",",","``","card1","''",":","{","``","GPU","ID","''",":","``","0x740f","''","}","}","Returns",":","A","json","string","contain","a","list","of","GPU","IDs"]
code: def _get_amd_pci_ids() -> Dict[str, Any]:
      """Get the list of GPUs IDs in JSON format
      Example:
          On a node with 2x MI210 GPUs
          return: {"card0": {"GPU ID": "0x740f"}, "card1": {"GPU ID": "0x740f"}}
      Returns:
          A json string contain a list of GPU IDs
      """
  
      try:
          amd_pci_ids = subprocess.check_output(
              ["rocm-smi", "--showid", "--json"]
          ).decode("utf-8")
      except Exception:
          logger.exception("Could not parse gpu information.")
          return None
  
      return eval(amd_pci_ids)
  
file_path: ray/python/ray/_private/accelerators/amd_gpu.py
imports: import os
  import sys
  import logging
  import subprocess
  from typing import Optional, List, Tuple, Dict, Any
  from ray._private.accelerators.accelerator import AcceleratorManager
label_desc: Use image node_id 9 for calling the AMDGPUAcceleratorManager obj's underlying member method code with example usage: obj._get_amd_pci_ids() and returns: eval, None