Power consumption processing method, system, device and equipment and storage medium

By obtaining the current power consumption of the graphics card and determining the power consumption level according to preset parameters, controlling the display status of the display component, solving the problem of users requiring operation input to view the power consumption of the graphics card, realizing intuitive power consumption monitoring.

CN119847851APending Publication Date: 2025-04-18MOORE THREADS TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311310909.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-10-10
Publication Date
2025-04-18

AI Technical Summary

Technical Problem

In the prior art, users need to perform operation inputs to view the power consumption information of the graphics card, and the process is inconvenient and intuitive.

Method used

By obtaining the current power consumption of the graphics card, determining the current power consumption level of the graphics card based on the preset power consumption level classification parameters, and controlling the display status of the display component to reflect the power consumption level.

Benefits of technology

It realizes that the display status of the display component is convenient for users to quickly and intuitively view the power consumption information of the graphics card, simplifying the process of users monitoring the graphics card workload.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119847851A_ABST
    Figure CN119847851A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a power consumption processing method, system, device and equipment and a storage medium, and the method comprises the steps: obtaining the current power consumption of a graphics card; determining a current power consumption level of the graphics card based on the current power consumption and a preset power consumption level division parameter; and controlling the display state of a display component arranged on the display card based on the current power consumption level. According to the embodiment of the invention, the current power consumption level of the display card can be reflected through the display state of the display component arranged on the display card, so that a user can conveniently, quickly and intuitively check the power consumption information of the display card, and the user can conveniently monitor the working load of the display card.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to, but is not limited to, the field of electronic technology, and in particular to a power consumption processing method, system, device, equipment, and storage medium. Background Art

[0002] Graphics cards are a crucial component of computer equipment. Because the power consumption of graphics cards can vary significantly depending on the applications being run, users often monitor their workload by reading their graphics card's power consumption in real time. Related technologies require user input (such as entering a command or accessing a specific software interface) to view graphics card power consumption information on the computer's display, making the viewing process inconvenient and unintuitive. Summary of the Invention

[0003] In view of this, embodiments of the present disclosure at least provide a power consumption processing method, system, apparatus, device, and storage medium.

[0004] The technical solution of the embodiment of the present disclosure is implemented as follows:

[0005] An embodiment of the present disclosure provides a method for processing power consumption, the method comprising:

[0006] Get the current power consumption of the graphics card;

[0007] Determining a current power consumption level of the graphics card based on the current power consumption and a preset power consumption level classification parameter;

[0008] Based on the current power consumption level, a display state of a display component provided on the graphics card is controlled.

[0009] An embodiment of the present disclosure provides a power consumption processing system, the system comprising:

[0010] A graphics card, and a power consumption acquisition component and a display component connected to the graphics card; wherein,

[0011] The graphics card includes a graphics processor;

[0012] The power consumption collection component is connected to the input power supply of the graphics card, and is used to collect the power consumption of the graphics card and send the collected power consumption information to the graphics processor;

[0013] The graphics processor is used to: receive the power consumption information sent by the power consumption acquisition component, and determine the current power consumption of the graphics card based on the power consumption information; determine the current power consumption level of the graphics card based on the current power consumption and preset power consumption level classification parameters; and control the display state of the display component based on the current power consumption level.

[0014] An embodiment of the present disclosure provides a power consumption processing device, the device comprising:

[0015] A first acquisition module is used to obtain the current power consumption of the graphics card;

[0016] A first determining module, configured to determine a current power consumption level of the graphics card based on the current power consumption and a preset power consumption level classification parameter;

[0017] The first control module is configured to control a display state of a display component provided on the graphics card based on the current power consumption level.

[0018] An embodiment of the present disclosure provides a computer device, including a memory and a processor, wherein the memory stores a computer program that can be run on the processor, and when the processor executes the program, some or all of the steps in the above method are implemented.

[0019] An embodiment of the present disclosure provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, some or all of the steps in the above method are implemented.

[0020] In the disclosed embodiment, the current power consumption of a graphics card is obtained; based on the current power consumption and preset power consumption classification parameters, the current power consumption level of the graphics card is determined; and based on the current power consumption level, the display state of a display component provided on the graphics card is controlled. In this way, the current power consumption level of the graphics card can be reflected by the display state of the display component provided on the graphics card, thereby allowing users to quickly and intuitively view the power consumption information of the graphics card and facilitate monitoring of the graphics card's workload.

[0021] It should be understood that the above general description and the following detailed description are merely exemplary and explanatory, and are not intended to limit the technical solutions of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0022] The accompanying drawings herein are incorporated into and constitute a part of the specification. These drawings illustrate embodiments consistent with the present disclosure and, together with the specification, are used to explain the technical solutions of the present disclosure.

[0023] Figure 1 A schematic diagram of an implementation flow of a power consumption processing method provided in an embodiment of the present disclosure;

[0024] Figure 2 A schematic diagram of an implementation flow of a power consumption processing method provided in an embodiment of the present disclosure;

[0025] Figure 3 A schematic diagram of an implementation flow of a power consumption processing method provided in an embodiment of the present disclosure;

[0026] Figure 4A schematic diagram of the structure of a power consumption processing system provided in an embodiment of the present disclosure;

[0027] Figure 5A A schematic diagram of the structure of a power consumption processing system provided in an embodiment of the present disclosure;

[0028] Figure 5B A schematic diagram of the structure of a power consumption acquisition circuit for a graphics card provided by an embodiment of the present disclosure;

[0029] Figure 5C A schematic diagram illustrating an implementation of extracting RGB codes from an LED light bar in a power consumption processing method provided in an embodiment of the present disclosure;

[0030] Figure 5D A schematic diagram of the display state of an LED light bar in a power consumption processing method provided in an embodiment of the present disclosure;

[0031] Figure 5E A schematic diagram of the display state of an LED light bar in a power consumption processing method provided in an embodiment of the present disclosure;

[0032] Figure 5F A schematic diagram of the display state of an LED light bar in a power consumption processing method provided in an embodiment of the present disclosure;

[0033] Figure 5G A schematic diagram of the display state of an LED light bar in a power consumption processing method provided in an embodiment of the present disclosure;

[0034] Figure 6 A schematic diagram of the structure of a power consumption processing device provided in an embodiment of the present disclosure;

[0035] Figure 7 A schematic diagram of a hardware entity of a computer device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION

[0036] In order to make the purpose, technical solutions and advantages of the present disclosure clearer, the technical solutions of the present disclosure are further elaborated in detail below with reference to the accompanying drawings and embodiments. The described embodiments should not be regarded as limiting the present disclosure. All other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present disclosure.

[0037] In the following description, reference is made to “some embodiments”, which describes a subset of all possible embodiments, but it will be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.

[0038] The terms "first / second / third" involved are merely used to distinguish similar objects and do not represent a specific ordering of the objects. It is understandable that "first / second / third" can be interchanged with a specific order or sequence where permitted so that the embodiments of the present disclosure described herein can be implemented in an order other than that illustrated or described herein.

[0039] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the art to which the present disclosure pertains. The terms used herein are for the purpose of describing the present disclosure only and are not intended to limit the present disclosure.

[0040] In view of this, an embodiment of the present disclosure provides a power consumption processing method. The method can be performed by a processor. In some embodiments, the power consumption processing method can be performed by a graphics processing unit (GPU) in a graphics card. In some embodiments, the power consumption processing method can also be performed by a processor of a computer device with a graphics card. Among them, the computer device may include but is not limited to at least one of a server, a laptop, a tablet computer, a desktop computer, a smart TV, a set-top box, a mobile device (such as a mobile phone, a portable video player, a personal digital assistant, a dedicated messaging device, a portable gaming device), etc., and the processor may include but is not limited to at least one of a central processing unit (CPU), a microprocessor (MPU), a digital signal processor (DSP), or a field programmable gate array (FPGA), etc. Figure 1 A schematic diagram of a power consumption processing method according to an embodiment of the present disclosure is provided. Figure 1 As shown, the method may include the following steps S101 to S103:

[0041] Step S101, obtaining the current power consumption of the graphics card.

[0042] Here, the current power consumption of the graphics card may include, but is not limited to, at least one of the sampled power consumption of the graphics card at the current moment, the average power consumption of the graphics card within a preset period of time before the current moment, and the like. During implementation, those skilled in the art may use any suitable method to obtain the current power consumption of the graphics card, and this is not limited herein.

