Method for determining light effect trajectory, sound and atmosphere lamp device
By combining audio information and basic data of the light strip to optimize the position of the light effect trajectory, the problems of unstable trajectory, low accuracy and poor consistency in the existing technology are solved, and the precise matching and smooth movement of the light effect and audio are achieved, which can adapt to the real-time response of complex audio scenes.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SHENZHEN XINYANG CHUANGZHI TECHNOLOGY CO LTD
- Filing Date
- 2026-04-20
- Publication Date
- 2026-07-10
AI Technical Summary
Existing lighting trajectory control technologies suffer from unstable trajectories, low precision, and poor consistency, failing to meet users' needs for precise lighting control, smooth motion, and real-time adaptation to the scene.
The predicted trajectory position of the light effect is determined by the audio information of the current audio frame, the basic trajectory position is determined by combining the basic data of the light strip, and the initial position deviation is optimized by the position deviation determination model to obtain the target position deviation. Finally, the basic trajectory position and the target position deviation are superimposed to obtain the target trajectory position of the light strip.
It improves the control precision and consistency of the lighting effect trajectory, achieves precise matching between the lighting effect movement and the audio rhythm, ensures the smoothness and regularity of the lighting effect movement, and adapts to real-time response in different scenarios.
Smart Images

Figure CN122069628B_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of lighting effect control technology, and in particular relates to a method for determining lighting effect trajectory, and a sound and ambient lighting device. Background Technology
[0002] With the deep integration of lighting and multimedia technologies, LED strips, as a flexible and malleable lighting medium, are widely used in various scenarios such as home decoration, stage performances, and smart device displays. Precise control of the lighting trajectory is one of the core steps in enhancing the visual experience of LED strips. This requires achieving precise matching between the movement of the lighting effects and the rhythm of the audio, while ensuring the smoothness, regularity, and consistency of the lighting movements.
[0003] Currently, the control method for lighting effect trajectories is generally an audio-driven real-time control method. This method responds to the received audio signal and predicts the trajectory position of the lighting effect through the audio signal, achieving real-time linkage between the lighting effect and the audio. However, since the audio signal is a one-dimensional time-series signal, the mapping relationship between the audio signal and the lighting effect position is difficult to control accurately. The trajectory position predicted directly from the audio signal has a large deviation, resulting in insufficient precision in lighting effect control. Summary of the Invention
[0004] This application provides a method for determining the trajectory of lighting effects, as well as a sound and ambient lighting device, which can solve the problem of insufficient precision in lighting effect control.
[0005] In a first aspect, embodiments of this application provide a method for determining a lighting effect trajectory, including:
[0006] In response to receiving the current audio frame, the predicted trajectory position of the light strip's lighting effect at the current moment is determined based on the audio information of the current audio frame;
[0007] Based on the basic data of the first light strip, the basic trajectory position of the light strip's lighting effect at the current moment is determined, wherein the basic data of the first light strip includes the movement cycle of the lighting effect, the starting position of the light strip's lighting effect, and the ending position of the light strip's lighting effect.
[0008] Determine the initial positional deviation between the predicted trajectory position and the base trajectory position;
[0009] The initial position deviation is input into the trained position deviation determination model, and the initial position deviation is optimized by the position deviation determination model to obtain the target position deviation.
[0010] The target trajectory position is obtained by superimposing the deviation between the base trajectory position and the target position, and the target trajectory position is used as the basis for illuminating the light strip.
[0011] In this application, the relevant technology determines the trajectory position of the lighting effect only based on the audio signal. However, the audio signal is a one-dimensional time-series signal, which only describes the sound state (such as intensity, rhythm, and timbre), making it difficult to quantify the trajectory position. This results in a certain degree of randomness in the lighting effect trajectory determined based on the audio signal (for example, low-volume audio tends to have a fixed trajectory position, while high-volume audio tends to have a wildly shifting trajectory position). This application determines the predicted trajectory position of the lighting effect based on the audio information of the current audio frame and determines the basic trajectory position of the lighting effect based on the basic data of the first light strip. Since the basic data of the first light strip includes the starting position of the lighting effect and the ending position of the light strip, and the starting position of the lighting effect and the ending position of the light strip can characterize the spatial position of the lighting effect (i.e., can quantify the trajectory position), the generated basic trajectory position is deterministic.
[0012] Furthermore, by determining the initial positional deviation between the predicted trajectory position and the base trajectory position, and optimizing the initial positional deviation using a positional deviation determination model to obtain the target positional deviation, and by further optimizing the positional deviation using the trained positional deviation determination model, the system can learn a refined correction relationship between audio rhythm, intensity, timbre, and other features and the light effect trajectory position. This ensures that the final target trajectory position maintains the basic motion pattern while responding to instantaneous changes in audio. Finally, the base trajectory position and the target position deviation are superimposed to obtain the target trajectory position of the light strip effect. This application calculates the deviation between the predicted trajectory position determined based on audio information and the base trajectory position determined by the light strip's basic data, and corrects the determined initial positional deviation using a positional deviation determination model. Finally, the base trajectory position is superimposed with the optimized target position deviation, which effectively reduces the randomness of light effect trajectory generation and achieves effective control over the light effect position.
[0013] In one possible implementation of the first aspect, determining the basic trajectory position of the light strip's lighting effect at the current moment based on the first light strip's basic data includes:
[0014] By inputting the basic data of the first light strip into the position determination model, the basic trajectory position of the light strip's lighting effect at the current moment is obtained;
[0015] The location determination model includes: ; ; The x-coordinate of the basic trajectory position, The ordinate of the basic trajectory position. The x-coordinate of the starting position of the lighting effect is [the coordinate of the position of the starting position of the lighting effect]. The vertical coordinate of the starting position of the lighting effect is [value]. Let x be the x-coordinate of the endpoint of the lighting effect. Let t be the ordinate of the endpoint of the lighting effect, T be the motion period of the lighting effect, and t be the current time.
[0016] In this application, by introducing the starting and ending positions of the lighting effect, the basic trajectory position is quantified, ensuring that the basic trajectory position is always confined within a set spatial range, thus enhancing the system's controllability and operational safety. Furthermore, the position determination model is a simple linear function based on the current time t and fixed parameters, resulting in very low computational complexity. For real-time lighting effect systems that require frame-by-frame audio processing, this lightweight trajectory position determination method can quickly output the basic trajectory position, ensuring low-latency system operation.
[0017] In one possible implementation of the first aspect, before inputting the position deviation into a trained position deviation determination model and optimizing the position deviation through the position deviation determination model to obtain the target position deviation, the method further includes:
[0018] Obtain the controller's operating time within the preset time period;
[0019] The ratio of the working time to the preset time is determined to obtain the computing power utilization rate of the controller;
[0020] Based on the computing power occupancy rate, the inference mode of the position deviation determination model in the current detection cycle is determined, wherein inference modes corresponding to different computing power occupancy rates are pre-stored, and the inference accuracy of different inference modes is different.
[0021] Accordingly, the step of inputting the initial position deviation into the trained position deviation determination model, and optimizing the initial position deviation through the position deviation determination model to obtain the target position deviation, includes:
[0022] The initial position deviation and the inference mode of the current detection cycle are input into the trained position deviation determination model. The initial position deviation is then optimized by the position deviation determination model to obtain the target position deviation.
[0023] In this application, since the maximum computing power of the controller is generally fixed, if the controller processes a large amount of data simultaneously, lag may occur, leading to data processing errors. This application achieves automatic accuracy balancing by monitoring the controller's computing power utilization in real time and dynamically selecting different precision inference modes based on the computing power utilization. This makes the position deviation determination model more suitable for the overall system state, ensuring that the position deviation determination model does not become a performance bottleneck, thereby optimizing the overall performance of the entire system.
[0024] In one possible implementation of the first aspect, the audio information includes rhythm density;
[0025] The step of inputting the initial position deviation and the inference mode of the current detection cycle into the trained position deviation determination model, and optimizing the initial position deviation through the position deviation determination model to obtain the target position deviation, includes:
[0026] The rhythm density, the initial position deviation, and the inference mode of the current detection cycle are input into the trained position deviation determination model. The initial position deviation is then optimized by the position deviation determination model to obtain the target position deviation.
[0027] In this application, rhythm density reflects the number of beats or accents per unit time, serving as a quantitative indicator of the tempo and activity level of audio. By further introducing rhythm density as an explicit feature, a more direct and explicit rhythmic guidance signal is provided to the position deviation determination model. This enables the model to perceive the rhythmic intensity of the current audio, thereby automatically adjusting the correction amplitude when correcting position deviation, achieving a fine coupling between lighting effects and rhythm density.
[0028] In one possible implementation of the first aspect, the step of inputting the rhythm density, the initial position deviation, and the inference pattern of the current detection cycle into a trained position deviation determination model, and optimizing the initial position deviation through the position deviation determination model to obtain the target position deviation, includes:
[0029] If the reasoning pattern determined in the previous detection cycle is different from the reasoning pattern in the current detection cycle, the rhythm density, the initial position deviation, and the reasoning pattern of the previous detection cycle are input into the trained position deviation determination model. The initial position deviation is then optimized by the position deviation determination model to obtain the first candidate position deviation.
[0030] The rhythm density, the initial position deviation, and the inference mode of the current detection cycle are input into the trained position deviation determination model. The initial position deviation is optimized by the position deviation determination model to obtain the second candidate position deviation.
[0031] The target position deviation is obtained based on the first candidate position deviation and the second candidate position deviation.
[0032] In this application, since the inference mode of the position deviation determination model is determined based on the computing power utilization rate of the controller, when the computing power utilization rate of the controller changes, causing the inference mode of the current detection cycle to be different from that of the previous cycle, the position deviation determined by the position deviation determination model under different inference modes will be different, which in turn will lead to different positions of the light effect trajectory determined based on the position deviation. Therefore, by calculating the first candidate position deviation based on the previous inference mode and the second candidate position deviation based on the current inference mode, and combining the two to obtain the final target position deviation, the determined target position deviation can be smoothly transitioned when the inference mode changes, thereby ensuring the smooth transition of the light effect trajectory position when the inference mode changes, effectively avoiding the trajectory abrupt change at the moment of inference mode switching, and ensuring the visual continuity of the light effect movement.
[0033] In one possible implementation of the first aspect, the audio information includes the emotion type of the current audio frame and the rhythm density of the current audio frame;
[0034] The step of determining the predicted trajectory position of the light strip's lighting effect at the current moment based on the audio information of the current audio frame includes:
[0035] Perform a Fourier transform on the current audio frame to obtain the spectral energy distribution of the current audio frame;
[0036] Find the number of rhythm point peaks from the said spectral energy distribution;
[0037] The rhythm density of the current audio frame is determined based on the number of rhythm point peaks.
[0038] Obtain the emotion type of the current audio frame;
[0039] Based on the emotion type and the rhythm density, the predicted trajectory position of the light strip's lighting effect at the current moment is determined.
[0040] In this application, the spectral energy distribution is obtained through Fourier transform, and the number of rhythm point peaks is extracted and the rhythm density is calculated. The emotion type reflects the overall emotional tendency of the audio frame. Based on the emotion type and rhythm density, the predicted trajectory position of the light strip effect at the current moment is determined, so that the system no longer relies on a single audio feature, but integrates rhythm structure features (rhythm density) and high-level semantic features (emotion type), providing a richer audio information basis for the predicted trajectory position, making the determined predicted trajectory position more consistent with the state of the current audio frame.
[0041] In one possible implementation of the first aspect, determining the predicted trajectory position of the light strip's lighting effect at the current moment based on the emotion type and the rhythm density includes:
[0042] By inputting the emotion type and the rhythm density into the trained user lighting effect preference model, the predicted trajectory position of the lighting effect of the light strip at the current moment can be obtained.
[0043] The training process of the user lighting effect preference model includes:
[0044] Acquire historical lighting effect data, wherein the historical lighting effect data includes lighting effect preference data of users manually adjusting the light strips corresponding to different audio;
[0045] The historical lighting effect data is used to train the user lighting effect preference model to be trained, resulting in the trained user lighting effect preference model.
[0046] In this application, different users may have significantly different lighting effect preferences. By introducing historical lighting effect data that users manually adjust as training samples, the user lighting effect preference model can learn the personalized lighting effect preferences of specific users, so that the predicted trajectory position is more in line with the user's aesthetic habits, rather than a general effect.
[0047] In one possible implementation of the first aspect, the method further includes:
[0048] Obtain the historical real lighting effect trajectory corresponding to the historical audio frame and the basic data of the second light strip of the historical audio frame;
[0049] Based on the second light strip's basic data, determine the historical basic trajectory position of the lighting effect at historical times;
[0050] Determine the historical positional deviation between the historical actual lighting trajectory and the historical basic trajectory position at the same moment;
[0051] The historical position deviation is input into the first neural network model and the second neural network model. The second neural network model is trained by knowledge distillation to obtain the trained second neural network model, which is the trained position deviation determination model.
[0052] In this application, by introducing a first neural network model (teacher model) and a second neural network model (student model) for joint training, the complex mapping relationship learned by the teacher model is distilled into the student model. The final deployed model is the trained student model (i.e., the position deviation determination model). While maintaining high prediction accuracy, the computational complexity and inference latency of the model are significantly reduced, making it more suitable for real-time lighting control scenarios.
[0053] Secondly, embodiments of this application provide a device for determining the trajectory of a lighting effect, comprising:
[0054] The trajectory prediction module is used to respond to the received current audio frame and determine the predicted trajectory position of the light strip's lighting effect at the current moment based on the audio information of the current audio frame.
[0055] The trajectory calculation module is used to determine the basic trajectory position of the light strip's lighting effect at the current moment based on the basic data of the first light strip, wherein the basic data of the first light strip includes the movement cycle of the lighting effect, the starting position of the light strip's lighting effect, and the ending position of the light strip's lighting effect.
[0056] The deviation calculation module is used to calculate the initial position deviation between the predicted trajectory position and the basic trajectory position;
[0057] The deviation optimization module is used to input the initial position deviation into the trained position deviation determination model, and optimize the initial position deviation through the position deviation determination model to obtain the target position deviation;
[0058] The position determination module is used to superimpose the deviation between the basic trajectory position and the target position to obtain the target trajectory position of the light strip's lighting effect, and the target trajectory position serves as the basis for illuminating the light strip.
[0059] Thirdly, embodiments of this application provide a terminal device, including: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the method for determining the lighting effect trajectory as described in any of the first aspects above.
[0060] Fourthly, embodiments of this application provide a computer-readable storage medium storing a computer program that, when executed by a processor, implements the method for determining the lighting effect trajectory as described in any of the first aspects above.
[0061] Fifthly, embodiments of this application provide a computer program product that, when run on a terminal device, causes the terminal device to execute the method for determining the lighting effect trajectory described in any of the first aspects above.
[0062] Sixthly, embodiments of this application provide an audio system, including:
[0063] A light strip, wherein the light strip is provided with multiple LED beads;
[0064] The system includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the method for determining the lighting trajectory described in the first aspect above, so that the light strip is illuminated according to the target trajectory position.
[0065] Seventhly, embodiments of this application provide an ambient lighting device, including:
[0066] A light strip installed in the interior of a passenger vehicle, the light strip having multiple LED beads;
[0067] The system includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the method for determining the light effect trajectory described in the first aspect above, so that the light strip is illuminated according to the target trajectory position. Attached Figure Description
[0068] To more clearly illustrate the technical solutions in the embodiments of this application, the drawings used in the description of the embodiments or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0069] Figure 1 This is a schematic diagram of an audio device provided in one embodiment of this application;
[0070] Figure 2 This is a flowchart illustrating a method for determining the lighting trajectory according to an embodiment of this application;
[0071] Figure 3 This is a comparative schematic diagram showing the trajectory positions determined by different methods according to an embodiment of this application;
[0072] Figure 4 This is a flowchart illustrating a method for determining a reasoning pattern according to an embodiment of this application;
[0073] Figure 5 This is a flowchart illustrating a method for determining accurate positional deviation provided in an embodiment of this application;
[0074] Figure 6 This is a flowchart illustrating a method for determining the predicted trajectory position according to an embodiment of this application;
[0075] Figure 7 This is a schematic diagram of the structure of a lighting trajectory determination device provided in an embodiment of this application;
[0076] Figure 8 This is a schematic diagram of the structure of a terminal device provided in an embodiment of this application. Detailed Implementation
[0077] It should be understood that, when used in this application specification and the appended claims, the term "comprising" indicates the presence of the described features, integrals, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components and / or a collection thereof.
[0078] Furthermore, in the description of this application and the appended claims, the terms "first," "second," "third," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0079] References to "one embodiment" or "some embodiments" in this specification mean that one or more embodiments of this application include a specific feature, structure, or characteristic described in connection with that embodiment. Therefore, the phrases "in one embodiment," "in some embodiments," "in other embodiments," "in still other embodiments," etc., appearing in different parts of this specification do not necessarily refer to the same embodiment, but rather mean "one or more, but not all, embodiments," unless otherwise specifically emphasized.
[0080] With the deep integration of lighting and multimedia technologies, LED strips, as a flexible and shape-adjustable lighting medium, are widely used in various scenarios such as home decoration, stage performances, and smart device displays. For example, ambient lighting (i.e., LED strips) can be installed on speakers, displays, passenger car interiors, and light bars. Light bars can be long cylindrical or circular, etc.
[0081] Taking intelligent devices as an example, such as audio equipment Figure 1 The images show speakers of different shapes. The hardware components of a speaker can include a signal receiving component, a data processing component, a sound reproduction component, and ambient lighting. The signal receiving component is the starting point for sound, used to acquire sound signals, which can be analog or digital signals, etc. The data processing component is used to filter and amplify the sound signal to obtain a processed sound signal. The sound reproduction component is used to convert the processed sound signal from an electrical signal into a sound wave. Additionally, the data processing component is used to determine the lighting mode of the ambient lighting to control its illumination.
[0082] The software architecture of an audio system can include an application layer, a service layer, a core processing layer, an algorithm and inference layer, and a system and driver layer.
[0083] The application layer is the interface through which users interact with the speaker, directly determining the product's functional experience. The application layer can include voice interaction, music playback, smart services, and system settings.
[0084] The service layer is the core that distinguishes smart speakers from traditional speakers, responsible for handling complex dialogue logic and providing personalized services. For example, the service layer can provide skill and service orchestration: routing user requests to the corresponding functional modules; the service layer can provide dialogue management: maintaining the context of the dialogue and resolving referential issues; the service layer can also provide user profiles: by analyzing user habits and preferences, it can provide personalized recommendations (such as recommending frequently listened-to music genres) and proactive services (such as automatically broadcasting morning traffic updates).
[0085] The core processing layer is responsible for processing all incoming and outgoing sound signals, ensuring that they are "clearly audible" and "well-playable".
[0086] The algorithm and inference layer is a collection of models that provide algorithmic support for upper-level processing, such as speech recognition models, natural language understanding models, and speech synthesis models.
[0087] The system and driver layers are responsible for interacting directly with the hardware and providing a unified calling interface for the upper layers.
[0088] During audio usage, after receiving a command signal, the application layer transmits it to the service layer. The service layer parses the command signal to determine the intent information. Based on this intent information, the service layer prepares resources and constructs a playback task, then transmits the playback task instruction to the core processing layer. The core processing layer retrieves the corresponding data based on the playback task instruction, decodes the data, and performs effect adaptation; it also calls the model in the algorithm and inference layer to adjust the audio. Finally, the core processing layer transmits the processed, correctly formatted audio data to the system and driver layer. The system and driver layer routes the audio data to the corresponding hardware device to achieve audio playback.
[0089] For smart devices equipped with ambient lighting, precise control of the lighting trajectory is the core of enhancing the visual experience of the light strip. The core requirement is to achieve precise matching between the movement of the lighting effect and the rhythm of the audio, while ensuring the smoothness, regularity and consistency of the lighting effect movement.
[0090] Currently, lighting effect trajectories are generally based on audio changes. By extracting audio information (such as volume, frequency, rhythm, etc.), the trajectory position of the lighting effect is predicted, thus achieving real-time linkage between lighting effects and audio. However, this purely audio-driven control method has many technical drawbacks: First, audio signals themselves have characteristics such as instantaneous changes, noise interference, and fluctuations in intensity. The light effect trajectory predicted solely from audio information is prone to problems such as position jumps, jitter, and flickering, resulting in discontinuous light effect movement and a poor visual experience. Second, the mapping relationship between audio features and light effect positions is difficult to control precisely. The trajectory position predicted directly from audio has a large deviation, resulting in insufficient precision in light effect control. Third, purely audio-driven light effects lack an overall rhythm and regularity, easily leading to haphazard movement and chaotic start and end positions. Especially in complex audio scenarios with varying music styles and fluctuating volumes, the light effect trajectory becomes uncontrollable, resulting in poor consistency in light effect performance across different scenarios. Finally, the purely audio-driven approach struggles to balance the real-time responsiveness and motion stability of the light effects. Either the response speed is fast but the trajectory is unstable, or the trajectory is relatively stable but cannot follow the audio rhythm in real time, making it difficult to balance the dual requirements of "dynamism" and "aesthetics."
[0091] In summary, existing lighting trajectory control technologies suffer from problems such as unstable trajectories, low accuracy, and poor consistency, failing to meet users' demands for precise lighting control, smooth motion, and real-time adaptation to scenes. Therefore, developing a lighting trajectory determination method that can balance real-time audio responsiveness with lighting motion stability, while improving trajectory control accuracy and consistency, has become a pressing technical problem for those skilled in the art.
[0092] To address the aforementioned issues, this application proposes a method for determining the trajectory of a lighting effect. The method involves determining the predicted trajectory position of the lighting effect based on the audio information of the current audio frame, and determining the basic trajectory position of the lighting effect based on the basic data of a first light strip. Then, the initial position deviation between the predicted trajectory position and the basic trajectory position is calculated. This initial position deviation is then optimized using a position deviation determination model to obtain the target position deviation. Finally, the basic trajectory position and the target position deviation are superimposed to obtain the target trajectory position of the light strip's lighting effect. This application combines the predicted trajectory position determined by the audio information of the current audio frame and the basic trajectory position determined by the basic data of the light strip when determining the trajectory position of the lighting effect, making the determined trajectory position of the lighting effect more accurate.
[0093] The following is a detailed description of the method for determining the lighting trajectory according to the embodiments of this application. The method of this application can be run in a terminal device, which can be a speaker, a display screen, a vehicle, a light stick, a television, a mechanical keyboard, a treadmill, a stage decoration equipment, etc.
[0094] Figure 2 A schematic flowchart of the method for determining the lighting effect trajectory provided in this application is shown, with reference to... Figure 2The method is described in detail below:
[0095] S101, in response to receiving the current audio frame, determines the predicted trajectory position of the light strip's lighting effect at the current moment based on the audio information of the current audio frame.
[0096] In this embodiment, the audio information may include the spectral flux of the current audio frame. Different trajectory positions corresponding to different spectral fluxes are pre-set. The trajectory position corresponding to the spectral flux of the current audio frame is found to obtain the predicted trajectory position of the lighting effect at the current moment. Spectral flux is a physical indicator used to measure the degree of change in sound timbre over time.
[0097] The method for calculating spectral flux is: SF i =∑|X i , k -X i-1 , k |²(k=1,2,...,M)SF i X is the spectral flux. i , k X represents the spectral amplitude of the i-th audio frame at the k-th spectral point; M is the total number of spectral points, which can be half the number of Fourier transform points corresponding to the current audio frame, and is not restricted here; i-1 , k Let be the spectral amplitude of the (i-1)th audio frame at the kth spectral point.
[0098] S102, based on the basic data of the first light strip, determine the basic trajectory position of the light strip's lighting effect at the current moment, wherein the basic data of the first light strip includes the motion cycle of the lighting effect, the starting position of the light strip's lighting effect, and the ending position of the light strip's lighting effect.
[0099] In this embodiment, the basic data of the first light strip is input into the position determination model to obtain the basic trajectory position of the light strip's lighting effect at the current moment.
[0100] The location determination model includes: ; ; The x-coordinate of the basic trajectory position, The ordinate of the basic trajectory position. The x-coordinate of the starting position of the lighting effect is [the coordinate of the position of the starting position of the lighting effect]. The vertical coordinate of the starting position of the lighting effect is [value]. Let x be the x-coordinate of the endpoint of the lighting effect. Let be the ordinate of the endpoint of the lighting effect, T be the motion period of the lighting effect, and t be the current time, where t is greater than 0 and less than or equal to T. To select the minimum value between t and Tt. This is used to achieve trajectory reciprocation. When t ≤ T / 2, the movement is forward (from the starting position of the lighting effect to the ending position of the lighting effect), and when t > T / 2, the movement is reverse (from the ending position of the lighting effect to the starting position of the lighting effect). In this application, the basic trajectory position is implemented using linear calculation, which significantly reduces the computational load.
[0101] S103, determine the initial position deviation between the predicted trajectory position and the basic trajectory position.
[0102] In this embodiment, the initial position deviation is obtained by subtracting the base trajectory position from the predicted trajectory position.
[0103] , ,in, The x-axis represents the initial position deviation. The ordinate represents the initial position deviation. The x-coordinate of the predicted trajectory position, The ordinate of the predicted trajectory position. The x-coordinate of the basic trajectory position, It is the ordinate of the position of the basic trajectory.
[0104] The initial position deviation is normalized to the interval [0, 1] to eliminate the influence of dimensions. Specifically, the normalization formula is: , The x-axis represents the normalized initial position deviation. The x-axis represents the initial position deviation. This is the preset minimum offset of the horizontal coordinate. This is the preset maximum offset of the horizontal coordinate. , The ordinate represents the normalized initial position deviation. The ordinate represents the initial position deviation. This is the minimum offset of the preset ordinate. This is the preset maximum offset of the ordinate.
[0105] S104, the initial position deviation is input into the trained position deviation determination model, and the initial position deviation is optimized by the position deviation determination model to obtain the target position deviation.
[0106] In this embodiment, the position deviation determination model can be a convolutional neural network model.
[0107] For example, a positional deviation determination model may include an input layer, two convolutional layers, and an output layer. The input layer receives the initial positional deviation, the two convolutional layers extract features from the initial positional deviation, and the output layer outputs the target positional deviation. For example, the two convolutional layers may include a first convolutional layer and a second convolutional layer. The first convolutional layer may have 16 channels, and the second convolutional layer may have 8 channels. Both the first and second convolutional layers may use the ReLU activation function (Rectified Linear Unit).
[0108] In this embodiment, the training process for the position deviation determination model is as follows:
[0109] S11, obtain the historical real lighting effect trajectory corresponding to the historical audio frame and the second light strip basic data of the historical audio frame.
[0110] In this embodiment, the historical true lighting effect trajectory is the actual lighting effect trajectory of the light strip changing with the historical audio frames.
[0111] The Grubbs criterion was used to filter historical real lighting effect trajectories, resulting in the filtered historical real lighting effect trajectories.
[0112] S12, based on the second light strip basic data, determine the historical basic trajectory position of the lighting effect at historical time.
[0113] In this embodiment, the basic data of the second light strip may include the motion cycle of the light effect, the starting position of the light effect of the light strip, and the ending position of the light effect of the light strip.
[0114] The calculation method for the historical baseline trajectory position is described in step S102 above and will not be repeated here.
[0115] S13, determine the historical position deviation between the historical real lighting trajectory and the historical basic trajectory position at the same moment.
[0116] In this embodiment, the calculation of historical position deviation is performed in accordance with the process of step S103 above, and will not be repeated here.
[0117] S14, the historical position deviation is input into the first neural network model and the second neural network model, and the second neural network model is trained by knowledge distillation to obtain the trained second neural network model. The trained second neural network model is the trained position deviation determination model.
[0118] In this embodiment, the first neural network model serves as the teacher model, and the second neural network model serves as the student model. The structure of the first neural network model is more complex than that of the second neural network model.
[0119] The teacher model is a heavy cloud-based model, such as a 6-layer convolutional neural network model; the student model is a miniature edge-based model, such as a 3-layer convolutional neural network model. The trajectory optimization capabilities of the teacher model are distilled into the student model, making the optimization capabilities of the student model closer to those of the teacher model, resulting in the trained student model.
[0120] The distillation loss function in the distillation process is L. distill = α * L hard + (1-α) * L soft L distill For distillation loss, For the hard loss function, L soft Here, α is the soft loss function, and α is the weighting coefficient.
[0121] The hard loss function is , This is the hard loss value. The total number of samples, Let x be the true optimization direction of the i-th sample (true x-direction perturbation). The y-component of the true optimization direction for the i-th sample (true y-direction perturbation). This is the prediction result (predicting the x-direction perturbation) calculated by the student model for the i-th sample. This is the prediction result (predicted y-direction perturbation) calculated by the student model for the i-th sample.
[0122] The soft loss function is , This is a soft loss value. The total number of samples, The output probability of the teacher model. This represents the output probability of the student model.
[0123] S105, the deviation between the basic trajectory position and the target position is superimposed to obtain the target trajectory position of the light strip's lighting effect.
[0124] In this embodiment, after obtaining the target trajectory position, the on / off state of the LED beads on the LED strip can be controlled according to the target trajectory position so that the LED strip's lighting effect position is at the target trajectory position in the current audio frame.
[0125] In this embodiment, the target position deviation can first be denormalized. The denormalization formula is as follows:
[0126] , The x-axis represents the normalized target position deviation. The x-coordinate of the target position deviation. The maximum value of the x-coordinate in the target position deviation in the training samples. It is the minimum x-coordinate of the target position deviation in the training samples. , The ordinate represents the normalized target position deviation. The ordinate in the target position deviation is... This represents the maximum value of the ordinate in the target position deviation within the training samples. It is the minimum value of the ordinate in the target position deviation in the training samples.
[0127] The target trajectory position is obtained by adding the inverse normalized target position deviation to the base trajectory position; the LEDs on the light strip are turned on and off according to the target trajectory position so that the illuminated position of the light effect on the light strip is the target trajectory position.
[0128] For example, such as Figure 3 As shown, if the base trajectory position is at position A of the light strip and the predicted trajectory position is at position B of the light strip, then after calculation, the final determined target trajectory position may be at position C.
[0129] In one possible implementation, in order to make the inference of the position deviation determination model more consistent with the current state of the controller, the computing power utilization rate of the controller can be calculated before using the position deviation determination model for inference. The inference mode of the controller can be determined by the computing power utilization rate, and then the position deviation determination model can infer the target position deviation based on the determined inference mode.
[0130] Specifically, such as Figure 4 As shown, prior to step S104 above, the method of this application may further include:
[0131] S201, obtain the controller's working time within the preset time period.
[0132] In this embodiment, the preset duration can be set as needed. For example, the preset duration can be 5 milliseconds or 10 milliseconds, etc., and there is no limitation here.
[0133] Working time represents the duration of time the controller is in a busy state, such as the duration of the controller being in trajectory optimization or audio acquisition.
[0134] S202, determine the ratio of the working time to the preset time, and obtain the computing power utilization rate of the controller.
[0135] For example, if the working time is 4 seconds and the preset time is 5 seconds, then the computing power utilization rate is 4 / 5 = 0.8.
[0136] S203, based on the computing power occupancy rate, determine the inference mode of the position deviation determination model in the current detection cycle, wherein inference modes corresponding to different computing power occupancy rates are pre-stored, and the inference accuracy of different inference modes is different.
[0137] Accordingly, the implementation process of step S104 above may include: inputting the initial position deviation and the inference mode of the current detection period into the trained position deviation determination model, and optimizing the initial position deviation through the position deviation determination model to obtain the target position deviation.
[0138] For example, pre-set low load threshold ranges (e.g., less than 40%), medium load threshold ranges (e.g., 40.1%-70%), and high load threshold ranges (e.g., greater than 70.1%). Low load threshold ranges correspond to low inference accuracy, medium load threshold ranges to medium inference accuracy, and high load threshold ranges to high inference accuracy. When the controller's computing power utilization is in the high load threshold range, it indicates that the controller's computing power is strained, and the inference accuracy of the position deviation determination model needs to be reduced to ensure its smooth operation and avoid computing power overload. When the controller's computing power utilization is in the low load threshold range, it indicates that the controller's computing power is sufficient, and the inference accuracy of the position deviation determination model needs to be increased to ensure that the target position deviation inferred by the model is as accurate as possible. When the controller's computing power utilization is in the medium load threshold range, it indicates that the controller's computing power is moderate, and the inference accuracy of the position deviation determination model is moderate, balancing inference accuracy with controller computing power consumption.
[0139] In one approach, after calculating the computing power utilization rate, it can be corrected to obtain a corrected computing power utilization rate. Based on the corrected computing power utilization rate, the positional deviation is determined, and the inference mode of the model in the current detection cycle is determined. Specifically, the computing power utilization rate is multiplied by a standard coefficient to obtain a first value; the first value is then added to a calibration offset to obtain the corrected computing power utilization rate.
[0140] In one possible implementation, the audio information may also include rhythm density. In order for the model to perceive the rhythm intensity of the current audio, it can automatically adjust the correction amplitude when correcting the position deviation, thereby achieving fine coupling between the light effect movement and the rhythm density. Alternatively, the rhythm density can be input into the position deviation determination model, so that the position deviation determination model can determine the target position deviation based on the rhythm density.
[0141] Specifically, the implementation process of step S104 above may also include:
[0142] The rhythm density, the initial position deviation, and the inference mode of the current detection cycle are input into the trained position deviation determination model. The initial position deviation is then optimized by the position deviation determination model to obtain the target position deviation.
[0143] In one possible implementation, such as Figure 5 As shown, when the computing power utilization rate of the controller changes, causing the inference mode of the current detection cycle to differ from that of the previous cycle, direct switching may cause a jump in the target position deviation. In order to effectively avoid the sudden change in trajectory during mode switching, ensure the visual continuity of the lighting effect movement, and achieve smooth switching between different inference accuracies, the implementation process of the above step S104 may also include:
[0144] S1041, if the inference pattern determined in the previous detection cycle is different from the inference pattern in the current detection cycle, the rhythm density, the initial position deviation, and the inference pattern of the previous detection cycle are input into the trained position deviation determination model, and the initial position deviation is optimized by the position deviation determination model to obtain the first candidate position deviation.
[0145] For example, if the inference pattern determined in the previous detection period is low inference accuracy and the inference pattern determined in the current detection period is high inference accuracy, then the inference pattern determined in the previous detection period is different from the inference pattern determined in the current detection period. The position deviation determination model uses low inference accuracy to determine the first candidate position deviation.
[0146] S1042, the rhythm density, the initial position deviation, and the inference mode of the current detection cycle are input into the trained position deviation determination model, and the initial position deviation is optimized by the position deviation determination model to obtain the second candidate position deviation.
[0147] S1043, the target position deviation is obtained based on the first candidate position deviation and the second candidate position deviation.
[0148] In this embodiment, the first candidate position deviation and the second candidate position deviation are weighted and summed to obtain the target position deviation.
[0149] Specifically, , For the target position deviation, The first candidate position deviation, This represents the deviation from the second candidate position. Preset weights.
[0150] In one possible implementation, such as Figure 6As shown, the audio information includes the emotion type and rhythm density of the current audio frame. The implementation of step S101 may include:
[0151] S1011, Perform a Fourier transform on the current audio frame to obtain the spectral energy distribution of the current audio frame.
[0152] In this embodiment, the Fourier transform is x(t) is the audio time-domain signal, i.e., the amplitude of the original audio waveform that changes over time; w(t) is the Hanning window function, used to truncate a segment of the audio to reduce spectral leakage; τ is the time offset, representing the position of the window function on the time axis; f is the frequency; j is the imaginary unit, indicating that the frequency domain result includes phase information; It is a Fourier kernel, used to extract the frequency f component; Integrating over the time offset τ represents the calculation performed as the window function slides to each position.
[0153] S1012, find the number of rhythm point peaks from the said spectral energy distribution.
[0154] In this embodiment, the peak value of the rhythm point is the position at the high point in the spectral energy.
[0155] S1013, determine the rhythm density of the current audio frame based on the number of rhythm point peaks.
[0156] In this embodiment, the rhythm density is obtained by dividing the number of rhythm peaks by the audio duration.
[0157] S1014, Obtain the emotion type of the current audio frame.
[0158] In this embodiment, the current audio frame is input into the emotion determination model to obtain the emotion type of the current audio frame, wherein the emotion type may include happiness, sadness, anger, and calmness.
[0159] S1015, Based on the emotion type and the rhythm density, determine the predicted trajectory position of the light strip's lighting effect at the current moment.
[0160] In one approach, a mapping table is pre-set between different emotion types, different rhythm densities, and the predicted trajectory positions of the lighting effects. The predicted trajectory position of the light strip's lighting effect at the current moment is determined by looking up the mapping table.
[0161] In another approach, the emotion type and the rhythm density are input into a trained user lighting effect preference model to obtain the predicted trajectory position of the light strip's lighting effect at the current moment.
[0162] The training process for the user lighting effect preference model includes:
[0163] S21, acquire historical lighting effect data, wherein the historical lighting effect data includes user-manually adjusted lighting effect preference data for different audio frequencies.
[0164] In this embodiment, the historical lighting effect data includes the user-selected lighting effect color, audio type, user operation time, and adjustment frequency. The historical lighting effect data is then filtered to obtain filtered historical lighting effect data. The filtering methods include determining whether the trajectory speed is greater than a preset speed and whether the equivalent curvature is greater than a preset value.
[0165] S22, the user lighting effect preference model to be trained is trained using the historical lighting effect data to obtain the trained user lighting effect preference model.
[0166] In this embodiment, the user lighting effect preference model can be a generative adversarial network (GAN), which includes a generator and a discriminator.
[0167] As an example, the generator can use a 3-layer convolutional neural network, with the input being a random noise vector z (16-dimensional) + a user preference feature vector P (8-dimensional, including normalized color, speed, and curvature preferences), and the output being a light effect trajectory parameter vector.
[0168] The discriminator can use a two-layer convolutional neural network. The input is the lighting effect trajectory parameters (the trajectory adjusted by the real user / the trajectory generated by the generator), and the output is the matching degree between the trajectory and the user's preference, Score (the value range is [0, 1]). The closer the Score is to 1, the more the trajectory matches the user's preference.
[0169] The generator aims to generate trajectory parameters that match user preferences, minimizing the difference between the generated trajectory and the real trajectory. The discriminator aims to accurately distinguish between the real trajectory and the generated trajectory, maximizing the discrimination accuracy.
[0170] The generator's loss function uses mean squared error loss to measure the difference between the generated trajectory and the true trajectory. The formula for mean squared error loss is: ,in, The loss value is α, and the weighting coefficient is α = 0.7. For realistic lighting effects; The discriminator scores the degree of matching of the generated trajectory. Generate results for the model. This represents the mean square error loss.
[0171] The discriminator loss function uses cross-entropy loss, and the formula for cross-entropy loss is: ,in, y is the loss value, y is the label (true trajectory y=1, generated trajectory y=0), and Score is the discriminator's output matching degree.
[0172] In one possible implementation, the above method may further include:
[0173] If collaborative training of device models exists across multiple devices—for example, if the device model can be used to determine user lighting effect preferences and / or positional deviations—one device can be selected as the master device, and the other devices as sub-devices. The master device is the central node, and the sub-devices are the edge nodes.
[0174] For sub-devices: Sub-devices train their own device models based on local data to obtain local model parameters. The local data is determined according to the type of device model. For example, if the device model is a user lighting effect preference model, then the local data includes the user's selected lighting effect color, etc.
[0175] The training objective for sub-devices is to minimize the prediction error of the device model and ensure that the device model is adapted to the characteristics of its own device.
[0176] The sub-device uses the stochastic gradient descent algorithm to perform E rounds of iterative training locally. The device model parameters are updated in each round of iteration, and the local model parameters for the t-th round are obtained after training is completed.
[0177] The sub-device uploads the local model parameters obtained from training to the main device.
[0178] For the master device: The master device receives the local model parameters sent by each sub-device and uses a hash verification method to verify the integrity of the local model parameters. If the verification fails, a retransmission command is sent to the sub-device. After receiving the retransmission command, the sub-device retransmits the local model parameters to the master device.
[0179] The main device verifies the validity of local model parameters, deletes local model parameters that exceed the preset range, and ensures the validity of global model parameters.
[0180] The master device uses a federated averaging algorithm, while the weights w of each sub-device and the local model parameters of each sub-device are calculated using a weighted averaging algorithm to determine the global model parameters. The larger the sample size of a sub-device, the greater its corresponding weight.
[0181] Specifically, the weight calculation formula is as follows: ,in, Let i be the weight value of the i-th sub-device. Let N be the number of valid local samples for the i-th sub-device, and N be the total number of sub-devices. Let N be the total sample size of all N sub-devices, and satisfy the following conditions: (The sum of the weights is 1). This represents the local effective sample size of the k-th sub-device.
[0182] Specifically, the global model parameters are: ,in, These are the global model parameters after aggregation in round t. Let i be the weight of the i-th sub-device. Let N be the local model parameters of the i-th sub-device in round t, and N be the total number of sub-devices.
[0183] The global model parameters are smoothed to obtain the final global model parameters.
[0184] The smoothing formula is:
[0185] in, These are the smoothed global parameters, and β is the smoothing coefficient (e.g., β=0.8). Let be the global model parameters for round t. These are the global model parameters from the previous round (i.e., round t-1), ensuring the stability of the global model parameters.
[0186] The master device sends the final global model parameters to the slave device, and the slave device updates its own stored device model based on the global model parameters.
[0187] Specifically, after receiving the global model parameters, the sub-device uses parameter fusion to obtain the parameters of its own stored device model.
[0188] The parameter fusion formula is: ,in, Here are the updated local model parameters for the i-th sub-device (used for the next round of training), and γ is the update coefficient (e.g., γ=0.7). The global model parameters for the t-th training round are issued by the master device. Let be the local model parameters of the sub-device during the t-th round of training.
[0189] It should be understood that the sequence number of each step in the above embodiments does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.
[0190] Corresponding to the method for determining the lighting trajectory described in the above embodiments, Figure 7 A structural block diagram of the device for determining the lighting trajectory provided in an embodiment of this application is shown. For ease of explanation, only the parts related to the embodiment of this application are shown.
[0191] Reference Figure 7The device 300 may include: a trajectory prediction module 310, a trajectory calculation module 320, a deviation calculation module 330, a deviation optimization module 340, and a position determination module 350.
[0192] The trajectory prediction module 310 is used to determine the predicted trajectory position of the light strip's lighting effect at the current moment based on the audio information of the current audio frame in response to receiving the current audio frame.
[0193] The trajectory calculation module 320 is used to determine the basic trajectory position of the light strip's lighting effect at the current moment based on the basic data of the first light strip, wherein the basic data of the first light strip includes the motion cycle of the lighting effect, the starting position of the light strip's lighting effect, and the ending position of the light strip's lighting effect.
[0194] The deviation calculation module 330 is used to determine the initial position deviation between the predicted trajectory position and the basic trajectory position;
[0195] The deviation optimization module 340 is used to input the initial position deviation into the trained position deviation determination model, and optimize the initial position deviation through the position deviation determination model to obtain the target position deviation;
[0196] The position determination module 350 is used to superimpose the deviation between the basic trajectory position and the target position to obtain the target trajectory position of the light strip's lighting effect, and the target trajectory position serves as the basis for lighting up the LED beads on the light strip.
[0197] It should be noted that the information interaction and execution process between the above-mentioned devices / units are based on the same concept as the method embodiments of this application. For details on their specific functions and technical effects, please refer to the method embodiments section, and they will not be repeated here.
[0198] This application embodiment also provides an audio system, including: a light strip with multiple LED beads; a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the above-mentioned method for determining the light effect trajectory, so that the light strip is lit up according to the target trajectory position.
[0199] This application embodiment also provides an ambient lighting device, including: a light strip mounted on the interior of a passenger vehicle, the light strip having a plurality of LED beads; a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, it implements the above-mentioned method for determining the lighting effect trajectory, so that the light strip is illuminated according to the target trajectory position.
[0200] This application also provides a terminal device, see [link to relevant documentation] Figure 8The terminal device 400 may include: at least one processor 410, a memory 420, and a computer program stored in the memory 420 and executable on the at least one processor 410. When the processor 410 executes the computer program, it implements the steps in any of the above method embodiments, for example... Figure 2 Steps S101 to S105 in the illustrated embodiment. Alternatively, when the processor 410 executes the computer program, it implements the functions of each module / unit in the above-described device embodiments, for example... Figure 7 The functions of the trajectory prediction module 310 to the position determination module 350 are shown.
[0201] For example, a computer program may be divided into one or more modules / units, one or more of which are stored in memory 420 and executed by processor 410 to complete this application. The one or more modules / units may be a series of computer program segments capable of performing a specific function, which are used to describe the execution process of the computer program in terminal device 400.
[0202] Those skilled in the art will understand that Figure 8 This is merely an example of a terminal device and does not constitute a limitation on the terminal device. It may include more or fewer components than shown, or combine certain components, or different components, such as input / output devices, network access devices, buses, etc.
[0203] The processor 410 can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor.
[0204] 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.
[0205] 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, all or part of the processes in the methods of the above embodiments 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 one or more processors, it can implement the steps of the various method embodiments described above.
[0206] Similarly, as a computer program product, when the computer program product is run on a terminal device, it enables the terminal device to implement the steps in the above-described method embodiments.
[0207] The computer program includes computer program code, which may be in the form of source code, object code, executable file, or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording media, USB flash drive, portable hard drive, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signals, telecommunication signals, and software distribution media, etc.
[0208] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application 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 this application, and should all be included within the protection scope of this application.
Claims
1. A method for determining the trajectory of a lighting effect, characterized in that, include: In response to receiving the current audio frame, the predicted trajectory position of the light strip's lighting effect at the current moment is determined based on the audio information of the current audio frame; Based on the basic data of the first light strip, the basic trajectory position of the light strip's lighting effect at the current moment is determined, wherein the basic data of the first light strip includes the movement cycle of the lighting effect, the starting position of the light strip's lighting effect, and the ending position of the light strip's lighting effect. Determine the initial positional deviation between the predicted trajectory position and the base trajectory position; The initial position deviation is input into the trained position deviation determination model, and the initial position deviation is optimized by the position deviation determination model to obtain the target position deviation. The target trajectory position is obtained by superimposing the deviation between the base trajectory position and the target position, and the target trajectory position is used as the basis for illuminating the light strip.
2. The method for determining the lighting effect trajectory as described in claim 1, characterized in that, The step of determining the basic trajectory position of the light strip's lighting effect at the current moment based on the first light strip's basic data includes: By inputting the basic data of the first light strip into the position determination model, the basic trajectory position of the light strip's lighting effect at the current moment is obtained; The location determination model includes: ; ; The x-coordinate of the basic trajectory position, The ordinate of the basic trajectory position. The x-coordinate of the starting position of the lighting effect is [the coordinate of the position of the starting position of the lighting effect]. The vertical coordinate of the starting position of the lighting effect is [value]. Let x be the x-coordinate of the endpoint of the lighting effect. Let t be the ordinate of the endpoint of the lighting effect, T be the motion period of the lighting effect, and t be the current time.
3. The method for determining the lighting effect trajectory as described in claim 1, characterized in that, Before optimizing the initial position deviation to obtain the target position deviation by inputting the initial position deviation into the trained position deviation determination model, the method further includes: Obtain the controller's operating time within the preset time period; The ratio of the working time to the preset time is determined to obtain the computing power utilization rate of the controller; Based on the computing power occupancy rate, the inference mode of the position deviation determination model in the current detection cycle is determined, wherein inference modes corresponding to different computing power occupancy rates are pre-stored, and the inference accuracy of different inference modes is different. Accordingly, the step of inputting the initial position deviation into the trained position deviation determination model, and optimizing the initial position deviation through the position deviation determination model to obtain the target position deviation, includes: The initial position deviation and the inference mode of the current detection cycle are input into the trained position deviation determination model. The initial position deviation is then optimized by the position deviation determination model to obtain the target position deviation.
4. The method for determining the lighting effect trajectory as described in claim 3, characterized in that, The audio information includes rhythm density; The step of inputting the initial position deviation and the inference mode of the current detection cycle into the trained position deviation determination model, and optimizing the initial position deviation through the position deviation determination model to obtain the target position deviation, includes: The rhythm density, the initial position deviation, and the inference mode of the current detection cycle are input into the trained position deviation determination model. The initial position deviation is then optimized by the position deviation determination model to obtain the target position deviation.
5. The method for determining the lighting effect trajectory as described in claim 4, characterized in that, The step of inputting the rhythm density, the initial position deviation, and the inference pattern of the current detection cycle into the trained position deviation determination model, and optimizing the initial position deviation through the position deviation determination model to obtain the target position deviation, includes: If the reasoning pattern determined in the previous detection cycle is different from the reasoning pattern in the current detection cycle, the rhythm density, the initial position deviation, and the reasoning pattern of the previous detection cycle are input into the trained position deviation determination model. The initial position deviation is then optimized by the position deviation determination model to obtain the first candidate position deviation. The rhythm density, the initial position deviation, and the inference mode of the current detection cycle are input into the trained position deviation determination model. The initial position deviation is optimized by the position deviation determination model to obtain the second candidate position deviation. The target position deviation is obtained based on the first candidate position deviation and the second candidate position deviation.
6. The method for determining the lighting effect trajectory as described in any one of claims 1 to 5, characterized in that, The audio information includes the emotion type of the current audio frame and the rhythm density of the current audio frame; The step of determining the predicted trajectory position of the light strip's lighting effect at the current moment based on the audio information of the current audio frame includes: Perform a Fourier transform on the current audio frame to obtain the spectral energy distribution of the current audio frame; Find the number of rhythm point peaks from the said spectral energy distribution; The rhythm density of the current audio frame is determined based on the number of rhythm point peaks. Obtain the emotion type of the current audio frame; Based on the emotion type and the rhythm density, the predicted trajectory position of the light strip's lighting effect at the current moment is determined.
7. The method for determining the lighting effect trajectory as described in claim 6, characterized in that, Determining the predicted trajectory position of the light strip's lighting effect at the current moment based on the emotion type and the rhythm density includes: By inputting the emotion type and the rhythm density into the trained user lighting effect preference model, the predicted trajectory position of the lighting effect of the light strip at the current moment can be obtained. The training process of the user lighting effect preference model includes: Acquire historical lighting effect data, wherein the historical lighting effect data includes lighting effect preference data of users manually adjusting the light strips corresponding to different audio; The historical lighting effect data is used to train the user lighting effect preference model to be trained, resulting in the trained user lighting effect preference model.
8. The method for determining the lighting effect trajectory as described in claim 1, characterized in that, The method further includes: Obtain the historical real lighting effect trajectory corresponding to the historical audio frame and the basic data of the second light strip of the historical audio frame; Based on the second light strip's basic data, determine the historical basic trajectory position of the lighting effect at historical times; Determine the historical positional deviation between the historical actual lighting trajectory and the historical basic trajectory position at the same moment; The historical position deviation is input into the first neural network model and the second neural network model. The second neural network model is trained by knowledge distillation to obtain the trained second neural network model, which is the trained position deviation determination model.
9. A sound system, characterized in that, include: A light strip, wherein the light strip is provided with multiple LED beads; The memory, the processor, and the computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the method for determining the light effect trajectory as described in any one of claims 1 to 8, so that the light strip is illuminated according to the target trajectory position.
10. An ambient lighting device, characterized in that, The ambient lighting device includes: A light strip installed in the interior of a passenger vehicle, the light strip having multiple LED beads; The system includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the computer program, implements the method for determining the light effect trajectory as described in any one of claims 1 to 8, such that the light strip is illuminated according to the target trajectory position.