You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+5-12Lines changed: 5 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -24,26 +24,19 @@ This is a Python script that uses the Pygame library to display the current FPS
24
24
* Run the script using `python FPS-Monitor.py`
25
25
26
26
27
-
<h2>Usage :movie_camera: </h2>
28
-
29
-
The script will display the current FPS in the top left corner of the window. The GPU and CPU usage will be displayed on the right side of the window.
30
-
31
-
You can resize the window to your desired size by clicking and dragging the edges of the window.
32
-
33
-
To exit the script, simply close the window or press the 'X' button in the top right corner of the window.
34
-
35
27
<h2>Limitations :warning: </h2>
36
28
37
29
This script is only compatible with NVidia GPUs. It will not work with other types of GPUs such as AMD or Intel. Additionally, it will only display information for the first GPU it detects. If you have multiple GPUs installed, you will need to modify the script to display information for all of them.
38
30
39
31
40
32
<h2>Features :space_invader: </h2>
41
-
42
-
You can customize the script to display additional information such as GPU memory usage or CPU temperature. You can also change the font, text color and background color of the window to match your personal preferences.
33
+
This code is a Python script that uses Pygame, sys, psutil, gpustat, and cpuinfo libraries to display system information in a graphical interface. The code initializes the Pygame library, sets the height and width of the window, and sets up a font for text display. <br>
43
34
<br>
35
+
The script has several functions that are responsible for getting specific system information and returning text in the form of a Pygame surface. The fpsrun() function returns the current FPS value as text. <br>
36
+
<br> The get_cpu_usage() function returns the CPU usage percentage, along with the CPU name, in text format with different colors depending on whether the CPU is from AMD, Intel, or any other brand. <br>
37
+
<br> The get_gpu_usage() and get_gpu_name() functions return the GPU usage percentage and name in text format with green color. The get_ram_info() and get_ram_usage() functions return the total RAM and the RAM usage percentage in text format with orange color.
44
38
45
-
Currently in testing: Color changing depending on having AMD or Intel.
46
-
AMD goes red, while Intel goes blue
39
+
<br> In the main loop, the script listens for Pygame quit events, updates the screen with the system information, and updates the display 60 times per second. The script displays the FPS value, CPU name, CPU usage, GPU name, GPU usage, total RAM, and RAM usage on the screen.
0 commit comments