[0043] In some embodiments, when the current power consumption of a graphics card includes the sampled power consumption of the graphics card at the current moment, the power consumption of the graphics card collected by the power consumption collection component at the current moment can be obtained, and the sampled power consumption of the graphics card at the current moment can be determined based on the power consumption. For example, the power consumption of the graphics card collected by the power consumption collection component at the current moment can be determined as the sampled power consumption of the graphics card at the current moment. In another example, the power consumption of the graphics card collected by the power consumption collection component at the current moment can be filtered to obtain the sampled power consumption of the graphics card at the current moment.

[0044] In some embodiments, when the current power consumption of the graphics card includes the average power consumption of the graphics card within a preset time period before the current moment (i.e., the current average power consumption), multiple sampled power consumptions of the graphics card collected by the power consumption collection component within the preset time period before the current moment can be obtained, and the current average power consumption of the graphics card can be determined based on the average value of the multiple sampled power consumptions.

[0045] It should be understood that the power consumption collection component can be any suitable component or circuit selected based on actual circumstances that can collect the power consumption of the graphics card, and is not limited here. In some embodiments, the power consumption collection component can include a current and voltage monitoring chip, such as an INA3221 chip. During implementation, the power consumption collection component can collect sampled power consumption of the graphics card by monitoring the power input interface of the graphics card, and output the collected sampled power consumption of the graphics card to the processor executing the method.

[0046] In some implementations, the sampled power consumption of the graphics card can be obtained from the power consumption acquisition component at a preset frequency, wherein the preset frequency can be pre-set according to actual conditions and is not limited here.

[0047] In some embodiments, a preset communication protocol may be used to interact with the power consumption acquisition component to obtain the sampled power consumption of the graphics card. For example, the preset communication protocol may include, but is not limited to, the Inter-Integrated Circuit (I2C) protocol, etc., which is not limited here.

[0048] Step S102: determining the current power consumption level of the graphics card based on the current power consumption and preset power consumption level classification parameters.

[0049] Here, the power consumption level classification parameter may be a pre-set parameter for classifying power consumption, and may include but is not limited to at least one of the first number of power consumption levels, the power consumption value interval corresponding to each power consumption level, and the level classification method. The level classification method may be, for example, equal interval classification or non-equal interval classification.

[0050] During implementation, the power consumption level classification parameters may be default values ​​pre-stored in a register of the computer device and / or a register of a graphics card, or may be set by the user based on actual needs and stored in the corresponding register, without limitation herein. The first number of power consumption levels to be classified, the power consumption value range corresponding to each power consumption level, the level classification method, etc. may be determined based on actual conditions.

[0051] In some embodiments, the first number of divided power consumption levels can be determined based on the number of pixels in the display component (e.g., the number of indicator lights in the indicator light module, etc.). For example, when the number of pixels in the display component is 10, the first number of divided power consumption levels can be determined to be 10, or the first number of divided power consumption levels can be determined to be 5. In some embodiments, the first number of divided power consumption levels can be determined based on the maximum power consumption of the graphics card. For example, when the maximum power consumption of the graphics card is 300 watts (W), the first number can be determined to be 10; when the maximum power consumption of the graphics card is 400 W, the first number can be determined to be 15.

[0052] In some embodiments, the power consumption value interval corresponding to each power consumption level can be obtained by dividing the maximum power consumption of the graphics card according to the first number of divided power consumption levels and the level division method based on actual needs. For example, when the maximum power consumption of the graphics card is 300W, the first number of divided power consumption levels is 10, and the level division method is equal interval division, then 10 power consumption levels P1 to P10 can be determined, and the power consumption value interval corresponding to power consumption level P1 can be 0 to 30W, the power consumption value interval corresponding to power consumption level P2 can be 31 to 60W, the power consumption value interval corresponding to power consumption level P3 can be 61 to 90W, the power consumption value interval corresponding to power consumption level P4 can be 91 to 120W, ... the power consumption value interval corresponding to power consumption level P10 can be 271 to 300W. For another example, when the maximum power consumption of the graphics card is 300W, the first number of power consumption levels is 5, and the level division method is non-equal interval division. If the program currently running on the graphics card is within the power consumption range of 100 to 200W and the user is more concerned about the power consumption information, then 5 power consumption levels P1 to P5 can be determined. The power consumption value range corresponding to power consumption level P1 can be 0 to 100W, the power consumption value range corresponding to power consumption level P2 can be 101 to 130W, the power consumption value range corresponding to power consumption level P3 can be 131 to 160W, the power consumption value range corresponding to power consumption level P4 can be 161 to 200W, and the power consumption value range corresponding to power consumption level P5 can be 201 to 300W.

[0053] During implementation, the current power consumption level of the graphics card can be determined based on the current power consumption and preset power consumption level classification parameters in any suitable manner, which is not limited here.

[0054] In some embodiments, when the power consumption level classification parameters include power consumption value intervals corresponding to each power consumption level, the current power consumption of the graphics card can be matched with the power consumption value intervals corresponding to at least one power consumption level, the power consumption value intervals matching the current power consumption are determined, and the power consumption level corresponding to the matching power consumption value intervals are determined as the current power consumption level of the graphics card.

[0055] In some embodiments, when the power consumption level division parameters include a first number of divided power consumption levels and a level division method, the maximum power consumption of the graphics card can be divided according to the first number and the level division method to obtain the power consumption value range corresponding to each power consumption level, and the current power consumption level of the graphics card can be determined based on the current power consumption of the graphics card and the power consumption value range corresponding to each power consumption level.

[0056] Step S103: Based on the current power consumption level, controlling the display state of the display component provided on the graphics card.

[0057] Here, the display component may include but is not limited to at least one of an indicator light module, a liquid crystal display screen, a digital tube, and the like.

[0058] For different power consumption levels, the display component can be controlled to be in a corresponding display state, wherein the display state of the display component may include but is not limited to at least one of an on / off state, the number of lights on, the lighting duration, the display color, the flashing frequency, the display symbol, the display pattern, etc.

[0059] During implementation, the display state of the display component corresponding to each power consumption level can be determined by those skilled in the art according to actual needs and is not limited here.

[0060] In some embodiments, when the display assembly includes an indicator light module, different power consumption levels may correspond to different lighting lengths of the indicator light module. For example, a higher power consumption level corresponds to a longer lighting length of the corresponding indicator light module, and a lower power consumption level corresponds to a shorter lighting length of the corresponding indicator light module. The indicator light module may be any suitable module including at least one indicator light. For example, the indicator light module may include, but is not limited to, at least one of a light-emitting diode (LED) light bar, an LED light ring, and the like.

[0061] In some embodiments, when the display component includes an indicator light module, different power consumption levels may correspond to different lighting lengths and different display colors of the indicator light module. For example, as the power consumption level increases, the lighting length of the corresponding indicator light module becomes longer, and the display color of each indicator light in the indicator light module gradually transitions from green to red, or the display color of each indicator light that is sequentially lit in the indicator light module gradually transitions from green to red. It should be understood that the display colors of each indicator light in the indicator light module can be the same or different, and this is not limited here.

[0062] In some embodiments, when the display assembly includes an indicator light module, different power consumption levels may correspond to different flashing frequencies of the indicator lights in the indicator light module. For example, as the power consumption level increases, the flashing frequency of the indicator lights in the corresponding indicator light module gradually becomes faster.

[0063] In some embodiments, when the display component includes a liquid crystal display, different power consumption levels may correspond to different display colors of the liquid crystal display. For example, as the power consumption level increases, the corresponding display color of the liquid crystal display gradually transitions from green to red.

[0064] In some embodiments, when the display component includes a liquid crystal display, different power consumption levels may correspond to different display patterns of the liquid crystal display. For example, as the power consumption level increases, the corresponding display pattern of the liquid crystal display gradually transitions from a preset first pattern representing idleness to a second pattern representing busyness.

[0065] In some embodiments, when the display component includes a digital tube, different power consumption levels may correspond to different display symbols on the digital tube. For example, when the power consumption level is the first level, the corresponding digital tube may display the symbol "P1", and when the power consumption level is the second level, the corresponding digital tube may display the symbol "P2".

