kernelfoundry.eval_pipeline.utils.sysinfo

System information helpers.

Functions

discover_intel_gpus()

Discover Intel GPUs by inspecting DRM devices in sysfs.

get_device_name_by_pci_address(pci_address)

Get the device name for a PCI address via lspci.

get_git_commit_hash()

Get the git describe hash for the current repo state.

get_icpx_version()

Get the Intel icpx compiler version string if available.

get_igc_revision()

Get the Intel IGC revision string if available.

get_intel_cpu_name()

Get the CPU model name from /proc/cpuinfo.

get_neo_revision()

Get the Intel NEO revision string if available.

get_nvcc_version()

Get the CUDA nvcc version string if available.

get_nvidia_compute_capabilities()

Get NVIDIA GPU compute capabilities from nvidia-smi.

get_nvidia_gpu_name()

Get the first NVIDIA GPU name if present.

get_ocl_driver_version()

Get the OpenCL driver version string if available.

get_torch_version()

Get the installed torch version without importing it.

get_total_system_memory_kb()

Get the total amount of system memory in kB from /proc/meminfo.

get_worker_info()

Get system info for the current worker.

kernelfoundry.eval_pipeline.utils.sysinfo.get_intel_cpu_name()[source]

Get the CPU model name from /proc/cpuinfo.

Returns:

CPU model name, or an empty string if unavailable.

Return type:

str

kernelfoundry.eval_pipeline.utils.sysinfo.get_total_system_memory_kb() int[source]

Get the total amount of system memory in kB from /proc/meminfo.

Returns:

Total memory in kB (from MemTotal), or 0 if unavailable.

Return type:

int

kernelfoundry.eval_pipeline.utils.sysinfo.get_torch_version()[source]

Get the installed torch version without importing it.

Returns:

Torch version string.

Return type:

str

kernelfoundry.eval_pipeline.utils.sysinfo.get_nvcc_version()[source]

Get the CUDA nvcc version string if available.

Returns:

nvcc version string, or an empty string if unavailable.

Return type:

str

kernelfoundry.eval_pipeline.utils.sysinfo.get_icpx_version()[source]

Get the Intel icpx compiler version string if available.

Returns:

icpx version string, or an empty string if unavailable.

Return type:

str

kernelfoundry.eval_pipeline.utils.sysinfo.get_ocl_driver_version()[source]

Get the OpenCL driver version string if available.

Returns:

OpenCL driver version string, or an empty string if unavailable.

Return type:

str

kernelfoundry.eval_pipeline.utils.sysinfo.get_neo_revision()[source]

Get the Intel NEO revision string if available.

Returns:

Intel NEO revision string, or an empty string if unavailable.

Return type:

str

kernelfoundry.eval_pipeline.utils.sysinfo.get_igc_revision()[source]

Get the Intel IGC revision string if available.

Returns:

Intel IGC revision string, or an empty string if unavailable.

Return type:

str

kernelfoundry.eval_pipeline.utils.sysinfo.get_git_commit_hash() str | None[source]

Get the git describe hash for the current repo state.

Returns:

Git describe hash, or an empty string if unavailable.

Return type:

str

kernelfoundry.eval_pipeline.utils.sysinfo.discover_intel_gpus() list[tuple[Path, str, str]][source]

Discover Intel GPUs by inspecting DRM devices in sysfs.

Returns:

Tuples of (card_path, device_id, pci_slot_name).

The device ID describes the GPU model, e.g. “0x56c0”, and can be passed to the compiler via TORCH_XPU_ARCH_LIST.

Return type:

list[tuple[Path, str, str]]

kernelfoundry.eval_pipeline.utils.sysinfo.get_device_name_by_pci_address(pci_address: str) str[source]

Get the device name for a PCI address via lspci.

Parameters:

pci_address (str) – PCI address of the device (e.g., “0000:3b:00.0”).

Returns:

Device name, or an empty string if not found.

Return type:

str

kernelfoundry.eval_pipeline.utils.sysinfo.get_nvidia_compute_capabilities() list[str][source]

Get NVIDIA GPU compute capabilities from nvidia-smi.

Returns:

Compute capability strings (e.g., [“7.5”, “8.6”]).

Return type:

list[str]

kernelfoundry.eval_pipeline.utils.sysinfo.get_nvidia_gpu_name() str[source]

Get the first NVIDIA GPU name if present.

Returns:

GPU name, or an empty string if not found.

Return type:

str

kernelfoundry.eval_pipeline.utils.sysinfo.get_worker_info()[source]

Get system info for the current worker.

Returns:

System info map including compiler, driver, and device details.

Return type:

dict