Method for acquiring waiting duration, electronic equipment and storage medium
By detecting the user's face image in the waiting area and combining the user identification list, it is determined whether the waiting time acquisition method is a key image of the target area, which solves the problem of low accuracy of waiting time in the prior art and improves user satisfaction.
Patent Information
- Application Number
- CN202510063559.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-15
- Publication Date
- 2025-05-13
- Estimated Expiration
- 2045-01-15
AI Technical Summary
The existing waiting time acquisition method fails to effectively consider people who do not need to requeuing to enter the target area again, resulting in a low accuracy of the calculated waiting time and affecting user satisfaction.
By detecting that a new user appears in the waiting area and continues to appear for a preset duration, obtain his facial image as the target image, and combine the current first, second and third user identification lists to determine whether the target image is a key image of the target area and calculate the waiting time.
Improve the accuracy of waiting time acquisition, consider the number of users who can enter the target area again without queuing, and enhance user satisfaction.
Smart Images

Figure CN119991384A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of data processing, and in particular to a method for obtaining a waiting time, an electronic device and a storage medium. Background Art
[0002] Waiting time is an important factor affecting user satisfaction. In some service places (such as hospitals, banks, etc.), it is also an important indicator to measure the management level of these places. At present, most waiting time acquisition methods mainly predict the waiting time corresponding to each queuer based on the number of people waiting to enter the target area, the queueing order of the queuers, and the historical stay time of a single queuer in the target area. However, the method does not take into account those people who can re-enter the target area without re-queuing (for example, patients who return after temporarily leaving for examination or consultation). When the number of such people who can re-enter the target area without re-queuing reaches a certain amount, it will directly affect the actual waiting time of the people who are waiting to enter the target area for the first time, and may cause the calculated waiting time to be less than the actual waiting time. Therefore, the accuracy of the waiting time obtained by the above method is low, which may reduce user satisfaction. Summary of the invention
[0003] In view of the above technical problems, the technical solution adopted by the present invention is:
[0004] According to a first aspect of the present invention, a method for obtaining a waiting time is provided, the method comprising the following steps:
[0005] S1. When a new user is detected to appear in the waiting area, and the duration of the new user's continuous appearance in the waiting area reaches a preset duration, and the facial image of the new user can be obtained, the facial image of the new user is used as the target image E, wherein the new user is the user entering the waiting area, and each time a user enters the waiting area, he or she is regarded as a new user.
[0006] S2. Determine whether the target image E is a key image corresponding to the target area according to the target image E, the current first-category user identification list set A, the current second-category user identification list set B, and the current third-category user identification list set C, wherein A = {A1, A2, ..., A i , …, A m}, A i ={A i1 , A i2 , …, A ij , …, A in(i)}, A i D i The corresponding first category user identification list, A ij For the current Ai The jth first-class user ID in the A, j ranges from 1 to n(i), and n(i) is the current A i The number of first-class user identifiers in D i is the i-th target area identifier in the target area identifier list D, D = {D1, D2, ..., D i , …, D m}, i ranges from 1 to m, m is the number of target area identifiers, and the coverage of any two different target areas does not overlap. B = {B1, B2, ..., B i , …, B m}, B i = {B i1 , B i2 , …, B ie , …, B if(i)}, B i D i The corresponding second category user identification list, B ie For the current B i The e-th second-class user identifier in the B, where the value of e ranges from 1 to f(i), and f(i) is the current B i The number of second-class user identifiers in C = {C1, C2, ..., C i , …, C m}, C i ={C i1 , C i2 , …, C ir , …, C is(i)}, C i D i The corresponding third category user identification list, C ir For the current C i The rth third-category user ID in the , r ranges from 1 to s(i), s(i) is the current C i The number of third-category user identifiers in the first category, the first category of users are users who are waiting in line to enter the target area for the first time, the second category of users are users who can enter the target area again without queuing, and the third category of users are users who are waiting in line to enter the target area again; step S2 includes the following steps S21-S24:
[0007] S21. If there is no F ij ≥F 0 , then get the target images E and B ie The image similarity G between corresponding facial images ie , F ij For target images E and A ij The image similarity between corresponding facial images, F 0 is the preset similarity threshold.
[0008] S22, if G ie ≥F 0 , then determine that the target image E is D i The key image corresponding to the target area, and B ie Insert into D i The corresponding fourth category user identification list; if G does not exist ie ≥F 0 , then get the target images E and C ir The image similarity H between corresponding facial images ir .
[0009] S23, if H ir ≥F 0 , then get the current time point and X ir The time difference between ir , X ir C ir The corresponding estimated task completion time.
[0010] S24, if K ir ≤K 0 , then determine that the target image E is D i The corresponding target area corresponds to the key image, and C ir Insert into D i The corresponding fourth category user identification list, where K 0 The preset time difference.
[0011] S3. If the target image E is D i The key image corresponding to the target area is obtained at the current time point D i The number L of the fourth category user identifiers in the fourth category user identifier list corresponding to the target area identifier of the corresponding target area i .
[0012] S4, if L i ≥L 0 , then get A ij The corresponding waiting time P ij , L 0 is the preset number of user identifiers, P ij Meet the following conditions: P ij =(j-1)×t1+L i × t2, t1 is the first preset waiting time, and t2 is the second preset waiting time.
[0013] According to a second aspect of the present invention, a non-transitory computer-readable storage medium is provided, in which a computer program is stored. The computer program is loaded and executed by a processor to implement the aforementioned method.
[0014] According to a third aspect of the present invention, there is provided an electronic device, comprising: a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the processor implements the aforementioned method when executing the computer program.
[0015] The present invention has at least the following beneficial effects:
[0016] The present invention provides a method for obtaining a waiting time, an electronic device and a storage medium. When a new user is detected to appear in a waiting area and the time for which the new user continues to appear in the waiting area reaches a preset time, and a facial image of the new user can be obtained, the facial image of the new user is used as a target image, and a fourth-category user identification corresponding to the target area is obtained according to the similarity between the target image and the facial image corresponding to the current first-category user identification, the similarity between the target image and the facial image corresponding to the current second-category user identification, and the similarity between the target image and the facial image corresponding to the current third-category user identification, and it is determined whether the target image is a key image of the target area, wherein the first-category user is a user who queues to enter the target area for the first time; the second-category user is a user who can enter the target area again without queuing; the third-category user is a user who queues to enter the target area again; and the fourth-category user is a user who is in the waiting area at the current time point and can enter the target area again without queuing. When the target image is a key image of the target area, the number of fourth-category user identifiers in the fourth-category user identifier list corresponding to the target area is obtained, and when the number of the fourth-category user identifiers is not less than the preset number of user identifiers, the waiting time corresponding to the first-category user identifier corresponding to the target area is calculated based on the order of the first-category user identifiers in the first-category user identifier list corresponding to the target area, the first preset waiting time, the second preset waiting time, and the number of the fourth-category user identifiers. It can be seen that in the process of obtaining the waiting time, the present invention takes into account the number of users who are in the waiting area at the current time point and can enter the target area again without queuing, which is conducive to improving the accuracy of the obtained waiting time, and thus is conducive to improving user satisfaction. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0018] Figure 1 A flowchart of a method for obtaining waiting time provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0019] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.
[0020] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar tasks, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. 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 server that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products, or devices.
[0021] The embodiment of the present invention provides a method for obtaining the waiting time. Figure 1 As shown, the method comprises the following steps:
[0022] S1. When a new user is detected to appear in the waiting area, and the duration of the new user's continuous appearance in the waiting area reaches a preset duration, and at the same time, the facial image of the new user can be obtained, the facial image of the new user is used as the target image E, wherein those skilled in the art know that the preset duration is a duration pre-set by those skilled in the art according to actual needs, for example: 30 seconds, 40 seconds, 50 seconds, which will not be repeated here.
[0023] In the above steps, the preset duration can be flexibly adjusted according to the actual situation, thereby avoiding the impact caused by misidentification due to a short passage.
[0024] Specifically, a new user is a user who enters the waiting area. Whenever a user enters the waiting area, he or she will be regarded as a new user, regardless of whether the user has entered the waiting area before. Even if the user leaves the waiting area halfway, when the user enters the waiting area again, he or she will still be regarded as a new user to avoid omissions.
[0025] Specifically, when a new user is detected to appear in the waiting area, and the new user continues to appear in the waiting area for a preset time, but the facial image of the new user cannot be obtained, the new user is continuously monitored, and once the facial image of the new user can be obtained, the facial image of the new user is used as the target image E.
[0026] Specifically, a video acquisition device is provided in the waiting area, and the video acquisition device acquires the video in the waiting area in real time and continuously uploads the acquired video stream.
[0027] S2. Determine whether the target image E is a key image corresponding to the target area according to the target image E, the current first-category user identification list set A, the current second-category user identification list set B, and the current third-category user identification list set C, wherein A = {A1, A2, ..., A i , …, A m}, A i ={A i1 , A i2 , …, A ij , …, A in(i)}, A i D i The corresponding first category user identification list, A ij For the current A i The jth first-class user ID in the A, j ranges from 1 to n(i), and n(i) is the current A i The number of first-class user identifiers in D i is the i-th target area identifier in the target area identifier list D, D = {D1, D2, ..., D i , …, D m}, i ranges from 1 to m, m is the number of target area identifiers, B = {B1, B2, ..., B i , …, B m}, B i = {B i1 , B i2 , …, B ie , …, B if(i)}, B i D i The corresponding second category user identification list, B ie For the current B i The e-th second-class user identifier in the B, where the value of e ranges from 1 to f(i), and f(i) is the current B i The number of second-class user identifiers in C = {C1, C2, ..., C i , …, C m}, C i ={C i1 , Ci2 , …, C ir , …, C is(i)}, C i D i The corresponding third category user identification list, C ir For the current C i The rth third-category user ID in the , r ranges from 1 to s(i), s(i) is the current C i The number of third-category user identifiers in .
[0028] Specifically, the first type of user identification is the identity identification of the first type of user, and the first type of user is the user who is waiting in line to enter the target area for the first time; the second type of user identification is the identity identification of the second type of user, and the second type of user is the user who can enter the target area again without queuing; the third type of user identification is the identity identification of the third type of user, and the third type of user is the user who is waiting in line to enter the target area again.
[0029] Specifically, the target area identifier is a unique identifier of the target area.
[0030] Furthermore, the target area is adjacent to the waiting area, and the user needs to pass through the waiting area to enter the target area.
[0031] Furthermore, the coverage of any two different target areas does not overlap.
[0032] Specifically, before step S2, the following steps S01-S04 are also included to obtain A, B and C:
[0033] S01. When receiving user information uploaded by a smart terminal, the user identifier in the user information is used as a first-category user identifier, and the first-category user identifier is inserted into a first-category user identifier list corresponding to a target area identifier corresponding to the user identifier, wherein the user information at least includes a user identifier, a facial image of the user, contact information of the user, and a target area identifier corresponding to the user identifier, and the above are only some of the examples given, and there may be other user information, such as: user name, user age, which will not be repeated here.
[0034] Specifically, the intelligent terminal is arranged outside the waiting area.
[0035] Specifically, after the first type of user identification is inserted into the first type of user identification list, the initial waiting time T corresponding to the first type of user identification is obtained, and T meets the following conditions:
[0036] T=(SL-1)×t1, wherein SL is the number of first-category user identifiers in the first-category user identifier list after the first-category user identifier is inserted into the first-category user identifier list, and t1 is the first preset waiting time.
[0037] In a specific embodiment, the first preset waiting time is a time preset by those skilled in the art according to actual needs, for example, 15 minutes, 20 minutes, which will not be described in detail here.
[0038] In a specific embodiment, the first preset waiting time can be calculated based on the average length of time that the first type of users stay in the target area during a historical period of time, which will not be described in detail here.
[0039] Further, based on T, a notification text T corresponding to the first type of user identifier corresponding to T is generated. 0 , and use the contact information corresponding to the first type of user identifier to send T 0 Sent to the first category of users corresponding to the first category of user identifiers.
[0040] Specifically, T 0 To notify T 0 The corresponding first type of users, their current waiting time is T.
[0041] Specifically, after the first category user identification is inserted into the first category user identification list, the initial waiting time is obtained according to the number of the first category user identifications in the first category user identification list. It can be understood that when the first category users start to queue up, an initial waiting time is obtained according to the number of people currently in the queue. When the target image is a key image of the target area, the number of the fourth category user identifications in the fourth category user identification list corresponding to the target area is obtained. When the number of the fourth category user identifications is not less than the preset number of user identifications, based on the order of the first category user identifications in the first category user identification list corresponding to the target area, the first preset waiting time, the second preset waiting time, etc. The waiting time and the number of the fourth category user identifiers are used to calculate the waiting time corresponding to the first category user identifier corresponding to the target area. Otherwise, no processing is performed. Even if the number of the fourth category user identifiers in the fourth category user identifier list corresponding to the target area is not met, the waiting time can be obtained if the number of the fourth category user identifiers is not less than the preset number of user identifiers, thereby avoiding the situation where the waiting time cannot be obtained all the time. A notification text corresponding to the first category user identifier corresponding to the waiting time is generated based on the waiting time, and the notification text is sent to the first category user corresponding to the first category user identifier through the contact method corresponding to the first category user identifier, which is conducive to improving user satisfaction.
[0042] Specifically, the first user identification list is a first-in-first-out queue.
[0043] Specifically, after the smart terminal is started, the first user identification list, the second user identification list and the third user identification list corresponding to the target area identification are automatically generated, and the first user identification list, the second user identification list and the third user identification list are initially NULL.
[0044] Specifically, when the user completes information confirmation on the smart terminal, the smart terminal will upload the user information of the user.
[0045] S02, when receiving A ij When the corresponding task identifiers to be executed are combined, A ij From A i , and A ij Insert into C i In which, the combination of task identifiers to be executed includes several task identifiers to be executed, and the task identifier to be executed is a unique identity identifier of the task to be executed.
[0046] Specifically, when A ij The corresponding first type of users enter D i After the corresponding target area, located at D i The task allocation personnel in the corresponding target area will assign tasks to A based on the user's actual situation. ij The corresponding first-class user is assigned several tasks to be executed, and the task identifier combination composed of the task identifiers of the tasks to be executed and A ij Input to set in D i In the terminal device in the corresponding target area, when D i The terminal device in the corresponding target area receives A ij and A ij When the corresponding task identifier combination is completed, upload A ij and A ij The corresponding combination of task identifiers to be executed.
[0047] S03, according to C ir The corresponding task identifier combination U ir and the preset task execution time mapping list V, obtain C ir The corresponding target task execution time W ir , V={V1,V2,…,V g , …, V h},V g = {V g1 , V g2},V g is the gth preset task execution time mapping combination, where g ranges from 1 to h, and h is the number of preset task execution time mapping combinations. g1 V gThe preset task identification combination in the preset task identification combination includes several preset task identifications, V g2 V g1 The corresponding preset task execution time, where U ir All pending task identifiers and V g1 When all the preset task identifiers in are completely consistent, let W ir =V g2 ; For example: If U ir The tasks to be executed in are identified as ID 1, ID 2, ID 3 and ID 4, V g1 The tasks to be executed in are marked as mark 2, mark 3, mark 1 and mark 4, then W ir =V g2 .
[0048] In a specific embodiment, the preset task execution duration mapping list is a list pre-set by those skilled in the art according to actual needs, which will not be described in detail here.
[0049] In a specific embodiment, the preset task execution time mapping list can be calculated based on the average value of the combination of to-be-executed task identifiers corresponding to the third category of users and the task completion time corresponding to the third category of users within the historical time period. The task completion time corresponding to the third category of users is the time between the time point when the third category of users starts to execute their corresponding to-be-executed tasks and the time point when the task results of all their corresponding to-be-executed tasks are obtained. No further details are given here.
[0050] S04. Get C ir The corresponding estimated task completion time point X ir , and in X ir When you arrive, C ir From C i Delete it and set C ir Insert into B i Among them, X ir Meet the following conditions:
[0051] X ir =DQ ir +W ir , DQ ir C ir Inserted into C i time point in the .
[0052] Through the above steps, the first category of users are users who are waiting in line to enter the target area for the first time; the second category of users are users who can enter the target area again without queuing; the third category of users are users who are waiting in line to enter the target area again. Based on the user information uploaded by the smart terminal, the combination of to-be-executed task identifiers corresponding to the first category of user identifiers, and the estimated task completion time points corresponding to the third category of user identifiers, the first category of user identifier lists, the second category of user identifier lists, and the third category of user identifier lists are continuously updated, and the user identifiers of users of the same category are divided into the same list, which lays a foundation for obtaining the fourth category of user identifier lists corresponding to the target area and determining whether the target image is a key image corresponding to the target area according to the target image, the current first category of user identifier list set, the current second category of user identifier list set, and the current third category of user identifier list set.
[0053] Specifically, step S2 includes the following steps S21-S24:
[0054] S21. If there is no F ij ≥F 0 , then get the target images E and B ie The image similarity G between corresponding facial images ie , F ij For target images E and A ij The image similarity between corresponding facial images, F 0 is the preset similarity threshold. If there is F ij ≥F 0 , it is determined that the target image E is not the key image corresponding to the target area, wherein those skilled in the art know that any method of obtaining the image similarity between two images in the prior art belongs to the protection scope of the present invention and will not be described in detail here.
[0055] Specifically, F 0 The value range of is [0.8, 1).
[0056] Specifically, the key image corresponding to the target area can be understood as: a facial image of a user that may cause the waiting time of the first type of users in the target area to be prolonged.
[0057] Through the above steps, if the image similarity between the target image and the facial image corresponding to the first type of user identification is not less than the preset similarity threshold, it means that the user corresponding to the target image and the first type of user corresponding to the first type of user identification are the same user, that is, the new user entering the waiting area is the first type of user, and the entry of the user will not prolong the waiting time of the first type of users in the target area. Therefore, the target image is not the key image corresponding to the target area. If there is no target image with an image similarity corresponding to the first type of user identification less than the preset similarity threshold, it means that the user corresponding to the target image is not the first type of user. At this time, it is necessary to further determine whether the user corresponding to the target image is a second type of user.
[0058] S22, if G ie ≥F 0 , then determine that the target image E is D i The key image corresponding to the target area, and B ie Insert into D i The corresponding fourth category user identification list; if G does not exist ie ≥F 0 , then get the target images E and C ir The image similarity H between corresponding facial images ir .
[0059] Through the above steps, if the image similarity between the target image and the facial image corresponding to the second type of user identification is not less than the preset similarity threshold, it means that the user corresponding to the target image and the second type of user corresponding to the second type of user identification are the same user, that is, the user entering the waiting area is a user who can enter the target area again without queuing, and the entry of the user may prolong the waiting time of the first type of users in the target area. Therefore, the target image is the key image corresponding to the target area. If the image similarity between the target image and the facial image corresponding to the second type of user identification is less than the preset similarity threshold, it means that the user corresponding to the target image is not a second type of user either. At this time, it is necessary to further determine whether the user corresponding to the target image is a third type of user.
[0060] S23, if H ir ≥F 0 , then get the current time point and X ir The time difference between ir If there is no H ir ≥F 0 , it is determined that the target image E is not the key image corresponding to the target area.
[0061] S24, if K ir ≤K 0 , then determine that the target image E is D iThe corresponding target area corresponds to the key image, and C ir Insert into D i The corresponding fourth category user identification list, where K 0 It is a preset time difference. Those skilled in the art know that the preset time difference is a time difference pre-set by those skilled in the art according to actual needs, for example: 1 minute, 2 minutes, which will not be repeated here.
[0062] Through the above steps, if the image similarity between the target image and the facial image corresponding to the third category user identifier is not less than the preset similarity threshold, it means that the user corresponding to the target image and the third category user corresponding to the third category user identifier are the same user. At this time, the time difference between the current time point and the estimated task completion time point corresponding to the third category user identifier is obtained. When the estimated task completion time point corresponding to the third category user identifier is reached, the third category user has obtained the execution results of all the tasks to be executed. At this time, the third category user will become a second category user. Therefore, if the time difference between the current time point and the estimated task completion time point corresponding to the third category user identifier is not greater than the preset time difference, This indicates that at this time, the third category user corresponding to the third category user identifier has most likely obtained the execution results of all the tasks to be executed and can enter the target area again without queuing. Therefore, the user corresponding to the target image entering the waiting area will most likely prolong the waiting time of the first category users in the target area. Therefore, the target image is the key image corresponding to the target area. If the image similarity between the target image and the facial image corresponding to the third category user identifier is less than the preset similarity threshold, it indicates that the user corresponding to the target image is not a third category user either. The user corresponding to the target image entering the waiting area will not prolong the waiting time of the first category users in the target area. Therefore, the target image is not the key image corresponding to the target area.
[0063] Specifically, if the duration between the insertion time point corresponding to the fourth category user identifier and the current time point is not less than the preset duration, the fourth category user identifier is deleted from the fourth category user identifier list where the fourth category user identifier is located, and the insertion time point corresponding to the fourth category user identifier is the time point when the fourth category user identifier is inserted into the fourth category user identifier list, wherein the preset duration is a duration pre-set by a technician in this field according to actual needs, for example: 20 minutes, 30 minutes, which will not be repeated here.
[0064] Specifically, the fourth category user identification list includes several fourth category user identifications, where the fourth category user identifications are identity identifications of fourth category users, and the fourth category users are users who are in the waiting area at the current time point and can enter the target area again without queuing.
[0065] Through the above steps, when the duration between the insertion time point corresponding to the fourth type of user identifier and the current time point is not less than the preset duration, the fourth type of user identifier is deleted to avoid the situation where the fourth type of user has left the target area and the waiting area, but the corresponding fourth type of user identifier still exists in the fourth type of user identifier list, which is conducive to improving the accuracy of obtaining the waiting time.
[0066] Specifically, after the intelligent terminal is started, a fourth category user identification list corresponding to the target area identification is automatically generated, and the fourth category user identification list is initially NULL.
[0067] In a specific embodiment, if K ir >K 0 , then the user corresponding to the target image is continuously monitored. If ir Before the target image arrives, if the user corresponding to the target image leaves the waiting area, no processing will be performed. Otherwise, ir When arriving, determine that the target image E is D i The corresponding target area corresponds to the key image, and C ir Insert into D i In the corresponding fourth category user identification list, the user corresponding to the target image is continuously monitored. When the user corresponding to the target image can affect the waiting time of the first category of users in the target area, the target image is used as a key image to avoid misjudgment.
[0068] S3. If the target image E is D i The key image corresponding to the target area is obtained at the current time point D i The number L of the fourth category user identifiers in the fourth category user identifier list corresponding to the target area identifier of the corresponding target area i .
[0069] Specifically, if the target image E is not the key image corresponding to the target area, no processing is performed.
[0070] S4, if L i ≥L 0 , then get A ij The corresponding waiting time P ij , L 0 is the preset number of user identifiers, P ij Meet the following conditions:
[0071] P ij =(j-1)×t1+L i × t2, t2 is the second preset waiting time. Those skilled in the art know that the preset number of user identifiers is the number of user identifiers pre-set by those skilled in the art according to actual needs, for example: 3, 4, 5, which will not be repeated here.
[0072] Specifically, t2<t1.
[0073] In a specific embodiment, the second preset waiting time is a time pre-set by a technician in this field according to actual needs. For example, if the first preset waiting time is 10 minutes, then the second preset waiting time is 5 minutes; if the first preset waiting time is 20 minutes, then the second preset waiting time is 10 minutes, which will not be repeated here.
[0074] Specifically, the first preset waiting time can be understood as: the predicted length of time that the first type of users stay in the target area; the second preset waiting time can be understood as: the predicted length of time that the fourth type of users stay in the target area. Since the first type of users are users waiting in line to enter the target area for the first time, and the fourth type of users are users who are in the waiting area at the current time point and can enter the target area again without queuing, that is, the fourth type of users have already entered the target area. Therefore, the length of time that the fourth type of users stay in the target area should be less than the length of time that the first type of users stay in the target area.
[0075] Specifically, if L i <L 0 , no processing is performed.
[0076] Specifically, based on P ij Generate A ij Corresponding notification text Q ij , and through A ij The corresponding contact information will be Q ij Send to A ij The corresponding first type of users.
[0077] Specifically, Q ij To notify A ij The corresponding first type of users, whose current waiting time is P ij .
[0078] Through the above steps, when a new user is detected to appear in the waiting area, and the time for which the new user continues to appear in the waiting area reaches a preset duration, and the facial image of the new user can be obtained, the facial image of the new user is used as the target image, and according to the similarity between the target image and the facial image corresponding to the current first-category user identifier, the similarity between the target image and the facial image corresponding to the current second-category user identifier, and the similarity between the target image and the facial image corresponding to the current third-category user identifier, the fourth-category user identifier corresponding to the target area is obtained, and it is determined whether the target image is a key image of the target area, wherein the first-category user is a user who is waiting in line to enter the target area for the first time; the second-category user is a user who can enter the target area again without queuing; the third-category user is a user who is waiting in line to enter the target area again; and the fourth-category user is a user who is in the waiting area at the current time point and can enter the target area again without queuing. When the target image is a key image of the target area, the number of fourth-category user identifiers in the fourth-category user identifier list corresponding to the target area is obtained, and when the number of the fourth-category user identifiers is not less than the preset number of user identifiers, the waiting time corresponding to the first-category user identifier corresponding to the target area is calculated based on the order of the first-category user identifiers in the first-category user identifier list corresponding to the target area, the first preset waiting time, the second preset waiting time, and the number of the fourth-category user identifiers, a notification text corresponding to the first-category user identifier corresponding to the waiting time is generated based on the waiting time, and the notification text is sent to the first-category user corresponding to the first-category user identifier through the contact method corresponding to the first-category user identifier, taking into account the number of users who are in the waiting area at the current time point and can enter the target area again without queuing, which is conducive to improving the accuracy of the obtained waiting time, and further conducive to improving user satisfaction.
[0079] In a specific application scenario, the waiting area may be a waiting area, the first type of users may be people who have just seen a doctor, the second type of users may be people who are currently able to have a follow-up visit, the third type of users may be people who are waiting in line to get the test results before having a follow-up visit, the target area may be a consulting room, the smart terminal may be a sign-in machine, the tasks to be executed may be items that need to be checked, the identifiers of the tasks to be executed may be the names of the items that need to be checked, the task assignors in the target area may be doctors in the consulting room, and the fourth type of users may be people who are currently in the waiting area and are currently able to have a follow-up visit. When someone enters the waiting area and continues to appear in the waiting area for a preset duration, the facial image of this person is used as the target image; when the user completes the sign-in on the sign-in machine, the user is used as the first type of user. When the first type of user completes the consultation in the consulting room, the doctor will enter the name of the examination item into the computer, and the computer will send it to the server. At this time, the first type of user is used as the third type of user. When the third type of user has completed all the examination items and obtained the results of all the examination items, the The third category of users, as the second category of users, determines whether the target image is a key image corresponding to the target area based on the target image and the facial images of the first category of users, the facial images of the second category of users, and the facial images of the third category of users, and obtains the fourth category of users corresponding to the target area. When the target image is the key image of the target area, it means that the entry of the user corresponding to the target image will affect the waiting time of the first category of users in the target area. At this time, the waiting time corresponding to the first category of user identifier corresponding to the target area identifier is calculated according to the number of fourth category user identifiers corresponding to the target area identifier, the order of the first category user identifier in the list of first category user identifiers corresponding to the target area identifier, the first preset waiting time and the second preset waiting time. A notification text corresponding to the first category of user identifier is generated based on the waiting time, and the notification text is sent to the first category of users through the communication method corresponding to the first category of user identifier. Taking into account the number of users who are in the waiting area at the current time point and can enter the target area again without queuing, it is beneficial to improve the accuracy of the obtained waiting time, and thus it is beneficial to improve user satisfaction.
[0080] An embodiment of the present invention also provides a non-transitory computer-readable storage medium, which can be set in an electronic device to store a computer program related to a method in a method embodiment, and the computer program is loaded and executed by the processor to implement the method provided in the above embodiment.
[0081] An embodiment of the present invention further provides an electronic device, comprising: a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the processor implements the method provided in the above embodiment when executing the computer program.
[0082] An embodiment of the present invention further provides a computer program product, which includes program code. When the program product is run on an electronic device, the program code is used to enable the electronic device to execute the steps of the method according to various exemplary embodiments of the present invention described above in this specification.
[0083] The present invention provides a method for obtaining a waiting time, an electronic device and a storage medium. When a new user is detected to appear in a waiting area and the time for which the new user continues to appear in the waiting area reaches a preset time, and a facial image of the new user can be obtained, the facial image of the new user is used as a target image, and a fourth-category user identification corresponding to the target area is obtained according to the similarity between the target image and the facial image corresponding to the current first-category user identification, the similarity between the target image and the facial image corresponding to the current second-category user identification, and the similarity between the target image and the facial image corresponding to the current third-category user identification, and it is determined whether the target image is a key image of the target area, wherein the first-category user is a user who queues to enter the target area for the first time; the second-category user is a user who can enter the target area again without queuing; the third-category user is a user who queues to enter the target area again; and the fourth-category user is a user who is in the waiting area at the current time point and can enter the target area again without queuing. When the target image is a key image of the target area, the number of fourth-category user identifiers in the fourth-category user identifier list corresponding to the target area is obtained, and when the number of the fourth-category user identifiers is not less than the preset number of user identifiers, the waiting time corresponding to the first-category user identifier corresponding to the target area is calculated based on the order of the first-category user identifiers in the first-category user identifier list corresponding to the target area, the first preset waiting time, the second preset waiting time, and the number of the fourth-category user identifiers. It can be seen that in the process of obtaining the waiting time, the present invention takes into account the number of users who are in the waiting area at the current time point and can enter the target area again without queuing, which is conducive to improving the accuracy of the obtained waiting time, and thus is conducive to improving user satisfaction.
[0084] Although some specific embodiments of the present invention have been described in detail by way of example, it should be understood by those skilled in the art that the above examples are only for illustration, not for limiting the scope of the present invention. It should also be understood by those skilled in the art that various modifications may be made to the embodiments without departing from the scope and spirit of the present invention.
Claims
1. A method for obtaining a waiting time, characterized in that: The method comprises the following steps: S1. When a new user is detected to appear in the waiting area, and the duration of the new user's continuous appearance in the waiting area reaches a preset duration, and a facial image of the new user can be obtained, the facial image of the new user is used as the target image E, wherein the new user is the user entering the waiting area, and each time a user enters the waiting area, the user is regarded as a new user; S2. Determine whether the target image E is a key image corresponding to the target area according to the target image E, the current first-category user identification list set A, the current second-category user identification list set B, and the current third-category user identification list set C, wherein A = {A1, A2, ..., A i , …, A m }, A i ={A i1 , A i2 , …, A ij , …, A in(i) }, A i D i The corresponding first category user identification list, A ij For the current A i The jth first-class user ID in the A, j ranges from 1 to n(i), and n(i) is the current A i The number of first-class user identifiers in D i is the i-th target area identifier in the target area identifier list D, D = {D1, D2, ..., D i , …, D m }, i ranges from 1 to m, m is the number of target area identifiers, and the coverage of any two different target areas does not overlap. B = {B1, B2, ..., B i , …, B m }, B i = {B i1 , B i2 , …, B ie , …, B if(i) }, B i D i The corresponding second category user identification list, B ie For the current B i The e-th second-class user identifier in the B, where the value of e ranges from 1 to f(i), and f(i) is the current B i The number of second-class user identifiers in C = {C1, C2, ..., C i , …, C m }, C i ={C i1 , C i2 , …, C ir , …, C is(i) }, C i D i The corresponding third category user identification list, C ir For the current C i The rth third-category user ID in the , r ranges from 1 to s(i), s(i) is the current C i The number of third-category user identifiers in the first category, the first category of users are users who are waiting in line to enter the target area for the first time, the second category of users are users who can enter the target area again without queuing, and the third category of users are users who are waiting in line to enter the target area again; step S2 includes the following steps S21-S24: S21. If there is no F ij ≥F 0 , then get the target images E and B ie The image similarity G between corresponding facial images ie , F ij For target images E and A ij The image similarity between corresponding facial images, F 0 is the preset similarity threshold; S22, if G ie ≥F 0 , then determine that the target image E is D i The key image corresponding to the target area, and B ie Insert into D i The corresponding fourth category user identification list; if G does not exist ie ≥F 0 , then get the target images E and C ir The image similarity H between corresponding facial images ir ; S23, if H ir ≥F 0 , then get the current time point and X ir The time difference between ir , X ir C ir The corresponding estimated task completion time; S24, if K ir ≤K 0 , then determine that the target image E is D i The corresponding target area corresponds to the key image, and C ir Insert into D i The corresponding fourth category user identification list, where K 0 is the preset time difference; S3. If the target image E is D i The key image corresponding to the target area is obtained at the current time point D i The number L of the fourth category user identifiers in the fourth category user identifier list corresponding to the target area identifier of the corresponding target area i ; S4, if L i ≥L 0 , then get A ij The corresponding waiting time P ij , L 0 is the preset number of user identifiers, P ij Meet the following conditions: P ij =(j-1)×t1+L i × t2, t1 is the first preset waiting time, t2 is the second preset waiting time.
2. The method for obtaining the waiting time according to claim 1, characterized in that: The target area identifier is a unique identifier of the target area. The target area is adjacent to the waiting area, and the user must pass through the waiting area to enter the target area.
3. The method for obtaining the waiting time according to claim 1, characterized in that: In step S21, it also includes: if there is F ij ≥F 0 , it is determined that the target image E is not the key image corresponding to the target area.
4. The method for obtaining the waiting time according to claim 1, characterized in that: In step S23, it also includes: if there is no H ir ≥F 0 , it is determined that the target image E is not the key image corresponding to the target area.
5. The method for obtaining the waiting time according to claim 1, characterized in that: F 0 The value range of is [0.8, 1).
6. The method for obtaining the waiting time according to claim 1, characterized in that: The fourth category user identification list includes several fourth category user identifications, where the fourth category user identifications are identity identifications of fourth category users, and the fourth category users are users who are in the waiting area at the current time point and can enter the target area again without queuing.
7. The method for obtaining the waiting time according to claim 1, characterized in that: The first preset waiting time is the predicted length of time that the first type of users stay in the target area, and the second preset waiting time is the predicted length of time that the fourth type of users stay in the target area.
8. The method for obtaining the waiting time according to claim 1, characterized in that: t2<t1。 9. A non-transitory computer-readable storage medium, characterized in that: The storage medium stores a computer program, which is loaded and executed by a processor to implement the method for obtaining the waiting time as described in any one of claims 1 to 8.
10. An electronic device, comprising: A processor, a memory, and a computer program stored in the memory and executable on the processor, wherein the processor implements the method for obtaining the waiting time as described in any one of claims 1 to 8 when executing the computer program.
Citation Information
Patent Citations
Taxi queuing management method and system, and computer readable storage medium
CN108492551A
Queuing duration detection method, device and system
CN111046769A
Identification task processing method, electronic equipment and storage medium
CN116469025A
Method and device for determining waiting duration
CN117314961A
Method and apparatus for determining queuing waiting time
WO2023077783A1