[0066] In some embodiments, based on the current power consumption level, a control signal corresponding to the current power consumption level may be sent to the display component to control the display component to present a display state corresponding to the current power consumption level.

[0067] In the disclosed embodiment, the current power consumption of a graphics card is obtained; based on the current power consumption and preset power consumption classification parameters, the current power consumption level of the graphics card is determined; and based on the current power consumption level, the display state of a display component provided on the graphics card is controlled. In this way, the current power consumption level of the graphics card can be reflected by the display state of the display component provided on the graphics card, thereby allowing users to quickly and intuitively view the power consumption information of the graphics card and facilitate monitoring of the graphics card's workload.

[0068] In some embodiments, the above step S103 may include the following steps S111 to S112:

[0069] Step S111 : determining target display control information based on the current power consumption level.

[0070] Here, the target display control information may include any appropriate control information for controlling the display component to display in a display state corresponding to the current power consumption level, and the embodiments of the present disclosure are not limited thereto. For example, the target display control information may include control information for controlling the display color of the display component, control information for controlling the on / off state of the display component, and / or control information for controlling the number of lights on the display component.

[0071] In some implementations, display control information corresponding to each power consumption level may be preset, and the display control information corresponding to the current power consumption level may be determined as the target display control information.

[0072] Step S112: controlling the display state of the display component provided on the graphics card based on the target display control information.

[0073] Here, the processor executing the method may send the target display control information to the display component, and the display component may adjust the current display state based on the target display control information in response to receiving the target display control information.

[0074] In this way, the display state of the display component can be controlled conveniently and quickly based on the target display control information corresponding to the current power consumption level.

[0075] In some embodiments, the display component includes an indicator light module, the indicator light module includes at least one indicator light and a control unit corresponding to each indicator light, and the target display control information includes at least one display code. The above step S111 may include the following step S121:

[0076] Step S121 : determining a display code corresponding to at least one target indicator light in the indicator light module based on the current power consumption level.

[0077] The above step S112 may include the following step S122:

[0078] Step S122: sending the display code corresponding to each target indicator light to the control unit corresponding to the target indicator light, so that the control unit controls the display state of the target indicator light based on the received display code.

[0079] Here, the display code in the target display control information is a signal code used to control the display state of the corresponding target indicator light. The target indicator light is the indicator light to be illuminated corresponding to the current power consumption level. The control unit corresponding to the indicator light can control the display state of the indicator light based on the received display code. The display state of the indicator light may include, but is not limited to, at least one of the following: the on / off state of the indicator light, the display color, the flashing frequency, etc.

[0080] In implementation, each power consumption level may correspond to at least one target indicator light to be lit, and a display state corresponding to each target indicator light. The display state corresponding to each target indicator light may be controlled by a display code corresponding to the target indicator light.

[0081] In some embodiments, the display code corresponding to the target indicator light may include a signal code for controlling the on / off state of the target indicator light. For example, if the first power consumption level P1 is pre-set to be represented by lighting the first indicator light in the indicator light module, then the first power consumption level P1 corresponds to a target indicator light, and the target indicator light is the first indicator light in the indicator light module. Since the target indicator light needs to be lit, the display code corresponding to the target indicator light is a signal code for controlling the lighting of the target indicator light.

[0082] In some embodiments, the display code corresponding to the target indicator light may include a signal code for controlling the display color of the target indicator light. For example, if the second power consumption level P2 is pre-set to be represented by the first indicator light in the indicator light module being green and the second indicator light being yellow, then the second power consumption level P2 corresponds to two target indicator lights, the first and second indicator lights in the indicator light module, and the display code corresponding to the first indicator light is a signal code for controlling the first indicator light to be green, and the display code corresponding to the second indicator light is a signal code for controlling the second indicator light to be yellow.

[0083] It should be noted that, during implementation, any suitable method may be used to send the display code corresponding to each target indicator light to the control unit corresponding to the target indicator light, and the embodiments of the present disclosure are not limited thereto. In some embodiments, when the method is performed by a graphics card GPU, the display code corresponding to the target indicator light may be output via the GPU's general-purpose input / output (GPIO) port to the control unit corresponding to the target indicator light.

[0084] In the above embodiment, based on the current power consumption level, a display code corresponding to at least one target indicator light is determined from the indicator light module; the display code corresponding to each target indicator light is sent to the control unit corresponding to the target indicator light, so that the control unit controls the display state of the target indicator light based on the received display code. In this way, the display state of each target indicator light can be quickly and directly controlled using the display code corresponding to the at least one target indicator light corresponding to the current power consumption level, thereby intuitively reflecting the current power consumption level of the graphics card through the display state of the at least one target indicator light in the indicator light module.

[0085] In some embodiments, step S111 may include the following step S131:

[0086] Step S131: Read target display control information corresponding to the current power consumption level from a first register of the graphics card.

[0087] Here, the first register may be any suitable register in the graphics card, which is not limited in the embodiment of the present disclosure. For example, the first register may be a Basic Input Output System (BIOS) register, or other registers.

[0088] The first register may store display control information corresponding to each power consumption level, wherein the display control information corresponding to each power consumption level may be set in the first register when the graphics card leaves the factory, or may be set by the user according to actual conditions.

[0089] In the above embodiment, by reading the target display control information corresponding to the current power consumption level from the first register of the graphics card, the efficiency of determining the target display control information can be improved, thereby reducing the delay in the process of controlling the display state of the display component based on the current power consumption level, so that the user can determine the current power consumption level of the graphics card more promptly according to the display state of the display component.

[0090] In some embodiments, the above method may further include the following step S141:

[0091] Step S141 : in response to obtaining display control information corresponding to at least one power consumption level configured in the first operation interface, updating the display control information corresponding to the at least one power consumption level into the first register.

[0092] Here, the first operation interface may be any suitable interactive interface displayed on a computer device, and the embodiment of the present disclosure is not limited to this.

[0093] It is understandable that the display control information corresponding to the power consumption level can be manually configured by the user in the first operation interface, or can be automatically configured in the first operation interface through an intelligent tool, and the embodiments of the present disclosure are not limited to this.

[0094] In some implementations, the display control information corresponding to the configured at least one power consumption level may be updated to the first register by calling an application programming interface (API) of a graphics card driver to access the first register.

[0095] In the above embodiment, the display control information corresponding to at least one power consumption level can be configured in the first operation interface. In this way, the display state of the display component corresponding to each power consumption level can be customized according to the actual needs of the user, thereby better meeting the needs of the user.

[0096] In some embodiments, the power consumption level classification parameter includes a power consumption value interval corresponding to at least one preset power consumption level; the above step S102 may include the following step S151:

[0097] Step S151: determining the power consumption level of the graphics card whose corresponding power consumption value interval in the at least one power consumption level includes the current power consumption as the target power consumption level of the graphics card.

[0098] Here, the power consumption value interval corresponding to at least one power consumption level can be pre-set by those skilled in the art according to actual needs, and the embodiments of the present disclosure are not limited to this.

[0099] In some embodiments, the power consumption level classification parameter is read from a third register of the graphics card. The above method may further include the following step S161:

[0100] Step S161: In response to obtaining the power consumption level classification parameters configured in the third operation interface, the power consumption level classification parameters are stored in the third register.

[0101] Here, the third operation interface can be any suitable interactive interface displayed on a computer device, and the embodiment of the present disclosure is not limited to this.

[0102] The third register may be any suitable register in the graphics card, and the present disclosure is not limited thereto. For example, the third register may be a BIOS register or other register. In implementation, the third register may be the same register as the first register or may be a different register.

[0103] It is understandable that the power consumption level classification parameters can be manually configured by the user in the third operation interface, or can be automatically configured in the third operation interface through an intelligent tool, and the embodiments of the present disclosure are not limited to this.

[0104] In some implementations, the configured power consumption level division parameters can be stored in the third register by calling an API for a graphics card driver to access the third register.

[0105] In the above embodiment, the power consumption level division parameters can be configured in the third operation interface. In this way, the power consumption levels can be customized according to the actual needs of the user, thereby better meeting the needs of the user.

[0106] An embodiment of the present disclosure provides a power consumption processing method, which can be executed by a GPU in a graphics card or by a processor of a computer device having a graphics card. Figure 2 A schematic diagram of a power consumption processing method according to an embodiment of the present disclosure is provided. Figure 2 As shown, the method may include the following steps S201 to S204:

[0107] Step S201: Acquire a plurality of first sampled power consumptions of the graphics card collected by the power consumption collection component within a preset time period before the current moment.

[0108] Step S202: determining the current average power consumption of the graphics card based on the average value of the plurality of first sampled power consumptions.

[0109] Here, the preset duration can be a pre-set default duration, or a duration configured by the user according to actual needs. For example, the preset duration can be 0.5 seconds, 1 second, or 2 seconds.

[0110] The current average power consumption of the graphics card refers to the average power consumption of the graphics card in the preset time period before the current moment. For example, if the preset time period is 2 seconds, the current average power consumption of the graphics card can be the average power consumption of the graphics card in the 2 seconds before the current moment.

[0111] Step S203: determining the current power consumption level of the graphics card based on the current average power consumption and preset power consumption level classification parameters.

[0112] Step S204: Based on the current power consumption level, controlling the display state of the display component provided on the graphics card.

[0113] Here, steps S203 to S204 correspond to steps S102 to S103 in the aforementioned embodiment, respectively. When implementing, reference may be made to the implementation of the aforementioned steps S102 to S103.

[0114] In the disclosed embodiment, the current power consumption level of the graphics card is determined by obtaining the average power consumption of the graphics card within a preset period of time before the current moment, and based on the current average power consumption and a preset power consumption level classification parameter. In this way, since the power consumption of a graphics card typically fluctuates frequently, the current power consumption level of the graphics card can be more accurately determined based on the current average power consumption and the preset power consumption level classification parameter. This allows the current power consumption level of the graphics card to be more accurately reflected through the display status of the display component, allowing the user to more accurately monitor the workload of the graphics card.

[0115] In some embodiments, after step S201, the method further includes steps S211 to S213:

[0116] Step S211: Obtain multiple second sampled power consumptions of the graphics card collected within the preset time period before the current moment every preset time period, and update the current average power consumption of the graphics card based on the average value of the multiple second sampled power consumptions to obtain the updated current average power consumption.

[0117] Step S212: Based on the updated current average power consumption and the power consumption level classification parameter, the current power consumption level of the graphics card is updated to obtain an updated current power consumption level.

[0118] Step S213: updating the display state of the display component based on the updated current power consumption level.

[0119] It is understood that through the above steps S211 to S213, the current power consumption level of the graphics card can be updated at preset time intervals, thereby updating the display status of the display component. In this way, the display status of the display component can be updated to reflect changes in the current power consumption level of the graphics card in a more timely manner, thereby better meeting the user's usage needs.

[0120] In some embodiments, when the executor of the method is a GPU of a graphics card, the GPU may send a reset signal RESET to the display component at preset intervals, and send a control signal corresponding to the updated current power consumption level to the display component after sending the reset signal RESET; after receiving the reset signal RESET, the display component may re-receive the control signal corresponding to the updated current power consumption level after the reset signal RESET ends, so as to refresh the display status corresponding to the updated current power consumption level.

[0121] In some embodiments, considering that the power consumption of the graphics card fluctuates frequently, if one wants to capture occasional power consumption changes, a smaller preset time duration can be set to increase the sensitivity of power consumption monitoring, thereby improving the real-time performance of updating the display status of the display component, so as to reflect the changes in the current power consumption level of the graphics card in a more real-time manner.

[0122] In some implementations, if you want to observe the average power consumption of a graphics card within a certain period of time, you can set a larger preset time length to reduce the sensitivity of power consumption monitoring, thereby reducing irregular fluctuations caused by overly dense power consumption level divisions, and better meeting user usage needs.

[0123] In some embodiments, the preset duration is read from a second register of the graphics card, and the method further includes the following step S221:

[0124] Step S221 , in response to obtaining the preset time length configured in the second operation interface, storing the preset time length in a preset second register.

[0125] Here, the second operation interface can be any suitable interactive interface displayed on the computer device, and the embodiments of the present disclosure are not limited to this. It should be noted that the second operation interface, as well as the first operation interface and the third operation interface mentioned above, can be the same operation page or different operation interfaces, which is not limited here.

[0126] The second register may be any suitable register in the graphics card, and the embodiments of the present disclosure are not limited thereto. For example, the second register may be a BIOS register or other registers.

[0127] It is understandable that the preset duration can be manually configured by the user in the second operation interface, or can be automatically configured in the second operation interface through an intelligent tool, and the embodiments of the present disclosure are not limited to this.

[0128] In some implementations, the configured preset duration may be stored in the second register by calling an API of a graphics card driver to access the second register.

[0129] In the above embodiment, the preset duration can be configured in the second operation interface. In this way, the preset duration can be customized according to the actual needs of the user, thereby better meeting the needs of the user.

[0130] An embodiment of the present disclosure provides a power consumption processing method, which can be executed by a GPU in a graphics card or by a processor of a computer device having a graphics card. Figure 3 A schematic diagram of a power consumption processing method according to an embodiment of the present disclosure is provided. Figure 3As shown, the method may include the following steps S301 to S305:

[0131] Step S301, obtaining the current power consumption of the graphics card.

[0132] Step S302: determining the current power consumption level of the graphics card based on the current power consumption and preset power consumption level classification parameters.

[0133] Step S303: Based on the current power consumption level, control the display state of the display component provided on the graphics card.

[0134] Here, steps S301 to S303 correspond to steps S101 to S103 in the aforementioned embodiment, respectively. When implementing, reference may be made to the implementation of the aforementioned steps S101 to S103.

[0135] Step S304: Obtain preset alarm configuration parameters; the alarm configuration parameters include alarm conditions and alarm display mode.

[0136] Step S305 : When the current power consumption satisfies the alarm condition, the display state of the display component is updated based on the alarm display mode.

[0137] Here, the alarm configuration parameters may be the default values ​​set when the processor leaves the factory, or may be pre-configured by the user according to actual needs, which is not limited in the embodiments of the present disclosure.

[0138] The alarm condition may include, but is not limited to, at least one of: current power consumption being greater than a preset alarm threshold, current power consumption being greater than a preset alarm threshold for multiple consecutive times, and the like.

[0139] The alarm display mode may include any suitable display mode for indicating the occurrence of an alarm, and is not limited here. In some embodiments, the alarm display mode may include, but is not limited to, at least one of a display color, a flashing frequency, etc. For example, when the current power consumption meets the alarm threshold, the display color for indicating the occurrence of an alarm may be set to red, and / or the flashing frequency for indicating the occurrence of an alarm may be set to a first preset frequency, so as to provide an alarm prompt through the display color and / or flashing frequency of the display component.

[0140] In the disclosed embodiment, preset alarm configuration parameters are obtained, including an alarm condition and an alarm display mode. When the current power consumption of the graphics card meets the alarm condition, the display state of the display component is updated based on the alarm display mode. In this way, the current power consumption of the graphics card can be monitored according to the preset alarm condition and alarm display mode, and an alarm prompt can be promptly issued by updating the display state of the display component when the current power consumption of the graphics card meets the alarm condition.

[0141] In some embodiments, the above method may further include the following step S311:

[0142] Step S311 , in response to obtaining the alarm condition and the alarm display mode configured in the fourth operation interface, storing the alarm condition and the alarm display mode in a fourth register of the graphics card.

[0143] The above step S304 may include the following step S312:

[0144] Step S312: Read the alarm condition and the alarm display mode from the fourth register.

[0145] Here, the fourth operation interface can be any suitable interactive interface displayed on a computer device, and the embodiments of the present disclosure are not limited to this. It should be noted that the fourth operation interface, as well as the first operation interface, the second operation interface, and the third operation interface mentioned above, can be the same operation page or different operation interfaces, and this is not limited here.

[0146] The fourth register may be any suitable register in the graphics card, and the present disclosure is not limited thereto. For example, the fourth register may be a BIOS register or other register.

[0147] It should be noted that the fourth register, and the above-mentioned first register, second register, and third register may be the same register or different registers.

[0148] It is understandable that the alarm conditions and alarm display methods can be manually configured by the user in the fourth operation interface, or can be automatically configured in the fourth operation interface through intelligent tools, and the embodiments of the present disclosure are not limited to this.

[0149] In some implementations, the configured alarm condition and alarm display mode may be stored in the fourth register by calling an API of a graphics card driver to access the fourth register.

[0150] In the above embodiment, the alarm condition and the alarm display mode can be configured in the fourth operation interface. In this way, the alarm condition and the alarm display mode can be customized according to the actual needs of the user, thereby better meeting the needs of the user.

[0151] The present disclosure provides a power consumption processing system. Figure 4 A schematic diagram of the structure of a power consumption processing system provided by an embodiment of the present disclosure is shown in FIG. Figure 4 As shown, the power consumption processing system includes: a graphics card 410, and a power consumption acquisition component 420 and a display component 430 connected to the graphics card 410; wherein,

[0152] The graphics card 410 includes a graphics processor 411;

[0153] The power consumption collection component 420 is connected to the input power supply 440 of the graphics card 410 and is used to collect the power consumption of the graphics card 410 and send the collected power consumption information to the graphics processor 411;

[0154] The graphics processor 411 is used to: receive the power consumption information sent by the power consumption acquisition component 420, and determine the current power consumption of the graphics card 410 based on the power consumption information; determine the current power consumption level of the graphics card 410 based on the current power consumption and preset power consumption level classification parameters; and control the display state of the display component 430 based on the current power consumption level.

[0155] In some embodiments, the graphics processor is further configured to: determine target display control information based on the current power consumption level; and control a display state of a display component provided on the graphics card based on the target display control information.

[0156] In some embodiments, the display component includes an indicator light module, the indicator light module includes at least one indicator light and a control unit corresponding to each of the indicator lights, and the target display control information includes at least one display code; the graphics processor is also used to: based on the current power consumption level, determine the display code corresponding to at least one target indicator light from the indicator light module; send the display code corresponding to each of the target indicator lights to the control unit corresponding to the target indicator light, so that the control unit controls the display status of the target indicator light based on the received display code.

[0157] In some embodiments, the graphics processor is further configured to read target display control information corresponding to the current power consumption level from a first register of the graphics card.

[0158] In some embodiments, the graphics processor is further configured to: in response to obtaining display control information corresponding to at least one power consumption level configured in the first operation interface, update the display control information corresponding to the at least one power consumption level into the first register.

[0159] In some embodiments, the current power consumption includes the current average power consumption; the graphics processor is further used to: obtain multiple first sampled power consumptions of the graphics card collected by the power consumption collection component within a preset time period before the current moment; and determine the current average power consumption of the graphics card based on the average value of the multiple first sampled power consumptions.

[0160] In some embodiments, after obtaining multiple first sampled power consumptions of the graphics card collected by the power consumption collection component within a preset time period before the current moment, the graphics processor is further used to: obtain multiple second sampled power consumptions of the graphics card collected within a preset time period before the current moment every preset time period, and update the current average power consumption of the graphics card based on the average value of the multiple second sampled power consumptions to obtain an updated current average power consumption; update the current power consumption level of the graphics card based on the updated current average power consumption and the power consumption level classification parameter to obtain an updated current power consumption level; and update the display status of the display component based on the updated current power consumption level.

[0161] In some embodiments, the preset duration is read from the second register of the graphics card; the graphics processor is further used to: in response to obtaining the preset duration configured in the second operation interface, store the preset duration in a preset second register.

[0162] In some embodiments, the power consumption level division parameters include power consumption value ranges corresponding to at least one preset power consumption level; the graphics processor is also used to: determine the power consumption level of the power consumption value range corresponding to the at least one power consumption level including the current power consumption as the target power consumption level of the graphics card.

[0163] In some embodiments, the power consumption level division parameter is read from the third register of the graphics card; the graphics processor is also used to: in response to obtaining the power consumption level division parameter configured in the third operation interface, store the power consumption level division parameter in the third register.

[0164] In some embodiments, the graphics processor is further used to: obtain preset alarm configuration parameters; the alarm configuration parameters include alarm conditions and alarm display modes; and when the current power consumption meets the alarm conditions, update the display status of the display component based on the alarm display mode.

[0165] In some embodiments, the graphics processor is further used to: in response to obtaining the alarm condition and the alarm display mode configured in the fourth operation interface, store the alarm condition and the alarm display mode in the fourth register of the graphics card; and read the alarm condition and the alarm display mode from the fourth register.

[0166] The following describes the application of the power consumption processing method provided by the embodiment of the present disclosure in a practical scenario, taking an LED light bar as an example of a display component.

[0167] The disclosed embodiments provide a power consumption processing method and a power consumption processing system. These methods can provide intuitive feedback to users directly through the display status of an LED light bar on the graphics card's exterior, without relying on user input or operation, to quickly inform users of the graphics card's current power consumption level. The display color and illuminated length of the LED light bar on the graphics card's exterior vary with the graphics card's current power consumption. This allows the LED light bar on the graphics card's exterior to display the graphics card's current power consumption level in real time on the hardware, significantly enhancing the graphics card's appearance and technological appeal.

[0168] Figure 5A A schematic diagram of the structure of a power consumption processing system provided by an embodiment of the present disclosure is shown in FIG. Figure 5A As shown, the power consumption processing system may include: a GPU chip 510 of a graphics card, an external PCIE power input 520 of a graphics card, a PCIE gold finger power input 530 of a graphics card, a power consumption collection component 540, an LED light bar 550, an LED power supply control module 560, a BIOS register 570, and an operating system driver 580, wherein:

[0169] The external PCIE power input 520 of the graphics card and the PCIE gold finger power input 530 of the graphics card are two parts of the input power of the graphics card;

[0170] The power consumption collection component 540 is connected to the external PCIE power supply input 520 of the graphics card and the PCIE gold finger power input 530 of the graphics card to collect the power consumption of the graphics card, and sends the collected power consumption information to the GPU chip 510 of the graphics card through the I2C protocol;

[0171] The GPU chip 510 is configured to: receive power consumption information sent by the power consumption acquisition component 540, and determine the current power consumption of the graphics card based on the power consumption information; determine the current power consumption level of the graphics card based on the current power consumption of the graphics card and the preset power consumption level classification parameters read from the BIOS register 570; and control the display state of the LED light bar 550 based on the current power consumption level;

[0172] The operating system driver 580 is used to provide an API for accessing the BIOS register and store the power consumption level classification parameters configured by the user in the BIOS register 570 .

[0173] In some implementations, the power consumption level classification parameter may be determined by the number of LED lamp beads in the LED light bar, and the power consumption levels may be classified according to the maximum power consumption of the graphics card. For example, if the total number of LED beads in an LED light strip is 10, the number of power consumption levels is less than or equal to 10. The power consumption levels can be divided into 10 power consumption levels, P1 to P10, with power consumption levels P1 to P10 corresponding to the 10 LED beads in the LED light strip. For example, if the total power consumption of the graphics card is 300W, the power consumption levels are 0-30W as power consumption level P1, 31-60W as power consumption level P2, 61-90W as power consumption level P3, 91-120W as power consumption level P4, 121-150W as power consumption level P5, 151-180W as power consumption level P6, 181-210W as power consumption level P7, 211-240W as power consumption level P8, 241-270W as power consumption level P9, and 271-300W as power consumption level P10. The power consumption display level parameters can be set in the BIOS register before shipment.

[0174] In some embodiments, the sensitivity of power consumption monitoring can be set by a preset duration, that is, the preset duration is used to control the interval at which the GPU chip refreshes the display status of the LED light bar. The GPU chip can send a reset signal RESET to the LED light bar at every preset interval, and after sending the reset signal RESET, send a control signal corresponding to the updated current power consumption level to the LED light bar. After receiving the reset signal RESET, the LED light bar can receive the control signal corresponding to the updated current power consumption level again after the reset signal RESET ends, thereby refreshing the display status corresponding to the updated current power consumption level.

[0175] In some embodiments, the graphics card's power input includes two parts: one is a high-speed serial computer expansion bus standard Peripheral Component Interconnect Express (PCIE) gold finger power input, and the other is from an external PCIE power input. During implementation, two or more current and voltage monitoring chips can be selected to obtain the graphics card's sampled power consumption. The sampled power consumption collected by the current and voltage monitoring chips is sent to the graphics card's GPU chip via the output pins of the I2C circuit. The GPU chip can then obtain the binary code corresponding to the current sampled power and obtain the current sampled power consumption by searching the corresponding table between the binary code and the sampled power consumption within the GPU chip. The chip reads the preset time duration T_reset in the BIOS register internally and converts the average power consumption within the preset time duration T_reset to obtain the real-time power consumption to be displayed. The P_level setting in the BIOS is then searched, and after reading the RGB (Red-Green-Blue) code setting value of the current power consumption level P_level in the BIOS, the GPU's GPIO outputs the RGB code representing the real-time power consumption to the LED module for display.

