Data processing method, device, electronic device and computer storage medium

By grouping the user data of multiple terminals, the problem of precise face-to-face matching of users is solved, the fun of the event is increased, and offline payment methods are promoted.

CN114187025BActive Publication Date: 2025-04-01ALIPAY (HANGZHOU) INFORMATION TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111289649.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-11-02
Publication Date
2025-04-01
Estimated Expiration
2041-11-02

AI Technical Summary

Technical Problem

The prior art is difficult to achieve precise face-to-face matching between users, promote offline payment methods, and the user's participation in activities is not fun.

Method used

By acquiring user data sent by multiple terminals, packet matching is performed on the terminal based on these data, ensuring that the distance between at least two terminals in each packet does not exceed the preset threshold value, and the matching results are consistent.

Benefits of technology

It achieves precise face-to-face matching of users, increases the fun of users participating in activities, promotes users to drive people around them to participate in activities, and promotes offline payment methods.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114187025B_ABST
    Figure CN114187025B_ABST
Patent Text Reader

Abstract

The embodiments of this specification disclose a data processing method, device, electronic device and computer storage medium. The method includes: obtaining user data sent by multiple terminals, performing group matching according to the user data sent by the multiple terminals, and sending the group matching results to the corresponding terminals, wherein each group includes at least two terminals, the distance between the terminals in each group does not exceed a preset threshold, and the matching results of at least two terminals in each group are consistent.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of information technology, and in particular to a data processing method, device, electronic device and computer storage medium. Background Art

[0002] With the development of mobile communication technology, online shopping has become the mainstream shopping method in people's lives, which has brought great convenience to people's lives. In order to achieve promotional purposes (such as increasing sales, increasing page views, etc.), major merchants often hold some activities to attract customers. Major merchants usually use methods with strong user participation such as shake to attract more users to participate, and match the participating users. After the match is successful, rights and interests are issued to encourage users to consume. Summary of the invention

[0003] The embodiments of this specification provide a data processing method, device, electronic device and computer storage medium, which can achieve accurate face-to-face matching of users, encourage users to bring people around them to participate in activities, distribute benefits after successful matching, and promote offline payment methods.

[0004] In a first aspect, an embodiment of this specification provides a data processing method, including:

[0005] Acquire user data sent by multiple terminals; wherein the user data includes a user identifier corresponding to the terminal and user identifiers of other terminals within a Bluetooth search range of the terminal;

[0006] Grouping and matching the multiple terminals based on the user data sent by the multiple terminals; wherein each group includes at least two terminals, the distance between the at least two terminals does not exceed a preset threshold, and the matching results of the at least two terminals are consistent;

[0007] The above group matching results are sent to the corresponding terminal.

[0008] In a possible implementation, the user data further includes geographic location information and a timestamp corresponding to the terminal; the timestamp is the time when the terminal sends the user data.

[0009] In a possible implementation manner, the grouping and matching the multiple terminals based on the user data sent by the multiple terminals includes:

[0010] Based on the user data sent by the above-mentioned multiple terminals, determine the session information corresponding to each of the above-mentioned terminals;

[0011] Multiple terminals with the same session information are grouped and matched.

[0012] In a possible implementation, determining the session information corresponding to each of the terminals based on the user data sent by the multiple terminals includes:

[0013] Determine whether there is a first target session based on the timestamp and the geographic location information of each terminal, where the time range covered by the first target session includes the timestamp;

[0014] If the first target session exists, determining the first target session to be the session corresponding to the terminal;

[0015] If the first target session does not exist, determining whether a second target session exists based on the timestamp and the geographic location information, wherein the start time of the second target session is later than the start time of the first target session;

[0016] If the second target session exists, determining the second target session to be the session corresponding to the terminal;

[0017] If the second target session does not exist, a target session is generated based on the timestamp and the geographic location information, and the target session is determined to be the session corresponding to the terminal; the earliest time in the time range covered by the target session is not later than the time corresponding to the timestamp;

[0018] Among them, the length of the time range covered by the first target session, the length of the time range covered by the second target session, and the length of the time range covered by the target session are equal.

[0019] In a possible implementation, the user data further includes Bluetooth signal strengths of other terminals within the Bluetooth search range of the terminal;

[0020] Before grouping and matching the multiple terminals based on the user data sent by the multiple terminals, the method further includes:

[0021] sorting the user data according to the Bluetooth signal strength;

[0022] The grouping and matching of the multiple terminals with the same session information includes: grouping and matching the multiple terminals with the same session information according to the order of the user data.

[0023] In a possible implementation, the grouping and matching of the multiple terminals having the same session information according to the sorting of the user data includes:

[0024] According to the sorting of the user data, Bluetooth matching is performed on the multiple terminals with the same session information to obtain pairwise Bluetooth matching results;

[0025] After grouping and matching the multiple terminals with the same session information according to the sorting of the user data, the method further includes:

[0026] If there is user data without Bluetooth matching results in multiple sessions, position matching is performed on the user data without Bluetooth matching results to obtain pairwise position matching results; wherein the time ranges covered by the above multiple sessions are the same.

[0027] In a possible implementation, performing location matching on the user data without Bluetooth matching results in the multiple sessions includes:

[0028] Calculate the geographical fence corresponding to each terminal without Bluetooth matching result according to the geographical location information of the terminal without Bluetooth matching result;

[0029] Determine multiple geographic fences around a target terminal; the target terminal is any one of the terminals without Bluetooth matching results;

[0030] Determine respectively the terminal to be matched that is closest to the target terminal in each of the geographic fences;

[0031] Determine, from among the terminals to be matched corresponding to the plurality of geographical fences, a terminal to be matched closest to the target terminal as a target matching terminal;

[0032] The target terminal and the target matching terminal are the position matching results of the pairwise matching.

[0033] In a possible implementation manner, before grouping and matching the multiple terminals based on the user data sent by the multiple terminals, the method further includes:

[0034] Receiving a request for querying matching results sent by a target terminal; the target terminal is any one of the multiple terminals;

[0035] In response to the request for querying the matching results, determining whether the time at which the target terminal sends the request for querying the matching results is later than the latest time of the session corresponding to the target terminal;

[0036] The sending of the group matching result to the corresponding terminal includes: if the time when the target terminal sends the request for querying the matching result is later than the latest time of the session corresponding to the target terminal, sending the group matching result of the target terminal to the target terminal.

[0037] In a possible implementation manner, the grouping and matching the multiple terminals based on the user data sent by the multiple terminals includes:

[0038] Determine whether there is a matching result corresponding to the above session according to the session information corresponding to the above target terminal;

[0039] If not, the plurality of terminals are grouped and matched based on the user data sent by the plurality of terminals having the same session information as the target terminal.

[0040] In a second aspect, an embodiment of the present specification provides a data processing device, including:

[0041] An acquisition module, used to acquire user data sent by multiple terminals; wherein the user data includes a user identifier corresponding to the terminal and user identifiers of other terminals within the Bluetooth search range of the terminal;

[0042] A matching module, configured to group and match the plurality of terminals based on the user data sent by the plurality of terminals; wherein each group includes at least two terminals, the distance between the at least two terminals does not exceed a preset threshold, and the matching results of the at least two terminals are consistent;

[0043] The sending module is used to send the above group matching results to the corresponding terminal.

[0044] In a possible implementation, the user data further includes geographic location information and a timestamp corresponding to the terminal; the timestamp is the time when the terminal sends the user data.

[0045] In a possible implementation, the matching module includes:

[0046] A first determining unit, configured to determine the session information corresponding to each of the terminals based on the user data sent by the multiple terminals;

[0047] The first matching unit is used to group and match multiple terminals with the same session information.

[0048] In a possible implementation manner, the first determining unit includes:

[0049] A first determining subunit, configured to determine whether there is a first target session based on the timestamp and the geographic location information of each terminal, wherein the time range covered by the first target session includes the timestamp;

[0050] A second determining subunit is configured to determine, if the first target session exists, that the first target session is a session corresponding to the terminal;

[0051] A third determining subunit is configured to determine whether a second target session exists based on the timestamp and the geographic location information if the first target session does not exist, and the start time of the second target session is later than the start time of the first target session;

[0052] a fourth determining subunit, configured to determine, if the second target session exists, that the second target session is the session corresponding to the terminal;

[0053] a fifth determining subunit, configured to generate a target session based on the timestamp and the geographic location information if the second target session does not exist, and determine that the target session is the session corresponding to the terminal; the earliest moment of the time range covered by the target session is the moment corresponding to the timestamp;

[0054] Among them, the length of the time range covered by the first target session, the length of the time range covered by the second target session, and the length of the time range covered by the target session are equal.

[0055] In a possible implementation, the user data further includes Bluetooth signal strengths of other terminals within the Bluetooth search range of the terminal;

[0056] The device further includes: a sorting module, configured to sort the user data according to the Bluetooth signal strength;

[0057] The first matching unit is specifically used for grouping and matching the multiple terminals with the same session information according to the order of the user data.

[0058] In a possible implementation, the first matching unit is specifically configured to: perform Bluetooth matching on the multiple terminals with the same session information according to the order of the user data to obtain pairwise Bluetooth matching results;

