Added "if name == 'main':" and moved all function calls below it. I also renamed "rocm-smi" to "rocm_smi.py" and created a symbolic link named "rocm-smi" for backwards compatibilty.
These changes allow one to import rocm_smi into any other python script.
All tests pass except the load from file test:
"Testing /home/prospector/build/roc-smi/rocm-smi --load...
FAILURE: Failed to change GPU OverDrive when loading values from save file /tmp/tmp.e5UI60DD5V/clocks.tmp
Test complete: /home/prospector/build/roc-smi/rocm-smi --load"
This test also fails on my computer when using the upstream version. If I recreate the test manually it works.
I've merged this locally, and it should be included in our 1.8 release. Thus I'll close it since it required some manual work to update it on the master branch so the PR won't be the same.
Added "if name == 'main':" and moved all function calls below it. I also renamed "rocm-smi" to "rocm_smi.py" and created a symbolic link named "rocm-smi" for backwards compatibilty.
These changes allow one to import rocm_smi into any other python script.
All tests pass except the load from file test: "Testing /home/prospector/build/roc-smi/rocm-smi --load... FAILURE: Failed to change GPU OverDrive when loading values from save file /tmp/tmp.e5UI60DD5V/clocks.tmp Test complete: /home/prospector/build/roc-smi/rocm-smi --load" This test also fails on my computer when using the upstream version. If I recreate the test manually it works.
Will diagnose test failure as time allows.