Vehicle voice game method and device, electronic equipment and storage medium
By setting up a microphone array inside the vehicle and using time difference and phase difference positioning algorithms, combined with ambient lighting displays, the problem of insufficient interactivity and immersion in existing vehicle voice game systems has been solved, providing real-time voice interaction and personalized control, thus enhancing the gaming experience.
Patent Information
- Application Number
- CN202410976254.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-19
- Publication Date
- 2024-11-22
AI Technical Summary
Existing vehicle voice game systems lack voice microphones that are relevant to passenger location, making it impossible to accurately detect the order in which user voice recordings are made, resulting in an unsatisfactory gaming experience and a lack of interactivity and immersion.
By employing a microphone array combined with time difference positioning and phase difference positioning algorithms, voice feedback information is collected through the sound detection device inside the vehicle to determine the target sound zone, and the ambient lighting display is controlled to enhance interactivity and immersion.
It enables real-time voice interaction, enhancing the game's fun and engagement, and improves user immersion through visual feedback from lights, making the driving process more vivid and interesting.
Smart Images

Figure CN118987598A_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of automobile technology, and in particular to a vehicle voice game method, device, electronic device and storage medium. Background Art
[0002] With the continuous advancement of automotive technology, vehicle intelligence is the best way to improve users' vehicle experience.
[0003] In the related art, in order to improve the user's vehicle experience, it is generally achieved by adding a voice game system. However, the voice game system usually relies on smartphones or other portable devices, and players need to operate manually to participate in the game. In addition, these systems usually lack voice microphones related to the passenger position and cannot accurately detect the order of recording the user's voice, resulting in a suboptimal gaming experience. In addition, there is no ambient light display function corresponding to the passengers, which makes the gaming experience lack interactivity and immersion. Summary of the invention
[0004] Embodiments of the present application provide a vehicle voice game method, device, system, electronic device, and computer-readable storage medium.
[0005] In a first aspect, an embodiment of the present application provides a vehicle voice game method, the method comprising:
[0006] In response to the start instruction of the game answering mode, the game voice questions and game voice prompts are broadcasted through the pre-set sound detection device inside the current vehicle;
[0007] Collecting first voice feedback information through the sound detection device, and determining a target sound zone based on the first voice feedback information, wherein the first voice feedback information is first feedback information collected by the sound detection device for the game voice prompt and the game voice problem;
[0008] Control the atmosphere light display corresponding to the target sound zone.
[0009] Optionally, the sound detection device includes a microphone array, and the microphone array is arranged at each seat inside the vehicle. The collecting of the first voice feedback information by the sound detection device and determining the target sound zone based on the first voice feedback information includes:
[0010] Collecting first voice feedback information through the microphone array;
[0011] Determine the time information corresponding to the first voice feedback information by using a time difference positioning algorithm, and determine the first sound source position based on the time information;
[0012] Determine the phase information corresponding to the first voice feedback information by using a phase difference positioning algorithm, and determine the second sound source position based on the phase information;
[0013] A target sound range corresponding to the first voice feedback information is determined based on the first sound source position and the second sound source position.
[0014] Optionally, determining the time information corresponding to the first voice feedback information by using a time difference positioning algorithm, and determining the first sound source position based on the time information includes:
[0015] Acquire time difference information corresponding to the first voice feedback information and each microphone in the microphone array, and distance information between the first voice feedback information and each microphone in the microphone array;
[0016] A first sound source position is determined based on the time difference information and the distance information.
[0017] Optionally, determining phase information corresponding to the first voice feedback information by using a phase difference positioning algorithm, and determining the second sound source position based on the phase information includes:
[0018] Acquire the first voice feedback information and phase difference information corresponding to each microphone in the microphone array, and the distance information between the first voice feedback information and each microphone in the microphone array;
[0019] A second sound source position is determined based on the phase difference information and the distance information.
[0020] Optionally, the controlling of the ambient light display corresponding to the target sound zone includes:
[0021] Determining whether the first voice feedback information satisfies the game answer corresponding to the game voice question;
[0022] If so, the ambient light display corresponding to the target sound zone is controlled.
[0023] Optionally, the determining whether the first voice feedback information satisfies a game answer corresponding to the game voice question includes:
[0024] Converting the first voice feedback information into text information;
[0025] Preprocessing the text information to obtain target text information;
[0026] Performing a similarity comparison between the target text information and the preset text information corresponding to the game answer corresponding to the game voice question to obtain a target similarity;
[0027] If the target similarity is greater than a preset threshold, the first voice feedback information satisfies the game answer corresponding to the game voice question.
[0028] Optionally, the performing a similarity comparison between the target text information and the preset text information corresponding to the game answer corresponding to the game voice question to obtain the target similarity includes:
[0029] The target text information and the preset text information corresponding to the game answer corresponding to the game voice question are respectively converted into a first character string two-dimensional array and a second character string two-dimensional array by a preset edit distance algorithm;
[0030] Performing an edit distance calculation based on the first character string two-dimensional array and the second character string two-dimensional array to obtain an edit distance between the first character string two-dimensional array and the second character string two-dimensional array;
[0031] A target similarity is generated according to the edit distance.
[0032] In a second aspect, an embodiment of the present application provides a vehicle voice game device, the device comprising:
[0033] A sending module, for responding to a start instruction of the game answering mode, and broadcasting the game voice questions and game voice prompts through a pre-set sound detection device inside the current vehicle;
[0034] A voice zone determination module, configured to collect first voice feedback information through the sound detection device, and determine a target voice zone based on the first voice feedback information, wherein the first voice feedback information is first feedback information collected by the sound detection device for the game voice prompt and the game voice problem;
[0035] The control module is used to control the ambient light display corresponding to the target sound zone.
[0036] Optionally, the sound detection device includes a microphone array, and the microphone array is arranged at each seat inside the vehicle, and the sound zone determination module includes:
[0037] A first voice zone determination submodule, used for collecting first voice feedback information through the microphone array;
[0038] A second sound zone determination submodule, configured to determine time information corresponding to the first voice feedback information by using a time difference positioning algorithm, and determine a first sound source position based on the time information;
[0039] a third sound zone determination submodule, configured to determine phase information corresponding to the first voice feedback information by using a phase difference positioning algorithm, and determine a second sound source position based on the phase information;
[0040] The fourth sound zone determination submodule is used to determine the target sound zone corresponding to the first voice feedback information based on the first sound source position and the second sound source position.
[0041] Optionally, the second sound range determination submodule includes:
[0042] A first sound zone determination unit, used to obtain time difference information corresponding to the first voice feedback information and each microphone in the microphone array, and distance information between the first voice feedback information and each microphone in the microphone array;
[0043] The second sound zone determining unit is used to determine the first sound source position based on the time difference information and the distance information.
[0044] Optionally, the third sound range determination submodule includes:
[0045] a third sound zone determination unit, configured to obtain phase difference information corresponding to the first voice feedback information and each microphone in the microphone array, and distance information between the first voice feedback information and each microphone in the microphone array;
[0046] The fourth sound zone determination unit is used to determine the second sound source position based on the phase difference information and the distance information.
[0047] Optionally, the control module includes:
[0048] A first control submodule, configured to determine whether the first voice feedback information satisfies the game answer corresponding to the game voice question;
[0049] The second control submodule is used to control the display of the atmosphere light corresponding to the target sound zone.
[0050] Optionally, the first control submodule includes:
[0051] A first control unit, configured to convert the first voice feedback information into text information;
[0052] A second control unit, used for preprocessing the text information to obtain target text information;
[0053] A third control unit is used to compare the target text information with the preset text information corresponding to the game answer corresponding to the game voice question to obtain a target similarity;
[0054] The fourth control unit is used to determine that if the target similarity is greater than a preset threshold, the first voice feedback information satisfies the game answer corresponding to the game voice question.
[0055] Optionally, the third control unit includes:
[0056] A first control subunit is used to convert the target text information and the preset text information corresponding to the game answer corresponding to the game voice question into a first character string two-dimensional array and a second character string two-dimensional array respectively through a preset edit distance algorithm;
[0057] A second control subunit is configured to perform an edit distance calculation based on the first character string two-dimensional array and the second character string two-dimensional array to obtain an edit distance between the first character string two-dimensional array and the second character string two-dimensional array;
[0058] The third control subunit is used to generate target similarity according to the edit distance.
[0059] In a third aspect, an embodiment of the present application further provides an electronic device, comprising: a processor; and a memory for storing instructions executable by the processor, wherein the processor is configured to execute the instructions to implement any of the vehicle voice game methods described above.
[0060] In a fourth aspect, an embodiment of the present application further provides a computer-readable storage medium, which, when instructions in the computer-readable storage medium are executed by a processor of an electronic device, enables the electronic device to execute any of the vehicle voice game methods described above.
[0061] In a fifth aspect, an embodiment of the present application further provides a vehicle, comprising the vehicle voice game device as described above.
[0062] In an embodiment of the present application, in response to the start instruction of the game answering mode, the game voice questions and game voice prompts are broadcasted through the pre-set sound detection device inside the current vehicle; the first voice feedback information is collected through the sound detection device, and the target sound zone is determined based on the first voice feedback information, wherein the first voice feedback information is the first feedback information collected by the sound detection device for the game voice prompt and the game voice question; and the display of the atmosphere light corresponding to the target sound zone is controlled. The present application can achieve sound zone locking by setting a voice microphone related to the position and then processing the collected first voice feedback information. By integrating the sound detection device inside the vehicle, it not only provides an instant voice interactive experience, but also personalizes the control of the atmosphere light by intelligently identifying the user's voice feedback, thereby enhancing the fun and participation of the game, combining entertainment with the vehicle environment, enriching the driving experience, and enhancing the user's immersion through the visual feedback of the light, making the driving process more vivid and interesting.
[0063] The above description is only an overview of the technical solution of the present application. In order to more clearly understand the technical means of the present application, it can be implemented in accordance with the contents of the specification. In order to make the above and other purposes, features and advantages of the present application more obvious and easy to understand, the specific implementation methods of the present application are listed below. BRIEF DESCRIPTION OF THE DRAWINGS
[0064] Various other advantages and benefits will become apparent to those of ordinary skill in the art by reading the detailed description of the preferred embodiments below. The accompanying drawings are only for the purpose of illustrating the preferred embodiments and are not to be considered as limiting the present application. Also, the same reference symbols are used throughout the accompanying drawings to represent the same components. In the accompanying drawings:
[0065] Figure 1 It is a flowchart of the steps of a vehicle voice game method provided by an embodiment of the present application;
[0066] Figure 2 yes Figure 1 A flowchart of step 102 in a flowchart of a method for vehicle voice gaming;
[0067] Figure 3 is a flowchart of another vehicle voice game method provided by an embodiment of the present application;
[0068] Figure 4 yes Figure 3 A flowchart of step 303 in a flowchart of a method for vehicle voice gaming;
[0069] Figure 5 is a device block diagram of a vehicle voice game device provided by an embodiment of the present application;
[0070] Figure 6 is a structural diagram of an electronic device provided in an embodiment of the present application;
[0071] Figure 7 is a schematic diagram of a pre-set sound detection device in an exemplary vehicle voice game method provided in an embodiment of the present application;
[0072] Figure 8 It is a schematic diagram of vehicle space coordinates in an exemplary vehicle voice game method provided in an embodiment of the present application. DETAILED DESCRIPTION
[0073] The exemplary embodiments of the present application will be described in more detail below with reference to the accompanying drawings. Although the exemplary embodiments of the present application are shown in the accompanying drawings, it should be understood that the present application can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided in order to enable a more thorough understanding of the present application and to fully convey the scope of the present application to those skilled in the art.
[0074] Figure 1 is a flowchart of the steps of a vehicle voice game method provided by an embodiment of the present application, such as Figure 1 As shown, the method may include:
[0075] Step 101, in response to a start instruction of the game answering mode, the game voice question and the game voice prompt are broadcasted through a preset sound detection device in the current vehicle;
[0076] It should be noted that in the embodiments of the present application, reference is made to Figure 7 The pre-set sound detection device inside the current vehicle can be a microphone array. Specifically, there is a microphone above each position in the car, for a total of four microphones. It can then accurately capture voice according to the position of the passengers, and output game voice questions and game voice prompts, which can ensure that the system can distinguish the speeches of different players and correctly process their inputs.
[0077] Among them, the game voice questions can be game voice questions pre-set in the question bank in response to the user's instruction to start the game quick answer mode, for example, voice questions such as "What color is the sky?"; the game voice prompts can be a countdown of 3, 2, 1 or other forms of prompting the start of the game, and this application does not make any specific limitations on this.
[0078] Specifically, when the user switches to the game answering mode, the vehicle's cloud can generate questions (for example: the founding time of New China) and standard answers (1949), as shown below. The vehicle's cloud sends a json type string to the vehicle terminal. After receiving it, the vehicle terminal can call the TTS module to convert the text in subText into voice and broadcast it in the car. At the same time, shareperfence is used to temporarily store standard_answer in the car computer as the standard answer for subsequent comparison.
[0079]
[0080]
[0081] Step 102, collecting first voice feedback information through the sound detection device, and determining a target sound range based on the first voice feedback information, wherein the first voice feedback information is first feedback information collected by the sound detection device for the game voice prompt and the game voice problem;
[0082] It should be noted that in the embodiment of the present application, after the sound detection device sends the game voice question and the game voice prompt to the user, the users in the car can answer quickly. At this time, there are multiple sounds. Therefore, the first voice feedback information is the first feedback information collected by the sound detection device for the game voice prompt and the game voice question, that is, the first voice feedback information collected by the sound detection device is the voice information feedback of the user who first answers the game voice question according to the game voice prompt.
[0083] Furthermore, if Figure 2 As shown, the sound detection device includes a microphone array, and the microphone array is arranged at each seat inside the vehicle. Step 102 includes the following steps:
[0084] Step 201, collecting first voice feedback information through the microphone array;
[0085] Step 202, determining time information corresponding to the first voice feedback information by using a time difference positioning algorithm, and determining a first sound source position based on the time information;
[0086] Further, step 202 includes: obtaining the time difference information corresponding to the first voice feedback information and each microphone in the microphone array, and the distance information between the first voice feedback information and each microphone in the microphone array; and determining the first sound source position based on the time difference information and the distance information.
[0087] Step 203, determining phase information corresponding to the first voice feedback information through a phase difference positioning algorithm, and determining a second sound source position based on the phase information;
[0088] Further, step 203 includes: obtaining phase difference information corresponding to the first voice feedback information and each microphone in the microphone array, and distance information between the first voice feedback information and each microphone in the microphone array; and determining the position of the second sound source based on the phase difference information and the distance information.
[0089] Step 204: determine a target sound range corresponding to the first voice feedback information based on the first sound source position and the second sound source position.
[0090] It should be noted that, for the above steps 201-204, the present application adopts a voice processing method that combines time difference positioning (Time Difference of Arrival, TDOA) and phase difference positioning (Phase Difference of Arrival, PDOA) to accurately detect the voice recording order of different players, lock the sound zone by analyzing the first voice feedback information, and perform game operations accordingly.
[0091] Specifically, refer to Figure 8 , assuming that the spatial coordinates of the sound source position S are (x, y, z), the spatial coordinates of the driver's seat are (x1, y1, z1), the spatial coordinates of the co-driver's seat are (x2, y2, z2), the spatial coordinates of the left rear seat are (x3, y3, z3), and the spatial coordinates of the right rear seat are (x4, y4, z4). Because the four microphones can be regarded as being on the same plane, it can be assumed here that the spatial coordinates of the driver's seat are (x1, y1, z1) which is the coordinate origin.
[0092] Therefore, the time difference localization algorithm is first used to determine the position of the first sound source. Specifically, first, a set of equations constructed by the distance from the sound source to each microphone can be obtained, namely, the following formulas 1-4:
[0093] d1=c*t1(Formula 1)
[0094] d2=c*t2(Formula 2)
[0095] d3=c*t3(Formula 3)
[0096] d4=c*t4(Formula 4)
[0097] Secondly, the time difference equation system can be constructed by the following formula 2:
[0098]
[0099] Finally, by solving the equation group corresponding to the above formulas 1-10, the position of a sound source in the three-dimensional space can be obtained, that is, the specific position in the three-dimensional space corresponding to the first voice feedback information. The specific formula is as follows: Formula 3:
[0100]
[0101] Among them, in the above formulas 1-13, c is the propagation speed of sound waves in the air, t1, t2, t3, t4 are the times when the sound waves reach the four microphones respectively, and (x, y, z) is the specific position in three-dimensional space corresponding to the voice feedback information.
[0102] Secondly, the phase difference positioning algorithm is used to determine the position of the second sound source. Specifically, based on the above formulas 1-4, the phase difference equation group formulas 14-19 are constructed:
[0103]
[0104] By solving the above equations, the position of the sound source in the three-dimensional space can be obtained, that is, the specific position in the three-dimensional space corresponding to the first voice feedback information.
[0105]
[0106] It should be noted that in the embodiment of the present application, the phase information of the sound waves received by each microphone is analyzed. The phase difference of the sound waves arriving at each microphone is calculated. The phase difference and the propagation speed of the sound wave are used to calculate the position of the sound source. Phase is a basic property of a wave, which describes the vibration or fluctuation state of the wave. In acoustics, phase refers to the time difference of sound waves arriving at different locations. Phase difference refers to the difference between the phases of two sound waves, which is an important parameter for determining the position of the sound source. Specifically, when a sound wave is emitted from a sound source and propagates to multiple receivers, the time it arrives at each receiver will be different due to the different propagation speeds and propagation paths of the sound waves. This time difference is called the time difference (Time Difference of Arrival, TDOA), while the phase difference (Phase Difference of Arrival, PDOA) describes the phase state of the sound wave when it arrives at different receivers.
[0107] It should be noted that combining TDOA and PDOA can improve the accuracy of positioning. The following steps can be used to determine the location of the sound source: Measure the time difference and phase difference: record the timestamp and phase information of each microphone receiving the sound wave, and calculate the time difference and phase difference of the sound wave reaching each microphone. Use the time difference and the speed of sound wave propagation to determine the approximate location of the sound source, use the phase difference and the speed of sound wave propagation to provide additional positioning information, and combine the time difference and phase difference information to determine the precise location of the sound source. Once the location of the sound source is determined, the system locks the target sound zone corresponding to the location, and the microphone in the target sound zone continues to record. At the same time, the microphones in the other three sound zones will immediately turn off the microphones and stop recording.
[0108] Then, within the locked target sound area, the system further processes the sound event, such as recording, audio processing, etc.
[0109] It should be noted that, in the embodiment of the present application, the target sound zone is an area divided into four equal parts based on the position in the vehicle and the arrangement position of the microphone, which can be preset in advance.
[0110] Step 103, controlling the ambient light display corresponding to the target sound zone.
[0111] It should be noted that in the embodiment of the present application, the ambient light inside the vehicle body is used to indicate the position of each passenger. When a player speaks or it is their turn to participate in the game, after locking the corresponding target sound zone, the identity of the current speaker or participant can be prompted to other players by controlling the display status and color of the light, thereby enhancing the interactivity and immersion of the game.
[0112] In an embodiment of the present application, in response to the start instruction of the game answering mode, the game voice questions and game voice prompts are broadcasted through the pre-set sound detection device inside the current vehicle; the first voice feedback information is collected through the sound detection device, and the target sound zone is determined based on the first voice feedback information, wherein the first voice feedback information is the first feedback information collected by the sound detection device for the game voice prompt and the game voice question; and the display of the atmosphere light corresponding to the target sound zone is controlled. The present application can achieve sound zone locking by setting a voice microphone related to the position and then processing the collected first voice feedback information. By integrating the sound detection device inside the vehicle, it not only provides an instant voice interactive experience, but also personalizes the control of the atmosphere light by intelligently identifying the user's voice feedback, thereby enhancing the fun and participation of the game, combining entertainment with the vehicle environment, enriching the driving experience, and enhancing the user's immersion through the visual feedback of the light, making the driving process more vivid and interesting.
[0113] In addition, this application uses a new algorithm voice processing that combines time difference of arrival (TDOA) and phase difference of arrival (PDOA) to accurately detect the order of voice recordings of different players. By analyzing the sound characteristics and timestamps of the voice, the system can determine the order of each player's speech, then lock the voice zone, and perform game operations accordingly.
[0114] Figure 3 is a flowchart of the steps of a vehicle voice game method provided by an embodiment of the present application, such as Figure 3 As shown, the method may include:
[0115] Step 301, in response to the start instruction of the game answering mode, the game voice question and the game voice prompt are broadcasted through the preset sound detection device in the current vehicle;
[0116] Step 302, collecting first voice feedback information through the sound detection device, and determining a target sound range based on the first voice feedback information, wherein the first voice feedback information is first feedback information collected by the sound detection device for the game voice prompt and the game voice problem;
[0117] Step 303, determining whether the first voice feedback information satisfies the game answer corresponding to the game voice question;
[0118] Furthermore, if Figure 4 As shown, step 303 includes the following steps 401-404, that is, the determination of whether the first voice feedback information satisfies the game answer corresponding to the game voice question includes:
[0119] Step 401, converting the first voice feedback information into text information;
[0120] Step 402, preprocessing the text information to obtain target text information;
[0121] It should be noted that in the embodiment of the present application, in the above steps 401-402, after determining the target sound zone, the first voice feedback information needs to be processed, that is, the first voice feedback information needs to be converted into text information, and after being converted into text information, the text information will be pre-processed.
[0122] Specifically, after being converted into text by the ASR module, the text needs to be processed to ensure that its comparison with the standard answer is not affected by special characters such as punctuation marks.
[0123] To do this, you can use the regular expression result.replace("[\\p{P}\\p{Space}¥|<>$^=~]+".toRegex(),"") to replace special characters, punctuation marks, and spaces with empty strings. This ensures the purity of the text and makes the comparison more accurate and fair.
[0124] Furthermore, because speech recognition may lead to some ambiguity or errors, such as homophones, the text needs to be further standardized. One way is to convert the text into pinyin, which can eliminate the differences in Chinese characters and make the comparison more consistent and accurate. At the same time, converting Chinese characters to Arabic numerals can ensure a unified numerical expression and avoid comparison bias caused by different numerical formats.
[0125] Step 403, performing a similarity comparison between the target text information and the preset text information corresponding to the game answer corresponding to the game voice question to obtain a target similarity;
[0126] It should be noted that in the embodiment of the present application, when comparing the passenger's answer with the standard answer, the matchNlp(result:String?) function can be used for similarity matching, and the decideScore(result:String) function can be used for scoring.
[0127] Furthermore, in this process, punctuation marks are not included in the scoring to ensure the accuracy and fairness of the comparison.
[0128] Further, step 403, that is, performing a similarity comparison between the target text information and the preset text information corresponding to the game answer corresponding to the game voice question, and obtaining the target similarity includes:
[0129] The target text information and the preset text information corresponding to the game answer corresponding to the game voice question are respectively converted into a first character string two-dimensional array and a second character string two-dimensional array by a preset edit distance algorithm;
[0130] Performing an edit distance calculation based on the first character string two-dimensional array and the second character string two-dimensional array to obtain an edit distance between the first character string two-dimensional array and the second character string two-dimensional array;
[0131] A target similarity is generated according to the edit distance.
[0132] It should be noted that because there are certain homophones, front and back nasal sounds, flat tongue sounds and curled tongue sounds, and considering the possible pinyin standardized answers, it is necessary to compare the pinyin forms of the answers to ensure that even when there is ambiguity in speech recognition, the comparison can still be carried out accurately.
[0133] For example, in the example, the standard answer returned by the cloud is 1949. After processing by the voice recognition module, the text on the screen may be 1949. In order to deal with this situation, the measures taken by this application are to convert Chinese characters into pinyin, and at the same time convert the Chinese numerals one, two, three, and four in the text into Arabic numerals 1, 2, 3, and 4. Among them, in Android, a third-party library can be used to convert Chinese characters into pinyin, such as pinyin4j. In this example, the standard answer is 1949. First of all, 1949 is composed of Chinese characters and Arabic numerals, which can be split into 1949nian, and then compared with the answer given by the passenger for scoring.
[0134] If the passenger says "It seems to be 1949", "It is 1949", "I think it was 1949", etc., in this case, the game system will first check whether the keyword 1949 is contained. If not, it will be directly judged as an error. If it is contained, the algorithm will be used to score.
[0135] Among them, the algorithm scoring part is based on a preset edit distance algorithm.
[0136] Specifically, the Levenshtein distance between two strings a and b is denoted as lev a,b (|a|, |b|). In the following formula 23, |a| and |b| respectively represent the lengths of strings a and b. Indicates that when a i ≠b j the value is 1, otherwise the value is 0. In this way, lev a,b (i, j) is the distance between the first i characters of a and the first j characters of b.
[0137]
[0138] For example, in this case, "1949 year" is converted to pinyin "1949nianba", and compared with the standard answer "1949nian" using the algorithm. The two strings are String A = "1949nianba" and String B = "1949nian". An two-dimensional array is created where i represents the index of B [row] and j represents the index of A [column]. When i or j is equal to 0, it means both are empty strings. lev(i, j) represents the edit distance required for the strings to become the same up to the specified coordinate point. Therefore, as shown in Table 1 below, the value required here is the value at the lower right corner (the final edit distance).
[0139] If i = 0 or j = 0, lev(i, j) = j or i. Here, 0 represents the empty string at the front. To make the empty string at this position the same, no operation is required, so lev(i, j) = 0, which is the following situation.
[0140] Table 1 Schematic table of an exemplary preset edit distance algorithm
[0141]
[0142]
[0143] If i and j>=1, then lev(i,j)=min{lev(i-1,j)+1,lev(i,j-1)+1,lev(i-1,j-1)+h}, if B[i]=A[j], then h=0, otherwise h=1; the min function is used to take the minimum of the three edit distances. Therefore, first derive the value of the position i=1,j=1, lev(1,1)=min(lev(0,1)+1,lev(1,0)+1,lev(0,0)+h); since B[i]=A[j] is equal at this position, h=0, then lev(1,1)=min(1,1,0)=0; that is, the edit distance of "01" edited to "01" is 0.
[0144] Table 2 Schematic diagram of an exemplary preset edit distance algorithm
[0145] 0 1 9 4 9 n i a n b a 0 0 1 2 3 4 5 6 7 8 9 10 1 1 0 1 2 3 4 5 6 7 8 9 9 2 1 0 1 2 3 4 5 6 7 8 4 3 2 1 0 1 2 3 4 5 6 7 9 4 3 2 1 0 1 2 3 4 5 6 n 5 4 3 2 1 0 1 2 3 4 5 i 6 5 4 3 2 1 0 1 2 3 4 a 7 6 5 4 3 2 1 0 1 2 3 n 8 7 6 5 4 3 2 1 0 1 2
[0146] From this we can conclude that the edit distance between "1949nian" and "1949nianba" is 2, so the similarity between the two texts is (1-(2 / max(length of the "1949nian" string, length of the "1949nianba" string)), (1-(2 / 10))=0.80, so the similarity is 80%.
[0147] Through the above measures, it can be ensured that after the countdown, the comparison between the passenger's answer and the standard answer is accurate and fair, thus providing a reliable basis for the evaluation results.
[0148] Step 404: If the target similarity is greater than a preset threshold, the first voice feedback information satisfies the game answer corresponding to the game voice question.
[0149] It should be noted that if the score of passenger A's answer is higher than the preset threshold after comparison with the standard answer, for example, the score is higher than 80%, it can be judged as the correct answer. If the score is lower than 80%, it is judged as an incorrect answer.
[0150] Step 304: If yes, control the ambient light display corresponding to the target sound zone.
[0151] It should be noted that in the embodiment of the present application, after the correct answer is determined, the atmosphere light of the passenger's position will light up. If it is determined to be an incorrect answer, the sound zone lock will also be released, and the passenger can choose whether to continue the game.
[0152] The present application sets a voice microphone related to the position and can achieve sound zone locking by processing the collected first voice feedback information. By integrating the sound detection device inside the vehicle, it not only provides an instant voice interaction experience, but also personalizes the control of the atmosphere light through intelligent recognition of the user's voice feedback, thereby enhancing the fun and sense of participation of the game, combining entertainment with the vehicle environment, enriching the driving experience, and enhancing the user's sense of immersion through the visual feedback of the light, making the driving process more vivid and interesting.
[0153] In addition, the embodiment of the present application can ensure that after the countdown ends, the comparison between the passenger's answer and the standard answer is accurate and fair through the preset edit distance algorithm, thereby providing a reliable basis for the evaluation result.
[0154] Corresponding to the method provided in the vehicle voice game method embodiment of the present application, see Figure 5 The present application also provides a device block diagram of a vehicle voice game device. In this embodiment, the device includes:
[0155] The sending module 501 is used to respond to the start instruction of the game answering mode and broadcast the game voice question and the game voice prompt through the preset sound detection device in the current vehicle;
[0156] A voice zone determination module 502 is used to collect first voice feedback information through the sound detection device, and determine a target voice zone based on the first voice feedback information, wherein the first voice feedback information is the first feedback information collected by the sound detection device for the game voice prompt and the game voice problem;
[0157] The control module 503 is used to control the display of the ambience light corresponding to the target sound zone.
[0158] Optionally, the sound detection device includes a microphone array, and the microphone array is arranged at each seat inside the vehicle, and the sound zone determination module includes:
[0159] A first voice zone determination submodule, configured to collect first voice feedback information through the microphone array;
[0160] A second sound zone determination submodule, configured to determine time information corresponding to the first voice feedback information by using a time difference positioning algorithm, and determine a first sound source position based on the time information;
[0161] a third sound zone determination submodule, configured to determine phase information corresponding to the first voice feedback information by using a phase difference positioning algorithm, and determine a second sound source position based on the phase information;
[0162] The fourth sound zone determination submodule is used to determine the target sound zone corresponding to the first voice feedback information based on the first sound source position and the second sound source position.
[0163] Optionally, the second sound range determination submodule includes:
[0164] A first sound zone determination unit, used to obtain time difference information corresponding to the first voice feedback information and each microphone in the microphone array, and distance information between the first voice feedback information and each microphone in the microphone array;
[0165] The second sound zone determining unit is used to determine the first sound source position based on the time difference information and the distance information.
[0166] Optionally, the third sound range determination submodule includes:
[0167] a third sound zone determination unit, configured to obtain phase difference information corresponding to the first voice feedback information and each microphone in the microphone array, and distance information between the first voice feedback information and each microphone in the microphone array;
[0168] The fourth sound zone determination unit is used to determine the second sound source position based on the phase difference information and the distance information.
[0169] Optionally, the control module includes:
[0170] A first control submodule, configured to determine whether the first voice feedback information satisfies the game answer corresponding to the game voice question;
[0171] The second control submodule is used to control the display of the atmosphere light corresponding to the target sound zone.
[0172] Optionally, the first control submodule includes:
[0173] A first control unit, configured to convert the first voice feedback information into text information;
[0174] A second control unit, used for preprocessing the text information to obtain target text information;
[0175] A third control unit is used to compare the target text information with the preset text information corresponding to the game answer corresponding to the game voice question to obtain a target similarity;
[0176] The fourth control unit is used to determine that if the target similarity is greater than a preset threshold, the first voice feedback information satisfies the game answer corresponding to the game voice question.
[0177] Optionally, the third control unit includes:
[0178] A first control subunit is used to convert the target text information and the preset text information corresponding to the game answer corresponding to the game voice question into a first character string two-dimensional array and a second character string two-dimensional array respectively through a preset edit distance algorithm;
[0179] A second control subunit is configured to perform an edit distance calculation based on the first character string two-dimensional array and the second character string two-dimensional array to obtain an edit distance between the first character string two-dimensional array and the second character string two-dimensional array;
[0180] The third control subunit is used to generate target similarity according to the edit distance.
[0181] In summary, the embodiment of the present application provides a vehicle voice game device, which responds to the start instruction of the game answer mode, broadcasts the game voice questions and game voice prompts through the pre-set sound detection device inside the current vehicle; collects the first voice feedback information through the sound detection device, and determines the target sound zone based on the first voice feedback information, wherein the first voice feedback information is the first feedback information collected by the sound detection device for the game voice prompt and the game voice question; and controls the display of the atmosphere light corresponding to the target sound zone. The present application can achieve sound zone locking by setting a voice microphone related to the position and then processing the collected first voice feedback information. By integrating the sound detection device inside the vehicle, it not only provides an instant voice interaction experience, but also personalizes the control of the atmosphere light by intelligently identifying the user's voice feedback, thereby enhancing the fun and participation of the game, and combining entertainment with the vehicle environment, which not only enriches the driving experience, but also enhances the user's immersion through the visual feedback of the light, making the driving process more vivid and interesting.
[0182] Figure 6 This is a structural diagram of an electronic device M00 provided in an embodiment of the present application. In the figure, the electronic device M00 includes a processor M01 and a memory M02. The memory M02 stores programs or instructions that can be run on the processor M01. When the program or instructions are executed by the processor M01, the various steps of the above-mentioned vehicle voice game method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, they are not repeated here.
[0183] In an embodiment of the present application, the memory M02 can be used to store software programs and various data. The memory M02 may mainly include a first storage area for storing programs or instructions and a second storage area for storing data, wherein the first storage area may store an operating system, an application program or instructions required for at least one function (such as a sound playback function, an image playback function, etc.), etc. In addition, the memory M02 may include a volatile memory or a non-volatile memory, or the memory x09 may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), a static random access memory (SRAM), a dynamic random access memory (DRAM), a synchronous dynamic random access memory (SDRAM), a double data rate synchronous dynamic random access memory (DDRSDRAM), an enhanced synchronous dynamic random access memory (ESDRAM), a synchronous link dynamic random access memory (SLDRAM) and a direct memory bus random access memory (DRRAM). The memory M02 in the embodiment of the present application includes but is not limited to these and any other suitable types of memories.
[0184] The processor M01 may include one or more processing units; optionally, the processor M01 integrates an application processor and a modem processor, wherein the application processor mainly processes operations related to an operating system, a user interface, and application programs, and the modem processor mainly processes wireless communication signals, such as a baseband processor. It is understandable that the modem processor may not be integrated into the processor M01.
[0185] An embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, each process of the above-mentioned vehicle voice game method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.
[0186] The processor is the processor in the electronic device described in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory ROM, a random access memory RAM, a magnetic disk or an optical disk.
[0187] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned vehicle voice game method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0188] It should be understood that the chip involved in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.
[0189] An embodiment of the present application provides a computer program product, which is stored in a storage medium. The program product is executed by at least one processor to implement the various processes of the above-mentioned vehicle voice game method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.
[0190] It should be noted that, in this article, the terms "comprise", "include" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise one..." do not exclude the presence of other identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in reverse order according to the functions involved, for example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.
[0191] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the relevant technology, can be embodied in the form of a computer software product, which is stored in a storage medium (such as ROM / RAM, a disk, or an optical disk), and includes a number of instructions for a terminal (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present application.
[0192] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.
Claims
1. A vehicle voice game method, characterized in that: The method comprises: In response to the start instruction of the game answering mode, the game voice questions and game voice prompts are broadcasted through the pre-set sound detection device inside the current vehicle; Collecting first voice feedback information through the sound detection device, and determining a target sound zone based on the first voice feedback information, wherein the first voice feedback information is first feedback information collected by the sound detection device for the game voice prompt and the game voice problem; Control the atmosphere light display corresponding to the target sound zone.
2. The method according to claim 1, characterized in that The sound detection device includes a microphone array, and the microphone array is arranged at each seat in the vehicle. The first voice feedback information is collected by the sound detection device, and the target sound zone is determined based on the first voice feedback information. Collecting first voice feedback information through the microphone array; Determine the time information corresponding to the first voice feedback information by using a time difference positioning algorithm, and determine the first sound source position based on the time information; Determine the phase information corresponding to the first voice feedback information by using a phase difference positioning algorithm, and determine the second sound source position based on the phase information; A target sound range corresponding to the first voice feedback information is determined based on the first sound source position and the second sound source position.
3. The method according to claim 2, characterized in that The determining the time information corresponding to the first voice feedback information by using a time difference positioning algorithm, and determining the first sound source position based on the time information includes: Acquire time difference information corresponding to the first voice feedback information and each microphone in the microphone array, and distance information between the first voice feedback information and each microphone in the microphone array; A first sound source position is determined based on the time difference information and the distance information.
4. The method according to claim 2, characterized in that: The determining the phase information corresponding to the first voice feedback information by using a phase difference positioning algorithm, and determining the second sound source position based on the phase information includes: Acquire the first voice feedback information and phase difference information corresponding to each microphone in the microphone array, and the distance information between the first voice feedback information and each microphone in the microphone array; A second sound source position is determined based on the phase difference information and the distance information.
5. The method according to claim 1, characterized in that The control of the ambient light display corresponding to the target sound zone includes: Determining whether the first voice feedback information satisfies the game answer corresponding to the game voice question; If so, the ambient light display corresponding to the target sound zone is controlled.
6. The method according to claim 5, characterized in that The determining whether the first voice feedback information satisfies the game answer corresponding to the game voice question includes: Converting the first voice feedback information into text information; Preprocessing the text information to obtain target text information; Performing a similarity comparison between the target text information and the preset text information corresponding to the game answer corresponding to the game voice question to obtain a target similarity; If the target similarity is greater than a preset threshold, the first voice feedback information satisfies the game answer corresponding to the game voice question.
7. The method according to claim 6, characterized in that The similarity comparison between the target text information and the preset text information corresponding to the game answer corresponding to the game voice question to obtain the target similarity includes: The target text information and the preset text information corresponding to the game answer corresponding to the game voice question are respectively converted into a first character string two-dimensional array and a second character string two-dimensional array by a preset edit distance algorithm; Performing an edit distance calculation based on the first character string two-dimensional array and the second character string two-dimensional array to obtain an edit distance between the first character string two-dimensional array and the second character string two-dimensional array; A target similarity is generated according to the edit distance.
8. A vehicle voice game device, characterized in that: The device comprises: A sending module, for responding to a start instruction of the game answering mode, and broadcasting the game voice questions and game voice prompts through a pre-set sound detection device inside the current vehicle; A voice zone determination module, configured to collect first voice feedback information through the sound detection device, and determine a target voice zone based on the first voice feedback information, wherein the first voice feedback information is first feedback information collected by the sound detection device for the game voice prompt and the game voice problem; The control module is used to control the ambient light display corresponding to the target sound zone.
9. An electronic device, characterized in that: include: processor; a memory for storing instructions executable by the processor; Wherein, the processor is configured to execute the instructions to implement the vehicle voice game method as described in any one of claims 1 to 7.
10. A storage medium, characterized in that: When the instructions in the storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the vehicle voice game method as claimed in any one of claims 1 to 7.