[0059] The above-mentioned matching module also includes: a second matching unit, which is used to perform position matching on the terminals without Bluetooth matching results in multiple sessions if there are terminals without Bluetooth matching results in the above-mentioned multiple sessions, so as to obtain position matching results that match each other; wherein the time range covered by the above-mentioned multiple sessions is the same.

[0060] In a possible implementation, the second matching unit includes:

[0061] A calculation subunit, configured to calculate the geographical fences corresponding to the terminals without Bluetooth matching results according to the geographical location information of the terminals without Bluetooth matching results;

[0062] A sixth determination subunit is used to determine a plurality of geographic fences around a target terminal; the target terminal is any one of the terminals without a Bluetooth matching result;

[0063] A seventh determination subunit, configured to respectively determine the to-be-matched terminal that is closest to the target terminal in each of the geographic fences;

[0064] An eighth determination subunit is used to determine, from among the terminals to be matched corresponding to the plurality of geographical fences, a terminal to be matched closest to the target terminal as a target matching terminal;

[0065] The target terminal and the target matching terminal are the position matching results of the pairwise matching.

[0066] In a possible implementation, the above device further includes:

[0067] A receiving module, configured to receive a request for querying matching results sent by a target terminal; the target terminal is any one of the multiple terminals;

[0068] A judgment module, configured to respond to the request for querying the matching result and judge whether the time at which the target terminal sends the request for querying the matching result is later than the latest time of the session corresponding to the target terminal;

[0069] The sending module is specifically used to send the group matching result of the target terminal to the target terminal if the time when the target terminal sends the request for querying the matching result is later than the latest time of the session corresponding to the target terminal.

[0070] In a possible implementation, the matching module includes:

[0071] A second determining unit, configured to determine whether there is a matching result corresponding to the above session according to the session information corresponding to the above target terminal;

[0072] The third matching unit is configured to group and match the plurality of terminals based on user data sent by a plurality of terminals having the same session information as the target terminal if there is no matching result for the session corresponding to the target terminal.

[0073] In a third aspect, an embodiment of this specification provides an electronic device, including: a processor and a memory;

[0074] The processor is connected to the memory;

[0075] The above-mentioned memory is used to store executable program code;

[0076] The processor runs a program corresponding to the executable program code by reading the executable program code stored in the memory, so as to execute the method provided by the first aspect of the embodiment of this specification or any possible implementation of the first aspect.

[0077] In a fourth aspect, an embodiment of the present specification provides a computer storage medium, wherein the computer storage medium stores a plurality of instructions, wherein the instructions are suitable for being loaded by a processor and executing the method provided by the first aspect of the embodiment of the present specification or any possible implementation of the first aspect.

[0078] The embodiment of this specification obtains user data sent by multiple terminals, and groups and matches them based on the user data sent by the multiple terminals, and finally sends the group matching results to the corresponding terminals. Among them, the user data includes the user identification corresponding to the terminal, and the user identifications of other terminals within the Bluetooth search range of the terminal. Each group includes at least two terminals, and the distance between the at least two terminals does not exceed the preset threshold. The matching results of the terminals in each group are consistent. By adopting this method, on the one hand, by matching other terminals around the terminal, the user can lead the people around him to participate in the activity. On the other hand, the matching results of the terminals in each group are consistent, which can make the matching results displayed by the users in each group consistent, thereby achieving face-to-face accurate matching, increasing the fun of users participating in activities, and further promoting users to lead people around them to participate in activities, so as to achieve the promotion purpose of the merchant. BRIEF DESCRIPTION OF THE DRAWINGS

[0079] In order to more clearly illustrate the technical solutions in the embodiments of this specification, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this specification. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0080] Figure 1 A schematic diagram of the architecture of a data processing system provided for an exemplary embodiment of this specification;

[0081] Figure 2A-2D A schematic diagram of an interface of a group matching process provided by an exemplary embodiment of this specification;

[0082] Figure 3 A flowchart of a data processing method provided for an exemplary embodiment of this specification;

[0083] Figure 4 A schematic diagram of the waiting time of a target terminal provided by an exemplary embodiment of this specification;

[0084] Figure 5 A schematic diagram of a data reporting process provided by an exemplary embodiment of this specification;

[0085] Figure 6 A schematic diagram of hotspot area degradation provided for an exemplary embodiment of this specification;

[0086] Figure 7 A schematic diagram of geo-fence division provided for an exemplary embodiment of this specification;

[0087] Figure 8 A schematic diagram of terminal information belonging to the same session provided by an exemplary embodiment of this specification;

[0088] Fig. 9 A schematic diagram of target terminal session matching provided by an exemplary embodiment of this specification;

[0089] Fig.10 A schematic diagram of a group matching process provided by an exemplary embodiment of this specification;

[0090] Figures 11A-11G The intention of Bluetooth pairing provided by an exemplary embodiment of this specification;

[0091] Figure 12A-12B A schematic diagram of position matching provided for an exemplary embodiment of this specification;

[0092] Fig.13 A schematic diagram of the structure of a data processing device provided as an exemplary embodiment of this specification;

[0093] Fig.14 A schematic diagram of the structure of an electronic device provided as an exemplary embodiment of this specification. DETAILED DESCRIPTION

[0094] The technical solutions in the embodiments of this specification will be described clearly and completely below in conjunction with the drawings in the embodiments of this specification.

[0095] The terms "first", "second", "third", etc. in this specification and claims and the above drawings are used to distinguish different objects, rather than to describe a specific order. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not limited to the listed steps or units, but may optionally include steps or units that are not listed, or may optionally include other steps or units inherent to these processes, methods, products or devices.

[0096] Please refer to Figure 1 , Figure 1 The following is a schematic diagram of the architecture of a data processing system provided by an exemplary embodiment of this specification. Figure 1 As shown, the data processing system 10 may include: a server 110 and a plurality of terminals 120. Among them:

[0097] The terminal 120 may be a user terminal. An application may be installed in the terminal 120. When the terminal 120 receives a trigger operation (e.g., shaking the phone) based on the application, the terminal may implement functions such as sending user data, receiving or querying the results of group matching, etc. Each terminal 120 may establish a data relationship with the network, and establish a data connection relationship with the server 110 through the network, such as sending user data, querying and receiving matching results, etc. Among them, the terminal 120 may be, but is not limited to, a mobile phone, a tablet computer, a laptop computer, and other devices with an application installed. In the embodiment of this specification, the user data may include a user identity document (UID) logged in on the terminal 120, the geographical location information of the terminal 120, and the user IDs (UIDs) corresponding to other terminals within the Bluetooth search range of the terminal 120. Among them, the geographical location information of the terminal may include at least longitude (lon) and latitude (lat). Further, the geographical location information may also include a city identifier city_ID (e.g., the city_ID corresponding to Wuhan City is 330100), an area identifier area_ID (e.g., the area_ID corresponding to Hongshan District is 330110), etc.

[0098] The server 110 can accurately match multiple users corresponding to the multiple terminals 120 face to face based on the user data sent by the multiple terminals 120, that is, to implement the data processing method described in the embodiments of this specification. The server 110 can also receive data such as user data sent by any user terminal in the network or multiple terminals 120, or send data such as the corresponding accurate matching result to any user terminal in the network or multiple terminals 120.

[0099] In some possible embodiments, the data processing system 10 may further include a cache server (not shown in the figure), which is specifically used to receive user data uploaded by the terminal 120. In this embodiment, the server 110 can obtain user data from the cache server and perform group matching on the user data. The cache server in the embodiment of this specification may be RZTbase

[0100] The network may be a medium providing a communication link between the server 110 and the plurality of terminals 120, or may be the Internet including network devices and transmission media, but is not limited thereto. The transmission media may be a wired link (such as but not limited to coaxial cable, optical fiber, and digital subscriber line (DSL)) or a wireless link (such as but not limited to wireless fidelity (WIFI), Bluetooth, and mobile device network).

[0101] Understandably, Figure 1The number of terminals 120 in the data processing system shown is only an example, and in a specific implementation, the data processing system may include any number of terminals 120. This embodiment of the specification does not limit this.

[0102] Next, combine Figure 1 , introduces the implementation scenario corresponding to the data processing method provided in the embodiment of this specification, that is, the process from the user's participation in the activity to the issuance of rights and interests after successful matching. For details, please refer to Figure 2A-2D A schematic diagram of the interface of the group matching process provided in the embodiments of this specification.

[0103] For example, the terminal 120 may receive a user's click operation on an installed application A (including a shake function), and in response to the click operation, the terminal may display the following information: Figure 2A Then, the terminal 120 may receive a user operation (such as but not limited to a click operation) based on the "shake red envelope" control in the user interface 20, or the terminal 120 may receive a user's shaking operation on the terminal 120 based on a gyroscope or an acceleration sensor when displaying the user interface 20, so that the terminal 120 may display a red envelope that can be Figure 2B The user interface 20 shown in FIG. 1 is shown in FIG. 1 . At this time, the terminal 120 can report the user data to the server 110 and wait for the server 110 to perform accurate group matching and calculate the matching results for the multiple terminals 120 participating in the same session. At this time, the user interface 20 will display the following Figure 2B The prompt box 201 in the figure reads “Matching…”. When the server 110 has completed matching the above-mentioned multiple terminals 120, the matching results can be sent to the corresponding terminals 120. The terminals 120 receive the matching results. Figure 2C As shown: users "Li Lei" and "Han Meimei" are matched in the same group, that is, user "Li Lei" is matched with user "Han Meimei", and the interface of user "Li Lei" is as follows Figure 2C As shown in 30A in FIG. 30A; the user "Han Meimei" also matches "Li Lei", and the interface of the user "Han Meimei" is as follows Figure 2C At this time, both user "Li Lei" and user "Han Meimei" can receive the activity rights by clicking the "Receive" area in the interface, that is, enter the following Figure 2D The user interface 40 shown is used to collect corresponding activity benefits.

