A lighting effect control method and related equipment
By using a label recognition neural network model to extract labels from images and match lighting effect templates, the problem of limited lighting effect control is solved, enabling the diversification of lighting effects and full utilization of image information, thereby improving the user experience.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-09-27
- Publication Date
- 2026-03-10
Smart Images

Figure CN115884481B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of lighting, and more particularly to a lighting effect control method and related equipment. Background Technology
[0002] As an indispensable part of modern life, lighting fixtures have expanded beyond just illumination as people's living standards have improved. They are now used for decoration in various settings to adjust the atmosphere and mood of the environment, adding beauty to life.
[0003] Lighting effects refer to the brightness, color, and other parameters exhibited by lighting fixtures. With technological advancements, lighting fixtures and their corresponding lighting effect control methods have emerged that can flexibly adapt to different scenarios. People can set lighting effects according to their own lighting needs to control the brightness, color, and other parameters displayed by the lighting fixtures. One representative lighting effect control method involves acquiring user-uploaded images, analyzing and extracting colors from the images, and using the color with the highest proportion in the image as the color displayed by the lighting fixtures to control the lighting effect.
[0004] However, this method of controlling lighting effects based on image color parameters only results in changes in color, making the lighting effect too simplistic. Summary of the Invention
[0005] The purpose of this invention is to solve the problem of limited lighting effect control in existing systems. The lighting effect control method provided in this application includes:
[0006] The first aspect of this application provides a lighting effect control method, including:
[0007] Acquire the target image;
[0008] The instruction is to use a label recognition neural network model to extract labels from the target image, and after extracting the target image labels, to determine the target lighting effect template corresponding to the target image labels. The label recognition neural network model is obtained by training a neural network model with a specific structure using a training sample set. The target lighting effect template includes multiple different types of lighting effect parameters.
[0009] Based on the target lighting effect template, control the lighting effect of the target lighting fixture.
[0010] Based on the lighting effect control method provided in the first aspect of this application, optionally, the lighting effect control method is applied to a terminal device, and the step of indicating that a label recognition neural network model is used to extract labels from the target image, and determining the target lighting effect template corresponding to the target image label after extracting the target image label, includes:
[0011] The target image is uploaded to the server, and the server is instructed to use a label recognition neural network model to extract labels from the target image. After extracting the target image labels, the target lighting effect template corresponding to the target image labels is determined.
[0012] Before the step of controlling the lighting effect of the target luminaire according to the target lighting effect template, the lighting effect control method further includes:
[0013] Receive the target lighting effect template sent by the server.
[0014] Based on the lighting effect control method provided in the first aspect of this application, optionally, the lighting effect control method is applied to a server, and the step of acquiring the target image includes:
[0015] Acquire the target image uploaded by the terminal device;
[0016] The step of controlling the lighting effect of the target lighting fixture according to the target lighting effect template includes:
[0017] The target lighting effect template is sent to the terminal device to instruct the terminal device to control the lighting effect of the target lamp according to the target lighting effect template.
[0018] Based on the lighting effect control method provided in the first aspect of this application, optionally, the step of controlling the lighting effect of the target luminaire according to the target lighting effect template includes:
[0019] The lighting effect of the target lighting fixture is controlled according to a first lighting effect template, a second lighting effect template, or a third lighting effect template. The first lighting effect template is a new lighting effect template obtained by the server after modifying the parameters of the target lighting effect template based on the tone label of the target image. The second lighting effect template is a new lighting effect template obtained by the server after modifying the parameters of the target lighting effect template based on the RGB parameter values of the target color blocks in the target image. The third lighting effect template is a new lighting effect template obtained by the server after modifying the parameters of the target lighting effect template based on the tone label and the RGB parameter values of the target color blocks. The tone label is used to characterize the grayscale characteristics of the target image, and the RGB parameter values of the target color blocks are used to characterize the RGB parameter information included in the target image.
[0020] Based on the lighting effect control method provided in the first aspect of this application, optionally, the step of controlling the lighting effect of the target luminaire according to the target lighting effect template includes:
[0021] The image information of the target image is obtained, and the parameters of the target lighting effect template are corrected according to the image information to obtain a corrected target lighting effect template, wherein the image information is used to characterize specific feature information of the target image;
[0022] The target lighting fixture is controlled according to the modified target lighting effect template.
[0023] Based on the lighting effect control method provided in the first aspect embodiment of this application, optionally, after the step of controlling the lighting effect of the target luminaire according to the target lighting effect template, the lighting effect control method further includes:
[0024] In response to the user's setting operation on the lighting effect control interface, the image information of the target image to be acquired is determined according to the setting operation, wherein the image information is used to characterize specific feature information of the target image;
[0025] The image information is acquired, and the parameters of the target lighting effect template are corrected according to the image information to obtain the corrected target lighting effect template.
[0026] The target lighting fixture is controlled according to the modified target lighting effect template.
[0027] Based on the lighting effect control method provided in the first aspect of this application, optionally, the image information is a tone label of the target image, the tone label is used to characterize the grayscale characteristics of the target image, and the step of modifying the parameters of the target lighting effect template according to the image information to obtain a modified target lighting effect template includes:
[0028] The target lighting effect template is modified according to the tone label to obtain the first lighting effect template.
[0029] Based on the lighting effect control method provided in the first aspect of this application, optionally, the image information is the RGB parameter value of the target color block of the target image, the RGB parameter value of the target color block is used to characterize the RGB parameter information included in the target image, and the step of correcting the parameters of the target lighting effect template according to the image information to obtain a corrected target lighting effect template includes:
[0030] The target lighting effect template is modified according to the RGB parameter values of the target color block to obtain the second lighting effect template.
[0031] Based on the lighting effect control method provided in the first aspect of this application, optionally, the image information includes the tone label of the target image and the RGB parameter values of the target color blocks included in the target image. The tone label is used to characterize the grayscale characteristics of the target image, and the RGB parameter values of the target color blocks are used to characterize the RGB parameter information included in the target image. The step of correcting the parameters of the target lighting effect template according to the image information to obtain a corrected target lighting effect template includes:
[0032] The target lighting effect template is modified according to the tone label and the RGB parameter value of the target color block to obtain the third lighting effect template.
[0033] Based on the lighting effect control method provided in the first aspect embodiment of this application, optionally, before acquiring the target image, the lighting effect control method further includes:
[0034] Obtain the original training set consisting of the original images and the corresponding labels for the original images;
[0035] The original training set is augmented to obtain an augmented training set;
[0036] The enhanced training set is normalized to obtain the training sample set;
[0037] The label recognition neural network model is obtained by training a neural network model with a specific structure using a training sample set.
[0038] Based on the lighting effect control method provided in the first aspect of this application, optionally, the plurality of different types of lighting effect parameters include:
[0039] At least one or more of the following lighting effect parameters: brightness, change speed, color block saturation, and change direction;
[0040] Based on the lighting effect control method provided in the first aspect of this application, optionally, the target image is a video frame acquired at a specific time interval of the target video.
[0041] Based on the lighting effect control method provided in the first aspect embodiment of this application, optionally, after the step of controlling the lighting effect of the target luminaire according to the target lighting effect template, the lighting effect control method further includes:
[0042] Save the first correspondence between the target image and the target lighting effect template;
[0043] When the target image is acquired again, the label recognition neural network model is not enabled, and the target lighting effect template corresponding to the target image is determined by querying the first correspondence.
[0044] A second aspect of this application provides a lighting effect control method, which is applied to a target lighting fixture, including:
[0045] The device receives a lighting effect template sent by a terminal device or a server, wherein the lighting effect template is the target lighting effect template in the lighting effect control method described in any one of the first aspects of the embodiments of this application.
[0046] Configure the lighting effect parameters according to the various types of lighting effect parameters included in the lighting effect template.
[0047] A third aspect of this application provides a lighting effect control device, including:
[0048] The acquisition unit is used to acquire the target image;
[0049] The processing unit is configured to instruct the use of a label recognition neural network model to extract labels from the target image, and after extracting the target image labels from the target image, determine the target lighting effect template corresponding to the target image labels. The label recognition neural network model is obtained by training a neural network model with a specific structure using a training sample set. The target lighting effect template includes multiple different types of lighting effect parameters.
[0050] The control unit is used to control the lighting effect of the target lighting fixtures according to the target lighting effect template.
[0051] A fourth aspect of this application provides a terminal device, including:
[0052] Central processing unit, memory, input / output interfaces, wired or wireless network interfaces, and power supply;
[0053] The memory is either a short-term memory or a persistent memory;
[0054] The central processing unit is configured to communicate with the memory and execute instructions in the memory on the central processing unit to perform the method as described in any one of the first aspects of the embodiments of this application.
[0055] A fifth aspect of this application provides a server, including:
[0056] Central processing unit, memory, input / output interfaces, wired or wireless network interfaces, and power supply;
[0057] The memory is either a short-term memory or a persistent memory;
[0058] The central processing unit is configured to communicate with the memory and execute instructions in the memory on the central processing unit to perform the method as described in any one of the first aspects of the embodiments of this application.
[0059] A sixth aspect of this application provides a lighting fixture, including:
[0060] A receiving unit is configured to receive a lighting effect template sent by a terminal device or a server, wherein the lighting effect template is the target lighting effect template in the lighting effect control method as described in any one of the first aspects of the embodiments of this application;
[0061] The configuration unit is used to configure the lighting effect parameters according to the various types of lighting effect parameters included in the lighting effect template.
[0062] A seventh aspect of this application provides a computer-readable storage medium including instructions that, when executed on a computer, cause the computer to perform the lighting effect control method as described in any one of the first aspects of this application.
[0063] The eighth aspect of this application provides a computer program product containing instructions, characterized in that, when run on a computer, it causes the computer to execute the lighting effect control method as described in any one of the first aspects of this application. From the above technical solutions, it can be seen that the embodiments of this application have the following advantages: This solution acquires a target image. It processes the target image using a label recognition neural network model to obtain a target image label corresponding to the target image, determines a target lighting effect template corresponding to the target image label, and controls the target lighting fixture based on multiple different types of lighting effect parameters included in the target lighting effect template. The label recognition neural network model is pre-trained, and different types of labels are set for images expressing different meanings. Each label has a matching lighting effect template, and the lighting effect template includes multiple different types of lighting effect parameters. Therefore, when controlling the lighting effect based on the target image, multiple different types of parameters can be adjusted, making the lighting effect more varied and better meeting user needs. Attached Figure Description
[0064] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of this application. For those skilled in the art, other drawings can be obtained based on the provided drawings without creative effort.
[0065] Figure 1 A schematic diagram of an environment to which the lighting effect control method provided in this application is applicable;
[0066] Figure 2 A flowchart illustrating an embodiment of the lighting effect control method provided in this application;
[0067] Figure 3 A schematic diagram illustrating the grayscale histogram division method provided in this application;
[0068] Figure 4 A schematic diagram illustrating the method for determining tone labels provided in this application;
[0069] Figure 5 A schematic diagram of the low-tone grayscale histogram provided in this application;
[0070] Figure 6 A flowchart illustrating an embodiment of the label recognition neural network training process provided in this application;
[0071] Figure 7 This is another schematic flowchart illustrating an embodiment of the lighting effect control method provided in this application;
[0072] Figure 8 This is another schematic flowchart illustrating an embodiment of the lighting effect control method provided in this application;
[0073] Figure 9 This is another schematic flowchart illustrating an embodiment of the lighting effect control method provided in this application;
[0074] Figure 10 This is another schematic flowchart illustrating an embodiment of the lighting effect control method provided in this application;
[0075] Figure 11 This is a schematic diagram of a structural embodiment of the lighting effect control device provided in this application;
[0076] Figure 12 This is a schematic diagram of a terminal device embodiment provided in this application;
[0077] Figure 13 A schematic diagram of a server embodiment provided in this application;
[0078] Figure 14 This is a structural schematic diagram of an embodiment of the lighting fixture provided in this application. Detailed Implementation
[0079] This application provides a lighting effect control method for controlling the display effect of a target lighting fixture, so as to extract more information based on the image provided by the user, and then adjust multiple different types of parameters when controlling the lighting effect based on the target image, so as to make the lighting effect more varied.
[0080] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application are clearly and completely described below. Obviously, the described embodiments are only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of the present application.
[0081] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a particular order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments described herein can be implemented in a sequence other than that illustrated or described herein. Furthermore, the terms “comprising” and “having,” and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0082] Lighting effects refer to the brightness, color, and other parameters exhibited by lighting fixtures. With technological advancements, lighting fixtures and corresponding lighting effect control methods have emerged that can flexibly adapt to different scenarios. People can set their own lighting effects according to their individual lighting needs, controlling changes in brightness, speed, color, segmentation, and direction. One representative lighting effect control method involves analyzing the colors of user-uploaded images to control the lighting effects. However, this method, based on image color parameters, only changes the color of the lighting effect, failing to fully utilize the information contained in the user-uploaded image, resulting in overly simplistic lighting effects.
[0083] To address the aforementioned problems, this application provides a lighting effect control method to diversify lighting effect types and improve user experience. Before detailing this method, it is necessary to introduce its application environment; for details, please refer to [link to relevant documentation]. Figure 1 , Figure 1 This is a schematic diagram of an environment to which the lighting effect control method of this application is applicable.
[0084] The devices involved in the application environment of this method include: a lamp 101, a terminal device 102, and a server 103. The lamp 101 and the terminal device 102 are interconnected via wireless protocols such as Bluetooth or ZigBee. The terminal device 102 and the server 103 are connected via a wireless network. The lamp 101 can be a light-emitting device such as a light strip or a light box composed of multiple LEDs. The terminal device 102 is a user's mobile phone, tablet, or iPad. The server 103 is a single server or cloud server that can communicate with the terminal device 102 via the Internet. In actual operation, the user uploads a specific image to the server 103 through the terminal device 102. The server 103 analyzes the specific image, obtains the corresponding lighting effect template, and returns it to the terminal device 102. The lighting effect template is a parameter group composed of multiple different types of lighting effect parameters. The terminal device 102 forwards the lighting effect template to the target lamp. The target lamp changes its corresponding lighting effect parameters according to the lighting effect template, thereby completing the lighting effect control process.
[0085] It is understood that this diagram is for illustrative purposes only and may not reflect the actual implementation. For instance, the relationship between lamp 101 and terminal device 102 may not be one-to-one, and the terminal device may control multiple lamps in practice. Furthermore, lighting control commands may not be forwarded through the terminal device; that is, after determining the corresponding control command, the server 103 can directly send it to the lamp to complete the lighting control process. This depends on the specific circumstances and is not limited here.
[0086] based on Figure 1 Please refer to the provided application environment. Figure 2 The lighting effect control method provided in this application includes steps 201 to 203.
[0087] 201. Obtain the target image.
[0088] Specifically, the implementing device in this solution is a server or a user-used terminal device used to control the target lighting fixtures. Alternatively, the server and the user-used terminal device can cooperate to complete the process; no specific limitations are made here. The target image is an image acquired by the implementing device from its local storage or from other devices in response to user operations. The source and method of the target image are not limited here. To facilitate subsequent processing, pre-processing operations such as compression can be performed on the target image during acquisition. The specific operation method depends on the actual scenario and is not limited here.
[0089] 202. Instruct the use of a label recognition neural network model to extract labels from the target image, and after extracting the target image labels from the target image, determine the target lighting effect template corresponding to the target image labels. The label recognition neural network model is obtained by training a neural network model with a specific structure using a training sample set. The target lighting effect template includes multiple different types of lighting effect parameters.
[0090] Specifically, the target lighting effect template includes multiple different types of lighting effect parameters. A lighting effect template is a parameter group composed of multiple different types of lighting effect parameters, each with its own defined parameter values. Specific types of lighting effect parameters may include: brightness, change speed, color block saturation, and change direction, etc. Different lighting effect tags correspond to different lighting effect templates, and each lighting effect template has different lighting effect parameter values.
[0091] The label recognition neural network model can be deployed locally on the implementing device or on another device with a communication connection to the implementing device. Instructing the implementing device to use the label recognition neural network model for label extraction of the target image can be done by the implementing device instructing the use of its locally pre-built label recognition neural network model, or by instructing the other device to extract the labels from the target image. When the target image label is extracted, the device deploying the label recognition neural network model queries its locally pre-built correspondence between different image labels and different lighting effect templates to determine the target lighting effect template corresponding to the target image label.
[0092] The label recognition neural network model is obtained by training a neural network model with a specific structure using a training sample set. The label recognition neural network is a pre-trained neural network structure. During training, staff can first select the neural network model structure to use. Generally, existing, mature neural network model structures that perform well in image recognition problems can be used, such as Deep Residual Networks (ResNet) or Dense Convolutional Networks (DenseNet). The actual neural network model structure selected can be determined based on the specific circumstances, and no specific restrictions are imposed here. The training sample set used during training is an image set with corresponding labels. The labels corresponding to each image in the image set are marked by staff. Specific label categories can be divided according to various criteria. For example, based on emotion, they can be divided into different types such as happy, sad, and soothing; based on visual style, they can be divided into minimalist, pop art, Chinese style, or cyberpunk; in game scenes, they can be divided according to game type such as shooting, role-playing, casual, and action; based on the tension conveyed by the visuals, they can be divided into tense and peaceful. The output layer of the neural network model structure is configured to correspond to each label. The specific label categories can be determined according to the actual situation. The examples given above are merely illustrative and are not intended to limit the embodiments of this application. The trained label recognition neural network model has the ability to output labels corresponding to the target image. After obtaining the target image labels corresponding to the target image, a lighting effect template matching the target image can be determined based on the target image labels.
[0093] 203. Control the lighting effects of the target lighting fixtures according to the target lighting effect template.
[0094] Specifically, the target lighting fixtures in this embodiment can include two types based on their device structure: RGB lighting fixtures and RGBIC lighting fixtures. For RGB lighting fixtures, such as RGB light strips, each light-emitting unit is controlled uniformly by a controller. RGBIC lighting fixtures, such as RGBIC light strips, can be divided into multiple light-emitting units, each with its own control IC, allowing for individual light emission control of each unit. Due to the different lighting fixture structures, when controlling the lighting effects of the target lighting fixture, it is necessary to convert the lighting effect parameters contained in the target lighting effect template into an abstract protocol that can be recognized by the target lighting fixture, based on its type. This abstract protocol can include multiple control commands, which the target lighting fixture executes to display the lighting effects set in the target lighting effect template.
[0095] The process of converting the target lighting effect template into an abstract protocol can be performed on the current device or on the target lighting fixture. When the conversion process is performed by the terminal device, the user can pre-set the type of the target lighting fixture on the terminal device, or the terminal device can determine the type of the target lighting fixture through communication with the target lighting fixture during step 504. The terminal device can then select the appropriate conversion strategy based on the type of the target lighting fixture. When performed on the target lighting fixture, the terminal device only needs to send the lighting effect template to the target lighting fixture. The target lighting fixture can then perform the conversion process locally according to the preset conversion strategy and configure itself according to the various types of lighting effect parameters included in the target lighting effect template.
[0096] When a specific target luminaire executes the control commands in the abstract protocol, it modifies the current lighting effect display to match the parameter values recorded in the target lighting effect template, thereby ensuring that the lighting effect of the target luminaire matches the content of the target image. The abstract protocol may include multiple fields. The target luminaire can determine the type and value of the lighting effect parameters represented by each field according to pre-defined rules, and then replace the currently displayed lighting effect. For example, if the current luminaire displays a brightness of 5 and a color change speed of 3, upon receiving the abstract protocol containing the target lighting effect template, which contains information such as a luminaire display brightness of 3 and a color change speed of 1, the target luminaire will replace the current parameter values, resulting in a lighting effect state with a display brightness of 3 and a color change speed of 1. It is understandable that the configuration process of the lighting effect parameters based on the target lighting effect template may differ in actual implementation. For example, in some cases, the target luminaire may only store the target lighting effect template and only perform the corresponding lighting effect conversion upon receiving additional transformation commands. This depends on the actual situation and is not limited here.
[0097] It should be noted that the types of target lighting fixtures mentioned above are only for illustrative purposes and should not be used as a limitation on all types of lighting fixtures that can be controlled by this application. For example, for lighting fixtures with multiple light-emitting units, each of which is controlled by a microcontroller, the above-mentioned lighting effect control scheme can also be used. The specific control idea is similar to that of the RGBIC lighting fixture type mentioned above, and will not be repeated here.
[0098] In some possible implementations, step 203, controlling the lighting effect of the target luminaire according to the target lighting effect template, may include: acquiring image information of the target image, and modifying the parameters of the target lighting effect template according to the image information to obtain a modified target lighting effect template, wherein the image information is used to characterize specific feature information of the target image; and controlling the lighting effect of the target luminaire according to the modified target lighting effect template.
[0099] Specifically, before controlling the lighting effects of the target lighting fixture, image information of the target image can be acquired. This image feature information is used to characterize specific features of the target image, such as hue, grayscale, color temperature, RGB ratio information, and / or information about specific objects contained therein. Then, based on the image information, the lighting effect template can be further modified, or adjusted, to ensure that the lighting effect better expresses the information conveyed by the image. Parameter modification may include adjusting parameters in the lighting effect template, such as the color values, color temperature, brightness values of color blocks, and / or the flashing speed of the lights.
[0100] In some possible implementations, after step 203, which involves controlling the lighting effect of the target luminaire according to the target lighting effect template, the lighting effect control method may further include: responding to a user's setting operation on the lighting effect control interface, determining image information of the target image to be acquired based on the setting operation, wherein the image information is used to characterize specific feature information of the target image; acquiring the image information and modifying the parameters of the target lighting effect template according to the image information to obtain a modified target lighting effect template; and controlling the lighting effect of the target luminaire according to the modified target lighting effect template.
[0101] Specifically, when the executing device in this application embodiment is a terminal device, the terminal device may have a lighting effect control interface. This interface may include setting buttons or menus, through which the user can instruct the terminal device to acquire image information of a user-defined type. This image information is used to characterize specific features of the target image, such as hue, grayscale, color temperature, RGB ratio information, and / or information about specific objects contained therein. Subsequently, the terminal device can further modify, or adjust, the parameters of the lighting effect template based on the image information, so that the lighting effect displayed by the template can better express the information conveyed by the image. Parameter modification may include adjusting parameters in the lighting effect template, such as the color value, color temperature, brightness value of color blocks, and / or the flashing speed of the lights.
[0102] In some possible implementations, the image information mentioned above may be the tone label of the target image, which is used to characterize the grayscale characteristics of the target image. The step of modifying the parameters of the target lighting effect template according to the image information to obtain the modified target lighting effect template may include: modifying the parameters of the target lighting effect template according to the tone label to obtain the first lighting effect template.
[0103] Specifically, the tone label is used to characterize the grayscale characteristics of the target image. The tone label can be obtained by performing tone analysis on the target image. The tone analysis process includes: performing grayscale processing on the target image to obtain the grayscale histogram of the target image; and determining the tone label corresponding to the target image based on the position of the peak and the grayscale pixel extent in the grayscale histogram of the target image.
[0104] Specifically, the grayscale conversion process involves transforming a color image into a grayscale image, where the grayscale value of each pixel ranges from 0 to 255. Weighted averaging and average averaging methods are then used to supplement this, resulting in a grayscale histogram of the target image. This histogram divides the grayscale range of 0-255 into multiple intervals, as shown in the example below. Figure 3 As shown, the tonal label of an image is determined based on the information displayed in the grayscale histogram. Optionally, the method for determining the tonal label can refer to... Figure 4 It includes twelve types: high long key, high medium key, high short key, medium short key, medium medium key, medium long key, low long key, low medium key, low short key, full long key, hard key, and soft key. For example, the grayscale histogram of low long key can be shown as follows: Figure 5 As shown, the peak value of the grayscale pixels is located on the right, indicating that the image is short-tone. The distribution of grayscale pixels across the entire grayscale range indicates that the image is long-tone. Combining these two factors, the tonal label for this image is determined to be low long-tone. It's important to note that in a full-length long-tone image, the brightness pixels are concentrated at the far left and far right of the histogram. For soft-tone photos, the histogram typically presents a trapezoidal distribution, with relatively uniform pixel brightness distribution. For hard-tone photos, the histogram typically presents a "two-peak" distribution, with pixels clustered in the brighter and darker areas respectively. It's understandable that the method for classifying and determining the tonal label of an image can be adjusted according to the actual situation; specific details are not limited here.
[0105] The first lighting effect template is obtained by adjusting various parameters within the target lighting effect template based on tone tags. For example, the target lighting effect template may include various lighting effect parameters such as brightness, change speed, color block saturation and change direction, the division rules between the background and accent parts of the target luminaire, and control parameters for the background and accent parts. It is worth noting that the division rules between the background and accent parts, as well as the control parameters for the background and accent parts, are specific to the RGBIC protocol. The adjustment method can be as follows: for a low long tone tag, reduce the brightness of the background part in the target lighting effect template by 12%-18%; for a high short tone tag, reduce the brightness of the background part by 5%-10% and increase the brightness of the accent parts by 5%-10%. The specific adjustment method can be set by the staff according to needs and is not limited here. After adjusting the lighting effect parameters in the target lighting effect template according to the tone tags, the corresponding first lighting effect template is obtained.
[0106] After obtaining the first lighting effect template, the implementing device can use the first lighting effect template to control the lighting effect of the target luminaire. Since the tonal tags of the target image are used in the lighting effect control of the target luminaire, the accuracy of controlling the lighting effect based on the target image can be further improved.
[0107] In some possible implementations, the image information mentioned above may be the RGB parameter values of the target color block of the target image. The RGB parameter values of the target color block are used to characterize the RGB parameter information included in the target image. The step of modifying the target lighting effect template according to the image information to obtain the modified target lighting effect template may include: modifying the target lighting effect template according to the RGB parameter values of the target color block to obtain a second lighting effect template.
[0108] Specifically, the RGB parameter values of the target color patch can be obtained by color patch extraction from the target image. This can involve acquiring the RGB values of each pixel in the image, statistically analyzing them, calculating the proportion of each RGB value, sorting them by size, and using the top N sorted RGB values to replace the preset color patches in the template for subsequent adjustments to the target lighting effect template. It's understandable that the target image can be compressed or its resolution adjusted before color patch extraction to reduce the amount of data in the target image, thereby reducing data processing workload and improving processing speed.
[0109] After obtaining the RGB parameter values of the target color blocks, the target lighting effect template is adjusted to obtain the second lighting effect template. Specifically, this includes adjusting the multiple different types of lighting effect parameters included in the target lighting effect template based on the RGB parameter values of the multiple target color blocks and the weights corresponding to each of the RGB parameter values of the target color blocks. For example, the RGB parameter weights of the extracted image are set so that the first three are background colors and the last five are accent colors. The result obtained from the color block extraction process replaces the RGB settings of the background color and accent color in the original lighting effect template.
[0110] After obtaining the second lighting effect template, the implementing device can use the second lighting effect template to control the lighting effect of the target lamp. Since the RGB parameter values of the target color block in the target image are used in the lighting effect control of the target lamp, the accuracy of controlling the lighting effect based on the target image can be further improved.
[0111] In some possible implementations, the image information described above may be the tone label of the target image and the RGB parameter values of the target color block. The tone label is used to characterize the tone information of the target image, and the RGB parameter values of the target color block are used to characterize the RGB parameter information included in the target image. The step of modifying the target lighting effect template according to the image information to obtain the modified target lighting effect template may include: modifying the target lighting effect template according to the tone label and the RGB parameter values of the target color block to obtain a third lighting effect template.
[0112] The third lighting effect template is a new lighting effect template obtained by simultaneously or sequentially modifying the target lighting effect template using the tonal tags and RGB parameter values of the target color blocks in the target image after determining the target lighting effect template, and then overlaying them. Since this process combines two independent processes, please refer to the aforementioned content for details, which will not be elaborated upon here.
[0113] After obtaining the third lighting effect template, the implementing device can use the third lighting effect template to control the lighting effect of the target lamps. Since the tonal tags of the target image and the RGB parameter values of the target color blocks are used in the lighting effect control of the target lamps, the determined lighting effect can more accurately convey the information implied in the target image, further improving the accuracy of controlling the lighting effect based on the target image.
[0114] As can be seen from the above embodiments, this solution acquires a target image, processes the target image using a label recognition neural network model to obtain the target image label corresponding to the target image, determines the target lighting effect template corresponding to the target image label, and controls the target lighting fixture based on multiple different types of lighting effect parameters corresponding to the target lighting effect template. The label recognition neural network model is pre-trained, and different types of labels are set for images expressing different meanings. Each label has a matching lighting effect template, which includes multiple different types of lighting effect parameters. Therefore, when controlling the lighting effect based on the target image, multiple different types of parameters can be adjusted, making the lighting effect more varied and better meeting user needs.
[0115] The following describes the training process of the label recognition neural network used in the implementation of this scheme. Specifically, before obtaining the target image in step 201, refer to... Figure 6 The schematic diagram of the training process of the label recognition neural network of this application may include steps 601 to 604.
[0116] 601. Obtain the original training set consisting of the original images and their corresponding labels.
[0117] Specifically, the original training set, consisting of original images and their corresponding labels, is obtained. The original images are collected from the internet; in practice, web crawlers or similar methods can be used for collection. The collected images are then filtered to remove meaningless or abnormal images. After obtaining the original images, staff categorize each image and assign it a corresponding label. The labels are based on the content displayed in the image. For example, images showing pets or home decor, which evoke a sense of everyday life, are labeled "Life," while images with a somber tone are labeled "Sad." The label settings can be adjusted based on factors such as lighting effects and templates; no specific limit is imposed here. Once all images and their corresponding labels are obtained, the original training set is acquired. The number of images in the original training set depends on the data processing capabilities of the device; no specific limit is imposed here.
[0118] 602. Perform data augmentation on the original training set to obtain an augmented training set.
[0119] Specifically, data augmentation is performed on the original training set to obtain the augmented training set. Data augmentation techniques used in this process may include: random image flipping, random jittering, random color modification, and adding noise, etc. The specific augmentation technique used can be determined based on the actual situation and is not limited here. After data augmentation of the original training set, multiple augmented images can be obtained. The labels corresponding to the augmented images are consistent with the labels corresponding to their original images. The augmented images and their corresponding labels together constitute the augmented training set. It is understandable that before performing data augmentation on the original training set, to ensure processing effectiveness and reduce the amount of data to be processed, the size of the original images can be adjusted, such as setting the original images to a uniform size. The specific method used can be determined based on the actual situation and is not limited here.
[0120] 603. Normalize the augmented training set to obtain the training sample set.
[0121] Specifically, the data included in the augmented training set may contain either very large or very small datasets. Directly using the augmented training set to train the neural network model can easily lead to poor model stability. Therefore, the augmented training set can be normalized, such as changing the grayscale range from 0-255 to 0-1, thereby reducing the size of the data and the differences between them, facilitating the subsequent training process. Steps 402 to 403 above can be completed using the MXNet module, which is a widely applicable deep learning library. It is understood that the normalization process can also be omitted, and the augmented training set can be used directly for training; this is not limited here.
[0122] 604. Use the training sample set to train a neural network model with a specific structure to obtain a label recognition neural network model.
[0123] Specifically, the neural network model with a specific structure used in this step can be a ResNet network or a DenseNet network, depending on the actual situation and not limited here. One feasible approach is to train it using the ResNet50_v2 model. In actual implementation, transfer learning can also be used to train the label recognition neural network model, that is, using other pre-trained models to train again using the same training sample set, depending on the actual situation and not limited here. The neural network model obtained through the above methods is more suitable for the image label extraction process.
[0124] Among some possible implementations, Figure 2In the embodiment shown, depending on the computing power of the device and the different devices deployed in the tag recognition neural network model, the main body implementing the scheme can be a separate server or a terminal device used by the user to control the target lamp. Alternatively, the server and the terminal device used by the user can cooperate to complete the process. The scheme will be further described below from the perspectives of the terminal device side, the server side, and the combination of the server and the terminal device.
[0125] The following provides an embodiment of the lighting effect control method of this application applied to the terminal device side. Please refer to... Figure 7 One embodiment of the lighting effect control method of this application includes steps 701 to 704.
[0126] 701. The terminal device acquires the target image.
[0127] Specifically, the terminal device can acquire target images uploaded by the user from the local device or from the Internet. These target images can be pictures, video frames from streaming media, or real-time images of the target device's current screen captured through a video output interface.
[0128] 702. The terminal device uploads the target image to the server and instructs the server to use a label recognition neural network model to extract labels from the target image. After extracting the target image labels, the terminal device determines the target lighting effect template corresponding to the target image labels.
[0129] Specifically, the terminal device can respond to the user's operation of uploading a target image to the server, and upload the target image to the server. This server can be equipped with a label recognition neural network model. Upon receiving the target image, the server can use this model to extract labels from the target image. Furthermore, upon extracting the target image labels, the server can query a pre-set mapping between different image labels and different lighting effect templates to determine the target lighting effect template corresponding to the target image label. For details regarding the label recognition neural network model and target image labels, please refer to [link to relevant documentation]. Figure 2 The relevant description of step 202 in the embodiment will not be repeated here.
[0130] 703. The terminal device receives the target lighting effect template sent by the server.
[0131] Specifically, the terminal device can receive the target lighting effect template determined by the server via wireless or wired connection.
[0132] 704. The terminal device controls the lighting effect of the target lighting fixtures according to the target lighting effect template.
[0133] Specifically, the target lighting fixtures in this embodiment can be divided into two types based on their device structure: RGB lighting fixtures and RGBIC lighting fixtures. For RGB lighting fixtures, such as RGB light strips, each light-emitting unit is uniformly controlled by a controller. RGBIC lighting fixtures, such as RGBIC light strips, can be divided into multiple light-emitting units, each with its own control IC, allowing for individual light-emitting control of each unit. Due to the different lighting fixture structures, when controlling the lighting effects of the target lighting fixture, it is necessary to convert the target lighting effect template into an abstract protocol that the target lighting fixture can recognize and execute, based on the type of the target lighting fixture. This abstract protocol can include multiple control commands, which the target lighting fixture executes to display the lighting effects set in the target lighting effect template.
[0134] The conversion process described above, which transforms the target lighting effect template into an abstract protocol that the target luminaire can recognize and execute, can be performed on either the terminal device or the target luminaire. When the conversion process is performed by the terminal device, the user can pre-set the type of the target luminaire on the terminal device, or the terminal device can determine the type of the target luminaire through communication with it during step 804. The terminal device can then select the appropriate conversion strategy based on the type of the target luminaire. When performed on the target luminaire, the terminal device only needs to send the lighting effect template to the target luminaire, allowing the target luminaire to perform the conversion process locally.
[0135] It should be noted that the types of target lighting fixtures mentioned above are for illustrative purposes only and should not be used as a limitation on the types of lighting fixtures that can be controlled by this application. For example, for lighting fixtures with multiple light-emitting units, each of which is controlled by a microcontroller, the above-mentioned lighting effect control scheme can also be used. The specific control idea is similar to that of the RGBIC lighting fixture type mentioned above, and will not be repeated here.
[0136] In some possible implementations, step 704, whereby the terminal device controls the lighting effect of the target lighting fixture according to the target lighting effect template, may include: the terminal device controlling the lighting effect of the target lighting fixture according to a first lighting effect template, a second lighting effect template, or a third lighting effect template; wherein, the first lighting effect template is a new lighting effect template obtained by the server after modifying the parameters of the target lighting effect template according to the tone label of the target image; the second lighting effect template is a new lighting effect template obtained by the server after modifying the parameters of the target lighting effect template according to the RGB parameter values of the target color blocks of the target image; and the third lighting effect template is a new lighting effect template obtained by the server after modifying the parameters of the target lighting effect template according to the tone label and the RGB parameter values of the target color blocks, wherein the tone label is used to characterize the grayscale characteristics of the target image, and the RGB parameter values of the target color blocks are used to characterize the RGB parameter information included in the target image.
[0137] Specifically, the first, second, and third lighting effect templates mentioned here are new lighting effect templates obtained by the server after obtaining the target lighting effect template and modifying its parameters based on the image information of the target image. The relevant information regarding the first, second, and third lighting effect templates has been described above. Figure 2 The contents involved in the illustrated embodiments have been described, and will not be repeated here.
[0138] In some possible implementations, step 704, whereby the terminal device controls the lighting effect of the target luminaire according to the target lighting effect template, may include: the terminal device acquiring image information of the target image, and modifying the parameters of the target lighting effect template according to the image information to obtain a modified target lighting effect template, wherein the image information is used to characterize specific feature information of the target image; and controlling the lighting effect of the target luminaire according to the modified target lighting effect template.
[0139] Specifically, before controlling the lighting effects of the target lighting fixture, the terminal device can obtain image information by processing the target image itself, or by receiving image information sent by the server after processing the target image. This image feature information is used to characterize specific features of the target image, such as hue, grayscale, color temperature, RGB ratio information, and / or information about specific objects contained therein. Then, based on the image information, the lighting effect template can be further modified, or adjusted, to ensure that the lighting effect better expresses the information conveyed by the target image. Parameter modification may include adjusting parameters in the lighting effect template, such as the color value, color temperature, brightness value, and / or the flashing speed of the light.
[0140] In some possible implementations, after step 704, where the terminal device controls the lighting effect of the target luminaire according to the target lighting effect template, the lighting effect control method may further include: the terminal device responding to a user's setting operation on the lighting effect control interface, determining image information of the target image to be acquired according to the setting operation, wherein the image information is used to characterize specific feature information of the target image; acquiring the image information, and modifying the parameters of the target lighting effect template according to the image information to obtain a modified target lighting effect template; and controlling the lighting effect of the target luminaire according to the modified target lighting effect template.
[0141] Specifically, the terminal device may have a lighting effect control interface, which may include setting buttons or menus. Users can use these buttons or menus to instruct the terminal device to acquire image information of a user-defined type. This image information is used to characterize specific features of the target image, such as hue, grayscale, color temperature, RGB ratio information, and / or information about specific objects contained within. Subsequently, the terminal device can further modify, or adjust, the parameters of the lighting effect template based on the image information, so that the lighting effect template better expresses the information conveyed by the image. Parameter modification may include adjusting parameters in the lighting effect template, such as the color value, color temperature, brightness value of color blocks, and / or the flashing speed of the lights.
[0142] In some possible implementations, the image information mentioned above may be a tone label of the target image, which is used to characterize the grayscale characteristics of the target image. The step of modifying the parameters of the target lighting effect template according to the image information to obtain a modified target lighting effect template may include: the terminal device modifying the parameters of the target lighting effect template according to the tone label to obtain a first lighting effect template.
[0143] Specifically, the tone label is used to characterize the grayscale characteristics of the target image. The tone label can be obtained by performing tone analysis on the target image. The tone analysis process includes: performing grayscale processing on the target image to obtain the grayscale histogram of the target image; and determining the tone label corresponding to the target image based on the position of the peak and the grayscale pixel extent in the grayscale histogram of the target image.
[0144] Specifically, the grayscale conversion process involves transforming a color image into a grayscale image, where the grayscale value of each pixel ranges from 0 to 255. Weighted averaging and average averaging methods are then used to supplement this, resulting in a grayscale histogram of the target image. This histogram divides the grayscale range of 0-255 into multiple intervals, as shown in the example below. Figure 3As shown, the tonal label of the image is determined based on the information displayed by the grayscale histogram. Optionally, the method for determining the tonal label can refer to... Figure 4 It includes twelve types: high long key, high medium key, high short key, medium short key, medium medium key, medium long key, low long key, low medium key, low short key, full long key, hard key, and soft key. For example, the grayscale histogram of low long key can be shown as follows: Figure 5 As shown, the peak value of the grayscale pixels is located on the right, indicating that the image is short-tone. The distribution of grayscale pixels across the entire grayscale range indicates that the image is long-tone. Combining these two factors, the tonal label for this image is determined to be low long-tone. It's important to note that in a full-length long-tone image, the brightness pixels are concentrated at the far left and far right of the histogram. For soft-tone photos, the histogram typically presents a trapezoidal distribution, with relatively uniform pixel brightness distribution. For hard-tone photos, the histogram typically presents a "two-peak" distribution, with pixels clustered in the brighter and darker areas respectively. It's understandable that the method for classifying and determining the tonal label of an image can be adjusted according to the actual situation; specific details are not limited here.
[0145] The first lighting effect template is obtained by adjusting various parameters within the target lighting effect template based on tone tags. For example, the target lighting effect template may include various lighting effect parameters such as brightness, change speed, color block saturation and change direction, the division rules between the background and accent parts of the target luminaire, and control parameters for the background and accent parts. It is worth noting that the division rules between the background and accent parts, as well as the control parameters for the background and accent parts, are specific to the RGBIC protocol. The adjustment method can be as follows: for a low long tone tag, reduce the brightness of the background part in the target lighting effect template by 12%-18%; for a high short tone tag, reduce the brightness of the background part by 5%-10% and increase the brightness of the accent parts by 5%-10%. The specific adjustment method can be set by the staff according to needs and is not limited here. After adjusting the lighting effect parameters in the target lighting effect template according to the tone tags, the corresponding first lighting effect template is obtained.
[0146] After obtaining the first lighting effect template, the terminal device can use it to control the lighting effects of the target lighting fixture. Because the tonal tags of the target image are used in the lighting effect control of the target lighting fixture, the accuracy of controlling the lighting effects based on the target image can be further improved.
[0147] In some possible implementations, the image information mentioned above may be the RGB parameter values of the target color block of the target image. The RGB parameter values of the target color block are used to characterize the RGB parameter information included in the target image. The step of modifying the target lighting effect template according to the image information to obtain the modified target lighting effect template may include: the terminal device modifying the target lighting effect template according to the RGB parameter values of the target color block to obtain a second lighting effect template.
[0148] Specifically, the RGB parameter values of the target color blocks can be obtained by extracting color blocks from the target image. This can involve acquiring the RGB values of each pixel in the image, statistically analyzing them, calculating the proportion of each RGB value, sorting them by size, and using the top N sorted RGB values to replace the preset color blocks in the template. This is necessary for subsequent adjustments to the target lighting effect template. It's understandable that the target image can be compressed or its resolution adjusted before color block extraction to reduce the amount of data in the target image, thereby reducing data processing workload and improving processing speed.
[0149] After obtaining the RGB parameter values of the target color blocks, the target lighting effect template is adjusted to obtain the second lighting effect template. Specifically, this includes adjusting the multiple different types of lighting effect parameters included in the target lighting effect template based on the RGB parameter values of the multiple target color blocks and the weights corresponding to each of the RGB parameter values of the target color blocks. For example, the RGB parameter weights of the extracted image are set so that the first three are background colors and the last five are accent colors. The result obtained from the color block extraction process replaces the RGB settings of the background color and accent color in the original lighting effect template.
[0150] After obtaining the second lighting effect template, the terminal device can use it to control the lighting effects of the target lighting fixture. Since the RGB parameter values of the target color blocks in the target image are used in the lighting effect control of the target lighting fixture, the accuracy of controlling the lighting effects based on the target image can be further improved.
[0151] In some possible implementations, the image information described above may be the tone label of the target image and the RGB parameter value of the target color block. The tone label is used to characterize the tone information of the target image, and the RGB parameter value of the target color block is used to characterize the RGB parameter information included in the target image. The step of correcting the parameters of the target lighting effect template according to the image information to obtain a corrected target lighting effect template may include: the terminal device correcting the parameters of the target lighting effect template according to the tone label and the RGB parameter value of the target color block to obtain a third lighting effect template.
[0152] The third lighting effect template is obtained by combining the first lighting effect template and the second lighting effect template in the aforementioned possible situations. For details, please refer to the above content, which will not be repeated here.
[0153] After obtaining the third lighting effect template, the terminal device can use it to control the lighting effects of the target lighting fixture. Because the tonal tags of the target image and the RGB parameter values of the target color blocks are used in the lighting effect control of the target lighting fixture, the accuracy of controlling the lighting effects based on the target image can be further improved.
[0154] In some possible implementations, after step 704, the terminal device controls the lighting effect of the target lamp according to the target lighting effect template. After execution, the terminal device can also save the first correspondence between the target image and the target lighting effect template. When the target image is acquired again, the target lighting effect template corresponding to the target image is determined based on the first correspondence. That is, the lighting effect template obtained each time the target image is processed is saved, so that when the same image is acquired again, there is no need to process the image again using a neural network model. The corresponding lighting effect template can be directly determined through the stored first correspondence, thereby improving the speed of the lighting effect control process and enhancing the feasibility of this solution.
[0155] In some possible implementations, step 701, where the terminal device acquires the target image, may include: the terminal device receiving an image selection instruction sent by the user through a lighting effect configuration interface, wherein the lighting effect configuration interface includes one or more images, each of which has one or more corresponding target lighting effect templates, and there is a first correspondence between the one or more target lighting effect templates and the one or more images.
[0156] The terminal device can provide a lighting effect configuration interface, which is used to display one or more images. Each image displayed in the lighting effect configuration interface has a corresponding target lighting effect template. When using it, the user can select an image through the lighting effect configuration interface, so that the target lamp displays the corresponding target lighting effect template.
[0157] As can be seen from the above embodiments, this solution acquires a target image, processes the target image using a label recognition neural network model to obtain the target image label corresponding to the target image, determines the target lighting effect template corresponding to the target image label, and controls the target lighting fixture based on multiple different types of lighting effect parameters corresponding to the target lighting effect template. The label recognition neural network model is pre-trained, and different types of labels are set for images expressing different meanings. Each label has a matching lighting effect template, which includes multiple different types of lighting effect parameters. Therefore, when controlling the lighting effect based on the target image, multiple different types of parameters can be adjusted, making the lighting effect more varied and better meeting user needs.
[0158] The following is an embodiment of the lighting effect control method of this application applied to the server side. Please refer to... Figure 8 One embodiment of the lighting effect control method of this application includes steps 801 to 803.
[0159] 801. The server obtains the target image uploaded by the terminal device.
[0160] Specifically, terminal devices can interact with servers via a network. Users can obtain target images of interest through any means and send them to the server via an application specifically designed for lighting effect control. The server then retrieves the target images uploaded by the terminal devices for subsequent image processing.
[0161] 802. The server instructs the use of a label recognition neural network model to extract labels from the target image, and after extracting the target image labels, determines the target lighting effect template corresponding to the target image labels. The label recognition neural network model is obtained by training a neural network model with a specific structure using a training sample set. The target lighting effect template includes multiple different types of lighting effect parameters.
[0162] Specifically, in this embodiment, the label recognition neural network model is deployed on a server. After receiving a target image, the server can use the label recognition neural network model to extract labels from the target image. After extracting the target image labels, the server determines the target lighting effect template corresponding to the target image labels. The label recognition neural network model is obtained by training a neural network model with a specific structure using a training sample set. The target lighting effect template includes multiple different types of lighting effect parameters. This step is the same as described above. Figure 2 Step 202 in the corresponding embodiment is similar, and will not be described in detail here.
[0163] 803. The server sends the target lighting effect template to the terminal device to instruct the terminal device to control the lighting effect of the target lamp according to the target lighting effect template.
[0164] Specifically, the server sends the target lighting effect template to the terminal device via wired or wireless means, so as to instruct the terminal device to control the lighting effect of the target lamp according to the target lighting effect template.
[0165] Specifically, the target lighting fixtures in this embodiment can be divided into two types based on their device structure: RGB lighting fixtures and RGBIC lighting fixtures. For RGB lighting fixtures, such as RGB light strips, each light-emitting unit is uniformly controlled by a controller. RGBIC lighting fixtures, such as RGBIC light strips, can be divided into multiple light-emitting units, each with its own control IC, allowing for individual light-emitting control of each unit. Due to the different lighting fixture structures, when controlling the lighting effects of the target lighting fixture, it is necessary to convert the target lighting effect template into an abstract protocol that the target lighting fixture can recognize and execute, based on the type of the target lighting fixture. This abstract protocol can include multiple control commands, which the target lighting fixture executes to display the lighting effects set in the target lighting effect template.
[0166] In some possible implementations, before step 803, whereby the server sends the target lighting effect template to the terminal device to instruct the terminal device to control the lighting effect of the target lamp according to the target lighting effect template, the following steps may be included: the server acquires image information of the target image and modifies the parameters of the target lighting effect template according to the image information to obtain a modified target lighting effect template, wherein the image information is used to characterize specific feature information of the target image; the server sends the modified target lighting effect template to the terminal device to instruct the terminal device to control the lighting effect of the target lamp according to the modified target lighting effect template.
[0167] Specifically, before the server sends the target lighting effect template to the terminal device, it can also acquire image information of the target image. This image feature information is used to characterize specific features of the target image, such as hue, grayscale, color temperature, RGB ratio information, and / or information about specific objects contained therein. Then, based on the image information, the lighting effect template can be further modified, or adjusted, to ensure that the lighting effect better expresses the information conveyed by the image. Parameter modification may include adjusting parameters in the lighting effect template, such as the color value, color temperature, brightness value of color blocks, and / or the flashing speed of the lights.
[0168] In some possible implementations, the image information mentioned above may be the tone label of the target image, which is used to characterize the grayscale characteristics of the target image. The step of modifying the parameters of the target lighting effect template according to the image information to obtain the modified target lighting effect template may include: the server modifying the parameters of the target lighting effect template according to the tone label to obtain the first lighting effect template.
[0169] Specifically, the tone label is used to characterize the grayscale characteristics of the target image. The tone label can be obtained by performing tone analysis on the target image. The tone analysis process includes: performing grayscale processing on the target image to obtain the grayscale histogram of the target image; and determining the tone label corresponding to the target image based on the position of the peak and the grayscale pixel extent in the grayscale histogram of the target image.
[0170] Specifically, the grayscale conversion process involves transforming a color image into a grayscale image, where the grayscale value of each pixel ranges from 0 to 255. Weighted averaging and average averaging methods are then used to supplement this, resulting in a grayscale histogram of the target image. This histogram divides the grayscale range of 0-255 into multiple intervals, as shown in the example below. Figure 3 As shown, the tonal label of the image is determined based on the information displayed by the grayscale histogram. Optionally, the method for determining the tonal label can refer to... Figure 4 It includes twelve types: high long key, high medium key, high short key, medium short key, medium medium key, medium long key, low long key, low medium key, low short key, full long key, hard key, and soft key. For example, the grayscale histogram of low long key can be shown as follows: Figure 5 As shown, the peak value of the grayscale pixels is located on the right, indicating that the image is short-tone. The distribution of grayscale pixels across the entire grayscale range indicates that the image is long-tone. Combining these two factors, the tonal label for this image is determined to be low long-tone. It's important to note that in a full-length long-tone image, the brightness pixels are concentrated at the far left and far right of the histogram. For soft-tone photos, the histogram typically presents a trapezoidal distribution, with relatively uniform pixel brightness distribution. For hard-tone photos, the histogram typically presents a "two-peak" distribution, with pixels clustered in the brighter and darker areas respectively. It's understandable that the method for classifying and determining the tonal label of an image can be adjusted according to the actual situation; specific details are not limited here.
[0171] The first lighting effect template is obtained by adjusting various parameters within the target lighting effect template based on tone tags. For example, the target lighting effect template may include various lighting effect parameters such as brightness, change speed, color block saturation and change direction, the division rules between the background and accent parts of the target luminaire, and control parameters for the background and accent parts. It is worth noting that the division rules between the background and accent parts, as well as the control parameters for the background and accent parts, are specific to the RGBIC protocol. The adjustment method can be as follows: for a low long tone tag, reduce the brightness of the background part in the target lighting effect template by 12%-18%; for a high short tone tag, reduce the brightness of the background part by 5%-10% and increase the brightness of the accent parts by 5%-10%. The specific adjustment method can be set by the staff according to needs and is not limited here. After adjusting the lighting effect parameters in the target lighting effect template according to the tone tags, the corresponding first lighting effect template is obtained.
[0172] After obtaining the first lighting effect template, the server can use it to control the lighting effects of the target lighting fixtures. Because the tonal tags of the target image are used in the lighting effect control of the target lighting fixtures, the accuracy of controlling the lighting effects based on the target image can be further improved.
[0173] In some possible implementations, the image information mentioned above may be the RGB parameter values of the target color block of the target image. The RGB parameter values of the target color block are used to characterize the RGB parameter information included in the target image. The step of modifying the target lighting effect template according to the image information to obtain the modified target lighting effect template may include: the server modifying the target lighting effect template according to the RGB parameter values of the target color block to obtain a second lighting effect template.
[0174] Specifically, the RGB parameter values of the target color blocks can be obtained by extracting color blocks from the target image. This can involve acquiring the RGB values of each pixel in the image, statistically analyzing them, calculating the proportion of each RGB value, sorting them by size, and using the top N sorted RGB values to replace the preset color blocks in the template. This is necessary for subsequent adjustments to the target lighting effect template. It's understandable that the target image can be compressed or its resolution adjusted before color block extraction to reduce the amount of data in the target image, thereby reducing data processing workload and improving processing speed.
[0175] After obtaining the RGB parameter values of the target color blocks, the target lighting effect template is adjusted to obtain the second lighting effect template. Specifically, this includes adjusting the multiple different types of lighting effect parameters included in the target lighting effect template based on the RGB parameter values of the multiple target color blocks and the weights corresponding to each of the RGB parameter values of the target color blocks. For example, the RGB parameter weights of the extracted image are set so that the first three are background colors and the last five are accent colors. The result obtained from the color block extraction process replaces the RGB settings of the background color and accent color in the original lighting effect template.
[0176] After obtaining the second lighting effect template, the server can use it to control the lighting effects of the target lights. Since the RGB parameter values of the target color blocks in the target image are used in the lighting effect control of the target lights, the accuracy of controlling the lighting effects based on the target image can be further improved.
[0177] In some possible implementations, the image information described above may be the tone label of the target image and the RGB parameter value of the target color block. The tone label is used to characterize the tone information of the target image, and the RGB parameter value of the target color block is used to characterize the RGB parameter information included in the target image. The step of modifying the target lighting effect template according to the image information to obtain the modified target lighting effect template may include: the server modifying the target lighting effect template according to the tone label and the RGB parameter value of the target color block to obtain a third lighting effect template.
[0178] The third lighting effect template is obtained by combining the first lighting effect template and the second lighting effect template in the aforementioned possible situations. For details, please refer to the above content, which will not be repeated here.
[0179] After obtaining the third lighting effect template, the server can use it to control the lighting effects of the target lighting fixtures. Because the tonal tags of the target image and the RGB parameter values of the target color blocks are used in the lighting effect control of the target lighting fixtures, the accuracy of controlling the lighting effects based on the target image can be further improved.
[0180] As can be seen from the above embodiments, this solution acquires a target image, processes the target image using a label recognition neural network model to obtain the target image label corresponding to the target image, determines the target lighting effect template corresponding to the target image label, and controls the target lighting fixture based on multiple different types of lighting effect parameters corresponding to the target lighting effect template. The label recognition neural network model is pre-trained, and different types of labels are set for images expressing different meanings. Each label has a matching lighting effect template, which includes multiple different types of lighting effect parameters. Therefore, when controlling the lighting effect based on the target image, multiple different types of parameters can be adjusted, making the lighting effect more varied and better meeting user needs.
[0181] The following is an embodiment of the lighting effect control method of this application, described on both the terminal device and the server. Please refer to... Figure 9 One embodiment of the lighting effect control method of this application includes steps 901 to 908.
[0182] 901. The terminal device acquires the target image.
[0183] Specifically, the terminal device can acquire target images uploaded by the user from the local device or from the Internet. These target images can be pictures, video frames from streaming media, or real-time images of the target device's current screen captured through a video output interface.
[0184] 902. The terminal device sends the target image to the server.
[0185] Specifically, the terminal device sends the target image to the server via wired or wireless means.
[0186] 903. The server obtains the target image uploaded by the terminal device.
[0187] Specifically, this solution uses the example of a terminal device sending a target image to a server. The terminal device performing this step can be a user's mobile phone, iPad, tablet, or other similar device, depending on the specific situation; no limitation is made here. The terminal device can interact with the server via a network. The user can obtain a target image of interest through any means and send it to the server via a dedicated lighting effect control application. The server receives the target image uploaded by the terminal device for subsequent image processing.
[0188] 904. The server uses a label recognition neural network model to extract labels from the target image, and after extracting the target image labels, determines the target lighting effect template corresponding to the target image labels. The label recognition neural network model is obtained by training a neural network model with a specific structure using a training sample set. The target lighting effect template includes multiple different types of lighting effect parameters.
[0189] It should be noted that this step is the same as the one described above. Figure 8 Step 802 in the corresponding embodiment is similar, and will not be described in detail here.
[0190] 905. The server sends the target lighting effect template to the terminal device.
[0191] Specifically, the server sends the target lighting effect template to the terminal device via wired or wireless means.
[0192] 906. The terminal device receives the target lighting effect template sent by the server.
[0193] 907. The terminal device controls the lighting effect of the target lighting fixtures according to the target lighting effect template.
[0194] Specifically, steps 906 to 907 are the same as those described above. Figure 7 The corresponding steps 703 to 704 are similar, and will not be elaborated here.
[0195] In some possible implementations, step 907, whereby the terminal device controls the lighting effect of the target lamp according to the target lighting effect template, may include: the terminal device acquiring image information of the target image, and modifying the parameters of the target lighting effect template according to the image information to obtain a modified target lighting effect template, wherein the image information is used to characterize specific feature information of the target image; and controlling the lighting effect of the target lamp according to the modified target lighting effect template.
[0196] Specifically, before the terminal device controls the lighting effects of the target lighting fixture, the server or terminal device can acquire image information of the target image. This image feature information is used to characterize specific features of the target image, such as hue, grayscale, color temperature, RGB ratio information, and / or information about specific objects contained therein. Then, based on the image information, the lighting effect template can be further modified, or adjusted, to ensure that the lighting effect better expresses the information conveyed by the image. Parameter modification may include adjusting parameters in the lighting effect template, such as the color value, color temperature, brightness value of color blocks, and / or the flashing speed of the lights.
[0197] In some possible implementations, after step 907, where the terminal device controls the lighting effect of the target luminaire according to the target lighting effect template, the lighting effect control method may further include: the terminal device responding to a user's setting operation on the lighting effect control interface, determining image information of the target image to be acquired according to the setting operation, wherein the image information is used to characterize specific feature information of the target image; acquiring the image information, and modifying the parameters of the target lighting effect template according to the image information to obtain a modified target lighting effect template; and controlling the lighting effect of the target luminaire according to the modified target lighting effect template.
[0198] Specifically, when the executing device in this application embodiment is a terminal device, the terminal device may have a lighting effect control interface. This interface may include setting buttons or menus, through which the user can instruct the terminal device to acquire image information of a user-defined type. This image information is used to characterize specific features of the target image, such as hue, grayscale, color temperature, RGB ratio information, and / or information about specific objects contained therein. Subsequently, the terminal device can further modify, or adjust, the parameters of the lighting effect template based on the image information, so that the lighting effect displayed by the template can better express the information conveyed by the image. Parameter modification may include adjusting parameters in the lighting effect template, such as the color value, color temperature, brightness value of color blocks, and / or the flashing speed of the lights.
[0199] In some possible implementations, the image information mentioned above may be the tone label of the target image, which is used to characterize the grayscale characteristics of the target image. The step of modifying the parameters of the target lighting effect template according to the image information to obtain the modified target lighting effect template may include: the server or terminal device modifying the parameters of the target lighting effect template according to the tone label to obtain the first lighting effect template.
[0200] Specifically, the tone label is used to characterize the grayscale characteristics of the target image. The tone label can be obtained by performing tone analysis on the target image. The tone analysis process includes: performing grayscale processing on the target image to obtain the grayscale histogram of the target image; and determining the tone label corresponding to the target image based on the position of the peak and the grayscale pixel extent in the grayscale histogram of the target image.
[0201] Specifically, the grayscale conversion process involves transforming a color image into a grayscale image, where the grayscale value of each pixel ranges from 0 to 255. Weighted averaging and average averaging methods are then used to supplement this, resulting in a grayscale histogram of the target image. This histogram divides the grayscale range of 0-255 into multiple intervals, as shown in the example below. Figure 3As shown, the tonal label of the image is determined based on the information displayed by the grayscale histogram. Optionally, the method for determining the tonal label can refer to... Figure 4 It includes twelve types: high long key, high medium key, high short key, medium short key, medium medium key, medium long key, low long key, low medium key, low short key, full long key, hard key, and soft key. For example, the grayscale histogram of low long key can be shown as follows: Figure 5 As shown, the peak value of the grayscale pixels is located on the right, indicating that the image is short-tone. The distribution of grayscale pixels across the entire grayscale range indicates that the image is long-tone. Combining these two factors, the tonal label for this image is determined to be low long-tone. It's important to note that in a full-length long-tone image, the brightness pixels are concentrated at the far left and far right of the histogram. For soft-tone photos, the histogram typically presents a trapezoidal distribution, with relatively uniform pixel brightness distribution. For hard-tone photos, the histogram typically presents a "two-peak" distribution, with pixels clustered in the brighter and darker areas respectively. It's understandable that the method for classifying and determining the tonal label of an image can be adjusted according to the actual situation; specific details are not limited here.
[0202] The first lighting effect template is obtained by adjusting various parameters within the target lighting effect template based on tone tags. For example, the target lighting effect template may include various lighting effect parameters such as brightness, change speed, color block saturation and change direction, the division rules between the background and accent parts of the target luminaire, and control parameters for the background and accent parts. It is worth noting that the division rules between the background and accent parts, as well as the control parameters for the background and accent parts, are specific to the RGBIC protocol. The adjustment method can be as follows: for a low long tone tag, reduce the brightness of the background part in the target lighting effect template by 12%-18%; for a high short tone tag, reduce the brightness of the background part by 5%-10% and increase the brightness of the accent parts by 5%-10%. The specific adjustment method can be set by the staff according to needs and is not limited here. After adjusting the lighting effect parameters in the target lighting effect template according to the tone tags, the corresponding first lighting effect template is obtained.
[0203] After obtaining the first lighting effect template, the server or terminal device can use the first lighting effect template to control the lighting effect of the target lighting fixture. Since the tonal tags of the target image are used in the lighting effect control of the target lighting fixture, the accuracy of controlling the lighting effect based on the target image can be further improved.
[0204] In some possible implementations, the image information mentioned above may be the RGB parameter values of the target color block of the target image. The RGB parameter values of the target color block are used to characterize the RGB parameter information included in the target image. The step of modifying the target lighting effect template according to the image information to obtain the modified target lighting effect template may include: the server or terminal device modifying the target lighting effect template according to the RGB parameter values of the target color block to obtain the second lighting effect template.
[0205] Specifically, the RGB parameter values of the target color blocks can be obtained by extracting color blocks from the target image. This can involve acquiring the RGB values of each pixel in the image, statistically analyzing them, calculating the proportion of each RGB value, sorting them by size, and using the top N sorted RGB values to replace the preset color blocks in the template. This is necessary for subsequent adjustments to the target lighting effect template. It is understandable that before color block extraction, the server or terminal device can compress or adjust the resolution of the target image to reduce the amount of data in the target image, thereby reducing data processing load and improving processing speed.
[0206] After obtaining the RGB parameter values of the target color blocks from the server or terminal device, the target lighting effect template is adjusted to obtain the second lighting effect template. Specifically, this includes adjusting the multiple different types of lighting effect parameters included in the target lighting effect template based on the RGB parameter values of the multiple target color blocks and the weights corresponding to each of the target color block RGB parameter values. For example, the RGB parameter weights of the extracted image are set so that the first three are background colors and the last five are accent colors. The result obtained from the color block extraction process replaces the RGB settings of the background color and accent color in the original lighting effect template.
[0207] After obtaining the second lighting effect template, the server or terminal device can use it to control the lighting effects of the target lighting fixture. Since the RGB parameter values of the target color blocks in the target image are used in the lighting effect control of the target lighting fixture, the accuracy of controlling the lighting effects based on the target image can be further improved.
[0208] In some possible implementations, the image information described above may be the tone label of the target image and the RGB parameter values of the target color block. The tone label is used to characterize the tone information of the target image, and the RGB parameter values of the target color block are used to characterize the RGB parameter information included in the target image. The step of correcting the parameters of the target lighting effect template according to the image information to obtain a corrected target lighting effect template may include: the server or terminal device correcting the parameters of the target lighting effect template according to the tone label and the RGB parameter values of the target color block to obtain a third lighting effect template.
[0209] The third lighting effect template is obtained by combining the first lighting effect template and the second lighting effect template in the aforementioned possible situations. For details, please refer to the above content, which will not be repeated here.
[0210] After obtaining the third lighting effect template, the server and terminal devices can use it to control the lighting effects of the target lights. Because the tonal tags of the target image and the RGB parameter values of the target color blocks are used in the lighting effect control of the target lights, the accuracy of controlling the lighting effects based on the target image can be further improved.
[0211] In some possible implementations, after step 907, the terminal device controls the lighting effect of the target lamp according to the target lighting effect template. After execution, the terminal device or server can also save the first correspondence between the target image and the target lighting effect template. When the target image is acquired again, the target lighting effect template corresponding to the target image is determined based on the first correspondence. That is, the lighting effect template obtained each time the target image is processed is saved, so that when the same image is acquired again, there is no need to process the image again using a neural network model. The corresponding lighting effect template can be directly determined through the stored first correspondence, thereby improving the speed of the lighting effect control process and enhancing the feasibility of this solution.
[0212] As can be seen from the above embodiments, this solution acquires a target image, processes the target image using a label recognition neural network model to obtain the target image label corresponding to the target image, determines the target lighting effect template corresponding to the target image label, and controls the target lighting fixture based on multiple different types of lighting effect parameters corresponding to the target lighting effect template. The label recognition neural network model is pre-trained, and different types of labels are set for images expressing different meanings. Each label has a matching lighting effect template, which includes multiple different types of lighting effect parameters. Therefore, when controlling the lighting effect based on the target image, multiple different types of parameters can be adjusted, making the lighting effect more varied and better meeting user needs.
[0213] For specific applications of the lighting effect control method provided in this application on the lighting fixture side, please refer to [the relevant documentation]. Figure 10 This includes steps 1001 to 1002.
[0214] 1001. Receive lighting effect templates sent by terminal devices or servers.
[0215] Specifically, the target lighting fixture receives a target lighting effect template. This target lighting effect template is obtained by a server or terminal device acquiring a target image, processing the target image using a label recognition neural network model to obtain a target image label corresponding to the target image. The label recognition neural network model is obtained by training a neural network model with a specific structure using a training sample set. The target lighting effect template corresponding to the target image label is then determined. This target lighting effect template corresponds to multiple different types of lighting effect parameters. The process of determining the target lighting effect template can be referred to the above. Figure 2 , Figures 6 to 9 The specific details of the corresponding embodiments are not repeated here. The target lighting fixture type may include those described above. Figure 2 , Figures 6 to 9 The specific details of the RGB lighting fixtures and RGBIC lighting fixtures mentioned will not be elaborated here.
[0216] 1002. Configure the lighting effect parameters according to the various types of lighting effect parameters included in the lighting effect template.
[0217] Specifically, the target luminaire is configured according to multiple different types of lighting effect parameters included in the target lighting effect template. That is, the target luminaire modifies the current lighting effect display to the parameter values recorded in each lighting effect parameter within the target lighting effect template, thereby matching the lighting effect of the target luminaire with the content of the target image. Specifically, the server can convert the lighting effect parameters contained in the target lighting effect template into an abstract protocol recognizable by the target luminaire, and send this abstract protocol to the target luminaire so that the target luminaire executes the lighting effect parameters included in the abstract protocol. The abstract protocol may include multiple fields. The target luminaire can determine the type and value of the lighting effect parameters represented by each field according to pre-set rules, and then replace the currently displayed lighting effect. For example, if the current luminaire displays a brightness of 5 and a color change speed of 3, after receiving the abstract protocol containing the target lighting effect template, the information included in the lighting effect template is that the luminaire displays a brightness of 3 and a color change speed of 1. The target luminaire will then replace the current parameter values, so that the lighting effect state displayed by the luminaire is a brightness of 3 and a color change speed of 1. It is understandable that the configuration process of the lighting effect parameters based on the target lighting effect template may differ in actual implementation. For example, in some cases, the target luminaire may only store the target lighting effect template and perform the corresponding lighting effect conversion only after receiving the corresponding conversion command. The specifics can be determined according to the actual situation and are not limited here.
[0218] As can be seen from the above embodiments, this solution acquires a target image, processes the target image using a label recognition neural network model to obtain the target image label corresponding to the target image, determines the target lighting effect template corresponding to the target image label, and controls the target lighting fixture based on multiple different types of lighting effect parameters corresponding to the target lighting effect template. The label recognition neural network model is pre-trained, and different types of labels are set for images expressing different meanings. Each label has a matching lighting effect template, which includes multiple different types of lighting effect parameters. Therefore, when controlling the lighting effect based on the target image, multiple different types of parameters can be adjusted, making the lighting effect more varied and better meeting user needs.
[0219] The lighting effect control method in the embodiments of the application has been described above. The device involved in this application will be described below. Please refer to... Figure 11 One embodiment of the lighting effect control device provided in this application includes:
[0220] Acquisition unit 1101 is used to acquire the target image;
[0221] The processing unit 1102 is used to instruct the use of a label recognition neural network model to extract labels from the target image, and after extracting the target image labels of the target image, to determine the target lighting effect template corresponding to the target image labels. The label recognition neural network model is obtained by training a neural network model with a specific structure using a training sample set. The target lighting effect template includes multiple different types of lighting effect parameters.
[0222] The control unit 1103 is used to control the lighting effect of the target lighting fixture according to the target lighting effect template.
[0223] In this embodiment, the processes executed by each unit in the lighting effect control device are the same as those described above. Figure 2 The method flow described in the corresponding embodiments is similar and will not be repeated here.
[0224] Figure 12 This is a schematic diagram of the structure of a terminal device provided in an embodiment of this application. The terminal device 1200 may include one or more central processing units (CPUs) 1201 and a memory 1205, in which one or more applications or data are stored.
[0225] The memory 1205 can be volatile or persistent storage. The program stored in the memory 1205 can include one or more modules, each module including a series of instruction operations on the server. Furthermore, the central processing unit 1201 can be configured to communicate with the memory 1205 and execute the series of instruction operations stored in the memory 1205 on the terminal device 1200.
[0226] Terminal device 1200 may also include one or more power supplies 1202, one or more wired or wireless network interfaces 1203, one or more input / output interfaces 1204, and / or one or more operating systems, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™, etc.
[0227] The central processing unit 1201 can perform the operations performed by the terminal devices in the aforementioned embodiments, which will not be described in detail here.
[0228] Figure 13 This is a schematic diagram of the structure of a server provided in an embodiment of this application. The server 1300 may include one or more central processing units (CPUs) 1301 and a memory 1305, in which one or more applications or data are stored.
[0229] The memory 1305 can be volatile or persistent storage. The program stored in the memory 1305 can include one or more modules, each module including a series of instruction operations on the server. Furthermore, the central processing unit 1301 can be configured to communicate with the memory 1305 and execute the series of instruction operations stored in the memory 1305 on the server 1300.
[0230] Server 1300 may also include one or more power supplies 1302, one or more wired or wireless network interfaces 1303, one or more input / output interfaces 1304, and / or one or more operating systems, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™, etc.
[0231] The central processing unit 1301 can execute similar methods and processes as described in the foregoing embodiments, and will not be repeated here.
[0232] Please see Figure 14 One embodiment of the lighting fixture provided in this application includes:
[0233] Receiving unit 1401 is used to receive a lighting effect template sent by a terminal device or a server, wherein the lighting effect template is as described above. Figure 2 , Figures 6 to 9 The target lighting effect template in the lighting effect control method described in the corresponding embodiment;
[0234] Configuration unit 1402 is used to configure according to multiple different types of lighting effect parameters included in the lighting effect template.
[0235] In this embodiment, the processes executed by each unit in the lamp are the same as those described above. Figure 10 The method flow described in the corresponding embodiments is similar and will not be repeated here.
[0236] The present invention also provides a computer-readable storage medium for implementing the function of a lighting effect control method, wherein a computer program is stored thereon, and when the computer program is executed by a processor, the processor can be used to execute the lighting effect control method as described in the above embodiments.
[0237] It is understood that if the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a corresponding computer-readable storage medium or integrated as a computer program product to execute the above methods. Based on this understanding, all or part of the processes in the above-described embodiments of the present invention can also be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the above-described method embodiments. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include: any entity or device capable of carrying the computer program code, recording media, USB flash drives, portable hard drives, magnetic disks, optical disks, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signals, telecommunication signals, and software distribution media, etc. It should be noted that the content contained in the computer-readable medium may be appropriately added to or subtracted from the content as required by the legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, the computer-readable medium may not include electrical carrier signals and telecommunication signals.
[0238] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.
[0239] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.
[0240] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection between apparatuses or units through some interfaces, and may be electrical, mechanical, or other forms.
[0241] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0242] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0243] The above-described embodiments are only used to illustrate the technical solutions of the present invention, and are not intended to limit it. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method of controlling a light effect, characterized by, The method comprises the following steps: acquiring a target image; indicating to use a label recognition neural network model to perform label extraction on the target image, and determining a target lamp effect template corresponding to a target image label of the target image after the target image label is extracted, the label recognition neural network model being obtained by training a preset neural network model using a training sample set, and the target lamp effect template comprising lamp effect parameters of different types; controlling a target lamp according to the target lamp effect template, comprising: controlling the target lamp according to a first lamp effect template or a third lamp effect template; wherein the first lamp effect template is a new lamp effect template obtained by a server by performing parameter correction on the target lamp effect template according to a tone label of the target image, the third lamp effect template is a new lamp effect template obtained by the server by performing parameter correction on the target lamp effect template according to the tone label and a target color block RGB parameter value, and the tone label is used to represent the gray scale characteristics of the target image, and the target color block RGB parameter value is used to represent the RGB parameter information included in the target image. The tone label is obtained by performing tone analysis on the target image, and the process of performing tone analysis on the target image comprises: performing gray scale processing on the target image to obtain a gray scale histogram of the target image; determining the tone label corresponding to the target image based on the position of the peak value and the gray scale pixel width in the gray scale histogram of the target image; and determining the tone label from high long tone, high medium tone, high short tone, medium short tone, medium medium tone, medium long tone, low long tone, low medium tone, low short tone, full long tone, hard tone and soft tone.
2. The lamp effect control method according to claim 1, characterized in that, The lamp effect control method is applied to a terminal device, and the step of indicating to use a label recognition neural network model to perform label extraction on the target image and determining a target lamp effect template corresponding to a target image label of the target image after the target image label is extracted comprises: uploading the target image to a server and instructing the server to use a label recognition neural network model to perform label extraction on the target image, and determining a target lamp effect template corresponding to a target image label of the target image after the target image label is extracted; before the step of controlling a target lamp according to the target lamp effect template, the lamp effect control method further comprises: receiving the target lamp effect template sent by the server.
3. The lamp effect control method according to claim 1, characterized in that, The lamp effect control method is applied to a server, and the step of acquiring a target image comprises: acquiring the target image uploaded by a terminal device; the step of controlling a target lamp according to the target lamp effect template comprises: sending the target lamp effect template to the terminal device to instruct the terminal device to control the target lamp according to the target lamp effect template.
4. The lamp effect control method according to any one of claims 1 to 3, characterized in that, controlling a target lamp according to the target lamp effect template, comprising: acquire image information of the target image, and correct parameters of the target lamp effect template according to the image information, to obtain a corrected target lamp effect template, wherein the image information is used to represent image feature information of the target image; control lamp effect of the target lamp according to the corrected target lamp effect template.
5. The lamp effect control method according to claim 2, wherein After the step of controlling lamp effect of the target lamp according to the target lamp effect template, the lamp effect control method further comprises: in response to a setting operation of a user on a lamp effect control interface, determine image information of the target image to be acquired according to the setting operation, wherein the image information is used to represent image feature information of the target image; acquire the image information, and correct parameters of the target lamp effect template according to the image information, to obtain a corrected target lamp effect template; control lamp effect of the target lamp according to the corrected target lamp effect template.
6. The lamp effect control method according to claim 4, wherein The image information is a target color block RGB parameter value of the target image, the target color block RGB parameter value is used to represent RGB parameter information included in the target image, and the correcting parameters of the target lamp effect template according to the image information to obtain a corrected target lamp effect template comprises: correcting parameters of the target lamp effect template according to the target color block RGB parameter value to obtain a second lamp effect template.
7. The lamp effect control method according to any one of claims 1 to 3, characterized by, Before the step of acquiring the target image, the lamp effect control method further comprises: acquire an original training set composed of an original image and a label corresponding to the original image; perform data enhancement on the original training set to obtain an enhanced training set; perform normalization processing on the enhanced training set to obtain a training sample set; train a preset neural network model using the training sample set to obtain the label recognition neural network model.
8. The lamp effect control method according to any one of claims 1 to 3, characterized by, The plurality of different kinds of lamp effect parameters comprise: at least one or more lamp effect parameters in brightness, transformation speed, color block saturation and transformation direction.
9. The lamp effect control method according to any one of claims 1 to 3, characterized by, The target image is a video frame acquired at a target video interval for a predetermined time length.
10. The lamp effect control method according to any one of claims 1 to 3, characterized by, After the step of controlling lamp effect of the target lamp according to the target lamp effect template, the lamp effect control method further comprises: save a first correspondence relationship between the target image and the target lamp effect template; when the target image is acquired again, determine the target lamp effect template corresponding to the target image based on the first correspondence relationship.
11. A method of controlling a light effect, characterized by The lamp effect control method is applied to a target lamp, comprising: receive a lamp effect template sent by a terminal device or a server, the lamp effect template being the target lamp effect template in the lamp effect control method of any one of claims 1-10; configure according to a plurality of different kinds of lamp effect parameters included in the lamp effect template.
12. A light effect control device, characterized in that comprise: an acquisition unit, configured to acquire a target image; The processing unit is configured to instruct a label recognition neural network model to perform label extraction on the target image, and after the target image label of the target image is extracted, determine a target lamp effect template corresponding to the target image label, the label recognition neural network model being obtained by training a preset neural network model using a training sample set, and the target lamp effect template including a plurality of different types of lamp effect parameters. The control unit is configured to perform lamp effect control on the target lamp according to the target lamp effect template, including: performing lamp effect control on the target lamp according to the first lamp effect template or the third lamp effect template; wherein the first lamp effect template is a new lamp effect template obtained by performing parameter correction on the target lamp effect template according to a tone label of the target image by the server, the third lamp effect template is a new lamp effect template obtained by performing parameter correction on the target lamp effect template according to the tone label and a target color block RGB parameter value by the server, the tone label is used to represent the gray scale characteristics of the target image, and the target color block RGB parameter value is used to represent the RGB parameter information included in the target image. The tone label is obtained by performing tone analysis on the target image, and the process of performing tone analysis on the target image includes: performing gray scale processing on the target image to obtain a gray scale histogram of the target image; determining the tone label corresponding to the target image based on the position of the peak value and the gray scale pixel width in the gray scale histogram of the target image; and determining the tone label from high long tone, high medium tone, high short tone, medium short tone, medium medium tone, medium long tone, low long tone, low medium tone, low short tone, full long tone, hard tone and soft tone.
13. A terminal device, comprising: It includes: a central processing unit, a memory, an input / output interface, a wired or wireless network interface, and a power supply; the memory is a volatile memory or a persistent memory; the central processing unit is configured to communicate with the memory, execute instruction operations in the memory on the central processing unit, and perform the method of any one of claims 1-10.
14. A server, characterized by It includes: a central processing unit, a memory, an input / output interface, a wired or wireless network interface, and a power supply; the memory is a volatile memory or a persistent memory; the central processing unit is configured to communicate with the memory, execute instruction operations in the memory on the central processing unit, and perform the method of any one of claims 1-10.
15. A luminaire, characterized by It includes: a receiving unit configured to receive a lamp effect template sent by a terminal device or a server, the lamp effect template being the target lamp effect template in the lamp effect control method of any one of claims 1-10; a configuration unit configured to configure according to a plurality of different types of lamp effect parameters included in the lamp effect template.
16. A computer-readable storage medium comprising instructions, wherein: When the instructions are run on a computer, the computer is caused to perform the lamp effect control method of any one of claims 1-10.
17. A computer program product comprising instructions, characterized in that, When it is run on a computer, the computer is caused to perform the lamp effect control method of any one of claims 1-10.
Citation Information
Patent Citations
Lamplight adjusting method and device based on video parameter
CN105872748A
Light effect adjustment method, intelligent terminal and storage medium
CN110673900A