I wanted to share a custom component I have created to track the stats of AMD GPU’s.
Who are you?
Hi, I’m DeadEnd . I’ve been using Home Assistant for a few years now. I have been contributing back to the HA community in whatever ways I can (usually through helping others troubleshoot issues). This is my first (what I consider big) contribution to Home Assistant. I am not a developer or programmer, so this was also a fantastic learning experience for me!
What is this thing?
Simply put, this custom component creates a selection of sensors for the GPU similar to what the System Monitor does for the CPU/RAM/HDD.
Why track GPU on a server?
When I first decided to build a home server it was originally to be an NVR. Shortly after that I stumbled upon Home Assistant, and as many of you can related… became part of this community.
Well, I still am using the same server (with a Ryzen CPU that has integrated AMD graphics) and have found there is nothing available to monitor the GPU in Home Assistant. I am using Frigate as my NVR and it is capable of utilizing the GPU cores - so I’d like to track this just like the Home Assistant System Monitor does for other PC components.
How does this work?
This component uses the pyamdgpuinfo python package to pull GPU information. My first draft used
YAML configuration and you can use the
v0.1 tag for
YAML configuration if you prefer to use that. The main branch has been converted over to use
config-flow - so you should be able to add the component as a custom HACS repository. I will look to get it into HACS as a standard repo in the future. Once added, after a restart it should be in the list of Integrations to be added.
Soooo… for the 3 other people out there who have an AMD GPU in their server and want to track temperature, load, memory, etc. I share with you,
As stated earlier - this is my first python project - I’m pretty proud of it, but also am aware that I am a novice . I will do my best to fix bugs that are found and make improvements!
I hope some other people out there find this useful!
Thanks, and Cheers!