Single-trip movement time determination method and device, equipment, storage medium and product

By acquiring and analyzing acceleration, gyroscope, and geomagnetic signals, the problem of smartwatches struggling to identify the duration of a single swim has been solved, enabling accurate determination of swimming time.

CN121003791APending Publication Date: 2025-11-25SHENZHEN DO INTELLIGENT TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511143438.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-15
Publication Date
2025-11-25

AI Technical Summary

Technical Problem

Existing smartwatches struggle to accurately track the time of a single swim in swimming scenarios due to factors such as water resistance, irregular movements, and noise interference from sensor signals.

Method used

By acquiring acceleration signals, gyroscope signals, and geomagnetic signals, feature extraction and data analysis are performed to determine the turnaround time in order to calculate the single-trip travel time.

Benefits of technology

It accurately identifies the user's single lap time in the lane, providing the convenience of swimming back and forth within a preset time period.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121003791A_ABST
    Figure CN121003791A_ABST
Patent Text Reader

Abstract

The invention relates to a single-trip exercise time determination method and device, equipment, a storage medium and a product. The method comprises the following steps: acquiring an acquisition signal of a historical motion time period and a current moment; the acquisition signal comprises at least one of an acceleration signal, a gyroscope signal and a geomagnetic signal; performing feature extraction on the acquired signal to obtain an acquired signal feature; and carrying out data analysis on the acquired signal characteristics to obtain single-trip movement time. According to the method, the acceleration signal, the gyroscope signal and the geomagnetic signal are collected, the characteristics corresponding to the acceleration signal, the gyroscope signal and the geomagnetic signal are extracted, and the acceleration characteristics, the gyroscope characteristics and the geomagnetic characteristics are subjected to data analysis, so that the single-trip movement time of the user in the lane can be accurately determined; and great convenience is provided for the user who does the turn-back swimming exercise in the preset time period.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of data processing technology, and in particular to a method, apparatus, device, storage medium and product for determining the time of a single trip. Background Technology

[0002] As a complex sport, swimming presents numerous challenges to its monitoring technology. For professional athletes or users who require specific swimming skills, determining the duration of each lap within the lane after completing a preset time period of back-and-forth swimming has become a hot topic of concern.

[0003] Currently, although existing smartwatches are equipped with sensors such as accelerometers and gyroscopes to capture motion data, in swimming scenarios, factors such as water resistance, irregular movements, and sensor signal noise interference make it difficult to recognize swimming laps.

[0004] Therefore, determining the time for a single trip has become a pressing technical problem that needs to be solved. Summary of the Invention

[0005] Therefore, it is necessary to provide a method, device, equipment, storage medium, and product for determining the single-trip travel time after a user completes a round trip within a preset time period, which can accurately identify the travel time of each segment.

[0006] Firstly, this application provides a method for determining the time of a single trip, including:

[0007] Acquire signals from historical motion periods and the current moment; the acquired signals include at least one of acceleration signals, gyroscope signals, and geomagnetic signals;

[0008] Feature extraction is performed on the acquired signal to obtain the acquired signal features;

[0009] Data analysis is performed on the characteristics of the collected signals to obtain the time for a single trip.

[0010] In one embodiment, when the acquired signal is an acceleration signal or a geomagnetic signal, the above-mentioned feature extraction of the acquired signal to obtain the acquired signal features includes:

[0011] Based on the current acceleration / geomagnetic signal, the first target time's acceleration / geomagnetic signal, and the cumulative acceleration / geomagnetic signal between the first candidate time and the first target time, determine the cumulative acceleration / geomagnetic signal between the first candidate time and the current time;

[0012] The first target moment refers to the moment in the historical motion period that is closest to the current moment; the first candidate moment refers to the moment in the historical motion period that is closest to the current moment, which is the peak / trough.

[0013] In one embodiment, the above-mentioned data analysis of the acquired signal characteristics to obtain the single-trip travel time includes:

[0014] If the cumulative acceleration signal / cumulative geomagnetic signal between the first candidate time and the current time is greater than the preset acceleration threshold / preset geomagnetic threshold, then the current time is determined to be the turnaround time;

[0015] The time for a single trip is determined based on the start time of the movement / target turnaround time and the turnaround time; the target turnaround time refers to the turnaround time that is most recent in the historical movement time period.

[0016] In one embodiment, when the acquired signal is a gyroscope signal, the above-mentioned feature extraction of the acquired signal to obtain acquired signal features includes:

[0017] Based on the gyroscope signal at the current time and the cumulative gyroscope signal between the second candidate time and the second target time, determine the cumulative gyroscope signal between the second candidate time and the current time;

[0018] The second target moment refers to the moment closest to the current moment in the historical motion period; the second candidate moment refers to the moment when the motion started / the moment when the turnaround was closest to the current moment in the historical motion period.

[0019] In one embodiment, the above-mentioned data analysis of the acquired signal characteristics to obtain the single-trip travel time includes:

[0020] If the cumulative gyroscope signal between the second candidate time and the current time is greater than the cumulative gyroscope signal between the second candidate time and the second target time, and the cumulative gyroscope signal between the second candidate time and the second target time is less than the cumulative gyroscope signal between the second candidate time and the third target time; or, if the cumulative gyroscope signal between the second candidate time and the current time is less than the cumulative gyroscope signal between the second candidate time and the second target time, and the cumulative gyroscope signal between the second candidate time and the second target time is greater than the cumulative gyroscope signal between the second candidate time and the third target time, then the current time is determined to be the turnaround time; the third target time refers to the time in the historical motion period that is closest to the second target time.

[0021] The time for a single trip is determined based on the start time of the movement / target turnaround time and the turnaround time; the target turnaround time refers to the turnaround time that is most recent in the historical movement time period.

[0022] In one embodiment, before performing feature extraction on the acquired signal to obtain the acquired signal features, the above method further includes:

[0023] The acquired signal is low-pass filtered to obtain the low-pass filtered acquired signal.

[0024] Secondly, this application also provides a device for determining the time of a single trip, comprising:

[0025] The acquisition module is used to acquire the collected signals during the historical motion time period and at the current moment; the collected signals include at least one of acceleration signals, gyroscope signals and geomagnetic signals;

[0026] The extraction module is used to extract features from the acquired signals to obtain the features of the acquired signals;

[0027] The analysis module is used to perform data analysis on the characteristics of the acquired signals to obtain the time for a single trip.

[0028] Thirdly, this application also provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to perform the following steps:

[0029] Acquire signals from historical motion periods and the current moment; the acquired signals include at least one of acceleration signals, gyroscope signals, and geomagnetic signals;

[0030] Feature extraction is performed on the acquired signal to obtain the acquired signal features;

[0031] Data analysis is performed on the characteristics of the collected signals to obtain the time for a single trip.

[0032] Fourthly, this application also provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, performs the following steps:

[0033] Acquire signals from historical motion periods and the current moment; the acquired signals include at least one of acceleration signals, gyroscope signals, and geomagnetic signals;

[0034] Feature extraction is performed on the acquired signal to obtain the acquired signal features;

[0035] Data analysis is performed on the characteristics of the collected signals to obtain the time for a single trip.

[0036] Fifthly, this application also provides a computer program product, including a computer program that, when executed by a processor, performs the following steps:

[0037] Acquire signals from historical motion periods and the current moment; the acquired signals include at least one of acceleration signals, gyroscope signals, and geomagnetic signals;

[0038] Feature extraction is performed on the acquired signal to obtain the acquired signal features;

[0039] Data analysis is performed on the characteristics of the collected signals to obtain the time for a single trip.

[0040] The above-mentioned method, apparatus, equipment, storage medium, and product for determining the single-trip swimming time. The method includes: acquiring signals from historical swimming time periods and the current moment; the acquired signals include at least one of acceleration signals, gyroscope signals, and geomagnetic signals; extracting features from the acquired signals to obtain acquired signal features; and performing data analysis on the acquired signal features to obtain the single-trip swimming time. This method, by acquiring acceleration signals, gyroscope signals, and geomagnetic signals, extracting features corresponding to each of the acceleration, gyroscope, and geomagnetic signals, and performing data analysis on the acceleration, gyroscope, and geomagnetic features respectively, can accurately determine the user's single-trip swimming time in the lane, providing great convenience for users performing back-and-forth swimming within a preset time period. Attached Figure Description

[0041] To more clearly illustrate the technical solutions in the embodiments of this application or related technologies, the drawings used in the description of the embodiments of this application or related technologies will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.

[0042] Figure 1 This is an application environment diagram of a method for determining the time of a single trip in one embodiment;

[0043] Figure 2 This is a flowchart illustrating a method for determining the time of a single trip in one embodiment;

[0044] Figure 3 This is a flowchart illustrating the method for determining the time of a single trip in another embodiment;

[0045] Figure 4 This is a flowchart illustrating the method for determining the time of a single trip in another embodiment;

[0046] Figure 5 This is a flowchart illustrating the method for determining the time of a single trip in another embodiment;

[0047] Figure 6 This is a structural block diagram of a device for determining the time of a single trip in one embodiment. Detailed Implementation

[0048] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0049] As a complex sport, swimming presents numerous challenges to its monitoring technology. For professional athletes or users who require specific swimming skills, determining the duration of each lap within the lane after completing a preset time period of back-and-forth swimming has become a hot topic of concern.

[0050] Currently, while existing smartwatches are equipped with sensors such as accelerometers and gyroscopes to capture motion data, in swimming scenarios, factors such as water resistance, irregular movements, and sensor signal noise interference make it difficult to identify the duration of each lap. Therefore, determining the duration of a single lap has become an urgent technical problem to be solved. This application provides a method for determining the duration of each lap after a user completes a round trip within a preset time period, aiming to solve the aforementioned problem.

[0051] Having described the background technology of the method for determining the single-trip travel time provided in the embodiments of this application, the implementation environment involved in the method for determining the single-trip travel time provided in the embodiments of this application will be briefly described below. The method for determining the single-trip travel time provided in the embodiments of this application can be applied to, for example... Figure 1 The internal structure diagram of the computer device shown can be as follows: Figure 1As shown, the computer device includes a processor, memory, input / output interfaces, a communication interface, a display unit, and an input device. The processor, memory, and input / output interfaces are connected via a system bus, and the communication interface, display unit, and input device are also connected to the system bus via the input / output interfaces. The processor provides computational and control capabilities. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores the operating system and computer programs. The internal memory provides the environment for the operation of the operating system and computer programs in the non-volatile storage media. The input / output interfaces are used for exchanging information between the processor and external devices, including compact discs (CDs), digital versatile discs (DVDs), or universal serial bus (USB) flash drives. The communication interface is used for wired or wireless communication with external terminals; wireless communication can be achieved through Wi-Fi, mobile cellular networks, near field communication (NFC), or other technologies. When executed by the processor, the computer program implements a method for determining the time of a single trip. The display unit of this computer device is used to form a visually visible image and can be a display screen, a projection device, or a virtual reality imaging device. The display screen can be an LCD screen or an e-ink screen. The input device of this computer device can be a touch layer covering the display screen, or buttons, a trackball, or a touchpad set on the casing of the computer device, or an external keyboard, touchpad, or mouse, etc.

[0052] The technical solution of this application and how the technical solution of this application solves the above-mentioned technical problems are described in detail below with specific embodiments. These specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments. The embodiments of this application will now be described with reference to the accompanying drawings.

[0053] In one embodiment, such as Figure 2 As shown, a method for determining the time of a single trip is provided, which can be applied to... Figure 1 Taking a computer device as an example, the explanation includes the following steps:

[0054] S201. Acquire the historical motion time period and the current moment's acquisition signal; the acquisition signal includes at least one of acceleration signal, gyroscope signal and geomagnetic signal.

[0055] Among them, the historical motion time refers to the time between the moment the user started moving and the current moment. The acceleration signal can be obtained by the acceleration (ACC) sensor installed on the smartwatch worn by the user. The gyroscope signal can be obtained by the gyroscope (GYRO) sensor installed on the smartwatch worn by the user. The geomagnetic signal can be obtained by the magnetometer (MAG) sensor installed on the smartwatch worn by the user.

[0056] In this embodiment, when a user needs to accurately determine the duration of a single swim within a swimming period, they can wear a smartwatch before swimming. The smartwatch is pre-set with an ACC sensor, a GYRO sensor, and a magnetometer. After the user starts swimming, it can acquire acceleration signals, gyroscope signals, and geomagnetic signals in real time to obtain acceleration signals, gyroscope signals, and geomagnetic signals at various moments within the historical swimming period, as well as acceleration signals, gyroscope signals, and geomagnetic signals at the current moment.

[0057] S202. Extract features from the acquired signals to obtain the features of the acquired signals.

[0058] In this embodiment, after acquiring the collected signal, features can be extracted from the collected signal based on a preset feature extraction model to obtain the collected signal features. It should be noted that the preset feature extraction model can be pre-trained based on a neural network model.

[0059] It should be noted that the extracted signal features need to be able to reflect the differences between the user's turning, interval, and normal swimming movements.

[0060] Optionally, if the acquired signal is an acceleration signal, feature extraction is performed on the acceleration signal to obtain acceleration signal features; if the acquired signal is a gyroscope signal, feature extraction is performed on the gyroscope signal to obtain gyroscope signal features; if the acquired signal is a geomagnetic signal, feature extraction is performed on the geomagnetic signal to obtain geomagnetic signal features. The rules for feature extraction for different acquired signals can be different or the same, and this embodiment does not impose any restrictions.

[0061] S203. Perform data analysis on the characteristics of the collected signals to obtain the time for a single trip.

[0062] In this embodiment, after obtaining the characteristics of the acquired signal, the acquired signal characteristics can be analyzed based on a preset data analysis method to obtain the single-trip travel time.

[0063] Optionally, if the acquired signal characteristics are acceleration signal characteristics, then the acceleration signal is analyzed to obtain the single-trip motion time; if the acquired signal characteristics are gyroscope signal characteristics, then the gyroscope signal is analyzed to obtain the single-trip motion time; if the acquired signal characteristics are geomagnetic signal characteristics, then the geomagnetic signal is analyzed to obtain the single-trip motion time. The methods for analyzing different acquired signal characteristics can be different or the same, and this embodiment does not impose any restrictions.

[0064] In this embodiment, addressing the problem that existing technologies cannot accurately determine the time of each single lap in the swimming lane after a user completes a round trip within a preset time period, this application collects acceleration signals, gyroscope signals, and geomagnetic signals, extracts the features corresponding to these signals, and performs data analysis on the acceleration, gyroscope, and geomagnetic features. This allows for accurate determination of the user's single lap time in the swimming lane, providing great convenience for users performing round trip swimming exercises within a preset time period.

[0065] In this embodiment, when the acquired signal is an acceleration signal or a geomagnetic signal, the detailed process of acquiring the characteristics of the acquired signal will be explained. In an exemplary embodiment, the above-mentioned S202 includes:

[0066] Based on the current acceleration / geomagnetic signal, the first target time's acceleration / geomagnetic signal, and the cumulative acceleration / geomagnetic signal between the first candidate time and the first target time, determine the cumulative acceleration / geomagnetic signal between the first candidate time and the current time.

[0067] The first target moment refers to the moment in the historical motion period that is closest to the current moment; the first candidate moment refers to the moment in the historical motion period that is closest to the current moment, which is the peak / trough.

[0068] In this embodiment, when the acquired signal is an acceleration signal, the cumulative acceleration signal between the first candidate time and the current time is determined based on the acceleration signal at the current time, the acceleration signal at the first target time, and the cumulative acceleration signal between the first candidate time and the first target time.

[0069] Optionally, during swimming, the acceleration signal will remain at a stable level. When the user makes movements such as turning or pausing, a significant peak will appear on the acceleration signal. Therefore, when extracting features from the acceleration signal, the features of continuous rise and fall of the value closest to the current moment can be accumulated, as shown in the following formulas (1) and (2):

[0070]

[0071]

[0072] in, This refers to the continuously rising cumulative acceleration signal between the first candidate moment and the current moment. Here, the first candidate moment refers to the moment in the historical motion time period where the nearest trough is located. This refers to the continuously rising cumulative acceleration signal between the first candidate time and the first target time. Here, the first target time refers to the time closest to the current time in the historical motion time period. It refers to the acceleration signal at the current moment. This refers to the acceleration signal at the first target moment; This refers to the continuously decreasing cumulative acceleration signal between the first candidate time point and the current time point. Here, the first candidate time point refers to the time point in the historical motion time period where the nearest peak to the current time point is located. It refers to the cumulative acceleration signal that decreases continuously between the first candidate time and the first target time. Here, the first target time refers to the time closest to the current time in the historical motion time period.

[0073] Optionally, due to the influence of the Earth's magnetic field, the geomagnetic signal will flip when the user turns around, but will remain relatively stable during normal swimming. Therefore, the continuous rise and fall of the value closest to the current moment can be accumulated, as shown in the following formulas (3) and (4):

[0074]

[0075]

[0076] in, This refers to the continuously rising cumulative geomagnetic signal between the first candidate time and the current time. Here, the first candidate time refers to the time of the trough that is closest to the current time in the historical motion period. This refers to the continuously rising cumulative geomagnetic signal between the first candidate time and the first target time. Here, the first target time refers to the time closest to the current time in the historical motion period. This refers to the geomagnetic signal at the current moment. This refers to the geomagnetic signal at the first target moment; This refers to the continuously decreasing cumulative geomagnetic signal between the first candidate moment and the current moment. Here, the first candidate moment refers to the moment in the historical motion period where the nearest peak is located. It refers to the continuously decreasing cumulative geomagnetic signal between the first candidate time and the first target time. Here, the first target time refers to the time closest to the current time in the historical motion period.

[0077] This embodiment provides a method for obtaining acceleration signal features and geomagnetic signal features, providing a data foundation for subsequent data analysis based on acceleration signal features and geomagnetic signal features to obtain the single-trip motion time.

[0078] In this embodiment, when the acquired signal is an acceleration signal or a geomagnetic signal, the detailed process of obtaining the single-trip travel time will be explained. In an exemplary embodiment, such as... Figure 3 As shown, the above steps include:

[0079] S301. If the cumulative acceleration signal / cumulative geomagnetic signal between the first candidate time and the current time is greater than the preset acceleration threshold / preset geomagnetic threshold, then the current time is determined to be the turnaround time.

[0080] In this embodiment, when the acquired signal is an acceleration signal, after the cumulative acceleration signal between the first candidate time and the current time is acquired, the cumulative acceleration signal between the first candidate time and the current time can be compared with a preset acceleration threshold. If the cumulative acceleration signal between the first candidate time and the current time is greater than the preset acceleration threshold, then the current time is determined to be the turnaround time.

[0081] For example, during swimming, the acceleration signal is stable during normal swimming, but during obvious intervals such as turning intervals, there will be a huge abrupt change in the peak value of the acceleration signal. In terms of signal characteristics, it is a clear peak that rises and then falls continuously, or a trough that falls and then rises continuously. That is, AccUp and AccDown reach the threshold AccThreshold at the same time, which satisfies the following formula (5):

[0082]

[0083] in, and It is based on a preset threshold for actual application, used to distinguish between minute fluctuations within the signal and significant differences between actual turning movements.

[0084] In this embodiment, when the collected signal is a geomagnetic signal, after the cumulative geomagnetic signal between the first candidate time and the current time is collected, the cumulative geomagnetic signal between the first candidate time and the current time can be compared with a preset geomagnetic threshold. If the cumulative geomagnetic signal between the first candidate time and the current time is greater than the preset geomagnetic threshold, then the current time is determined to be the return time.

[0085] For example, during swimming, the geomagnetic signal remains stable during normal swimming. However, during significant intervals such as turns, the relative position of the geomagnetic field reverses, resulting in a sharp abrupt change in the geomagnetic signal peak. This manifests as a distinct, continuously rising and then falling peak, or a continuously falling and then rising trough. and Simultaneously reaching the threshold That is, it satisfies the following formula (6):

[0086]

[0087] in, and It is based on a preset threshold for actual application, used to distinguish between minute fluctuations within the signal and significant differences between actual turning movements.

[0088] Optionally, if the cumulative acceleration signal / cumulative geomagnetic signal between the first candidate time and the current time is not greater than the preset acceleration threshold / preset geomagnetic threshold, then the current time is determined not to be a turnaround time.

[0089] S302. Determine the time for a single trip based on the start time of the movement / target turnaround time and the turnaround time; the target turnaround time refers to the turnaround time that is closest to the turnaround time in the historical movement time period.

[0090] In this embodiment, after determining the turnaround time, the time interval between the previous turnaround time and the turnaround time in the motion start time / historical motion time interval can be determined as the single-trip motion time.

[0091] Optionally, if the turnaround time is the first turnaround, the time between the start time of the movement and the turnaround time is determined as the single-trip movement time; if the turnaround time is not the first turnaround, the time between the most recent turnaround time in the historical movement time period and the current turnaround time is determined as the single-trip movement time.

[0092] This embodiment provides a specific implementation method for determining the single-trip time when acceleration signals or geomagnetic signals are collected, providing a theoretical basis for accurately determining the user's single-trip time in the swimming lane.

[0093] In this embodiment, when the acquired signal is a gyroscope signal, the detailed process of acquiring the characteristics of the acquired signal will be explained. In an exemplary embodiment, the above-mentioned S202 includes:

[0094] Based on the gyroscope signal at the current time and the cumulative gyroscope signal between the second candidate time and the second target time, determine the cumulative gyroscope signal between the second candidate time and the current time.

[0095] The second target moment refers to the moment closest to the current moment in the historical motion period; the second candidate moment refers to the moment when the motion started / the moment when the turnaround was closest to the current moment in the historical motion period.

[0096] In this embodiment, when the acquired signal is a gyroscope signal, the cumulative gyroscope signal between the second candidate time and the current time is determined based on the gyroscope signal at the current time and the cumulative gyroscope signal between the second candidate time and the second target time.

[0097] Optionally, during swimming, the signal remains stable during normal swimming, but during actions such as turning or turning around, there will be a large angle change, which is reflected in the data as a sudden change in the angular velocity result. Therefore, it is necessary to accumulate the gyroscope values ​​from the historical movement time period to the current moment, as shown in the following formula (7):

[0098]

[0099] in, This refers to the accumulated gyroscope signal between the second candidate time and the current time. The second candidate time is the most recent turnaround time within the historical motion period, which is the time when the motion started or during the motion's duration. It refers to the cumulative gyroscope signal between the second candidate time and the second target time. The second target time is the time closest to the current time in the historical motion time period.

[0100] This embodiment provides a method for obtaining gyroscope signal characteristics, which provides a data foundation for subsequent data analysis based on gyroscope signal characteristics to obtain the single-trip motion time.

[0101] In this embodiment, when the acquired signal is a gyroscope signal, the detailed process of obtaining the single-trip motion time will be explained. In an exemplary embodiment, such as... Figure 4 As shown, the above steps include:

[0102] S401. If the cumulative gyroscope signal between the second candidate time and the current time is greater than the cumulative gyroscope signal between the second candidate time and the second target time, and the cumulative gyroscope signal between the second candidate time and the second target time is less than the cumulative gyroscope signal between the second candidate time and the third target time, or if the cumulative gyroscope signal between the second candidate time and the current time is less than the cumulative gyroscope signal between the second candidate time and the second target time, and the cumulative gyroscope signal between the second candidate time and the second target time is greater than the cumulative gyroscope signal between the second candidate time and the third target time, then the current time is determined to be the turnaround time; the third target time refers to the time in the historical motion time period that is closest to the second target time.

[0103] In this embodiment, during swimming, due to the rotational periodicity of a single swimming stroke, the gyroscope value GyroSum accumulated from the historical motion time period to the current moment shows a monotonically increasing or monotonically decreasing trend. Only when the signal of a large movement such as a turn does not conform to the previous periodicity will a large angular velocity appear. This is manifested in the signal as the monotonicity of the gyroscope value GyroSum accumulated from the previous historical motion time period to the current moment being disrupted. By identifying this monotonicity change, swimming laps can be divided. For the specific process, please refer to the following formulas (8) and (9):

[0104]

[0105] or

[0106]

[0107] in, This refers to the accumulated gyroscope signal between the second candidate time and the current time. The second candidate time is the most recent turnaround time within the historical motion period, which is the time when the motion started or during the motion's duration. This refers to the accumulated gyroscope signal between the second candidate time and the second target time. The second target time is the time closest to the current time in the historical motion time period. It refers to the cumulative gyroscope signal between the second candidate time and the third target time. The third target time is the time in the historical motion period that is closest to the second target time.

[0108] S402. Determine the time for a single trip based on the start time of the movement / target turnaround time and the turnaround time; the target turnaround time refers to the turnaround time that is most recent in the historical movement time period.

[0109] In this embodiment, after determining the turnaround time, the time interval between the start time of the movement / target turnaround time and the turnaround time can be determined as the single-trip movement time.

[0110] Optionally, if the turnaround time is the first turnaround, the time between the start time of the movement and the turnaround time is determined as the single-trip movement time; if the turnaround time is not the first turnaround, the time between the most recent turnaround time in the historical movement time period and the current turnaround time is determined as the single-trip movement time.

[0111] This embodiment provides a specific implementation method for determining the single-trip motion time when gyroscope signals are acquired, providing a theoretical basis for accurately determining the user's single-trip motion time in the swimming lane.

[0112] In this embodiment, in the above Figure 2 Based on the illustrated embodiment, after acquiring the historical motion time period and the current moment's collected signal, the collected signal can be further processed. In an exemplary embodiment, such as... Figure 5 As shown, the above method also includes:

[0113] S204. Perform low-pass filtering on the acquired signal to obtain the low-pass filtered acquired signal.

[0114] During swimming, the acceleration, gyroscope, and geomagnetic signals generated by swimming movements are related to the instantaneous swimming posture in the short term, while the long-term performance of the signals is related to swimming turns and rest. Therefore, the acceleration, gyroscope, and geomagnetic signals are preprocessed to extract long-term features for use in swimming lap recognition.

[0115] In this embodiment, the acceleration signal, gyroscope signal, and geomagnetic signal are each subjected to low-pass filtering to obtain the low-pass filtered acquisition signal. Optionally, the cutoff frequency range of the low-pass filter can be between 1 and 10 Hz, depending on the effective range of the actual signal, in order to amplify the motion signal during each stroke as much as possible and filter out the periodic motion information and out-of-band noise during normal swimming. The filter order can be 2 to 5. Higher orders will bring more significant filtering effects, but will also increase the processing complexity.

[0116] In this embodiment, the acquired signal is low-pass filtered to provide a data basis for determining the turnaround time based on the low-pass filtered acquired signal, thereby ensuring the accuracy of the determined swimming single-trip time.

[0117] It should be understood that although the steps in the flowcharts of the embodiments described above are shown sequentially according to the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the embodiments described above may include multiple steps or multiple stages. These steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these steps or stages is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the steps or stages of other steps.