[0104] The embodiment of this specification is not limited to matching two users who report user data. In a specific implementation, the embodiment of this specification can also match three or more users. For example, user A can be matched with user B and user C. At the same time, user B is also matched with user A and user C, and user C is also matched with user A and user B. The embodiment of this specification does not limit the number of users included in a group.

[0105] Next, combine Figure 1-2D , introduces the data processing method provided by the embodiments of this specification. For details, please refer to Figure 3 , which is a flow chart of a data processing method provided in the embodiment of this specification. Figure 3 As shown, the data processing method includes the following steps:

[0106] S102, obtaining user data sent by multiple terminals.

[0107] Specifically, after receiving the trigger operation, each terminal 120 may send its corresponding user data to the server 110. Exemplarily, the trigger operation may be that the terminal 120 may receive a user operation (such as but not limited to a click operation) based on the "shake red envelope" control in the user interface 20, or the terminal 120 may receive a user's shake operation on the terminal 120 based on a gyroscope or an acceleration sensor when displaying the user interface 20. The server 110 can obtain user data sent by multiple terminals 120 through the network. The user data includes a user identifier corresponding to the terminal 120, and user identifiers of other terminals within the Bluetooth search range of the terminal 120. Among them, the preset range refers to the Bluetooth search range of the terminal. The user identifier may be a string of characters composed of Chinese, English or symbols that can represent the identity of the user, for example, 2088102325262557, zfb-888, etc. This specification embodiment does not specifically limit this.

[0108] S104: Group and match multiple terminals based on user data sent by the multiple terminals.

[0109] Specifically, after the server 110 obtains the user data sent by the multiple terminals 120, it will also report the user data. The user data also includes the geographical location information and timestamp corresponding to the terminal 120. The timestamp is the time when the terminal 120 sends the user data, that is, the time when the terminal 120 receives the trigger operation. The geographical location information includes the city identification corresponding to the city where the terminal 120 is located and the longitude and latitude corresponding to the geographical location of the terminal 120. The city identification can be a string composed of Chinese or English or numbers or symbols that can represent the identity of the city, for example, 330100, beijing-8, etc. This specification embodiment does not specifically limit this. After the terminal 120 reports the user data, the server will determine the session information corresponding to each terminal based on the user data sent by the multiple terminals, and group and match multiple terminals with the same session information. That is, group and match multiple terminals located in the same session. How to determine the session information corresponding to each terminal will be introduced in subsequent embodiments and will not be described in detail here.

[0110] Optionally, the user data also includes the Bluetooth signal strength of other terminals within the Bluetooth search range of the terminal 120. The preset range may be 50 meters, 100 meters, etc. The specific range depends on the performance of the Bluetooth module of the terminal 110, and the embodiments of this specification do not specifically limit this. After the server reports the user data, the server 110 will sort the user data according to the Bluetooth signal strength, for example, from strong to weak, and then group and match multiple terminals with the same session information according to the sorting results of the user data. Each group includes at least two terminals, the distance between the at least two terminals does not exceed a preset threshold, and the matching results of the at least two terminals are consistent (for example Figure 2C The matching results of "Li Lei" and "Han Meimei" shown in FIG. 1 are consistent). The preset threshold may be 200 meters, 500 meters, etc., and may be set according to actual conditions. This specification embodiment does not specifically limit this.

[0111] S106, sending the group matching result to the corresponding terminal.

[0112] Specifically, after the server performs group matching on the above-mentioned multiple terminals, when the server receives a request for query matching results sent by the target terminal, if the time when the target terminal sends the request for query matching results is later than the latest time of the session corresponding to the target terminal, the group matching results of the target terminal are sent to the target terminal. The target terminal is any one of the multiple terminals. If the time when the target terminal sends the request for query matching results is earlier than the latest time of the session corresponding to the target terminal, the server may not respond to the query matching results of the target terminal, or the server may wait until the session ends before responding to the query matching results of the target terminal (calculating and sending matching results). In the embodiment of this specification, the time between the end of the session and the time when the target terminal sends the query matching results can be referred to as the waiting time. In this way, it can be ensured that no new terminals will be added to the session corresponding to the target terminal, that is, the terminals included in the session have been determined, thereby ensuring the accuracy of the final matching results.

[0113] For example, when the time when the target terminal sends the request for query matching results is 10:00:03, and the time of the session corresponding to the target terminal is 10:00:00-10:00:02, it can be determined that the time when the target terminal sends the request for query matching results is later than the latest time of the session corresponding to the target terminal, and the server will send the group matching results of the target terminal to the target terminal.

[0114] For example, Figure 4As shown, when the timestamp corresponding to the target terminal is 10:00:01.820, the matched session is Session 2, and the time range covered by Session 2 is 10:00:01-10:00:03, the waiting time of the target terminal is 1180 milliseconds ms, which is obtained by subtracting the time corresponding to the above timestamp from the latest time corresponding to Session 2. That is, the server needs to wait for 1180ms before starting to group and match the target terminals.

[0115] In some possible embodiments, after the target terminal reports the above user data, the server will determine whether there is a matching result for the session corresponding to the target terminal based on the session information corresponding to the target terminal. If not, the above multiple terminals are grouped and matched based on the user data sent by multiple terminals with the same session information as the target terminal. In other words, if a session includes 100 terminals, if a terminal (i.e., the above target terminal) is the first terminal among the 100 terminals to initiate a request to query the matching results to the server, then the request initiated by the target terminal to query the matching results triggers the server to group the terminals included in the session.

[0116] Furthermore, the server can save the matching result of the session in the memory. When other terminals in the session initiate a request to query the matching result to the server, the server can directly obtain the matching result of other terminals from the memory and send the matching result to the corresponding terminal.

[0117] The embodiment of this specification obtains user data sent by multiple terminals, and groups and matches them based on the user data sent by the multiple terminals, and finally sends the group matching results to the corresponding terminals. Among them, the user data includes the user identification corresponding to the terminal, and the user identifications of other terminals within the Bluetooth search range of the terminal. Each group includes at least two terminals, and the distance between the at least two terminals does not exceed the preset threshold. The matching results of the terminals in each group are consistent. By adopting this method, on the one hand, by matching other terminals around the terminal, the user can lead the people around him to participate in the activity. On the other hand, the matching results of the terminals in each group are consistent, which can make the matching results displayed by the users in each group consistent, thereby achieving face-to-face accurate matching, increasing the fun of users participating in activities, and further promoting users to lead people around them to participate in activities, so as to achieve the promotion purpose of the merchant.

[0118] In the above step S104, the implementation process of user data reporting is detailed in Figure 5 , which is a schematic diagram of a data reporting process according to an embodiment of this specification. Figure 5 As shown in the figure, the data reporting process includes the following steps:

[0119] Step 502: Process and verify the reported information.

[0120] Specifically, after obtaining the user data sent by multiple terminals, the server will verify whether the geographic location information included in the above user data is correct. If the geographic location information includes a city identifier and longitude and latitude, then verify whether the data representation format of the city identifier and longitude and latitude included in the user data is correct. When the data representation format of the city identifier and longitude and latitude are correct, then determine whether the longitude and latitude of the terminal are within the longitude and latitude range corresponding to the city according to the pre-stored preset data table. If so, it can be determined that the geographic location information included in the above user data is correct.

[0121] For example, when the city identifier included in the user data is "330100", the longitude is "120.047043", and the latitude is "30.280282", since the city identifier is composed of some numbers and the city represented by the city identifier can be found in the database, it can be determined that the data representation format of the city identifier is correct. Since the longitude "120.047043" is within the longitude representation range [-180, 180], and the latitude "30.280282" is within the latitude representation range [-90, 90], it can be determined that the data representation format of the longitude and latitude is also correct. When the city represented by the city identifier is Xihu District, and the longitude range of Xihu District is [120, 125], and the latitude range is [30, 35], it can be determined that the longitude and latitude are within the longitude and latitude range corresponding to the Xihu District of the above city, and it can be determined that the geographic location information included in the above user data is correct.

[0122] Optionally, the user data may include the strength of the Bluetooth scanning signal corresponding to the terminal in addition to the geographical location information, timestamp and user identification corresponding to the terminal. After the server verifies the geographical location information included in the above user data, it will also sort the user identifications of multiple terminals with the same geographical location information according to their corresponding Bluetooth scanning signal strength (Received Signal Strength Indication, RSSI). For example, when the RSSI corresponding to the terminal with the user identification "2088402527866158" is -51, and when the RSSI corresponding to the terminal with the user identification "2088102325262557" is -21, it can be judged that the RSSI (-51) corresponding to the terminal with the user identification "2088402527866158" is stronger than the RSSI (-21) corresponding to the terminal with the user identification "2088102325262557", that is, the user identification "2088402527866158" is ranked ahead of the user identification "2088102325262557".

[0123] Step 504: Build cache information.

[0124] Specifically, in the embodiments of this specification, after the user data participates in the group matching, since the user data participating in the group matching in the embodiments of this specification are time-sensitive (the data becomes invalid after the group matching is completed), the TBase cache server can be used in the embodiments of this specification to store data. That is, the terminal can send the user data to the TBase cache server for data caching. Exemplarily, the user data sent by the terminal includes: the user identification (uid) of the terminal, the longitude and latitude information (lat, lon) of the terminal, and the user identifications (uids) of other terminals scanned by the terminal via Bluetooth. Exemplarily, the cached information format is as follows:

[0125]

[0126] Step 506, TBase routing information is scattered.

[0127] Specifically, in the embodiment of this specification, in order to allow user data in the same area to be cached together, geo-fences are used as routes when caching user data. The cache server in the embodiment of this specification can specifically adopt an RZ Tbase cache server. Since user data in some hot spots such as Shanghai and Hangzhou are routed to the same cluster, in order to prevent the excessive amount of data from causing system abnormalities in the process of calculating geo-fences, it is necessary to break up the user data in the hot spots, that is, to downgrade the geo-fences in the area.

[0128] Figure 6 The following is a schematic diagram of a geo-fence downgrade process. Figure 6 As shown, when the first-level geo-fence 2 is a hotspot area, the geo-fence 2 can be downgraded to the second level, that is, the first-level geo-fence 2 is divided into four equal-sized second-level geo-fences 20, 21, 22, and 23. When the second-level geo-fence 13 is a hotspot area, the second-level geo-fence 13 can be further downgraded to the third level, that is, the second-level geo-fence 13 is divided into four equal-sized third-level geo-fences 130, 131, 132, and 133. It can be seen that in the specific implementation, there can be other geo-fence downgrade processing methods, which are not limited in the embodiments of this specification.

[0129] Step 508, calculate the geo-fence.

[0130] Specifically, since the user data of an area needs to be cached together, it is necessary to divide and store them in the same cluster area based on geographic fences. The GeoHash algorithm is used to calculate the geographic fence in the embodiment of this specification, and the S2 algorithm can also be used. This specification does not specifically limit this. The GeoHash algorithm is an address encoding method that can encode two-dimensional spatial longitude and latitude data into a string. In simple terms, the GeoHash algorithm can convert a geographic coordinate into a string, but this string does not represent a point, but a rectangular box. The rectangular box here can be understood as a geographic fence to which the location point corresponding to the above-mentioned geographic coordinates belongs. For example, when the geographic location information of terminal A is: longitude 120.435343, latitude 30.123123, the longitude and latitude corresponding to terminal A can be encoded into a string WX4EQX through the GeoHash algorithm, that is, the string WX4EQX corresponding to the above-mentioned longitude and latitude is used to represent the geographic fence corresponding to terminal A.

[0131] like Figure 7 As shown, it is a schematic diagram of geographic fence division provided by an exemplary embodiment of this specification. Figure 7 It can be seen that one rectangular box corresponds to one geo-fence, and each geo-fence corresponds to a string (WX4EQR, WX4EQX, WX4EQZ, etc.). Figure 7 The geographic range corresponding to each geo-fence shown is the same size. In some possible embodiments, if a certain area is a hotspot area, the geo-fence corresponding to the area can be downgraded, and the geo-fence can be further subdivided into multiple geo-fences with smaller ranges.

[0132] Step 510: Cache information is stored and waits for matching.

[0133] Specifically, after calculating the geographic fences corresponding to multiple user data, it is necessary to determine the session information corresponding to each of the terminals, and cache the user data sent by the terminals in the same session, waiting for group matching. Each session corresponds to a specific session identification code, and the session identification code may include the time range covered by the session and the geographic fence composition. Furthermore, the session identification code may also include a gameplay identifier. The gameplay identifier may be a string of Chinese, English or symbols that can represent the identity of the user, for example, PLAY10039632, PLAY1003963!, etc., which can be set according to actual conditions, and this manual does not make specific restrictions on this. The gameplay identifier is used to represent different activities, for example, the August promotion activity corresponds to a gameplay identifier, the September promotion activity corresponds to another gameplay identifier, and so on.

[0134] Specific as Figure 8As shown, it is a schematic diagram of terminal information belonging to the same session provided by an exemplary embodiment of this specification. Figure 8 The identification code of the session in a certain period of time in the area with the geographic fence WX4EQX is 16289769_WX4EQX_PLAY10039632. There are 3 users belonging to this session. The corresponding information of these 3 users is as follows: Figure 8 The user information list shown in the left figure includes the longitude (lon), latitude (lat), user identification (uid) of the three users (terminals), and user identifications (uids) of other terminals scanned by the terminal through Bluetooth.

[0135] In a specific implementation, it is known that there are multiple terminals located in the same geographic fence, but the time when some terminals are triggered to report user data to the server may be far apart. In order to ensure the efficiency of group matching, the time range covered by a session in the embodiment of this specification will not be very large, for example but not limited to 1 second, 2 seconds, 3 seconds, etc. The smaller the time range covered by the session, the shorter the time the server waits for the session to end, the higher the efficiency of the server in calculating the group matching, and the faster the terminal receives the response of the group matching result.

[0136] For example, if terminal A is triggered to report user data to the server at 8:00:01, and terminal B is triggered to report user data to the server at 14:00:20, then although terminal A and terminal B are in the same geographic fence, they cannot be classified into the same session. The following will specifically introduce how to determine the session information corresponding to a terminal based on the user data sent by the terminal.

[0137] Specifically, firstly, based on the timestamp and geographic location information (geofence) of each terminal, it is determined whether there is a first target session, wherein the time range covered by the first target session includes the timestamp corresponding to the terminal, that is, first find out whether there is a session whose time just covers the timestamp of the terminal. If there is a first target session, then determine whether the first target session is the session corresponding to the terminal. If there is no first target session, then determine whether there is a second target session based on the timestamp and geographic location information of the terminal, wherein the start time of the second target session is later than the start time of the first target session, that is, then find out whether there is a next session. If there is no second target session, then generate a target session based on the timestamp and geographic location information of the terminal, and determine that the target session is the session corresponding to the terminal, wherein the earliest time of the time range covered by the target session is not later than the time corresponding to the timestamp of the terminal. That is to say, if both the first target session and the second target session do not exist, the server will create a session based on the timestamp of the terminal. After the session is created, other terminals can be waited to join.

[0138] It should be noted that it is not limited to the above-mentioned search for only one session (the second target session) after searching for the first target session. In a specific implementation, more sessions (such as the third target session) may be searched later, and this specification does not limit this.

[0139] It should be noted that the length of the time range covered by each session can be the same, for example, 2 seconds. The length of the time range covered by each session can also be different. This embodiment of the specification does not limit this.

[0140] In addition, in order to avoid the existence of boundary problems, that is, when the timestamp of a terminal is exactly at the intersection of two sessions, it may be impossible to determine which session the terminal is added to, the time ranges corresponding to the sessions in the embodiments of this specification can be set to overlap. The intervals between the start times of each session can be set to be the same or different, and this embodiment of this specification does not limit this.

[0141] Next, combine Fig. 9 The following is a target terminal match diagram provided by an exemplary embodiment of this specification. Fig. 9 As shown, the time (i.e., timestamp) when the target terminal is triggered to shake is 10:00:01, and the geographic location information includes longitude 120.10788 and latitude 30.267042. Then, the geographic fence corresponding to the target terminal can be determined as WX4EQX. Then, the time range covered by the session 1 (the first target session) to be found is determined according to the timestamp, and based on the time range covered by session 1 (10:00:00-10:00:02) and the geographic fence (WX4EQX) corresponding to the target terminal (or also including the gameplay identifier), it is determined whether the session identification code to be found exists. If it exists, it is determined that session 1 exists, and session 1 is determined to be the session corresponding to the target terminal, and the user data of the target terminal is added to the user information list corresponding to session 1.

[0142] If session 1 does not exist, continue to search for a session, namely session 2 (the second target session), that is, based on the time range covered by session 2 (10:00:01-10:00:03) and the geographic fence (WX4EQX) corresponding to the target terminal (or also including the gameplay identifier), determine whether the session identification code to be searched exists. If it does, it is determined that session 2 exists, and session 2 is determined to be the session corresponding to the target terminal, and the user data of the target terminal is added to the user information list corresponding to session 2.

[0143] If session 2 does not exist, continue to search for a session, namely session 3 (the third target session), that is, based on the time range covered by session 3 (10:00:02-10:00:04) and the geographic fence (WX4EQX) corresponding to the target terminal (or also including the gameplay identifier), determine whether the session identification code to be searched exists. If it does, it is determined that session 3 exists, and session 3 is determined to be the session corresponding to the target terminal, and the user data of the target terminal is added to the user information list corresponding to session 3.

[0144] If session 3 does not exist, a time range is determined based on the timestamp of the target terminal, and a session identification code is generated by combining the time range and the geographic fence (or also including the gameplay identifier), that is, the target session is generated, that is, a new session is created as the session corresponding to the target terminal, and subsequent terminals are waited for to join the session.

[0145] The start time of the created session (target session) is not later than the time corresponding to the timestamp of the target terminal. This can be determined in combination with the setting rules of each session start time. For example, the start time of the session that is not later than the timestamp and closest to the timestamp can be used as the start time of the target session.

[0146] For example, if the start time of each session is set to be 1 second apart, when the timestamp of the target terminal is 10:00:01, 10:00:01 can be directly used as the start time of the target session. When the timestamp corresponding to the target terminal is 10:00:01.820, it is determined that the start time of the session before and closest to the timestamp is not 10:00:01, and 10:00:01 is used as the start time of the target session.

[0147] In the above step S106, the server performs grouping and allocation on multiple terminals in the same session. For details, please refer to Fig.10 , which is a schematic diagram of a group matching process according to an embodiment of this specification. Fig.10 As shown, the group allocation process includes the following steps:

[0148] Step 1002, request parameter verification.

[0149] Specifically, after reporting the data information, the terminal will initiate a request to the server to query the matching results. The request will carry the user ID of the terminal. After receiving the request from the terminal, the server can first verify the request parameters. Specifically, the waiting time of the terminal can be verified, and the session identification code can be verified.

[0150] Specifically, in order to ensure that the terminals of the same session can be matched in the same matching window (the time range covered by the session), the server needs to verify the waiting time of each terminal, that is, whether the terminal has waited for its corresponding waiting time. If the terminal sends a request to query the matching result to the server before the corresponding waiting time is reached, the server needs to block the request. If the waiting time is reached, the server can also verify whether the session identification code corresponding to the terminal is correct, and specifically verify whether the data format of the session identification code is correct. If not, the server needs to block the request.

[0151] Step 1004, query whether the matching result has been calculated.

[0152] Specifically, if the request parameter verification is passed, the server may query whether a matching result of the session already exists according to the session identification code corresponding to the terminal; if so, execute step 1006; if not, execute step 1008.

[0153] Step 1006, obtaining matching results.

[0154] Specifically, if the matching result of the session already exists, the server directly obtains the matching result of the terminal and sends the matching result of the terminal to the terminal.

[0155] Step 1008, searching for all user information in the session according to the session identification code.

[0156] Specifically, if the match result of the session does not exist, that is, the terminal is the first terminal among all the terminals included in the session to initiate a query request for the match result to the server, then the server is triggered to start calculating the match result. The server needs to search for all user information, i.e., user data, under the session according to the session identification code corresponding to the session. For example, all user information under the session is as follows: Figure 8 As shown in the user information list in , it includes the latitude lat, longitude lon, user ID uid of each user and the user IDs uids of other users that the user can search. That is to say, after receiving the request for querying matching results initiated by the target terminal, the server can determine whether there is a matching result for the session corresponding to the target terminal according to the session information corresponding to the target terminal. If not, the server will group and match the multiple terminals based on the user data sent by the multiple terminals with the same session information as the target terminal.

[0157] In some embodiments of the present description, the user data also includes the Bluetooth signal strength of other terminals within the Bluetooth search range of the terminal. Before the server performs group matching on the terminals, it can also sort the other terminals included in each user data according to the Bluetooth signal strength. For example, the Bluetooth signal strength can be sorted from strong to weak. Then the server performs group matching on multiple terminals with the same session information based on the sorted user data. That is, the server performs group matching on multiple terminals with the same session information according to the sorting of the user data.

[0158] Specifically, grouping and matching multiple terminals with the same session information according to the order of user data may specifically include: performing Bluetooth matching on multiple terminals with the same session information according to the order of user data to obtain pairwise Bluetooth matching results.

[0159] After the Bluetooth matching is completed, if there are terminals without Bluetooth matching results in multiple sessions, the terminals without Bluetooth matching results in these multiple sessions are position matched to obtain position matching results of two-to-two matching; wherein, the time range covered by these multiple sessions is the same. That is to say, the multiple terminals that are finally position matched belong to different geographic fences, but the corresponding time windows are the same.

[0160] Next, combine step 1010 ( Figures 11A-11G ) introduces the Bluetooth pairing process, and then combines step 1012 ( Figure 12A-12B ) introduces the process of position matching.

[0161] Step 1010, Bluetooth matching.

[0162] Specifically, after the server searches for all user information in the session according to the session identification code, it will perform Bluetooth matching on all terminals in the session.

[0163] Next, the specific implementation process of Bluetooth matching provided by an exemplary embodiment of this specification is introduced. Figures 11A-11G The process of performing Bluetooth matching for multiple terminals (AG) included in session 1 is exemplarily shown. Figures 11A-11G As shown:

[0164] First, all terminals A, B, C, D, E, F, and G in session 1 are sorted from far to near according to the time sequence of their joining this session. The sorting sequence indicates the server's matching sequence for each terminal. That is, when the timestamp corresponding to terminal A is before the timestamp corresponding to terminal B, the matching result of terminal A is calculated first, and then the matching result of terminal B is calculated. Each terminal also corresponds to other terminals that the terminal can search through Bluetooth scanning. For example, the other terminals that terminal A can search through Bluetooth scanning are B, C, D, and E. For another example, the other terminals that terminal B can search through Bluetooth scanning are A and C. Figures 11A-11G In the Bluetooth pairing process, the implementation process mainly includes the following steps:

[0165] S1: Process A's Bluetooth list, and A and B are matched successfully.

[0166] Specifically, Fig.11A As shown, since terminal A first joins session 1, A is matched first. Also, because the other terminals that can be searched corresponding to A, namely, the Bluetooth list, include B, C, D, and E, and B joins session 1 first and B is not matched with other terminals, A and B can be directly matched accurately. After the match is successful, the match result can be stored in the Bluetooth match result pool, that is, the Bluetooth match result pool will show that A matches B, and B also matches A. In the embodiments of this specification, the Bluetooth result match pool can be understood as a data storage space in the server, which is used to store the results of Bluetooth matching.

[0167] S2: Continue to loop A's Bluetooth list. C is not matched and falls into the intermediate relationship table.

[0168] Specifically, Fig. 11B As shown, the Bluetooth list of A continues to be cycled. Since A and B have been matched successfully, but C has not been matched, and B included in the Bluetooth search list of C has also been matched successfully, C is first placed in the intermediate relationship table. In the embodiment of this specification, the intermediate relationship table can also be understood as a data storage space in the server.

[0169] S3: Continue to loop A's Bluetooth list. D is not matched, falls into the intermediate relationship table, and successfully matches with C.

[0170] Specifically, Fig. 11CAs shown, A's Bluetooth list continues to loop. Since A and B have been matched successfully, C has not been matched, and D has not been matched either, and A included in D's Bluetooth search list has also been matched successfully, D is also included in the intermediate relationship table. Since B, C, D, and E can all be searched by A's Bluetooth, it proves that the distances between B, C, D, and E are also very close. Since C and D have both been scanned by A, and C and D are both in the intermediate relationship in session 1, that is, there is no matching result for C and D, then C and D can be matched. After the match is successful, C and D are removed from the intermediate relationship table, and the matching results of C and D are stored in the Bluetooth matching result pool.

[0171] S4: Continue to loop A's Bluetooth list, E is not matched and falls into the intermediate relationship table.

[0172] Specifically, Fig.11D As shown, the Bluetooth list of A continues to be cycled. Since A, B, C, and D have all been matched successfully, but E has not been matched, and E has not searched for other terminals, E is placed in the intermediate relationship table.

[0173] S5: The Bluetooth list loop of A ends, E is left alone in the intermediate relationship table, and is moved into the Bluetooth inter-connection relationship table.

[0174] Specifically, Fig.11E As shown, when A's Bluetooth list loop is finished, it is found that E is left alone in the intermediate relationship table, and then it is moved into the Bluetooth inter-connection relationship table, which means that there is a certain correlation between A and E. In the embodiment of this specification, the Bluetooth inter-connection relationship table can also be understood as a data storage space in the server.

[0175] S6: Circulate B's Bluetooth list and find that A, B, and C are all matched.

[0176] Specifically, Fig.11F As shown, when the Bluetooth list loop of A ends and E is moved into the Bluetooth inter-connection relationship table, the Bluetooth list of B will continue to loop. At this time, it will be found that A, B, and C included in the Bluetooth list of B have been matched successfully.

[0177] S7: Circulate the Bluetooth list of C and find that B and C are matched.

[0178] Specifically, Fig.11F As shown, after the loop of B's ​​Bluetooth list is completed, the loop of C's Bluetooth list can also find that B and C included in C's Bluetooth list have been matched.

[0179] S8: Circulate the Bluetooth list of D and find that A and D are matched.

[0180] Specifically, Fig.11FAs shown, after the loop of C's Bluetooth list is completed, the loop of D's Bluetooth list can also find that A and D included in D's Bluetooth list have also been matched.

[0181] S9: looping through the Bluetooth list of E and finding that the Bluetooth list of E is empty.

[0182] Specifically, Fig.11F As shown, after the Bluetooth list loop of D is completed, the Bluetooth list of E is looped, and it is found that the Bluetooth list of E is empty.

[0183] S10: looping through F's Bluetooth list, finding that A and F have not been matched, searching E in the Bluetooth inter-connection relationship table based on A, and F and E are matched successfully.

[0184] Specifically, Fig.11G As shown, after the loop of E's Bluetooth list is finished, the loop of F's Bluetooth list is found that A in F's Bluetooth list has not been matched with F, but A has been successfully matched with other terminals. Then, according to A, the Bluetooth inter-connection relationship table is searched to see if there is a terminal associated with A, that is, E, which has not been matched and is associated with A, can be found. Since both E and F are associated with A, it means that the distance between E and F is not far, so F and E can be successfully matched, and the matching result of E and F is stored in the Bluetooth matching result pool.

[0185] S11: looping through the Bluetooth list of G, finding that A and G have never been matched, and no result is found in the Bluetooth inter-connection relationship table based on A.

[0186] Specifically, Fig.11G As shown, after the loop of F's Bluetooth list is finished, G's Bluetooth list is looped, and it is found that A in G's Bluetooth list has not been matched with G, but A has been successfully matched with other terminals. Then, according to A, the Bluetooth inter-connection relationship table is searched to see if there is a terminal associated with A. However, since no corresponding result is found, G needs to be matched at this time.

[0187] Step 1012, position matching.

[0188] Specifically, when there are terminals without Bluetooth matching results in multiple sessions with different geographic fences but the same covered time range, location matching needs to be performed on these terminals.

[0189] Specifically, the geographical fences corresponding to the terminals without Bluetooth matching results are calculated based on the geographical location information of the terminals without Bluetooth matching results; multiple geographical fences around the target terminal are determined; the target terminal is any one of the terminals without Bluetooth matching results; the matching terminal closest to the target terminal in each of the geographical fences is determined; the matching terminal closest to the target terminal is determined as the target matching terminal from the matching terminals corresponding to the multiple geographical fences; the target terminal and the target matching terminal are the position matching results of the pairwise matching. In other words, a terminal closest to the target terminal can be determined from the geographical fences around the target terminal as the matching result of the target terminal.

[0190] Next, combine Figure 12A-12B The location matching process of terminal G is introduced.

[0191] Continued Fig.11G , since terminal G did not obtain a Bluetooth matching result, G falls into the location-based service (LBS) matching pool. In the embodiments of this specification, the LBS matching pool can also be understood as a storage space in the server. Of course, there will be terminals in the LBS matching pool that did not obtain Bluetooth matching results in other sessions. At this time, if the server needs to perform location matching on terminal G, it will traverse the LBS matching pool and find the nearest terminal according to the configured search radius. Specifically, Fig. 12B As shown, with the latitude and longitude of G as the center and r as the radius, the search is performed concurrently from the geo-fence where G is located and the 8 geo-fences around it. The terminal (terminal to be matched) closest to terminal G in the surrounding 8 geo-fences is determined. Fig. 12B It can be seen that the 7 terminals closest to terminal G in the 6 geographic fences within the search range can be searched, namely H, I, J, K, L, M, and N. Next, the distances between these 7 terminals and terminal G are calculated based on their geographic location information. Then the terminal corresponding to the minimum distance is matched with G. For example, due to Fig. 12B In the example, J is closest to G, so J is matched with G in the end, and the matching result is stored in the database. At this point, terminal J and terminal G are successfully matched after location matching. The server can match other terminals in the LBS matching pool in the above manner.

[0192] Step 1014, storing the matching results.

[0193] Specifically, the server may store the matching results of the Bluetooth matching in step 1010 and the position matching in step 1012 in a database, so that after multiple terminals in session 1 request the matching results, the server may directly send the matching results to the corresponding terminals.

[0194] In the embodiments of this specification, on the one hand, by ensuring that the terminals participating in the matching remain unchanged under the constraints of the matching time window, the same set of matching algorithms is used for each terminal to ensure that the matching results finally obtained by each terminal are consistent. On the other hand, in the embodiments of this specification, the first terminal that initiates a request to query the matching results to the server can trigger the server to start calculating the group matching results, and save all the matching results under the session after the end, and quickly obtain the matching results when other terminals in the session initiate a request to query the matching results, which can support the concurrent scenario, that is, support data access of a large number of terminals at the same time. On the other hand, the complete user information under the session is pieced together through the Bluetooth scanning information reported by each terminal, and the nearby terminals are matched based on the Bluetooth scanning information. At the same time, LBS matching is used as a supplementary solution for Bluetooth matching, and the boundary problem is avoided by scanning the eight surrounding geographic fences during the LBS matching process. Face-to-face accurate matching is achieved, which increases the fun of users participating in activities, further promotes users to drive people around them to participate in activities, and achieves the promotion purpose of merchants.

[0195] Please refer to Fig.13 , which provides a data processing device. The data processing device 130 includes:

[0196] The acquisition module 1310 is used to acquire user data sent by multiple terminals; wherein the user data includes a user identifier corresponding to the terminal and user identifiers of other terminals within the Bluetooth search range of the terminal;

[0197] A matching module 1320 is used to group and match the multiple terminals based on the user data sent by the multiple terminals; wherein each group includes at least two terminals, the distance between the at least two terminals does not exceed a preset threshold, and the matching results of the at least two terminals are consistent;

[0198] The sending module 1330 is used to send the above group matching result to the corresponding terminal.

[0199] In a possible implementation, the user data further includes geographic location information and a timestamp corresponding to the terminal; the timestamp is the time when the terminal sends the user data.

[0200] In a possible implementation, the matching module 1320 includes:

[0201] A first determining unit, configured to determine the session information corresponding to each of the terminals based on the user data sent by the multiple terminals;

[0202] The first matching unit is used to group and match multiple terminals with the same session information.

[0203] In a possible implementation manner, the first determining unit includes:

[0204] A first determining subunit, configured to determine whether there is a first target session based on the timestamp and the geographic location information of each terminal, wherein the time range covered by the first target session includes the timestamp;

[0205] A second determining subunit is configured to determine, if the first target session exists, that the first target session is a session corresponding to the terminal;

[0206] A third determining subunit is configured to determine whether a second target session exists based on the timestamp and the geographic location information if the first target session does not exist, and the start time of the second target session is later than the start time of the first target session;

[0207] a fourth determining subunit, configured to determine, if the second target session exists, that the second target session is the session corresponding to the terminal;

[0208] a fifth determining subunit, configured to generate a target session based on the timestamp and the geographic location information if the second target session does not exist, and determine that the target session is the session corresponding to the terminal; the earliest time of the time range covered by the target session is not later than the time corresponding to the timestamp;

[0209] Among them, the length of the time range covered by the first target session, the length of the time range covered by the second target session, and the length of the time range covered by the target session are equal.

[0210] In a possible implementation, the user data further includes Bluetooth signal strengths of other terminals within the Bluetooth search range of the terminal;

[0211] The device 130 further includes: a sorting module, configured to sort the user data according to the Bluetooth signal strength;

[0212] The first matching unit is specifically used for grouping and matching the multiple terminals with the same session information according to the order of the user data.

[0213] In a possible implementation, the first matching unit is specifically configured to: perform Bluetooth matching on the multiple terminals with the same session information according to the order of the user data to obtain pairwise Bluetooth matching results;

[0214] The above-mentioned matching module also includes: a second matching unit, which is used to perform position matching on the terminals without Bluetooth matching results in multiple sessions if there are terminals without Bluetooth matching results in the above-mentioned multiple sessions, so as to obtain position matching results that match each other; wherein the time range covered by the above-mentioned multiple sessions is the same.

[0215] In a possible implementation, the second matching unit includes:

[0216] A calculation subunit, configured to calculate the geographical fences corresponding to the terminals without Bluetooth matching results according to the geographical location information of the terminals without Bluetooth matching results;

[0217] A sixth determination subunit is used to determine a plurality of geographic fences around a target terminal; the target terminal is any one of the terminals without a Bluetooth matching result;

[0218] A seventh determination subunit, configured to respectively determine the to-be-matched terminal that is closest to the target terminal in each of the geographic fences;

[0219] An eighth determination subunit is used to determine, from among the terminals to be matched corresponding to the plurality of geographical fences, a terminal to be matched closest to the target terminal as a target matching terminal;

[0220] The target terminal and the target matching terminal are the position matching results of the pairwise matching.

[0221] In a possible implementation, the device 130 further includes:

[0222] A receiving module, configured to receive a request for querying matching results sent by a target terminal; the target terminal is any one of the multiple terminals;

[0223] A judgment module, configured to respond to the request for querying the matching result and judge whether the time at which the target terminal sends the request for querying the matching result is later than the latest time of the session corresponding to the target terminal;

[0224] The sending module 1330 is specifically configured to send the group matching result of the target terminal to the target terminal if the time at which the target terminal sends the request for querying the matching result is later than the latest time of the session corresponding to the target terminal.

[0225] In a possible implementation, the matching module 1320 includes:

