Commit d9302e92 authored by Ubuntu's avatar Ubuntu

log gpu power

parent c2741254
...@@ -7,6 +7,8 @@ import ( ...@@ -7,6 +7,8 @@ import (
"github.com/NVIDIA/go-nvml/pkg/nvml" "github.com/NVIDIA/go-nvml/pkg/nvml"
) )
// NVIDIA GeForce RTX 3080
func getGPU() ([]DeviceInfo, error) { func getGPU() ([]DeviceInfo, error) {
ret := nvml.Init() ret := nvml.Init()
if ret != nvml.SUCCESS { if ret != nvml.SUCCESS {
...@@ -68,6 +70,8 @@ func getGPU() ([]DeviceInfo, error) { ...@@ -68,6 +70,8 @@ func getGPU() ([]DeviceInfo, error) {
if v, ok := comput[name]; ok { if v, ok := comput[name]; ok {
c = v c = v
} else {
fmt.Println("can not find the model", name)
} }
e = DeviceInfo{ e = DeviceInfo{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment