Announcement

Collapse
No announcement yet.

How to write Nvidia's GPU temperature into the panel?

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    How to write Nvidia's GPU temperature into the panel?

    Since installing nvidia-prime and nvidia-370.28 I have been attempting to get the GPU temp to display on the panel.
    My first effort was to use lm-sensors. That failed because Neon User Edition with the nvidia gpu controlling the display will not allow it to stay in memory. And, the widget that I downloaded in 16.04 to use with lm-sensors will not display in the widget list in Neon after I download it.

    So, I began looking for nvidia source code that I could raid to create my own tool. I found nvidia-smi.
    Just issuing nvidia-smi gives:
    Code:
    :~$ nvidia-smi
    Thu Nov  3 11:41:25 2016       
    +-----------------------------------------------------------------------------+
    | NVIDIA-SMI 370.28                 Driver Version: 370.28                    |
    |-------------------------------+----------------------+----------------------+
    | GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
    | Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
    |===============================+======================+======================|
    |   0  GeForce GT 650M     Off  | 0000:01:00.0     N/A |                  N/A |
    | N/A   30C    P8    N/A /  N/A |    158MiB /  1998MiB |     N/A      Default |
    +-------------------------------+----------------------+----------------------+
                                                                                   
    +-----------------------------------------------------------------------------+
    | Processes:                                                       GPU Memory |
    |  GPU       PID  Type  Process name                               Usage      |
    |=============================================================================|
    |    0                  Not Supported                                         |
    +-----------------------------------------------------------------------------+
    Issuing nvidia-smi -q -d TEMPERATURE -l 2 gives a two second loop of:
    Code:
    ==============NVSMI LOG==============
    Timestamp                           : Thu Nov  3 11:59:19 2016
    Driver Version                      : 370.28
    
    Attached GPUs                       : 1
    GPU 0000:01:00.0
        Temperature
            GPU Current Temp            : 31 C
            GPU Shutdown Temp           : N/A
            GPU Slowdown Temp           : N/A
    Neither of these are satisfactory. However, I can scrape the standard output with
    nvidia-smi | grep '[0-9][0-9]C' | awk '{print $3}' | sed 's/C//' and it returns just the temperature on a single line:
    :~$ nvidia-smi | grep '[0-9][0-9]C' | awk '{print $3}' | sed 's/C//'
    Code:
    34
    Anyone know of a simple way to get that value to display in a box on the panel?
    "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
    – John F. Kennedy, February 26, 1962.

    #2
    This might work - https://store.kde.org/content/show.p...?content=87195

    Good luck, GG
    we see things not as they are, but as we are.
    -- anais nin

    Comment


      #3
      No Joy!
      Click image for larger version

Name:	Screenshot_20161103_131017.png
Views:	1
Size:	17.5 KB
ID:	643375
      and that tar.gz file extracted reveals two *skz* files.
      nvidia-sensors.skz
      nvidia-sensors-lite.skz
      I'll check them out.
      Last edited by GreyGeek; Nov 03, 2016, 12:18 PM.
      "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
      – John F. Kennedy, February 26, 1962.

      Comment


        #4
        Hope it works - I know you can do it with conky (but not in the panel). I'd shop around kde-look and kde-apps and maybe something better will turn up if that doesn't work
        we see things not as they are, but as we are.
        -- anais nin

        Comment


          #5
          https://store.kde.org/content/show.p...content=170354

          This works here, but it's not pretty or well written.
          Attached Files
          Last edited by oshunluvr; Nov 03, 2016, 03:23 PM.

          Please Read Me

          Comment


            #6
            you can also use nvidia-settings to get the info ,,,,,,,,,,

            Code:
            vinny@vinny-Bonobo-Extreme:~$ nvidia-settings -q gpucoretemp
            
              Attribute 'GPUCoreTemp' (vinny-Bonobo-Extreme:0.0): 52.
                'GPUCoreTemp' is an integer attribute.
                'GPUCoreTemp' is a read-only attribute.
                'GPUCoreTemp' can use the following target types: X Screen, GPU.
              Attribute 'GPUCoreTemp' (vinny-Bonobo-Extreme:0[gpu:0]): 52.
                'GPUCoreTemp' is an integer attribute.
                'GPUCoreTemp' is a read-only attribute.
                'GPUCoreTemp' can use the following target types: X Screen, GPU.
            and to "scrape"it as you put it ,,,,,,,,,,,,,

            Code:
            vinny@vinny-Bonobo-Extreme:~$ nvidia-settings -q gpucoretemp | grep -m 1 Attribute | awk '{print $4}' | sed -e 's/\.//'
            52
            but ,,,,ya how to get it in the panel ,,,,,,, you could write a qml script and make it a widget ,,,,,,,,thats what thay are ,,,,,,, .qml files

            VINNY
            i7 4core HT 8MB L3 2.9GHz
            16GB RAM
            Nvidia GTX 860M 4GB RAM 1152 cuda cores

            Comment


              #7
              Originally posted by oshunluvr View Post
              https://store.kde.org/content/show.p...content=170354

              This works here, but it's not pretty or well written.
              nice one ,,,,,,,yup it works just like that @hear as well

              but since that info is in my conky ,,,,,,,,,,,by by


              VINNY
              i7 4core HT 8MB L3 2.9GHz
              16GB RAM
              Nvidia GTX 860M 4GB RAM 1152 cuda cores

              Comment


                #8
                Originally posted by oshunluvr View Post
                https://store.kde.org/content/show.p...content=170354

                This works here, but it's not pretty or well written.
                Doesn't work for me. After trying the Aur and the Github version neither would appear in the list widgets, nor would they appear in the list of "uninstallable" widgets. Is your Neon added to 16.04 or are you running only Neon?
                "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
                – John F. Kennedy, February 26, 1962.

                Comment


                  #9
                  ya nether of those worked @ hear either ,,,,,install the .gz one ,,,,the top one .

                  VINNY
                  i7 4core HT 8MB L3 2.9GHz
                  16GB RAM
                  Nvidia GTX 860M 4GB RAM 1152 cuda cores

                  Comment


                    #10
                    Originally posted by vinnywright View Post
                    ya nether of those worked @ hear either ,,,,,install the .gz one ,,,,the top one .

                    VINNY

                    That was the one that worked, VINNY, thanks! And to oshunluver as well.
                    It allowed me to select nvidia-smi as the source for the T. Works great!
                    "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
                    – John F. Kennedy, February 26, 1962.

                    Comment


                      #11
                      it dose seem to fit in with my icons in the system tray



                      and is using the "nvidia-smi" @hear as well .

                      VINNY
                      i7 4core HT 8MB L3 2.9GHz
                      16GB RAM
                      Nvidia GTX 860M 4GB RAM 1152 cuda cores

                      Comment


                        #12
                        Here's mine:
                        Click image for larger version

Name:	Screenshot_20161103_214749.png
Views:	1
Size:	15.9 KB
ID:	643377
                        "A nation that is afraid to let its people judge the truth and falsehood in an open market is a nation that is afraid of its people.”
                        – John F. Kennedy, February 26, 1962.

                        Comment


                          #13
                          Originally posted by greygeek View Post
                          here's mine:
                          [ATTACH=CONFIG]6786[/ATTACH]


                          vinny
                          i7 4core HT 8MB L3 2.9GHz
                          16GB RAM
                          Nvidia GTX 860M 4GB RAM 1152 cuda cores

                          Comment

                          Working...
                          X