[0226] A second determining unit, configured to determine whether there is a matching result corresponding to the above session according to the session information corresponding to the above target terminal;

[0227] The third matching unit is configured to group and match the plurality of terminals based on user data sent by a plurality of terminals having the same session information as the target terminal if there is no matching result for the session corresponding to the target terminal.

[0228] The division of each module in the above-mentioned data processing device is only for illustration. In other embodiments, the data processing device can be divided into different modules as needed to complete all or part of the functions of the above-mentioned data processing device. The implementation of each module in the data processing device provided in the embodiments of this specification can be in the form of a computer program. The computer program can be run on a terminal or a server. The program modules constituted by the computer program can be stored in the memory of the terminal or the server. When the computer program is executed by the processor, all or part of the steps of the data processing method described in the embodiments of this specification are implemented.

[0229] See also Fig.14 , Fig.14 A schematic diagram of the structure of an electronic device provided in an embodiment of this specification is shown.

[0230] like Fig.14 As shown, the electronic device 140 may include: at least one processor 1401, at least one communication bus 1402, a user interface 1403, at least one network interface 1404, and a memory 1405. The communication bus 1402 may be used to realize the connection and communication of the above components.

[0231] The user interface 1403 may include a display screen (Display) and a camera (Camera), and the optional user interface may also include a standard wired interface and a wireless interface.

[0232] The network interface 1404 may optionally include a Bluetooth module, an NFC module, a Wi-Fi module, etc.

[0233] Among them, the processor 1401 may include one or more processing cores. The processor 1401 uses various interfaces and lines to connect various parts within the entire electronic device 140, and executes various functions and processes data of the routing device 140 by running or executing instructions, programs, code sets or instruction sets stored in the memory 1405, and calling data stored in the memory 1405. Optionally, the processor 1401 can be implemented in at least one hardware form of DSP, FPGA, and PLA. The processor 1401 can integrate one or a combination of CPU, GPU, modem, etc. Among them, the CPU mainly processes the operating system, user interface, and application programs; the GPU is responsible for rendering and drawing the content to be displayed on the display screen; the modem is used to process wireless communications. It can be understood that the above-mentioned modem may not be integrated into the processor 1401, and it can be implemented separately through a chip.

[0234] Among them, the memory 1405 may include RAM and ROM. Optionally, the memory 1405 includes a non-transitory computer-readable medium. The memory 1405 can be used to store instructions, programs, codes, code sets or instruction sets. The memory 1405 may include a program storage area and a data storage area, wherein the program storage area may store instructions for implementing an operating system, instructions for at least one function (such as a sending function, a matching function, a receiving function, etc.), instructions for implementing the above-mentioned various method embodiments, etc.; the data storage area may store data involved in the above-mentioned various method embodiments, etc. The memory 1405 may also be optionally at least one storage device located away from the aforementioned processor 1401. As Fig.14 As shown, the memory 1405 as a computer storage medium may include an operating system, a network communication module, a user interface module, and a data processing application program.

[0235] Specifically, the processor 1401 may be used to call the data processing application stored in the memory 1405, and specifically perform the following operations:

[0236] Acquire user data sent by multiple terminals; wherein the user data includes user identifiers corresponding to the terminals and user identifiers of other terminals within the Bluetooth search range of the terminals.

[0237] The multiple terminals are grouped and matched based on the user data sent by the multiple terminals; wherein each group includes at least two terminals, the distance between the at least two terminals does not exceed a preset threshold, and the matching results of the at least two terminals are consistent.

[0238] The above group matching results are sent to the corresponding terminal.

[0239] In some possible embodiments, the user data further includes geographic location information and a timestamp corresponding to the terminal; the timestamp is the moment when the terminal sends the user data.

[0240] In some possible embodiments, when the processor 1401 performs group matching on the multiple terminals based on the user data sent by the multiple terminals, specifically performs:

[0241] Based on the user data sent by the above-mentioned multiple terminals, the session information corresponding to each of the above-mentioned terminals is determined,

[0242] Multiple terminals with the same session information are grouped and matched.

[0243] In some possible embodiments, when the processor 1401 determines the session information corresponding to each of the above-mentioned terminals based on the user data sent by the above-mentioned multiple terminals, it specifically executes:

[0244] Based on the timestamp and the geographic location information of each terminal, it is determined whether a first target session exists, and a time range covered by the first target session includes the timestamp.

[0245] If the first target session exists, the first target session is determined to be the session corresponding to the terminal.

[0246] If the first target session does not exist, it is determined whether a second target session exists based on the timestamp and the geographic location information, and the start time of the second target session is later than the start time of the first target session.

[0247] If the second target session exists, the second target session is determined to be the session corresponding to the terminal.

[0248] If the second target session does not exist, a target session is generated based on the timestamp and the geographic location information, and the target session is determined to be the session corresponding to the terminal; the earliest time in the time range covered by the target session is no later than the time corresponding to the timestamp.

[0249] Among them, the length of the time range covered by the first target session, the length of the time range covered by the second target session, and the length of the time range covered by the target session are equal.

[0250] In some possible embodiments, the user data further includes Bluetooth signal strengths of other terminals within the Bluetooth search range of the terminal; before the processor 1401 performs group matching on the multiple terminals based on the user data sent by the multiple terminals, it is further configured to perform:

[0251] The user data is sorted according to the Bluetooth signal strength.

[0252] When the processor 1401 performs grouping and matching of multiple terminals with the same session information, it is specifically configured to perform: grouping and matching of the multiple terminals with the same session information according to the sorting of the user data.

[0253] In some possible embodiments, when the processor 1401 performs grouping and matching of the multiple terminals with the same session information according to the sorting of the user data, it is specifically configured to perform:

[0254] According to the order of the user data, Bluetooth matching is performed on the multiple terminals with the same session information to obtain pairwise Bluetooth matching results.

[0255] After executing grouping and matching the multiple terminals with the same session information according to the sorting of the user data, the processor 1401 is further configured to execute:

[0256] If there is user data without Bluetooth matching results in multiple sessions, position matching is performed on the user data without Bluetooth matching results in the above multiple sessions to obtain position matching results that are matched pairwise; wherein the time ranges covered by the above multiple sessions are the same.

[0257] In some possible embodiments, when the processor 1401 performs location matching for the terminals without Bluetooth matching results in the above multiple sessions, it is specifically used to perform:

[0258] The geographic fences corresponding to the terminals without Bluetooth matching results are calculated according to the geographic location information of the terminals without Bluetooth matching results.

[0259] Determine multiple geographic fences around a target terminal; the target terminal is any one of the terminals without Bluetooth matching results.

[0260] The terminal to be matched that is closest to the target terminal in each of the geographic fences is determined respectively.

[0261] A terminal to be matched closest to the target terminal is determined as a target matching terminal from among the terminals to be matched corresponding to each of the plurality of geographic fences.

[0262] The target terminal and the target matching terminal are the position matching results of the pairwise matching.

[0263] In some possible embodiments, before the processor 1401 performs group matching on the multiple terminals based on the user data sent by the multiple terminals, it is further configured to perform:

[0264] A request for querying matching results sent by a target terminal is received; the target terminal is any one of the multiple terminals.

[0265] In response to the request for querying the matching results, it is determined whether the time at which the target terminal sends the request for querying the matching results is later than the latest time of the session corresponding to the target terminal.

[0266] When the processor 1401 executes to send the above-mentioned group matching result to the corresponding terminal, it is specifically used to execute: if the time when the above-mentioned target terminal sends the request for querying the matching result is later than the latest time of the session corresponding to the above-mentioned target terminal, then the group matching result of the above-mentioned target terminal is sent to the above-mentioned target terminal.

[0267] In some possible embodiments, when the processor 1401 performs group matching on the multiple terminals based on the user data sent by the multiple terminals, it is specifically configured to perform:

[0268] Determine whether there is a matching result corresponding to the above session according to the session information corresponding to the target terminal.

[0269] If not, the plurality of terminals are grouped and matched based on the user data sent by the plurality of terminals having the same session information as the target terminal.

[0270] The embodiments of this specification also provide a computer-readable storage medium, which stores instructions, and when the instructions are executed on a computer or a processor, the computer or the processor executes one or more steps in the above embodiments. If the components of the above electronic device are implemented in the form of software functional units and sold or used as independent products, they can be stored in the computer-readable storage medium.