[0118] Based on the same inventive concept, this application also provides a device for determining the single-trip travel time to implement the method for determining the single-trip travel time described above. The solution provided by this device is similar to the solution described in the above method. Therefore, the specific limitations in one or more embodiments of the device for determining the single-trip travel time provided below can be found in the limitations of the method for determining the single-trip travel time described above, and will not be repeated here.

[0119] In one exemplary embodiment, such as Figure 6 As shown, a device for determining the time of a single trip is provided, comprising: an acquisition module 10, an extraction module 11, and an analysis module 12, wherein:

[0120] The acquisition module 10 is used to acquire the historical motion time period and the current moment's collected signals; the collected signals include at least one of acceleration signals, gyroscope signals and geomagnetic signals.

[0121] The extraction module 11 is used to extract features from the acquired signal to obtain the features of the acquired signal.

[0122] Analysis module 12 is used to perform data analysis on the characteristics of the acquired signals to obtain the single-trip motion time.

[0123] In an exemplary embodiment, when the acquired signal is an acceleration signal or a geomagnetic signal, the extraction module 11 includes:

[0124] The first determining unit is specifically used to determine the cumulative acceleration signal / cumulative geomagnetic signal between the first candidate time and the current time based on the acceleration signal / geomagnetic signal at the current time, the acceleration signal / geomagnetic signal at the first target time, and the cumulative acceleration signal / cumulative geomagnetic signal between the first candidate time and the first target time.

[0125] The first target moment refers to the moment in the historical motion period that is closest to the current moment; the first candidate moment refers to the moment in the historical motion period that is closest to the current moment, which is the peak / trough.

[0126] In an exemplary embodiment, the analysis module 12 is used to determine the current time as the turnaround time if the cumulative acceleration signal / cumulative geomagnetic signal between the first candidate time and the current time is greater than a preset acceleration threshold / preset geomagnetic threshold; and to determine the single-trip time based on the motion start time / target turnaround time and the turnaround time; the target turnaround time refers to the turnaround time most recently in the historical motion time period.

[0127] In an exemplary embodiment, when the acquired signal is a gyroscope signal, the extraction module 11 includes:

[0128] The second determining unit is specifically used to determine the cumulative gyroscope signal between the second candidate time and the current time based on the gyroscope signal at the current time and the cumulative gyroscope signal between the second candidate time and the second target time.

[0129] The second target moment refers to the moment closest to the current moment in the historical motion period; the second candidate moment refers to the moment when the motion started / the moment when the turnaround was closest to the current moment in the historical motion period.

[0130] In an exemplary embodiment, the analysis module 12 is further configured to determine the current time as the turnaround time if: the cumulative gyroscope signal between the second candidate time and the current time is greater than the cumulative gyroscope signal between the second candidate time and the second target time, and the cumulative gyroscope signal between the second candidate time and the second target time is less than the cumulative gyroscope signal between the second candidate time and the third target time; or, if the cumulative gyroscope signal between the second candidate time and the current time is less than the cumulative gyroscope signal between the second candidate time and the second target time, and the cumulative gyroscope signal between the second candidate time and the second target time is greater than the cumulative gyroscope signal between the second candidate time and the third target time, then the current time is determined as the turnaround time; the third target time refers to the time closest to the second target time in the historical motion time period; the single-trip motion time is determined based on the motion start time / target turnaround time and the turnaround time; the target turnaround time refers to the turnaround time closest to the turnaround time in the historical motion time period.

[0131] In an exemplary embodiment, the above-mentioned apparatus further includes: a processing module, configured to perform low-pass filtering on the acquired signal to obtain a low-pass filtered acquired signal.

[0132] Each module in the aforementioned device for determining the single-trip travel time can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device, or stored in the memory of a computer device as software, so that the processor can call and execute the operations corresponding to each module.

[0133] In one exemplary embodiment, a computer device is provided, including a memory and a processor, wherein the memory stores a computer program, and the processor executes the computer program to perform the following steps:

[0134] Acquire signals from historical motion periods and the current moment; the acquired signals include at least one of acceleration signals, gyroscope signals, and geomagnetic signals;

[0135] Feature extraction is performed on the acquired signal to obtain the acquired signal features;

[0136] Data analysis is performed on the characteristics of the collected signals to obtain the time for a single trip.

[0137] In one embodiment, the processor, when executing a computer program, also performs the following steps:

[0138] Based on the current acceleration / geomagnetic signal, the first target time's acceleration / geomagnetic signal, and the cumulative acceleration / geomagnetic signal between the first candidate time and the first target time, determine the cumulative acceleration / geomagnetic signal between the first candidate time and the current time;

[0139] The first target moment refers to the moment in the historical motion period that is closest to the current moment; the first candidate moment refers to the moment in the historical motion period that is closest to the current moment, which is the peak / trough.

[0140] In one embodiment, the processor, when executing a computer program, also performs the following steps:

[0141] If the cumulative acceleration signal / cumulative geomagnetic signal between the first candidate time and the current time is greater than the preset acceleration threshold / preset geomagnetic threshold, then the current time is determined to be the turnaround time;

[0142] The time for a single trip is determined based on the start time of the movement / target turnaround time and the turnaround time; the target turnaround time refers to the turnaround time that is most recent in the historical movement time period.

[0143] In one embodiment, the processor, when executing a computer program, also performs the following steps:

[0144] Based on the gyroscope signal at the current time and the cumulative gyroscope signal between the second candidate time and the second target time, determine the cumulative gyroscope signal between the second candidate time and the current time;

[0145] The second target moment refers to the moment closest to the current moment in the historical motion period; the second candidate moment refers to the moment when the motion started / the moment when the turnaround was closest to the current moment in the historical motion period.

[0146] In one embodiment, the processor, when executing a computer program, also performs the following steps:

[0147] If the cumulative gyroscope signal between the second candidate time and the current time is greater than the cumulative gyroscope signal between the second candidate time and the second target time, and the cumulative gyroscope signal between the second candidate time and the second target time is less than the cumulative gyroscope signal between the second candidate time and the third target time; or, if the cumulative gyroscope signal between the second candidate time and the current time is less than the cumulative gyroscope signal between the second candidate time and the second target time, and the cumulative gyroscope signal between the second candidate time and the second target time is greater than the cumulative gyroscope signal between the second candidate time and the third target time, then the current time is determined to be the turnaround time; the third target time refers to the time in the historical motion period that is closest to the second target time.

[0148] The time for a single trip is determined based on the start time of the movement / target turnaround time and the turnaround time; the target turnaround time refers to the turnaround time that is most recent in the historical movement time period.

[0149] In one embodiment, the processor, when executing a computer program, also performs the following steps:

[0150] The acquired signal is low-pass filtered to obtain the low-pass filtered acquired signal.

[0151] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, the computer program performing the following steps when executed by a processor:

[0152] Acquire signals from historical motion periods and the current moment; the acquired signals include at least one of acceleration signals, gyroscope signals, and geomagnetic signals;

[0153] Feature extraction is performed on the acquired signal to obtain the acquired signal features;

[0154] Data analysis is performed on the characteristics of the collected signals to obtain the time for a single trip.

[0155] In one embodiment, when the computer program is executed by a processor, it also performs the following steps:

[0156] Based on the current acceleration / geomagnetic signal, the first target time's acceleration / geomagnetic signal, and the cumulative acceleration / geomagnetic signal between the first candidate time and the first target time, determine the cumulative acceleration / geomagnetic signal between the first candidate time and the current time;

[0157] The first target moment refers to the moment in the historical motion period that is closest to the current moment; the first candidate moment refers to the moment in the historical motion period that is closest to the current moment, which is the peak / trough.

[0158] In one embodiment, when the computer program is executed by a processor, it also performs the following steps:

[0159] If the cumulative acceleration signal / cumulative geomagnetic signal between the first candidate time and the current time is greater than the preset acceleration threshold / preset geomagnetic threshold, then the current time is determined to be the turnaround time;

[0160] The time for a single trip is determined based on the start time of the movement / target turnaround time and the turnaround time; the target turnaround time refers to the turnaround time that is most recent in the historical movement time period.

[0161] In one embodiment, when the computer program is executed by a processor, it also performs the following steps:

[0162] Based on the gyroscope signal at the current time and the cumulative gyroscope signal between the second candidate time and the second target time, determine the cumulative gyroscope signal between the second candidate time and the current time;

[0163] The second target moment refers to the moment closest to the current moment in the historical motion period; the second candidate moment refers to the moment when the motion started / the moment when the turnaround was closest to the current moment in the historical motion period.

[0164] In one embodiment, when the computer program is executed by a processor, it also performs the following steps:

[0165] If the cumulative gyroscope signal between the second candidate time and the current time is greater than the cumulative gyroscope signal between the second candidate time and the second target time, and the cumulative gyroscope signal between the second candidate time and the second target time is less than the cumulative gyroscope signal between the second candidate time and the third target time; or, if the cumulative gyroscope signal between the second candidate time and the current time is less than the cumulative gyroscope signal between the second candidate time and the second target time, and the cumulative gyroscope signal between the second candidate time and the second target time is greater than the cumulative gyroscope signal between the second candidate time and the third target time, then the current time is determined to be the turnaround time; the third target time refers to the time in the historical motion period that is closest to the second target time.

[0166] The time for a single trip is determined based on the start time of the movement / target turnaround time and the turnaround time; the target turnaround time refers to the turnaround time that is most recent in the historical movement time period.

[0167] In one embodiment, when the computer program is executed by a processor, it also performs the following steps:

[0168] The acquired signal is low-pass filtered to obtain the low-pass filtered acquired signal.

[0169] In one embodiment, a computer program product is provided, including a computer program that, when executed by a processor, performs the following steps:

[0170] Acquire signals from historical motion periods and the current moment; the acquired signals include at least one of acceleration signals, gyroscope signals, and geomagnetic signals;

[0171] Feature extraction is performed on the acquired signal to obtain the acquired signal features;

[0172] Data analysis is performed on the characteristics of the collected signals to obtain the time for a single trip.

[0173] In one embodiment, when the computer program is executed by a processor, it also performs the following steps:

[0174] Based on the current acceleration / geomagnetic signal, the first target time's acceleration / geomagnetic signal, and the cumulative acceleration / geomagnetic signal between the first candidate time and the first target time, determine the cumulative acceleration / geomagnetic signal between the first candidate time and the current time;

[0175] The first target moment refers to the moment in the historical motion period that is closest to the current moment; the first candidate moment refers to the moment in the historical motion period that is closest to the current moment, which is the peak / trough.

[0176] In one embodiment, when the computer program is executed by a processor, it also performs the following steps:

[0177] If the cumulative acceleration signal / cumulative geomagnetic signal between the first candidate time and the current time is greater than the preset acceleration threshold / preset geomagnetic threshold, then the current time is determined to be the turnaround time;

[0178] The time for a single trip is determined based on the start time of the movement / target turnaround time and the turnaround time; the target turnaround time refers to the turnaround time that is most recent in the historical movement time period.

[0179] In one embodiment, when the computer program is executed by a processor, it also performs the following steps:

[0180] Based on the gyroscope signal at the current time and the cumulative gyroscope signal between the second candidate time and the second target time, determine the cumulative gyroscope signal between the second candidate time and the current time;

[0181] The second target moment refers to the moment closest to the current moment in the historical motion period; the second candidate moment refers to the moment when the motion started / the moment when the turnaround was closest to the current moment in the historical motion period.

[0182] In one embodiment, when the computer program is executed by a processor, it also performs the following steps:

[0183] If the cumulative gyroscope signal between the second candidate time and the current time is greater than the cumulative gyroscope signal between the second candidate time and the second target time, and the cumulative gyroscope signal between the second candidate time and the second target time is less than the cumulative gyroscope signal between the second candidate time and the third target time; or, if the cumulative gyroscope signal between the second candidate time and the current time is less than the cumulative gyroscope signal between the second candidate time and the second target time, and the cumulative gyroscope signal between the second candidate time and the second target time is greater than the cumulative gyroscope signal between the second candidate time and the third target time, then the current time is determined to be the turnaround time; the third target time refers to the time in the historical motion period that is closest to the second target time.

[0184] The time for a single trip is determined based on the start time of the movement / target turnaround time and the turnaround time; the target turnaround time refers to the turnaround time that is most recent in the historical movement time period.

[0185] In one embodiment, when the computer program is executed by a processor, it also performs the following steps:

[0186] The acquired signal is low-pass filtered to obtain the low-pass filtered acquired signal.

[0187] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile memory and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, artificial intelligence (AI) processors, etc., and are not limited to these.

[0188] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.

[0189] The embodiments described above are merely illustrative of several implementation methods of this application, and while the descriptions are specific and detailed, they should not be construed as limiting the scope of this patent application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the protection scope of this application. Therefore, the protection scope of this application should be determined by the appended claims.

Claims

1. A method for determining the time of a single trip, characterized in that, The method includes: Acquire historical motion time periods and current moment acquisition signals; the acquisition signals include at least one of acceleration signals, gyroscope signals and geomagnetic signals; Feature extraction is performed on the acquired signal to obtain the acquired signal features; The characteristics of the acquired signals are analyzed to obtain the time for a single trip.

2. The method according to claim 1, characterized in that, When the acquired signal is the acceleration signal or the geomagnetic signal, the step of extracting features from the acquired signal to obtain acquired signal features includes: Based on the current acceleration signal / geomagnetic signal, the first target time acceleration signal / geomagnetic signal, and the cumulative acceleration signal / cumulative geomagnetic signal between the first candidate time and the first target time, determine the cumulative acceleration signal / cumulative geomagnetic signal between the first candidate time and the current time; Wherein, the first target time refers to the time in the historical motion period that is closest to the current time; the first candidate time refers to the time in the historical motion period where the nearest peak / trough is located.

3. The method according to claim 2, characterized in that, The step of analyzing the characteristics of the acquired signals to obtain the single-trip travel time includes: If the cumulative acceleration signal / cumulative geomagnetic signal between the first candidate time and the current time is greater than the preset acceleration threshold / preset geomagnetic threshold, then the current time is determined to be the turnaround time; The time for a single trip is determined based on the start time of the movement / target turnaround time and the turnaround time; the target turnaround time refers to the turnaround time most recently in the historical movement time period.

4. The method according to claim 1, characterized in that, When the acquired signal is the gyroscope signal, the step of extracting features from the acquired signal to obtain acquired signal features includes: Based on the gyroscope signal at the current moment and the cumulative gyroscope signal between the second candidate moment and the second target moment, determine the cumulative gyroscope signal between the second candidate moment and the current moment; Wherein, the second target time refers to the time closest to the current time in the historical motion period; the second candidate time refers to the motion start time / the most recent turnaround time in the historical motion period that is closest to the current time.

5. The method according to claim 4, characterized in that, The step of analyzing the characteristics of the acquired signals to obtain the single-trip travel time includes: If the cumulative gyroscope signal between the second candidate time and the current time is greater than the cumulative gyroscope signal between the second candidate time and the second target time, and the cumulative gyroscope signal between the second candidate time and the second target time is less than the cumulative gyroscope signal between the second candidate time and the third target time; or, if the cumulative gyroscope signal between the second candidate time and the current time is less than the cumulative gyroscope signal between the second candidate time and the second target time, and the cumulative gyroscope signal between the second candidate time and the second target time is greater than the cumulative gyroscope signal between the second candidate time and the third target time, then the current time is determined to be the turnaround time; the third target time refers to the time in the historical motion time period that is closest to the second target time. The time for a single trip is determined based on the start time of the movement / target turnaround time and the turnaround time; the target turnaround time refers to the turnaround time most recently in the historical movement time period.

6. The method according to any one of claims 1-5, characterized in that, Before performing feature extraction on the acquired signal to obtain the acquired signal features, the method further includes: The acquired signal is subjected to low-pass filtering to obtain the low-pass filtered acquired signal.

7. A device for determining the time of a single trip, characterized in that, The device includes: The acquisition module is used to acquire the collected signals from the historical motion time period and the current moment; the collected signals include at least one of acceleration signals, gyroscope signals and geomagnetic signals; The extraction module is used to extract features from the acquired signal to obtain the acquired signal features; The analysis module is used to perform data analysis on the characteristics of the acquired signals to obtain the single-trip travel time.

8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that, When the processor executes the computer program, it implements the steps of the method according to any one of claims 1 to 6.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.

10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.