[0176] Figure 5B A schematic diagram of the structure of a power consumption acquisition circuit for a graphics card provided by an embodiment of the present disclosure is shown in FIG. Figure 5B As shown, the power consumption of the PCIE gold finger power input and the power consumption of the external PCIE power input can be collected by differential acquisition through current sensing precision resistors Rsense 1 and Rsense 2, wherein the pin V12_PCIE can be connected to the PCIE gold finger power input, and the pin V12_EXT8_IN can be connected to the external PCIE power input; the current and voltage monitoring chip 541 can summarize the power consumption of the PCIE gold finger power input and the power consumption of the external PCIE power input, and output them to the GPU chip through the I2C serial data pin SDA.

[0177] In some embodiments, the GPU chip can convert all the sampled power consumptions of the graphics card obtained within the preset time length T_reset before the current moment into the average power consumption within the preset time length T_reset, and then read the current power consumption level corresponding to the average power consumption from the BIOS register to determine which LED lamp beads in the LED light bar to light up. During implementation, the color control of the LED lamp beads can be supported by setting the value of the RGB code (corresponding to the display code in the aforementioned embodiment) corresponding to the current power consumption level in the BIOS register. For example, if it is monitored that the current power consumption level belongs to the lowest power consumption level P1, and the lowest power consumption level P1 is specified to light up the first LED lamp bead and the display color of the first LED lamp bead is green, then the target display control information corresponding to the power consumption level P1 in the BIOS register can be set to include an RGB code, and the value of the RGB code is 0x00FF00, where the first two digits of the hexadecimal code correspond to the brightness of red, the middle two digits correspond to the brightness of green, and the last two digits correspond to the brightness of blue. After the GPU chip reads an RGB code corresponding to power consumption level P1 from the BIOS register, it converts the RGB code into binary (0b'000000001111111100000000), and then outputs the binary RGB code to the LED light strip through the GPIO interface of the GPU chip to control the lighting of the first LED bead in the LED light strip and control the display color of the LED bead to be green.

[0178] For example, for a graphics card with a maximum power consumption of 300W and three LEDs, the power consumption levels are as follows: Power consumption level P1 corresponds to a power consumption range of 0 to 100W, power consumption level P2 corresponds to a power consumption range of 101 to 200W, and power consumption level P3 corresponds to a power consumption range greater than 200W. The preset duration T_reset is set to 0.5 seconds. The hexadecimal values ​​of the RGB codes corresponding to each power consumption level in the BIOS register are: P1 (0x00FF00 00000000000), P2 (0x00FF00FFFF00 000000), and P3 (0x00FF00 FFFF00 FF0000). When the GPU chip reads that the average power consumption within the current 0.5s is less than 100W, the current power consumption level is P1, and the RGB code corresponding to the power consumption level P1 is output to the LED light bar, that is, only the first LED lamp bead is lit and the first LED lamp bead is controlled to display green; when the GPU reads that the average power consumption within the current 0.5s is between 100-200W, the current power consumption level is P2, and the RGB code corresponding to the power consumption level P2 is output to the LED light bar, that is, the first LED lamp bead and the second LED lamp bead are lit, and display green and yellow respectively; when the GPU reads that the average power consumption within the current 0.5s is greater than 200W, the current power consumption level is P3, and the RGB code corresponding to the power consumption level P3 is output to the LED light bar, that is, the first LED lamp bead, the second LED lamp bead and the third LED lamp bead are all lit, and display green, yellow and red respectively.

[0179] In some embodiments, an LED light strip can use multiple LED lamp beads cascaded together in series, each lamp bead can be recorded as a pixel, and each pixel has a set of 3 times 8-bit RGB codes, a total of 24-bit data structure (i.e., R7 R6R5 R4 R3 R2 R1 R0 G7 G6 G5 G4 G3 G2 G1 G0 B7B6 B5 B4 B3 B2 B1 B0), which is used to control its color and brightness information. For n serially cascaded LED lamp beads, the GPU chip can output n groups of continuous 24-bit data through GPIO. After the LED light strip receives n sets of consecutive RGB codes transmitted from the GPU chip via GPIO, the first 24-bit data transmitted is extracted by the first LED bead and sent to the data latch inside the LED bead. The remaining RGB code is shaped and amplified by the internal shaping circuit and then forwarded to the next cascaded LED bead (i.e., the second LED bead) through the output port of the control chip corresponding to the first LED bead (corresponding to the control unit in the aforementioned embodiment). In this way, the RGB code data is reduced by 24 bits with each transmission of each LED bead until all LED beads obtain their respective 24-bit RGB codes, and this data cycle is displayed as complete. The LED light strip then waits for the reset signal T_reset and, after receiving the reset signal T_reset, repeats the above steps of extracting the RGB code to start the next refresh cycle.

[0180] Figure 5C This is a schematic diagram of extracting RGB codes from LED light strips in a power consumption processing method provided by an embodiment of the present disclosure. Figure 5C As shown, taking an LED light strip including three LED lamp beads L1, L2 and L3 as an example, after the LED light strip receives three groups of continuous 24-bit RGB codes transmitted from the GPIO interface of the GPU chip, the first 24-bit data transmitted is extracted by the first LED lamp bead L1 and is sent to the data latch D1 inside the first LED lamp bead L1. The remaining RGB code is shaped and amplified by the internal shaping processing circuit and then forwarded to the next cascaded LED lamp bead (i.e., the second LED lamp bead) through the output port of the control chip corresponding to the first LED lamp bead (corresponding to the control unit in the aforementioned embodiment). In this way, the group of RGB code data is reduced by 24 bits each time it is transmitted by an LED lamp bead, until the data latches D1, D2 and D3 inside the three LED lamp beads L1, L2 and L3 all obtain their respective 24-bit RGB codes.

[0181] In some embodiments, the power consumption processing system provided by the embodiment of the present disclosure can also support the user to customize the power consumption level division parameter P_level, the preset duration T_reset, and the color control information of the LED light (i.e., RGB code) in the operation interface. During implementation, the API of the graphics card driver can be called to access the BIOS register to allow the user to specify the level division rules in the power consumption level division parameter P_level. The user can specify multiple power consumption levels within the number of LED lamp beads in the LED light bar and the power consumption value range corresponding to each power consumption level. For example, if there are a total of 10 LED lamp beads (corresponding to 10 pixels), the user can specify the number of power consumption levels as 5, that is, 2 pixels as one power consumption level; the power consumption levels can be equally spaced or not. For example, if the user is more concerned about the power consumption of the program currently running within 100-200W, then 0-100W can be specified as power consumption level P1, 101-130W as power consumption level P2, 131-160W as power consumption level P3, 161-200W as power consumption level P4, and greater than 200W as power consumption level P5. In some embodiments, users can also dynamically monitor power consumption fluctuations by specifying a preset duration T_reset, which represents monitoring sensitivity, based on their needs. In some embodiments, users can also customize the display color of each LED bead at each power consumption level based on their personal preferences. The user-defined power consumption level parameter P_level, the preset duration T_reset, and the LED light color control information can all be obtained by the operating system driver and passed to the corresponding registers to implement the display control of the LED light bar.

[0182] In some embodiments, the current power consumption and / or current power consumption level of the graphics card is represented by the progress bar of the LED light bar (i.e., the length of lighting). The display colors of the LED beads in the LED light bar can be consistent or can be gradually changed. For example, see Figure 5D , the current power consumption and / or current power consumption level of the graphics card can be represented by the progress bar of the LED light bar 20 set on the graphics card 10. Figure 5E , the display colors of the LED lamp beads 511 in the LED light bar 51 are sequentially transitioned from light to dark. Figure 5F , (a) to (d) correspond to the display states of the LED light bar 52 under four power consumption levels from low to high. As the power consumption level increases, the progress bar of the LED light bar 52 gradually lengthens, and the display colors of each LED lamp bead in the LED light bar 52 change gradually in sequence.

[0183] In some embodiments, all LED lamp beads in all LED light strips can be lit at the same time and keep the same color, and only the 256-bit color difference can be controlled to represent the current power consumption and / or current power consumption level. For example, the LED lamp beads display colors from light orange to dark orange, representing low power consumption to high power consumption. For example, see Figure 5G , (e) to (h) correspond to the display status of the LED light bar 53 under four power consumption levels from low to high. Under the four power consumption levels, the progress bar of the LED light bar 53 remains unchanged, and the display colors of the various LED lamp beads in the LED light bar 53 are consistent. As the power consumption level increases, the display colors of the various LED lamp beads in the LED light bar 53 change synchronously.

[0184] It should be noted that the embodiments of the present disclosure are not limited to the method of using the display status of the LED light bar in the above-mentioned embodiment to represent the current power consumption and / or current power consumption level of the graphics card. Those skilled in the art can choose any appropriate method according to actual needs.

[0185] In the disclosed embodiments, on the one hand, the LED light bar on the graphics card is utilized to provide valuable information to the user when the LED light bar is in operation. On the other hand, the display status of the LED light bar directly provides the user with intuitive feedback, quickly informing the user of the current power consumption and / or current power consumption level of the graphics card, making it easier for the user to monitor and test the power consumption information of the graphics card. Furthermore, the constantly changing color of the LED light beads under different loads enhances the technological appearance of the graphics card. In addition, the user can customize the power consumption level classification rules, the preset duration representing the monitoring sensitivity, and / or the display progress bar length and / or display color of the LED light bar corresponding to each power consumption level according to their preferences, thereby better meeting the user's needs.

[0186] Based on the foregoing embodiments, an embodiment of the present disclosure provides a power consumption processing device, which includes the units included and the modules included in each unit, and can be implemented by a processor in a computer device; of course, it can also be implemented by a specific logic circuit; in the implementation process, the processor can be a central processing unit (CPU), a microprocessor (MPU), a digital signal processor (DSP) or a field programmable gate array (FPGA), etc.

[0187] Figure 6 A schematic diagram of the structure of a power consumption processing device provided by an embodiment of the present disclosure is shown in FIG. Figure 6As shown, the power consumption processing device 600 includes: a first acquisition module 610, a first determination module 620 and a first control module 630, wherein:

[0188] A first acquisition module 610 is configured to acquire the current power consumption of the graphics card;

[0189] A first determining module 620 is configured to determine a current power consumption level of the graphics card based on the current power consumption and a preset power consumption level classification parameter;

[0190] The first control module 630 is configured to control the display state of the display component provided on the graphics card based on the current power consumption level.

[0191] In some embodiments, the first control module is further configured to: determine target display control information based on the current power consumption level; and control a display state of a display component provided on the graphics card based on the target display control information.

[0192] In some embodiments, the display component includes an indicator light module, the indicator light module includes at least one indicator light and a control unit corresponding to each of the indicator lights, and the target display control information includes at least one display code; the first control module is also used to: based on the current power consumption level, determine the display code corresponding to at least one target indicator light from the indicator light module; send the display code corresponding to each of the target indicator lights to the control unit corresponding to the target indicator light, so that the control unit controls the display status of the target indicator light based on the received display code.

[0193] In some embodiments, the first control module is further configured to read target display control information corresponding to the current power consumption level from a first register of the graphics card.

[0194] In some embodiments, the device further includes: a first update module for, in response to obtaining display control information corresponding to at least one power consumption level configured in the first operation interface, updating the display control information corresponding to the at least one power consumption level into the first register.

[0195] In some embodiments, the current power consumption includes the current average power consumption; the first acquisition module is also used to: obtain multiple first sampled power consumptions of the graphics card collected by the power consumption collection component within a preset time period before the current moment; and determine the current average power consumption of the graphics card based on the average value of the multiple first sampled power consumptions.

[0196] In some embodiments, the device also includes: a second update module, used to: obtain multiple second sampled power consumptions of the graphics card collected within the preset time period before the current moment every preset time period, and update the current average power consumption of the graphics card based on the average value of the multiple second sampled power consumptions to obtain an updated current average power consumption; update the current power consumption level of the graphics card based on the updated current average power consumption and the power consumption level classification parameters to obtain an updated current power consumption level; and update the display status of the display component based on the updated current power consumption level.

[0197] In some embodiments, the preset duration is read from the second register of the graphics card, and the device also includes: a first storage module, which is used to store the preset duration in a preset second register in response to obtaining the preset duration configured in the second operation interface.

[0198] In some embodiments, the power consumption level division parameters include power consumption value ranges corresponding to at least one preset power consumption level; the first determination module is also used to: determine the power consumption level of the power consumption value range corresponding to the at least one power consumption level including the current power consumption as the target power consumption level of the graphics card.

[0199] In some embodiments, the power consumption level division parameter is read from the third register of the graphics card; the device also includes: a second storage module, which is used to store the power consumption level division parameter in the third register in response to obtaining the power consumption level division parameter configured in the third operation interface.

[0200] In some embodiments, the device also includes: a second acquisition module, used to obtain preset alarm configuration parameters; the alarm configuration parameters include alarm conditions and alarm display methods; a third update module, used to update the display status of the display component based on the alarm display method when the current power consumption meets the alarm conditions.

[0201] In some embodiments, the device also includes: a third storage module, used to store the alarm condition and the alarm display mode configured in the fourth operation interface in response to obtaining the alarm condition and the alarm display mode in the fourth register of the graphics card; the second acquisition module is also used to read the alarm condition and the alarm display mode from the fourth register.

[0202] The description of the above device embodiment is similar to the description of the above method embodiment and has similar beneficial effects as the method embodiment. In some embodiments, the functions or modules included in the device provided by the embodiment of the present disclosure can be used to perform the method described in the above method embodiment. For technical details not disclosed in the device embodiment of the present disclosure, please refer to the description of the method embodiment of the present disclosure for understanding.

[0203] It should be noted that, in the embodiments of the present disclosure, if the above method is implemented in the form of a software function module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the embodiment of the present disclosure is essentially or the part that contributes to the relevant technology can be embodied in the form of a software product, which is stored in a storage medium and includes a number of instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the methods described in each embodiment of the present disclosure. The aforementioned storage medium includes: various media that can store program codes, such as a U disk, a mobile hard disk, a read-only memory (ROM), a magnetic disk or an optical disk. In this way, the embodiments of the present disclosure are not limited to any specific hardware, software or firmware, or any combination of hardware, software and firmware.

[0204] An embodiment of the present disclosure provides a computer device, including a memory and a processor, wherein the memory stores a computer program that can be run on the processor, and when the processor executes the program, some or all of the steps in the above method are implemented.

[0205] The present disclosure provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements some or all of the steps in the above method. The computer-readable storage medium may be transient or non-transient.

[0206] An embodiment of the present disclosure provides a computer program, including computer-readable codes. When the computer-readable codes are executed in a computer device, a processor in the computer device executes some or all of the steps for implementing the above method.

[0207] The present disclosure provides a computer program product, which includes a non-transitory computer-readable storage medium storing a computer program, and when the computer program is read and executed by a computer, implements some or all of the steps in the above method. The computer program product can be implemented specifically by hardware, software, or a combination thereof. In some embodiments, the computer program product is specifically embodied as a computer storage medium. In other embodiments, the computer program product is specifically embodied as a software product, such as a software development kit (SDK), etc.

[0208] It should be noted that the descriptions of the various embodiments above tend to emphasize the differences between the embodiments, and reference can be made to the similarities or similarities between them. The descriptions of the above embodiments of the device, storage medium, computer program, and computer program product are similar to the descriptions of the above-mentioned method embodiments and have similar beneficial effects as the method embodiments. For technical details not disclosed in the embodiments of the device, storage medium, computer program, and computer program product disclosed herein, please refer to the description of the method embodiments disclosed herein for understanding.

[0209] It should be noted that Figure 7 A schematic diagram of a hardware entity of a computer device in an embodiment of the present disclosure is shown in FIG. Figure 7 As shown, the hardware entity of the computer device 700 includes: a processor 701, a communication interface 702 and a memory 703, wherein:

[0210] Processor 701 generally controls the overall operation of computer device 700 .

[0211] The communication interface 702 enables the computer device to communicate with other terminals or servers through a network.

[0212] The memory 703 is configured to store instructions and applications executable by the processor 701. It can also cache data to be processed or processed by the processor 701 and various modules in the computer device 700 (for example, image data, audio data, voice communication data, and video communication data). This can be implemented using flash memory (FLASH) or random access memory (RAM). Data can be transmitted between the processor 701, the communication interface 702, and the memory 703 via a bus 704.

[0213] It should be understood that “one embodiment” or “an embodiment” mentioned throughout the specification means that specific features, structures or characteristics related to the embodiment are included in at least one embodiment of the present disclosure. Therefore, “in one embodiment” or “in an embodiment” appearing throughout the specification does not necessarily refer to the same embodiment. In addition, these specific features, structures or characteristics can be combined in one or more embodiments in any suitable manner. It should be understood that in the various embodiments of the present disclosure, the size of the serial numbers of the above-mentioned steps / processes does not mean the order of execution, and the execution order of each step / process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present disclosure. The serial numbers of the embodiments of the present disclosure are for description only and do not represent the advantages and disadvantages of the embodiments.

[0214] It should be noted that, in this document, the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, article, or apparatus comprising a series of elements includes not only those elements but also other elements not explicitly listed, or elements inherent to such process, method, article, or apparatus. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of other identical elements in the process, method, article, or apparatus comprising the element.

[0215] In the several embodiments provided in the present disclosure, it should be understood that the disclosed devices and methods can be implemented in other ways. The device embodiments described above are merely schematic. For example, the division of the units is merely a logical function division. In actual implementation, there may be other division methods, such as: multiple units or components can be combined, or can be integrated into another system, or some features can be ignored or not executed. In addition, the coupling, direct coupling, or communication connection between the components shown or discussed can be through some interfaces, and the indirect coupling or communication connection of the devices or units can be electrical, mechanical or other forms.

[0216] The units described above as separate components may or may not be physically separate, and the components shown as units may or may not be physical units; they may be located in one place or distributed across multiple network units; some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment. In addition, the functional units in the various embodiments of the present disclosure may all be integrated into one processing unit, or each unit may be separately used as a unit, or two or more units may be integrated into one unit; the above-mentioned integrated units may be implemented in the form of hardware or in the form of hardware plus software functional units.

[0217] Those skilled in the art will understand that all or part of the steps of implementing the above-mentioned method embodiment can be completed by hardware related to program instructions, and the aforementioned program can be stored in a computer-readable storage medium. When the program is executed, it executes the steps of the above-mentioned method embodiment; and the aforementioned storage medium includes: mobile storage devices, read-only memories (ROM), magnetic disks or optical disks, and other media that can store program codes.

[0218] Alternatively, if the above-mentioned integrated unit of the present disclosure is implemented in the form of a software function module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present disclosure, or the part that contributes to the relevant technology, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes a number of instructions for enabling a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the methods described in each embodiment of the present disclosure. The aforementioned storage medium includes: various media that can store program codes, such as mobile storage devices, ROMs, magnetic disks, or optical disks.

[0219] The above is only an embodiment of the present disclosure, but the protection scope of the present disclosure is not limited thereto. Any changes or replacements that can be easily conceived by any technician familiar with this technical field within the technical scope disclosed in this disclosure should be covered by the protection scope of the present disclosure.

Claims

1. A power consumption processing method, characterized in that: The method comprises: Get the current power consumption of the graphics card; Determining a current power consumption level of the graphics card based on the current power consumption and a preset power consumption level classification parameter; Based on the current power consumption level, a display state of a display component disposed on the graphics card is controlled.

2. The method according to claim 1, characterized in that The controlling the display state of the display component disposed on the graphics card based on the current power consumption level includes: Based on the current power consumption level, determining target display control information; Based on the target display control information, a display state of a display component disposed on the graphics card is controlled.

3. The method according to claim 2, characterized in that The display component includes an indicator light module, the indicator light module includes at least one indicator light and a control unit corresponding to each of the indicator lights, and the target display control information includes at least one display code; The determining target display control information based on the current power consumption level includes: Based on the current power consumption level, determining a display code corresponding to at least one target indicator light from the indicator light module; The controlling the display state of the display component set on the graphics card based on the target display control information includes: The display code corresponding to each of the target indicator lights is sent to a control unit corresponding to the target indicator light, so that the control unit controls the display state of the target indicator light based on the received display code.

4. The method according to claim 2, characterized in that: The determining target display control information based on the current power consumption level includes: The target display control information corresponding to the current power consumption level is read from the first register of the graphics card.

5. The method according to claim 4, characterized in that The method further comprises: In response to acquiring display control information respectively corresponding to at least one power consumption level configured in the first operation interface, the display control information respectively corresponding to the at least one power consumption level is updated into the first register.

6. The method according to any one of claims 1 to 5, characterized in that The current power consumption includes current average power consumption; The obtaining of the current power consumption of the graphics card includes: Acquire multiple first sampled power consumptions of the graphics card collected by the power consumption collection component within a preset time period before a current moment; Based on an average value of the plurality of first sampled power consumptions, a current average power consumption of the graphics card is determined.

7. The method according to claim 6, characterized in that After acquiring a plurality of first sampled power consumptions of the graphics card collected by the power consumption collection component within a preset time period before the current moment, the method further includes: At every preset time period, a plurality of second sampled power consumptions of the graphics card collected within a preset time period before a current moment are obtained, and based on an average value of the plurality of second sampled power consumptions, a current average power consumption of the graphics card is updated to obtain an updated current average power consumption; Based on the updated current average power consumption and the power consumption level classification parameter, the current power consumption level of the graphics card is updated to obtain an updated current power consumption level; Based on the updated current power consumption level, the display state of the display component is updated.

8. The method according to claim 6, characterized in that The preset duration is read from a second register of the graphics card, and the method further includes: In response to acquiring the preset time length configured in the second operation interface, the preset time length is stored in a preset second register.

9. The method according to any one of claims 1 to 5, characterized in that The power consumption level classification parameter includes a power consumption value interval corresponding to at least one preset power consumption level; The determining the current power consumption level of the graphics card based on the current power consumption and a preset power consumption level classification parameter includes: The power consumption level whose power consumption value interval corresponds to the at least one power consumption level includes the current power consumption is determined as the target power consumption level of the graphics card.

10. The method according to any one of claims 1 to 5, characterized in that The power consumption level classification parameter is read from a third register of the graphics card; the method further includes: In response to acquiring the power consumption level classification parameters configured in the third operation interface, the power consumption level classification parameters are stored in the third register.

11. The method according to any one of claims 1 to 5, characterized in that The method further comprises: Obtaining preset alarm configuration parameters; the alarm configuration parameters include alarm conditions and alarm display methods; When the current power consumption meets the alarm condition, the display state of the display component is updated based on the alarm display mode.

12. The method according to claim 11, characterized in that The method further comprises: In response to acquiring the alarm condition and the alarm display mode configured in the fourth operation interface, storing the alarm condition and the alarm display mode in a fourth register of the graphics card; The obtaining of preset alarm configuration parameters includes: The alarm condition and the alarm display mode are read from the fourth register.

13. A power consumption processing system, characterized in that: The system comprises: A graphics card, and a power consumption acquisition component and a display component connected to the graphics card; wherein, The graphics card includes a graphics processor; The power consumption collection component is connected to the input power supply of the graphics card, and is used to collect the power consumption of the graphics card and send the collected power consumption information to the graphics processor; The graphics processor is used to: receive the power consumption information sent by the power consumption acquisition component, and determine the current power consumption of the graphics card based on the power consumption information; determine the current power consumption level of the graphics card based on the current power consumption and preset power consumption level classification parameters; and control the display state of the display component based on the current power consumption level.

14. A power consumption processing device, characterized in that: The device comprises: A first acquisition module, used to acquire the current power consumption of the graphics card; A first determination module, configured to determine a current power consumption level of the graphics card based on the current power consumption and a preset power consumption level classification parameter; The first control module is used to control the display state of the display component set on the graphics card based on the current power consumption level.

15. A computer device comprising a memory and a processor, wherein the memory stores a computer program executable on the processor, wherein: When the processor executes the program, the steps of the method according to any one of claims 1 to 12 are implemented.

16. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 12 are implemented.