Update AppImage

This commit is contained in:
MacRimi
2025-10-07 00:35:23 +02:00
parent f0b6f66be6
commit 658ce390e2
3 changed files with 74 additions and 16 deletions

View File

@@ -96,8 +96,17 @@ export default function Hardware() {
combinedData.utilization_gpu !== undefined ||
combinedData.memory_total ||
combinedData.power_draw ||
// Intel GPU specific fields
combinedData.engine_render !== undefined ||
combinedData.clock_graphics
combinedData.engine_blitter !== undefined ||
combinedData.engine_video !== undefined ||
combinedData.engine_video_enhance !== undefined ||
combinedData.clock_graphics ||
combinedData.clock_memory ||
// AMD GPU specific fields
combinedData.utilization_memory !== undefined ||
// NVIDIA GPU specific fields
combinedData.processes !== undefined
)
}
@@ -669,7 +678,7 @@ export default function Hardware() {
</div>
</div>
{/* Extended Monitoring Not Available Message */}
{selectedGPU.has_monitoring_tool === false && (
<div className="rounded-lg border border-blue-500/20 bg-blue-500/10 p-4">
<div className="flex gap-3">
<Info className="h-5 w-5 text-blue-500 flex-shrink-0 mt-0.5" />
@@ -681,6 +690,7 @@ export default function Hardware() {
</div>
</div>
</div>
)}
</div>
</>
)

View File

@@ -1580,6 +1580,21 @@ def get_detailed_gpu_info(gpu):
vendor = gpu.get('vendor', '').upper()
if vendor == 'INTEL':
try:
check_result = subprocess.run(['which', 'intel_gpu_top'], capture_output=True, timeout=1)
if check_result.returncode != 0:
# Tool not found
detailed_info['has_monitoring_tool'] = False
print(f"[v0] intel_gpu_top not found for Intel GPU")
return detailed_info
else:
detailed_info['has_monitoring_tool'] = True
print(f"[v0] intel_gpu_top found for Intel GPU")
except Exception as e:
print(f"[v0] Error checking for intel_gpu_top: {e}")
detailed_info['has_monitoring_tool'] = False
return detailed_info
try:
# Try JSON output first (newer versions of intel_gpu_top)
result = subprocess.run(
@@ -1603,7 +1618,7 @@ def get_detailed_gpu_info(gpu):
pass
# Fallback to text parsing
if not detailed_info:
if not detailed_info or len(detailed_info) == 1: # Only has_monitoring_tool flag
result = subprocess.run(
['intel_gpu_top', '-s', '100'],
capture_output=True, text=True, timeout=2
@@ -1641,6 +1656,20 @@ def get_detailed_gpu_info(gpu):
print(f"[v0] Error getting Intel GPU details: {e}")
elif vendor == 'AMD' or 'ATI' in vendor:
try:
check_result = subprocess.run(['which', 'radeontop'], capture_output=True, timeout=1)
if check_result.returncode != 0:
detailed_info['has_monitoring_tool'] = False
print(f"[v0] radeontop not found for AMD GPU")
return detailed_info
else:
detailed_info['has_monitoring_tool'] = True
print(f"[v0] radeontop found for AMD GPU")
except Exception as e:
print(f"[v0] Error checking for radeontop: {e}")
detailed_info['has_monitoring_tool'] = False
return detailed_info
try:
result = subprocess.run(
['radeontop', '-d', '-', '-l', '1'],
@@ -1674,6 +1703,20 @@ def get_detailed_gpu_info(gpu):
# NVIDIA GPU - use nvidia-smi
elif vendor == 'NVIDIA':
try:
check_result = subprocess.run(['which', 'nvidia-smi'], capture_output=True, timeout=1)
if check_result.returncode != 0:
detailed_info['has_monitoring_tool'] = False
print(f"[v0] nvidia-smi not found for NVIDIA GPU")
return detailed_info
else:
detailed_info['has_monitoring_tool'] = True
print(f"[v0] nvidia-smi found for NVIDIA GPU")
except Exception as e:
print(f"[v0] Error checking for nvidia-smi: {e}")
detailed_info['has_monitoring_tool'] = False
return detailed_info
try:
result = subprocess.run(
['nvidia-smi', '--query-gpu=index,name,driver_version,memory.total,memory.used,memory.free,temperature.gpu,power.draw,power.limit,utilization.gpu,utilization.memory,clocks.gr,clocks.mem,pcie.link.gen.current,pcie.link.width.current',
@@ -1872,7 +1915,7 @@ def get_gpu_info():
current_adapter = line.replace('Adapter:', '').strip()
continue
# Look for GPU-related sensors (nouveau, amdgpu, radeon, i915, etc.)
# Look for GPU-related sensors (nouveau, amdgpu, radeon, i915)
if ':' in line and not line.startswith(' '):
parts = line.split(':', 1)
sensor_name = parts[0].strip()
@@ -1891,8 +1934,8 @@ def get_gpu_info():
('i915' in current_adapter.lower() and gpu['vendor'] == 'Intel')):
# Parse temperature (only if not already set by nvidia-smi)
if '°C' in value_part or 'C' in value_part:
if 'temperature' not in gpu or gpu['temperature'] is None:
if '°C' in value_part or 'C' in value_part:
temp_match = re.search(r'([+-]?[\d.]+)\s*°?C', value_part)
if temp_match:
gpu['temperature'] = float(temp_match.group(1))

View File

@@ -103,6 +103,10 @@ export interface GPU {
utilization_memory?: number
clock_graphics?: string
clock_memory?: string
engine_render?: number
engine_blitter?: number
engine_video?: number
engine_video_enhance?: number
pcie_gen?: string
pcie_width?: string
fan_speed?: number
@@ -112,6 +116,7 @@ export interface GPU {
name: string
memory: string
}>
has_monitoring_tool?: boolean
note?: string
}