[0271] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of this specification is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted through the computer-readable storage medium. The computer instructions can be transmitted from a website site, computer, server or data center to another website site, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (Digital Subscriber Line, DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server, data center, etc. that contains one or more available media integrated. The available medium may be a magnetic medium (eg, a floppy disk, a hard disk, a magnetic tape), an optical medium (eg, a digital versatile disc (DVD)), or a semiconductor medium (eg, a solid state disk (SSD)).

[0272] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through a computer program, and the program can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. The aforementioned storage medium includes: ROM, RAM, magnetic disk or optical disk and other media that can store program codes. In the absence of conflict, the technical features in this embodiment and the implementation scheme can be combined arbitrarily.

[0273] The embodiments described above are merely preferred embodiments of this specification and are not intended to limit the scope of this specification. Without departing from the design spirit of this specification, various modifications and improvements made to the technical solutions of this specification by ordinary technicians in this field should fall within the scope of protection determined by the claims of this specification.

[0274] The above is a description of a specific embodiment of the present specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in an order different from that in the embodiments and still achieve the desired results. In addition, the processes depicted in the drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.

Claims

1. A data processing method, comprising: Acquire user data sent by multiple terminals; wherein the user data includes a user identifier corresponding to the terminal and user identifiers of other terminals within the Bluetooth search range of the terminal; the user data also includes geographic location information and a timestamp corresponding to the terminal; the timestamp is the time when the terminal sends the user data; Grouping and matching the multiple terminals based on the user data sent by the multiple terminals; wherein each group includes at least two terminals, the distance between the at least two terminals does not exceed a preset threshold, and the matching results of the at least two terminals are consistent; Sending the group matching result to the corresponding terminal; The grouping and matching the multiple terminals based on the user data sent by the multiple terminals includes: Determine the session information corresponding to each of the terminals based on the user data sent by the multiple terminals; Group and match multiple terminals with the same session information; The determining, based on the user data sent by the multiple terminals, the session information corresponding to each of the terminals includes: Determine whether there is a first target session based on the timestamp and the geographic location information of each terminal, where the time range covered by the first target session includes the timestamp; If the first target session exists, determining that the first target session is the session corresponding to the terminal; If the first target session does not exist, determining whether a second target session exists based on the timestamp and the geographic location information, wherein the start time of the second target session is later than the start time of the first target session; If the second target session exists, the second target session is determined to be the session corresponding to the terminal.

2. The method according to claim 1, wherein determining the session information corresponding to each of the terminals based on the user data sent by the multiple terminals further comprises: If the second target session does not exist, generating a target session based on the timestamp and the geographic location information, and determining that the target session is a session corresponding to the terminal; The earliest time in the time range covered by the target session is no later than the time corresponding to the timestamp; The length of the time range covered by the first target session, the length of the time range covered by the second target session, and the length of the time range covered by the target session are equal.

3. The method according to claim 1 or 2, wherein the user data further includes Bluetooth signal strengths of other terminals within the Bluetooth search range of the terminal; Before grouping and matching the multiple terminals based on the user data sent by the multiple terminals, the method further includes: sorting the user data according to the Bluetooth signal strength; The grouping and matching the multiple terminals with the same session information includes: grouping and matching the multiple terminals with the same session information according to the order of the user data.

4. The method according to claim 3, wherein grouping and matching the multiple terminals having the same session information according to the order of the user data comprises: Performing Bluetooth matching on multiple terminals with the same session information according to the order of the user data to obtain pairwise matching Bluetooth matching results; After grouping and matching the multiple terminals with the same session information according to the order of the user data, the method further includes: If there are terminals without Bluetooth matching results in multiple sessions, position matching is performed on the terminals without Bluetooth matching results in the multiple sessions to obtain position matching results that are matched pairwise; wherein the multiple sessions cover the same time range.

5. The method according to claim 4, wherein the performing location matching on the terminals without Bluetooth matching results in the multiple sessions comprises: Calculate the geographical fence corresponding to each terminal without Bluetooth matching result according to the geographical location information of the terminal without Bluetooth matching result; Identify multiple geo-fences around the target terminal; The target terminal is any one of the terminals without Bluetooth matching results; Determine respectively the terminal to be matched that is closest to the target terminal in each of the geographic fences; Determine, from among the terminals to be matched corresponding to the plurality of geographical fences, a terminal to be matched closest to the target terminal as a target matching terminal; The target terminal and the target matching terminal are the position matching results of the pairwise matching.

6. The method according to claim 1 or 2, before grouping and matching the multiple terminals based on the user data sent by the multiple terminals, the method further comprises: Receiving a request for query matching results sent by a target terminal; The target terminal is any one of the multiple terminals; In response to the request for the query matching result, determining whether the time at which the target terminal sends the request for the query matching result is later than the latest time of the session corresponding to the target terminal; The sending of the group matching result to the corresponding terminal includes: if the time when the target terminal sends the request for querying the matching result is later than the latest time of the session corresponding to the target terminal, sending the group matching result of the target terminal to the target terminal.

7. The method according to claim 6, wherein grouping and matching the multiple terminals based on the user data sent by the multiple terminals comprises: Determine whether there is a matching result for the session corresponding to the target terminal according to the session information corresponding to the target terminal; If not, the plurality of terminals are grouped and matched based on the user data sent by the plurality of terminals having the same session information as the target terminal.

8. A data processing device, comprising: An acquisition module, used to acquire user data sent by multiple terminals; wherein the user data includes a user identifier corresponding to the terminal and user identifiers of other terminals within the Bluetooth search range of the terminal; the user data also includes geographical location information and a timestamp corresponding to the terminal; the timestamp is the time when the terminal sends the user data; A matching module, configured to group and match the multiple terminals based on the user data sent by the multiple terminals; wherein each group includes at least two terminals, the distance between the at least two terminals does not exceed a preset threshold, and the matching results of the at least two terminals are consistent; A sending module, used for sending the group matching result to a corresponding terminal; The matching module comprises: A first determining unit, configured to determine the session information corresponding to each of the terminals based on the user data sent by the multiple terminals; A first matching unit, used for grouping and matching multiple terminals with the same session information; The first determining unit includes: A first determining subunit, configured to determine whether there is a first target session based on the timestamp and the geographic location information of each terminal, wherein a time range covered by the first target session includes the timestamp; A second determining subunit, configured to determine that the first target session is a session corresponding to the terminal if the first target session exists; a third determining subunit, configured to determine, if the first target session does not exist, whether a second target session exists based on the timestamp and the geographic location information, and the start time of the second target session is later than the start time of the first target session; The fourth determining subunit is configured to determine, if the second target session exists, that the second target session is a session corresponding to the terminal.

9. The apparatus according to claim 8, wherein the first determining unit further comprises: a fifth determining subunit, configured to generate a target session based on the timestamp and the geographic location information if the second target session does not exist, and determine that the target session is the session corresponding to the terminal; the earliest time of the time range covered by the target session is not later than the time corresponding to the timestamp; The length of the time range covered by the first target session, the length of the time range covered by the second target session, and the length of the time range covered by the target session are equal.

10. The device according to claim 8 or 9, wherein the user data further includes Bluetooth signal strengths of other terminals within the Bluetooth search range of the terminal; The device also includes: A sorting module, used to sort the user data according to the Bluetooth signal strength; The first matching unit is specifically configured to group and match the multiple terminals having the same session information according to the order of the user data.

11. The device according to claim 10, wherein the first matching unit is specifically configured to: perform Bluetooth matching on multiple terminals with the same session information according to the order of the user data to obtain pairwise Bluetooth matching results; The matching module further includes: The second matching unit is used to perform position matching on the terminals without Bluetooth matching results in multiple sessions if there are terminals without Bluetooth matching results in the multiple sessions, so as to obtain position matching results that match each other; wherein the time ranges covered by the multiple sessions are the same.

12. The device according to claim 11, wherein the second matching unit comprises: A calculation subunit, configured to calculate the geographical fences corresponding to the terminals without Bluetooth matching results according to the geographical location information of the terminals without Bluetooth matching results; a sixth determining subunit, configured to determine a plurality of geographic fences around a target terminal; The target terminal is any one of the terminals without Bluetooth matching results; A seventh determination subunit, configured to respectively determine a terminal to be matched that is closest to the target terminal in each of the geographic fences; An eighth determining subunit is used to determine, from among the terminals to be matched corresponding to the plurality of geographical fences, a terminal to be matched closest to the target terminal as a target matching terminal; The target terminal and the target matching terminal are the position matching results of the pairwise matching.

13. The device according to claim 8 or 9, further comprising: A receiving module, used for receiving a request for query matching results sent by a target terminal; The target terminal is any one of the multiple terminals; A judgment module, configured to judge, in response to the request for the query matching result, whether the time at which the target terminal sends the request for the query matching result is later than the latest time of the session corresponding to the target terminal; The sending module is specifically configured to send the group matching result of the target terminal to the target terminal if the time at which the target terminal sends the request for querying the matching result is later than the latest time of the session corresponding to the target terminal.

14. The device according to claim 13, wherein the matching module comprises: A second determining unit, configured to determine whether there is a matching result for the session corresponding to the target terminal according to the session information corresponding to the target terminal; The third matching unit is configured to group and match the multiple terminals based on user data sent by multiple terminals with the same session information as the target terminal if there is no matching result for the session corresponding to the target terminal.

15. An electronic device, comprising: Processor and memory; The processor is connected to the memory; The memory is used to store executable program code; The processor runs a program corresponding to the executable program code by reading the executable program code stored in the memory, so as to execute the method according to any one of claims 1 to 7.

16. A computer storage medium storing a plurality of instructions, wherein the instructions are suitable for being loaded by a processor and executing the method steps according to any one of claims 1 to 7.

17. A computer program product comprising instructions, which, when the computer program product is run on a computer or a processor, causes the computer or the processor to perform the method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Method and system for reserving online-reserved interurban coach based on close-range Bluetooth connection

    CN107645718A

  • User matching method and device, electronic equipment and medium

    CN112717374A