CN113008242B - User behavior data processing method, device, equipment and storage medium - Google Patents

User behavior data processing method, device, equipment and storage medium Download PDF

Info

Publication number
CN113008242B
CN113008242B CN202110298300.2A CN202110298300A CN113008242B CN 113008242 B CN113008242 B CN 113008242B CN 202110298300 A CN202110298300 A CN 202110298300A CN 113008242 B CN113008242 B CN 113008242B
Authority
CN
China
Prior art keywords
data
inflection points
effective
determining
accelerometer
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202110298300.2A
Other languages
Chinese (zh)
Other versions
CN113008242A (en
Inventor
舒向前
王楠
章国锋
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen TetrasAI Technology Co Ltd
Original Assignee
Shenzhen TetrasAI Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen TetrasAI Technology Co Ltd filed Critical Shenzhen TetrasAI Technology Co Ltd
Priority to CN202110298300.2A priority Critical patent/CN113008242B/en
Publication of CN113008242A publication Critical patent/CN113008242A/en
Application granted granted Critical
Publication of CN113008242B publication Critical patent/CN113008242B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01CMEASURING DISTANCES, LEVELS OR BEARINGS; SURVEYING; NAVIGATION; GYROSCOPIC INSTRUMENTS; PHOTOGRAMMETRY OR VIDEOGRAMMETRY
    • G01C21/00Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00
    • G01C21/20Instruments for performing navigational calculations
    • G01C21/206Instruments for performing navigational calculations specially adapted for indoor navigation
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01CMEASURING DISTANCES, LEVELS OR BEARINGS; SURVEYING; NAVIGATION; GYROSCOPIC INSTRUMENTS; PHOTOGRAMMETRY OR VIDEOGRAMMETRY
    • G01C22/00Measuring distance traversed on the ground by vehicles, persons, animals or other moving solid bodies, e.g. using odometers, using pedometers
    • G01C22/006Pedometers

Landscapes

  • Engineering & Computer Science (AREA)
  • Radar, Positioning & Navigation (AREA)
  • Remote Sensing (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Automation & Control Theory (AREA)
  • Measurement Of The Respiration, Hearing Ability, Form, And Blood Characteristics Of Living Organisms (AREA)

Abstract

The invention provides a user behavior data processing method, a device, equipment and a storage medium, which can carry out low-pass filtering processing on acquired acceleration data of a terminal, then adjust a threshold value required by calculation of effective acceleration data obtained after the low-pass filtering processing through data transmission frame rate during the acquisition of the acceleration data, thereby determining the step number of a user according to the screened inflection point number, ensuring that the filtered data not only meets the subsequent use requirement, but also occupies little calculated amount, ensuring that an algorithm can run at a webpage end, effectively reducing the hysteresis of the data, and the screening of the data can adapt to acceleration data with different frame rates, effectively detecting the step number of the user through the acceleration data, and effectively improving the detection accuracy.

Description

User behavior data processing method, device, equipment and storage medium
Technical Field
The disclosure relates to the technical field of computers, and in particular relates to a user behavior data processing method, device, equipment and storage medium.
Background
The indoor navigation technology can enable people in large-scale indoor places such as shopping malls, hospitals and schools to determine the positions of the people and find the wanted places by utilizing the accurate positioning function even in a building, so that more and more importance is attached. In the indoor navigation technology, since the dead reckoning (PEDESTRIAN DEAD Reckoning, PDR) technology is not required to pre-install a beacon node in a building, an inertial sensor (such as an acceleration sensor, a gyroscope, a magnetometer and the like) is utilized to calculate the step length and the direction of a person, namely, the trail of the person in the building is presumed.
The accuracy of the PDR technology is seriously dependent on the input data quality, however, in the current PDR technology for a common user, acceleration data acquisition is mostly carried out through terminal equipment (such as a mobile phone) of the user, data processing calculation is carried out through application in the terminal equipment, so that estimation of the step number, navigation and the like of the user is carried out, for example, the user can carry out PDR operation through a webpage end on the terminal equipment, but as the load of the terminal equipment changes, the frame rate of data transmission and other factors change, the accuracy of data processing is low, for example, the frame rate of acceleration data taken by the webpage end is low during data processing, the lower frame rate leads to inaccurate detection of the step number timestamp, the webpage end cannot acquire the real timestamp acquired by a sensor, only the timestamp when the data is used approximately, the error is large, and when the load of the webpage end is high, the frame rate is further reduced and random frame loss is accompanied, so that the detection difficulty is further increased, and the error is increased.
Disclosure of Invention
In view of this, embodiments of the present disclosure provide at least a method, an apparatus, an electronic device, and a readable storage medium for processing user behavior data, which can effectively detect the number of steps of a user, and help to improve the accuracy and precision of the detection result, so as to solve at least one of the technical problems in the prior art.
The embodiment of the disclosure provides a user behavior data processing method, which comprises the following steps:
acquiring acceleration data of a terminal and a corresponding data transmission frame rate during the acquisition of the acceleration data;
performing low-pass filtering processing on the acceleration data to obtain processed effective acceleration data;
Determining a plurality of effective data inflection points from the effective acceleration data based on an accelerometer modulo length threshold value matched with the data transmission frame rate;
and determining the action steps of the user based on the number of inflection points of the obtained plurality of effective data inflection points.
In this embodiment, the obtained acceleration data acquired by the accelerometer on the terminal (for example, mobile terminal) is processed through low-pass filtering, and the effective acceleration data after the low-pass filtering is screened through the data transmission frame rate during the process of obtaining the acceleration data, so as to determine the number of steps of the user, and the filtered data not only meets the subsequent use requirement, but also can ensure that only a small amount of calculation is occupied, so that the algorithm can run on the web page end, the hysteresis of the data can be effectively reduced, the screening of the data can adapt to the acceleration data with different frame rates, the walking number of the user can be effectively detected through the acceleration data, and the detection accuracy is effectively improved.
In an alternative embodiment, the method further comprises:
And when the target webpage is detected to be loaded on the terminal and is in an operating state, controlling an acceleration sensor of the terminal to acquire acceleration data of the terminal.
Therefore, step counting and detection can be performed through the webpage running in real time, APP is not required to be installed, the application is simple and convenient, and the application prospect is wide.
In an alternative embodiment, the determining a plurality of valid data inflection points from the valid acceleration data based on an accelerometer modulo length threshold that is matched to the data transmission frame rate includes:
determining a plurality of data time nodes in the effective acceleration data and accelerometer modular lengths corresponding to each data time node;
Determining a step number statistics array representing the action of the user according to the accelerometer module length of each data time node;
determining a plurality of preselected data inflection points from the step count statistics array;
and deleting the preselected data inflection points with the accelerometer module length smaller than the accelerometer module length threshold value matched with the data transmission frame rate from the preselected data inflection points to obtain a plurality of effective data inflection points in the effective acceleration data.
Thus, the data can be accurately and effectively processed through the step number statistical array obtained by calculation between the adjacent data nodes, and the leakage processing of the data is effectively reduced.
In an alternative embodiment, the determining the step count array characterizing the user action based on the accelerometer modulo length of each data time node includes:
calculating the accelerometer modular length corresponding to a later time node in every two adjacent data time nodes in the plurality of data time nodes, and the difference value between the accelerometer modular length corresponding to a previous time node;
if the difference value is greater than or equal to a first comparison threshold value, marking the accelerometer module length corresponding to the later time node as a first marking element in an array;
if the difference value is smaller than the first comparison threshold value, marking the accelerometer modular length corresponding to the later time node as a second marking element in the array;
And sequencing according to the sequence of the data time nodes corresponding to each first marking element and the data time nodes corresponding to each second marking element to obtain a step number statistical array which comprises a plurality of first marking elements and a plurality of second marking elements and is used for representing the action of the user.
In an alternative embodiment, the determining a plurality of preselected data inflection points characterizing the user action based on the step count statistics array includes:
And traversing the step number statistics array, and if the previous marking element in the two adjacent marking elements is different from the following marking element and the previous marking element is the first marking element, determining a time acquisition node corresponding to the previous marking element as a preselected data inflection point.
In an alternative embodiment, the determining a plurality of preselected data inflection points from the step count statistics array includes:
Calculating the difference value between the array element value corresponding to the preceding marker element and the array element value corresponding to the following marker element in every two adjacent marker elements in the step number statistics array;
And if the difference value is larger than the first comparison threshold value, determining a time acquisition node corresponding to the previous marking element as a preselected data inflection point.
In an alternative embodiment, the method further comprises:
If the time interval between two adjacent effective data inflection points in the determined effective data inflection points is smaller than a first time length threshold value matched with the data transmission frame rate, deleting the effective data inflection point with small accelerometer module length corresponding to the two adjacent effective data inflection points; determining the rest effective data inflection points as a plurality of effective data inflection points determined from the effective acceleration data; and/or
If the time interval between two adjacent effective data inflection points in the determined effective data inflection points is larger than a second duration threshold matched with the data transmission frame rate, reducing the accelerometer module length threshold; if the time acquisition node with the corresponding accelerometer module length larger than the adjusted accelerometer module length threshold value exists between the two adjacent effective data inflection points is detected, the detected time acquisition node is determined to be the effective data inflection point determined from the effective acceleration data.
In the embodiment, the jitter data can be accurately screened out and deleted, so that the accuracy of the data can be ensured, the effectiveness of step number statistics results can be improved, and the missing detection and the false detection caused by the jitter of the data can be effectively reduced.
In an alternative embodiment, the method further comprises:
determining that a time sequence of corresponding data time nodes in the plurality of valid data inflection points is positioned at the last at least two valid data inflection points;
And determining the current step length and the current speed of the user based on the data time node and the accelerometer modulo length of each of the at least two valid data inflection points.
In an alternative embodiment, the determining the current step size and the current speed of the user based on the data time node and the accelerometer modulo length of each of the at least two valid data inflection points includes:
Determining a current step frequency of the user based on a data time node of each of the at least two valid data inflection points;
calculating the current step length of the user according to the current step frequency and a module length variance determined based on the accelerometer module length of each of the at least two valid data inflection points;
and calculating the current speed of the user according to the current step length and action time determined based on the data time node of each of the at least two valid data inflection points.
The embodiment of the disclosure also provides a user behavior data processing device, which comprises:
The data acquisition module is used for acquiring acceleration data of the terminal and a corresponding data transmission frame rate during the acquisition of the acceleration data;
The data filtering module is used for performing low-pass filtering processing on the effective acceleration data to obtain processed effective acceleration data;
The first inflection point determining module is used for determining a plurality of effective data inflection points from the effective acceleration data based on an accelerometer module length threshold value matched with the data transmission frame rate;
The step number determining module is used for determining the action step number of the user based on the inflection point number of the obtained plurality of effective data inflection points.
In an alternative embodiment, the apparatus further comprises:
And the data acquisition module is used for controlling an acceleration sensor of the terminal to acquire acceleration data of the terminal when the target webpage is detected to be loaded on the terminal and is in an operating state.
In an alternative embodiment, the first inflection point determining module is specifically configured to:
determining a plurality of data time nodes in the effective acceleration data and accelerometer modular lengths corresponding to each data time node;
Determining a step number statistics array representing the action of the user according to the accelerometer module length of each data time node;
determining a plurality of preselected data inflection points from the step count statistics array;
and deleting the preselected data inflection points with the accelerometer module length smaller than the accelerometer module length threshold value matched with the data transmission frame rate from the preselected data inflection points to obtain a plurality of effective data inflection points in the effective acceleration data.
In an alternative embodiment, the first inflection point determining module is specifically configured to, when determining the step count array characterizing the user action according to the accelerometer modulo length of each data time node:
calculating the accelerometer modular length corresponding to a later time node in every two adjacent data time nodes in the plurality of data time nodes, and the difference value between the accelerometer modular length corresponding to a previous time node;
if the difference value is greater than or equal to a first comparison threshold value, marking the accelerometer module length corresponding to the later time node as a first marking element in an array;
if the difference value is smaller than the first comparison threshold value, marking the accelerometer modular length corresponding to the later time node as a second marking element in the array;
And sequencing according to the sequence of the data time nodes corresponding to each first marking element and the data time nodes corresponding to each second marking element to obtain a step number statistical array which comprises a plurality of first marking elements and a plurality of second marking elements and is used for representing the action of the user.
In an alternative embodiment, the first inflection point determining module is specifically configured to, when determining, according to the step count statistics array, a plurality of preselected data inflection points that characterize the user action:
And traversing the step number statistics array, and if the previous marking element in the two adjacent marking elements is different from the following marking element and the previous marking element is the first marking element, determining a time acquisition node corresponding to the previous marking element as a preselected data inflection point.
In an alternative embodiment, the first inflection point determining module is specifically configured to, when configured to determine a plurality of preselected data inflection points from the step count statistics array:
Calculating the difference value between the array element value corresponding to the preceding marker element and the array element value corresponding to the following marker element in every two adjacent marker elements in the step number statistics array;
And if the difference value is larger than the first comparison threshold value, determining a time acquisition node corresponding to the previous marking element as a preselected data inflection point.
In an alternative embodiment, the apparatus further comprises an inflection point screening module for:
If the time interval between two adjacent effective data inflection points in the determined effective data inflection points is smaller than a first time length threshold value matched with the data transmission frame rate, deleting the effective data inflection point with small accelerometer module length corresponding to the two adjacent effective data inflection points; determining the rest effective data inflection points as a plurality of effective data inflection points determined from the effective acceleration data; and/or
If the time interval between two adjacent effective data inflection points in the determined effective data inflection points is larger than a second duration threshold matched with the data transmission frame rate, reducing the accelerometer module length threshold; if the time acquisition node with the corresponding accelerometer module length larger than the adjusted accelerometer module length threshold value exists between the two adjacent effective data inflection points is detected, the detected time acquisition node is determined to be the effective data inflection point determined from the effective acceleration data.
In an alternative embodiment, the apparatus further comprises:
the second inflection point determining module is used for determining that the time sequence of the corresponding data time nodes in the plurality of effective data inflection points is positioned at the last at least two effective data inflection points;
And the action statistics module is used for determining the current step length and the current speed of the user based on the data time node and the accelerometer module length of each of the at least two effective data inflection points.
In an alternative embodiment, the action statistics module is specifically configured to:
Determining a current step frequency of the user based on a data time node of each of the at least two valid data inflection points;
calculating the current step length of the user according to the current step frequency and a module length variance determined based on the accelerometer module length of each of the at least two valid data inflection points;
and calculating the current speed of the user according to the current step length and action time determined based on the data time node of each of the at least two valid data inflection points.
The disclosed embodiments also provide a computer device comprising: the system comprises a processor, a memory and a bus, wherein the memory stores machine-readable instructions executable by the processor, when the computer device runs, the processor and the memory are communicated through the bus, and the machine-readable instructions are executed by the processor to execute the steps of the user behavior data processing method.
The disclosed embodiments also provide a computer readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the user behavior data processing method described above.
According to the user behavior data processing method, device and equipment and the readable storage medium, low-pass filtering processing can be conducted on acceleration data, then the threshold value required by calculation is adjusted on effective acceleration data obtained after the low-pass filtering processing through the data transmission frame rate in the period of obtaining the acceleration data, so that the number of steps of a user is determined, the filtered data can meet the subsequent use requirement, meanwhile, the fact that the filtered data occupies little calculation amount can be guaranteed, an algorithm can be operated at a webpage end, the hysteresis of the data can be effectively reduced, data screening can be adapted to acceleration data with different frame rates, the number of steps of the user can be effectively detected through the acceleration data, and the detection accuracy is effectively improved.
The foregoing objects, features and advantages of the disclosure will be more readily apparent from the following detailed description of the preferred embodiments taken in conjunction with the accompanying drawings.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present disclosure, the drawings required for the embodiments are briefly described below, which are incorporated in and constitute a part of the specification, these drawings showing embodiments consistent with the present disclosure and together with the description serve to illustrate the technical solutions of the present disclosure. It is to be understood that the following drawings illustrate only certain embodiments of the present disclosure and are therefore not to be considered limiting of its scope, for the person of ordinary skill in the art may admit to other equally relevant drawings without inventive effort.
FIG. 1 is a flowchart of a method for processing user behavior data according to an embodiment of the present disclosure;
FIG. 2 is a schematic diagram of acceleration data processing provided by an embodiment of the present disclosure;
FIG. 3 is a flowchart of another method for processing user behavior data according to an embodiment of the present disclosure;
FIG. 4 is a schematic diagram of a user behavior data processing apparatus according to an embodiment of the present disclosure;
FIG. 5 is a second schematic diagram of a user behavior data processing apparatus according to an embodiment of the disclosure;
FIG. 6 is a third diagram of a user behavior data processing apparatus according to an embodiment of the present disclosure;
FIG. 7 is a diagram of a user behavior data processing apparatus according to an embodiment of the present disclosure;
fig. 8 is a schematic diagram of a computer device according to an embodiment of the disclosure.
Detailed Description
For the purposes of making the objects, technical solutions and advantages of the embodiments of the present disclosure more apparent, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below with reference to the drawings in the embodiments of the present disclosure, and it is apparent that the described embodiments are only some embodiments of the present disclosure, but not all embodiments. The components of the embodiments of the present disclosure, which are generally described and illustrated in the figures herein, may be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the present disclosure provided in the accompanying drawings is not intended to limit the scope of the disclosure, as claimed, but is merely representative of selected embodiments of the disclosure. All other embodiments, which can be made by those skilled in the art based on the embodiments of this disclosure without making any inventive effort, are intended to be within the scope of this disclosure.
It should be noted that: like reference numerals and letters denote like items in the following figures, and thus once an item is defined in one figure, no further definition or explanation thereof is necessary in the following figures.
Based on the above study, the disclosure provides a user behavior data processing method, which can perform low-pass filtering processing on acceleration data, then adjust a threshold value required by screening the effective acceleration data after the low-pass filtering processing according to different frame rates during the period of acquiring the acceleration data, and can effectively detect the number of user behavior steps through the effective acceleration data, so that the filtered data can ensure that only a small calculated amount is occupied, an algorithm can run at a webpage end, the hysteresis of the data can be effectively reduced, the problem of low accuracy caused by the data transmission frame rate can be solved, and the screening of the data can adapt to acceleration degrees of different frame rates, thereby being beneficial to improving the detection accuracy.
For the sake of understanding the present embodiment, first, a detailed description will be given of a user behavior data processing method disclosed in an embodiment of the present disclosure, where an execution body of the user behavior data processing method provided in the embodiment of the present disclosure is generally a computer device with a certain computing capability, where the computer device includes, for example: the terminal device, or server or other processing device, may be a User Equipment (UE), mobile device, user terminal, cellular telephone, cordless telephone, personal digital assistant (Personal DIGITAL ASSISTANT, PDA), handheld device, computing device, vehicle mount device, wearable device, or the like. In some possible implementations, the user behavior data processing method may be implemented by way of a processor invoking computer readable instructions stored in a memory.
The user behavior data processing method provided by the embodiment of the present disclosure is described below by taking an execution body as a terminal device as an example.
Referring to fig. 1, fig. 1 is a flowchart of a user behavior data processing method according to an embodiment of the disclosure. As shown in fig. 1, the method includes:
s101: acquiring acceleration data of a terminal, and a corresponding data transmission frame rate during acquisition of the acceleration data.
In the step, when the number of steps of the user is detected or the number of steps of the user is detected to be used for calculating the speed, the step length or the navigation for the user later, for example, when the user loads a target webpage for calculating the speed, the step length or the navigation on a terminal, acceleration data can be acquired through an acceleration sensor on the terminal of the user, the target webpage can acquire the acceleration data and perform encapsulation processing on the acceleration data, then the encapsulated acceleration data sent by the target webpage can be acquired, and the data transmission frame rate corresponding to the period of acquiring the acceleration data can be obtained through calculation and the like on the acceleration data sent by the target webpage.
The acceleration sensor on the terminal may be a native acceleration sensor on the terminal, or may be an acceleration sensor mounted on the terminal. For example, the acceleration sensor may be a mobile phone or a wearable device of the user, or an acceleration sensor mounted on the mobile phone or the wearable device, or an acceleration sensor mounted on a notebook computer or a vehicle-mounted device of the user, if necessary.
The data transmission frame rate corresponding to the period of acquiring the acceleration data may refer to the data transmission frame rate of the target web page for transmitting the acceleration data during the period of receiving the encapsulated acceleration data transmitted by the target web page.
The data transmission frame rate may be a frame rate of each time point corresponding to the acceleration data at each time point, or may be an average frame rate of the acceleration data, or may be a frame rate fluctuation of the acceleration data in the whole time period, where the whole time period is divided into a plurality of sub-time periods according to the frame rate fluctuation of the acceleration data in the whole time period, and then the average frame rate in each sub-time period is used. For example, by counting how many times the web page sent the last 2 seconds every 2 seconds, and calculating the frame rate, if we send 80 data in 2 seconds, the frame rate can be considered as 40. The above exemplary calculations are merely illustrative and not limiting.
By way of example, when a user is in a shopping mall, school or exhibition hall or the like and has a certain range of indoor or outdoor places, the user can look over an indoor navigation map of a corresponding area to search when the user needs to find a corresponding shop, classroom or exhibition, the user is more complicated to download a corresponding APP at the moment, flow is wasted and the like, most of the user can select a mode of using a Web end, the user can open a corresponding Web to look over or even navigate by scanning a two-dimensional code and the like, and at the moment, acceleration data of the user during walking can be acquired through an acceleration sensor on the mobile phone of the user.
S102: and performing low-pass filtering processing on the acceleration data to obtain processed effective acceleration data.
Since some noise may exist in the collected raw acceleration data, which may cause jitter in the data waveform, for example, as shown in fig. 2, fig. 2 is a schematic diagram of acceleration data processing provided in an embodiment of the disclosure, after the acceleration data is obtained, a waveform curve 210 for representing a user action may be obtained through the acceleration data, where it is known that there is more jitter and noise in the waveform curve 210.
Therefore, in this step, the obtained acceleration data may be subjected to low-pass filtering processing, thereby obtaining effective acceleration data after the filtering processing.
After the low pass filtering process, the effective acceleration data with greatly reduced noise and the corresponding smoother waveform curve, such as waveform curve 220 in fig. 2, can be obtained.
In view of the fact that the frame rate of the acceleration sensor on the terminal is low, low-pass filtering is used for filtering the mode length of the triaxial accelerometer in the embodiment of the present disclosure, so that the calculated amount is low, data noise can be well removed, and a mild filtering coefficient is selected, so that the serious data lag after filtering can be avoided.
By way of example, the acceleration data may be low pass filtered by the following formula:
y(k)=x(k)*alpha+(1-alpha)*y(k-1);
where y (k) is the modular length of the filtered acceleration data k, x (k) is the original modular length of the acceleration data k, alpha is the filter coefficient, and y (k-1) is the filtered modular length of the acceleration data k-1 preceding the acceleration data k.
The filter coefficient alpha may be a coefficient corresponding to different acceleration sensors obtained by a deep learning mode.
S103: and determining a plurality of effective data inflection points from the effective acceleration data based on an accelerometer module length threshold value matched with the data transmission frame rate.
In the step, after the effective acceleration data and the data transmission frame rate are acquired, an accelerometer module length threshold value used for screening the effective acceleration data can be calculated through the data transmission frame rate, or the accelerometer module length threshold value calculated in the background after the data transmission frame rate is sent to the background is acquired, or the accelerometer module length threshold value corresponding to the data transmission frame rate is acquired according to a mapping relation between a preset frame rate and the module length threshold value, so that the effective acceleration data is screened, and a plurality of effective data inflection points are obtained.
Correspondingly, the accelerometer module length threshold value matched with the data transmission frame rate can be an accelerometer module length threshold value of each time point when the acceleration data is acquired, or can be a fixed accelerometer module length threshold value corresponding to the average frame rate in the whole data acquisition time period, or can be an average frame rate of each sub-time period in a plurality of sub-time periods in the whole data acquisition time period, and can be each corresponding accelerometer module length threshold value.
For example, as in the example shown in fig. 2, after the effective acceleration data is obtained, a waveform inflection point curve 230 for representing the number of steps of the user's action may be obtained from the effective acceleration data, and a plurality of inflection points of the waveform may be obtained from the waveform inflection point curve 230, which may be referred to as effective data inflection points of the user's action.
Therefore, the module length threshold value of the accelerometer is determined according to the data transmission frame rate so as to screen the acceleration data, the module length threshold value of the accelerometer can be adjusted through the data transmission frame rate so as to adapt to the acceleration data acquired under different frame rates, and when the frame rate changes when the data is acquired due to different working states of the terminal, the module length threshold value of the data screening is adjusted in time, so that the data screening precision can be effectively improved, and the accuracy of calculation of the subsequent steps and the like is ensured.
S104: and determining the action steps of the user based on the number of inflection points of the obtained plurality of effective data inflection points.
In the step, the action steps of the user can be obtained through the determined inflection point number of the inflection points of the effective data, namely, the action steps of the user are equal to the inflection point number.
Illustratively, the number of steps of the user's action can be derived from the number of inflection points in the waveform inflection point curve 230 in the example shown in fig. 2.
Although the user behavior data processing method provided in the embodiment of the disclosure is illustrated by taking the Web terminal as an example, the method is not limited to this, and in other embodiments, the method can be used by the APP without the APP to obtain the timestamp of the data, so that the calculation amount of the APP can be effectively reduced, and the obtained number of action steps of the user is directly provided to the APP for subsequent calculation.
According to the user behavior data processing method provided by the embodiment of the disclosure, acceleration data of a terminal are obtained, and a data transmission frame rate corresponding to the acceleration data period is obtained; performing low-pass filtering processing on the acceleration data to obtain processed effective acceleration data; determining a plurality of effective data inflection points from the effective acceleration data based on an accelerometer modulo length threshold value matched with the data transmission frame rate; and determining the action steps of the user based on the number of inflection points of the obtained plurality of effective data inflection points.
In this way, the low-pass filtering processing is carried out on the obtained acceleration data, and then the data transmission frame rate during the period of obtaining the acceleration data is used for adjusting the threshold value required by calculation of the effective acceleration data obtained after the low-pass filtering processing, so that the number of steps of a user is determined, the filtered data can not only meet the subsequent use requirement, but also ensure that the algorithm occupies little calculation amount, so that the algorithm can run at the webpage end, the hysteresis of the data can be effectively reduced, the screening of the data can be adapted to the acceleration data with different frame rates, the walking steps of the user can be effectively detected through the acceleration data, and the detection accuracy is effectively improved.
Referring to fig. 3, fig. 3 is a flowchart of another method for processing user behavior data according to an embodiment of the disclosure. As shown in fig. 3, the method includes:
S301: and when the target webpage is detected to be loaded on the terminal and is in an operating state, controlling an acceleration sensor of the terminal to acquire acceleration data of the terminal.
In an exemplary use scenario, for example, when a user needs to record motion information or navigate, a corresponding target webpage may be opened at a Web end by scanning a two-dimensional code or opening a link, and at this time, if it is detected that the target webpage is completely loaded on the terminal and is in an operation state, an acceleration sensor of the terminal may be controlled to collect acceleration data of the terminal.
Wherein, because the terminal moves along with the user, the acceleration data of the terminal can be regarded as the acceleration data of the user action.
S302: acquiring acceleration data of a terminal, and a corresponding data transmission frame rate during acquisition of the acceleration data.
S303: performing low-pass filtering processing on the acceleration data to obtain processed effective acceleration data;
S304: and determining a plurality of effective data inflection points from the effective acceleration data based on an accelerometer module length threshold value matched with the data transmission frame rate.
S305: and determining the action steps of the user based on the number of inflection points of the obtained plurality of effective data inflection points.
The descriptions of step S302 to step S305 may refer to the descriptions of step S101 to step S104, and may achieve the same technical effects and solve the same technical problems, which are not described herein.
In some possible embodiments, step S304 includes:
s3041: and determining a plurality of data time nodes in the effective acceleration data and accelerometer modulo length corresponding to each data time node.
In the step, a plurality of data time nodes can be determined through the acquisition time stamp corresponding to each data in the effective acceleration data, and the acceleration data of each data time node is calculated to obtain the accelerometer module length corresponding to each data time node.
The data time node may be a receiving time recorded when the effective acceleration data sent by the target web page is received and corresponding to the speed data, or may be a data acquisition time when the effective acceleration data is acquired.
S3042: a step count array characterizing the user's action is determined based on the accelerometer modular length for each data time node.
In the step, each data in the effective acceleration data can be calculated through the accelerometer module length of each data time node in an array statistical mode so as to obtain a step number statistical array for representing the action of the user.
Specifically, when determining the step number statistics array for representing the user action, calculating the accelerometer module length corresponding to the next time node in every two adjacent data time nodes in the plurality of data time nodes, and sorting the accelerometer module lengths corresponding to the previous time nodes according to the sequence of the data time nodes corresponding to each first mark element and each second mark element to obtain the step number statistics array for representing the user action, wherein the accelerometer module length corresponding to the next time node is marked as the first mark element in the array if the difference is greater than or equal to the first comparison threshold value, and the accelerometer module length corresponding to the next time node is marked as the second mark element in the array if the difference is less than the first comparison threshold value.
For example, taking the waveform curve 220 in fig. 2 as an example, the waveform curve 220 is drawn by a plurality of data time nodes and corresponding accelerometer module lengths, and it is known that when the curve rises, the difference between new data corresponding to the later time node and old data corresponding to the earlier time node is positive, and when the curve falls, the difference is negative, for convenience of marking, the positive and negative numbers can be respectively recorded as 1 and-1, and the first comparison threshold value is taken as 0, so that a step number statistical array representing the action of the user can be obtained.
For comparison, in the embodiment of the disclosure, the first comparison threshold may take 0, but is not limited thereto, and in other embodiments of the disclosure, the first comparison threshold may also take a value according to an array element value of the first flag element and an array element value of the second flag element.
S3043: and determining a plurality of preselected data inflection points from the step number statistics array.
In the step, after the step number statistics array is obtained, the marking elements of the step number statistics array can be further screened, so that the data time nodes corresponding to the screened marking elements are obtained, and a plurality of preselected data inflection points corresponding to the less selected marking elements are obtained.
Specifically, in some possible embodiments, determining the plurality of pre-selected data inflection points may be by traversing the step count array to compare the marker elements of the step count array, and if a preceding marker element of two adjacent marker elements is different from a following marker element, and the preceding marker element is the first marker element, determining a time acquisition node corresponding to the preceding marker element as the pre-selected data inflection point.
By way of example, it is known that by observing the waveform curve, when the curve continuously rises, the marks in the step count array are all 1, and when the curve continuously falls, the marks in the step count array are all-1, after obtaining the step count array including a series of consecutive 1s and consecutive 1s as mark elements, for example, (1, … -1, -1 …,1 … -1-1 …), if the adjacent mark element is changed from 1 to-1, or the adjacent mark element is changed from-1 to 1, that is, when the two mark elements are different, the curve can be considered to appear turning, further by observing the waveform curve, the adjacent mark element is changed from 1 to-1, that is, from the first mark element to the second mark element, when the first mark element is the first mark element, the waveform turns from-1 to the trough, and the adjacent mark element is changed from-1 to the first mark element, that is the second mark element, when the first mark element is the second mark element, the adjacent mark element turns from-1 to the trough, and therefore the waveform node is a preselected point, and the waveform node is a preselected point.
Specifically, in some possible embodiments, the determining of the plurality of preselected data inflection points may further include determining, as the preselected data inflection point, a time acquisition node corresponding to a preceding marker element by calculating a difference between an array element value corresponding to the preceding marker element and an array element value corresponding to a following marker element in each two adjacent marker elements in the step number statistics array, if the difference is greater than the first comparison threshold.
By way of example, by observing the waveform curve and combining the obtained step count array, it is known that, when the curve continuously rises or falls, the values of the array elements corresponding to the continuous marker elements in the step count array are the same, for example, 1 or-1, so after the step count array is obtained, the values of the array elements corresponding to the two adjacent marker elements in the step count array can be calculated, further, if the adjacent marker elements are changed from 1 to-1, the values of the array elements corresponding to the two adjacent marker elements are calculated, that is, the result of 1- (-1) is 2, which is greater than the first comparison threshold, at this time, that is, the waveform turns from the peak to the valley, and conversely, if the adjacent marker elements are changed from-1 to 1, the values of the array elements corresponding to-1 are calculated, that is, at this time, that is, the waveform turns from the peak to the peak, so that the time node corresponding to the previous marker element is collected, that is the time node corresponding to the previous marker element is the time node is the pre-selected inflection point, can be determined.
Accordingly, in the embodiment of the present disclosure, the difference between the value of the array element corresponding to the preceding marker element and the value of the array element corresponding to the following marker element is taken as an example to perform statistics, but not limited thereto, and in other embodiments, the difference between the value of the array element corresponding to the following marker element and the value of the array element corresponding to the preceding marker element may also be taken as an example to perform statistics, and accordingly, the obtained difference is correspondingly set smaller than the first comparison threshold, that is, if the difference is smaller than the first comparison threshold, the time acquisition node corresponding to the preceding marker element is determined as the preselected data inflection point.
S3044: and deleting the preselected data inflection points with the accelerometer module length smaller than the accelerometer module length threshold value matched with the data transmission frame rate from the preselected data inflection points to obtain a plurality of effective data inflection points in the effective acceleration data.
In the step, after the plurality of preselected data inflection points are obtained, the plurality of preselected data inflection points can be further screened, and the preselected data inflection points with the accelerometer module length smaller than the accelerometer module length threshold matched with the data transmission frame rate are deleted so as to remove the jitter data, thereby finally obtaining a plurality of effective data inflection points in the effective acceleration data.
Illustratively, as shown in the curve segment 221 of the waveform curve 220 in fig. 2, after the acceleration data is dithered, the corresponding waveform curve may also be dithered, for example, there are two inflection points in the curve segment 221, that is, two preselected data inflection points are corresponding to the inflection points, where the preselected data inflection points corresponding to the inflection points smaller than the accelerometer modulus length threshold value may be deleted by the accelerometer modulus length threshold value matched with the data transmission frame rate.
In some possible embodiments, the method further comprises:
if the time interval between two adjacent effective data inflection points in the determined effective data inflection points is smaller than a first time length threshold value matched with the data transmission frame rate, deleting the effective data inflection point with small accelerometer module length corresponding to the two adjacent effective data inflection points; and determining the rest effective data inflection points as a plurality of effective data inflection points determined from the effective acceleration data.
When the acceleration data is acquired, due to the shake of the acceleration sensor, data shake may exist that two adjacent effective data inflection points are adjacent and nearer, but are larger than the accelerometer module length threshold value.
At this time, in this step, the time interval between two adjacent valid data inflection points among the determined valid data inflection points may be detected, and if the time interval between two valid data inflection points exists that is smaller than the first time length threshold value matched with the data transmission frame rate, the valid data inflection point with the small corresponding accelerometer module length may be deleted.
Illustratively, as shown in the curve segment 222 of the waveform curve 220 in fig. 2, there are two waveform inflection points in the curve segment 222, but the two waveform inflection points are very close, that is, the time interval between the two waveform inflection points is smaller than the first time length threshold value matched with the data transmission frame rate, at this time, for the accuracy of data, the valid data inflection point with the small modulus length of the corresponding accelerometer may be deleted.
Further, if the accelerometer module length of the time interval is smaller than the two valid data inflection points of the first time length threshold matched with the data transmission frame rate is the same, one can be deleted at will, and the other can be left.
The first time length threshold value matched with the data transmission frame rate can be set according to requirements of data processing precision and the like, and can also be obtained by combining factors such as different frame rates in the data transmission period in a real-time matching mode through calculation and the like.
In some possible embodiments, the method further comprises:
If the time interval between two adjacent effective data inflection points in the determined effective data inflection points is larger than a second duration threshold matched with the data transmission frame rate, reducing the accelerometer module length threshold; if the time acquisition node with the corresponding accelerometer module length larger than the adjusted accelerometer module length threshold value exists between the two adjacent effective data inflection points is detected, the detected time acquisition node is determined to be the effective data inflection point determined from the effective acceleration data.
When the acceleration data is acquired, due to missed acquisition of the acceleration sensor, data is missed, and effective data may not be detected for a long time.
Therefore, in this step, if it is detected that the time interval between two adjacent valid data inflection points is greater than the second duration threshold value matched with the data transmission frame rate, it may be considered that there is a missing detection of data, at this time, the accelerometer mode length threshold value may be correspondingly reduced, and then the data between two valid data inflection points whose time interval is greater than the second duration threshold value matched with the data transmission frame rate is rescreened through the reduced accelerometer mode length threshold value, so as to find a time acquisition node whose corresponding accelerometer mode length is greater than the reduced accelerometer mode length threshold value, and determine the time acquisition node as the valid data inflection point determined from the valid acceleration data.
In some possible embodiments, the method further comprises:
Determining that a time sequence of corresponding data time nodes in the plurality of valid data inflection points is positioned at the last at least two valid data inflection points; and determining the current step length and the current speed of the user based on the data time node and the accelerometer modulo length of each of the at least two valid data inflection points.
In particular applications, the user will typically need to know current motion data, such as the current real-time speed of the user, etc.
Thus, in this step, the current step size and the current speed of the user may be calculated using the corresponding data time nodes of the plurality of valid data inflection points, the corresponding data time nodes and the accelerometer modulo length, which are chronologically located at the last at least two valid data inflection points.
Specifically, determining the current step size and the current speed of the user may be determining the current step frequency of the user based on the data time node of each of the at least two valid data inflection points, then calculating the current step size of the user according to the current step frequency and the module length variance determined based on the accelerometer module length of each of the at least two valid data inflection points, and then calculating the current speed of the user according to the current step size and the action time determined based on the data time node of each of the at least two valid data inflection points.
The time difference between the data time nodes of each two valid data inflection points in the at least two valid data inflection points can be regarded as a period of user action, and the reciprocal of the period can be regarded as the current step frequency of the user step.
Illustratively, the user's step size can be calculated by the following formula:
A=a+b*B+c*C;
Wherein A is the step length of the user, B is the current step frequency of the user, C is the module length variance determined based on the accelerometer module length of each effective data inflection point in the at least two effective data inflection points, and a, B and C are calculation coefficients. a. b, c may be trained by deep learning methods using big data, such as user history data, etc.
After obtaining the step length of the user, the step length can be regarded as the walking distance of the user, and then the walking time of the user is used, for example, the action time is determined according to the data time node of each effective data inflection point, so that the speed of the user can be calculated.
According to the user behavior data processing method provided by the embodiment of the disclosure, when the fact that the target webpage is loaded on the terminal is detected and the terminal is in the running state, an acceleration sensor of the terminal is controlled to acquire acceleration data of the terminal; acquiring acceleration data of a terminal and a corresponding data transmission frame rate during the acquisition of the acceleration data; performing low-pass filtering processing on the acceleration data to obtain processed effective acceleration data; determining a plurality of effective data inflection points from the effective acceleration data based on an accelerometer modulo length threshold value matched with the data transmission frame rate; and determining the action steps of the user based on the number of inflection points of the obtained plurality of effective data inflection points.
In this way, the control terminal collects acceleration data, low-pass filtering processing is carried out on the obtained acceleration data, the data transmission frame rate during the period of obtaining the acceleration data is used for adjusting a threshold value required by calculation of effective acceleration data obtained after processing, so that the step number of a user is determined, the filtered data can meet the subsequent use requirement, meanwhile, the condition that the algorithm occupies little calculation amount can be ensured, the algorithm can run at a webpage end, the hysteresis quality of the data can be effectively reduced, the screening of the data can be adapted to the acceleration data with different frame rates, the step number of the user can be effectively detected through the acceleration data, and the detection accuracy is effectively improved.
It will be appreciated by those skilled in the art that in the above-described method of the specific embodiments, the written order of steps is not meant to imply a strict order of execution but rather should be construed according to the function and possibly inherent logic of the steps.
Based on the same inventive concept, the embodiments of the present disclosure further provide a user behavior data processing device corresponding to the above-mentioned user behavior data processing method, and since the principle of solving the problem of the device in the embodiments of the present disclosure is similar to that of the user behavior data processing method in the embodiments of the present disclosure, implementation of the device may refer to implementation of the method, and repeated parts will not be repeated.
Referring to fig. 4 to 7, fig. 4 is a schematic diagram of a user behavior data processing device according to an embodiment of the present disclosure, fig. 5 is a schematic diagram of a second user behavior data processing device according to an embodiment of the present disclosure, fig. 6 is a schematic diagram of a third user behavior data processing device according to an embodiment of the present disclosure, and fig. 7 is a schematic diagram of a fourth user behavior data processing device according to an embodiment of the present disclosure. As shown in fig. 4, a user behavior data processing apparatus 400 provided by an embodiment of the present disclosure includes:
the data acquisition module 410 is configured to acquire acceleration data of the terminal, and a data transmission frame rate corresponding to the acceleration data during the acquisition.
The data filtering module 420 is configured to perform low-pass filtering processing on the acceleration data to obtain processed effective acceleration data;
The first inflection point determining module 430 is configured to determine a plurality of valid data inflection points from the valid acceleration data based on an accelerometer modulo length threshold value that is matched to the data transmission frame rate.
The step number determining module 440 is configured to determine the number of action steps of the user based on the number of inflection points of the obtained plurality of valid data inflection points.
In an alternative embodiment, as shown in fig. 5, the user behavior data processing apparatus 400 further includes:
and the data acquisition module 450 is used for controlling an acceleration sensor of the terminal to acquire acceleration data of the terminal when the target webpage is detected to be loaded on the terminal and is in an operating state.
In an alternative embodiment, the first inflection point determining module 430 is specifically configured to:
determining a plurality of data time nodes in the effective acceleration data and accelerometer modular lengths corresponding to each data time node;
Determining a step number statistics array representing the action of the user according to the accelerometer module length of each data time node;
determining a plurality of preselected data inflection points from the step count statistics array;
and deleting the preselected data inflection points with the accelerometer module length smaller than the accelerometer module length threshold value matched with the data transmission frame rate from the preselected data inflection points to obtain a plurality of effective data inflection points in the effective acceleration data.
In an alternative embodiment, the first inflection point determining module 430 is configured to, when determining a step count array characterizing a user action based on an accelerometer module length of each data time node, specifically:
calculating the accelerometer modular length corresponding to a later time node in every two adjacent data time nodes in the plurality of data time nodes, and the difference value between the accelerometer modular length corresponding to a previous time node;
if the difference value is greater than or equal to a first comparison threshold value, marking the accelerometer module length corresponding to the later time node as a first marking element in an array;
if the difference value is smaller than the first comparison threshold value, marking the accelerometer modular length corresponding to the later time node as a second marking element in the array;
And sequencing according to the sequence of the data time nodes corresponding to each first marking element and the data time nodes corresponding to each second marking element to obtain a step number statistical array which comprises a plurality of first marking elements and a plurality of second marking elements and is used for representing the action of the user.
In an alternative embodiment, the first inflection point determining module 430 is configured to, when configured to determine a plurality of preselected data inflection points representing actions of the user based on the step count statistics array:
And traversing the step number statistics array, and if the previous marking element in the two adjacent marking elements is different from the following marking element and the previous marking element is the first marking element, determining a time acquisition node corresponding to the previous marking element as a preselected data inflection point.
In an alternative embodiment, the first inflection point determining module 430 is configured to, when configured to determine a plurality of preselected data inflection points from the step count statistics array, specifically:
Calculating the difference value between the array element value corresponding to the preceding marker element and the array element value corresponding to the following marker element in every two adjacent marker elements in the step number statistics array;
And if the difference value is larger than the first comparison threshold value, determining a time acquisition node corresponding to the previous marking element as a preselected data inflection point.
In an alternative embodiment, as shown in fig. 6, the user behavior data processing apparatus 400 further includes an inflection point screening module 460, where the inflection point screening module 460 is configured to:
If the time interval between two adjacent effective data inflection points in the determined effective data inflection points is smaller than a first time length threshold value matched with the data transmission frame rate, deleting the effective data inflection point with small accelerometer module length corresponding to the two adjacent effective data inflection points; determining the rest effective data inflection points as a plurality of effective data inflection points determined from the effective acceleration data; and/or
If the time interval between two adjacent effective data inflection points in the determined effective data inflection points is larger than a second duration threshold matched with the data transmission frame rate, reducing the accelerometer module length threshold; if the time acquisition node with the corresponding accelerometer module length larger than the adjusted accelerometer module length threshold value exists between the two adjacent effective data inflection points is detected, the detected time acquisition node is determined to be the effective data inflection point determined from the effective acceleration data.
In an alternative embodiment, as shown in fig. 7, the user behavior data processing apparatus 400 further includes:
a second inflection point determining module 470, configured to determine that a time sequence of a corresponding data time node in the plurality of valid data inflection points is located at the last at least two valid data inflection points;
An activity statistics module 480 for determining a current step size and a current speed of the user based on the data time node and the accelerometer modulo length for each of the at least two valid data inflection points.
In an alternative embodiment, the action statistics module 480 is specifically configured to:
Determining a current step frequency of the user based on a data time node of each of the at least two valid data inflection points;
calculating the current step length of the user according to the current step frequency and a module length variance determined based on the accelerometer module length of each of the at least two valid data inflection points;
and calculating the current speed of the user according to the current step length and action time determined based on the data time node of each of the at least two valid data inflection points.
The user behavior data processing device provided by the embodiment of the disclosure obtains acceleration data of a terminal and a corresponding data transmission frame rate during the period of obtaining the acceleration data; performing low-pass filtering processing on the acceleration data to obtain processed effective acceleration data; determining a plurality of effective data inflection points from the effective acceleration data based on an accelerometer modulo length threshold value matched with the data transmission frame rate; and determining the action steps of the user based on the number of inflection points of the obtained plurality of effective data inflection points.
Therefore, the low-pass filtering processing can be carried out on the acceleration data, and then the threshold value required by the calculation of the processed effective acceleration data is adjusted through the data transmission frame rate during the acquired acceleration data, so that the number of steps of a user is determined, the filtered data not only meets the subsequent use requirement, but also can ensure that the algorithm occupies little calculation amount, so that the algorithm can run at the webpage end, the hysteresis of the data can be effectively reduced, the processing of the data can be adapted to the acceleration data with different frame rates, the walking number of the user can be effectively detected through the acceleration data, and the detection accuracy is effectively improved.
Referring to fig. 8, fig. 8 is a schematic diagram of a computer device according to an embodiment of the disclosure. As shown in fig. 8, the computer device 800 includes: a processor 810, a memory 820 and a bus 830, the memory 820 storing machine-readable instructions executable by the processor 810, the processor 810 and the memory 820 communicating over the bus 830 when the computer device 800 is running, the machine-readable instructions when executed by the processor 810 performing the steps of the user behavior data processing method described above.
The specific execution process of the above instruction may refer to the steps of the user behavior data processing method described in the embodiments of the present disclosure, which is not described herein again.
The disclosed embodiments also provide a computer readable storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the user behavior data processing method described in the above method embodiments. Wherein the storage medium may be a volatile or nonvolatile computer readable storage medium.
It will be clear to those skilled in the art that, for convenience and brevity of description, specific working procedures of the above-described system and apparatus may refer to corresponding procedures in the foregoing method embodiments, which are not described herein again. In the several embodiments provided in the present disclosure, it should be understood that the disclosed systems, devices, and methods may be implemented in other manners. The above-described apparatus embodiments are merely illustrative, for example, the division of the units is merely a logical function division, and there may be other manners of division in actual implementation, and for example, multiple units or components may be combined or integrated into another system, or some features may be omitted, or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be through some communication interface, device or unit indirect coupling or communication connection, which may be in electrical, mechanical or other form.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in each embodiment of the present disclosure may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a non-volatile computer readable storage medium executable by a processor. Based on such understanding, the technical solution of the present disclosure may be embodied in essence or a part contributing to the prior art or a part of the technical solution, or in the form of a software product stored in a storage medium, including several instructions to cause a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in the embodiments of the present disclosure. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (Random Access Memory, RAM), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
Finally, it should be noted that: the foregoing examples are merely specific embodiments of the present disclosure, and are not intended to limit the scope of the disclosure, but the present disclosure is not limited thereto, and those skilled in the art will appreciate that while the foregoing examples are described in detail, it is not limited to the disclosure: any person skilled in the art, within the technical scope of the disclosure of the present disclosure, may modify or easily conceive changes to the technical solutions described in the foregoing embodiments, or make equivalent substitutions for some of the technical features thereof; such modifications, changes or substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the disclosure, and are intended to be included within the scope of the present disclosure. Therefore, the protection scope of the present disclosure shall be subject to the protection scope of the claims.

Claims (11)

1. A method of processing user behavior data, the method comprising:
acquiring acceleration data of a terminal and a corresponding data transmission frame rate during the acquisition of the acceleration data;
performing low-pass filtering processing on the acceleration data to obtain processed effective acceleration data;
Determining a plurality of effective data inflection points from the effective acceleration data based on an accelerometer modulo length threshold value matched with the data transmission frame rate;
Determining the action steps of the user based on the number of inflection points of the obtained plurality of effective data inflection points;
the determining a plurality of effective data inflection points from the effective acceleration data based on the accelerometer module length threshold matched with the data transmission frame rate comprises:
determining a plurality of data time nodes in the effective acceleration data and accelerometer modular lengths corresponding to each data time node;
Determining a step number statistics array representing the action of the user according to the accelerometer module length of each data time node;
determining a plurality of preselected data inflection points from the step count statistics array;
and deleting the preselected data inflection points with the accelerometer module length smaller than the accelerometer module length threshold value matched with the data transmission frame rate from the preselected data inflection points to obtain a plurality of effective data inflection points in the effective acceleration data.
2. The method according to claim 1, wherein the method further comprises:
And when the target webpage is detected to be loaded on the terminal and is in an operating state, controlling an acceleration sensor of the terminal to acquire acceleration data of the terminal.
3. The method of claim 1, wherein determining a step count array characterizing user actions based on accelerometer modulo length for each data time node comprises:
calculating the accelerometer modular length corresponding to a later time node in every two adjacent data time nodes in the plurality of data time nodes, and the difference value between the accelerometer modular length corresponding to a previous time node;
if the difference value is greater than or equal to a first comparison threshold value, marking the accelerometer module length corresponding to the later time node as a first marking element in an array;
if the difference value is smaller than the first comparison threshold value, marking the accelerometer modular length corresponding to the later time node as a second marking element in the array;
And sequencing according to the sequence of the data time nodes corresponding to each first marking element and the data time nodes corresponding to each second marking element to obtain a step number statistical array which comprises a plurality of first marking elements and a plurality of second marking elements and is used for representing the action of the user.
4. A method according to claim 3, wherein said determining a plurality of preselected data inflection points characterizing a user action based on said step count array comprises:
And traversing the step number statistics array, and if the previous marking element in the two adjacent marking elements is different from the following marking element and the previous marking element is the first marking element, determining a time acquisition node corresponding to the previous marking element as a preselected data inflection point.
5. A method according to claim 3, wherein said determining a plurality of preselected data inflection points from said step count statistics array comprises:
Calculating the difference value between the array element value corresponding to the preceding marker element and the array element value corresponding to the following marker element in every two adjacent marker elements in the step number statistics array;
And if the difference value is larger than the first comparison threshold value, determining a time acquisition node corresponding to the previous marking element as a preselected data inflection point.
6. The method according to any one of claims 1-5, further comprising:
If the time interval between two adjacent effective data inflection points in the determined effective data inflection points is smaller than a first time length threshold value matched with the data transmission frame rate, deleting the effective data inflection point with small accelerometer module length corresponding to the two adjacent effective data inflection points; determining the rest effective data inflection points as a plurality of effective data inflection points determined from the effective acceleration data; and/or
If the time interval between two adjacent effective data inflection points in the determined effective data inflection points is larger than a second duration threshold matched with the data transmission frame rate, reducing the accelerometer module length threshold; if the time acquisition node with the corresponding accelerometer module length larger than the adjusted accelerometer module length threshold value exists between the two adjacent effective data inflection points is detected, the detected time acquisition node is determined to be the effective data inflection point determined from the effective acceleration data.
7. The method according to claim 1, wherein the method further comprises:
determining that a time sequence of corresponding data time nodes in the plurality of valid data inflection points is positioned at the last at least two valid data inflection points;
And determining the current step length and the current speed of the user based on the data time node and the accelerometer modulo length of each of the at least two valid data inflection points.
8. The method of claim 7, wherein the determining the current step size and the current speed of the user based on the data time node and the accelerometer modulo length of each of the at least two valid data inflection points comprises:
Determining a current step frequency of the user based on a data time node of each of the at least two valid data inflection points;
calculating the current step length of the user according to the current step frequency and a module length variance determined based on the accelerometer module length of each of the at least two valid data inflection points;
and calculating the current speed of the user according to the current step length and action time determined based on the data time node of each of the at least two valid data inflection points.
9. A user behavior data processing apparatus, the apparatus comprising:
The data acquisition module is used for acquiring acceleration data of the terminal and a corresponding data transmission frame rate during the acquisition of the acceleration data;
The data filtering module is used for performing low-pass filtering processing on the acceleration data to obtain processed effective acceleration data;
The first inflection point determining module is used for determining a plurality of effective data inflection points from the effective acceleration data based on an accelerometer module length threshold value matched with the data transmission frame rate;
the step number determining module is used for determining the action step number of the user based on the number of inflection points of the obtained plurality of effective data inflection points;
the first inflection point determining module is specifically configured to:
determining a plurality of data time nodes in the effective acceleration data and accelerometer modular lengths corresponding to each data time node;
Determining a step number statistics array representing the action of the user according to the accelerometer module length of each data time node;
determining a plurality of preselected data inflection points from the step count statistics array;
and deleting the preselected data inflection points with the accelerometer module length smaller than the accelerometer module length threshold value matched with the data transmission frame rate from the preselected data inflection points to obtain a plurality of effective data inflection points in the effective acceleration data.
10. A computer device, comprising: a processor, a memory and a bus, said memory storing machine readable instructions executable by said processor, said processor and said memory communicating over the bus when the computer device is running, said machine readable instructions when executed by said processor performing the steps of the user behavior data processing method according to any of claims 1 to 8.
11. A computer-readable storage medium, characterized in that the computer-readable storage medium has stored thereon a computer program which, when executed by a processor, performs the steps of the user behavior data processing method according to any one of claims 1 to 8.
CN202110298300.2A 2021-03-19 2021-03-19 User behavior data processing method, device, equipment and storage medium Active CN113008242B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110298300.2A CN113008242B (en) 2021-03-19 2021-03-19 User behavior data processing method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110298300.2A CN113008242B (en) 2021-03-19 2021-03-19 User behavior data processing method, device, equipment and storage medium

Publications (2)

Publication Number Publication Date
CN113008242A CN113008242A (en) 2021-06-22
CN113008242B true CN113008242B (en) 2024-06-07

Family

ID=76403657

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110298300.2A Active CN113008242B (en) 2021-03-19 2021-03-19 User behavior data processing method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113008242B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116028870B (en) * 2023-03-29 2023-06-13 京东方艺云(苏州)科技有限公司 Data detection method and device, electronic equipment and storage medium
CN117387655B (en) * 2023-12-12 2024-03-15 绍兴圆方半导体有限公司 Step counting method, step counting device, terminal and storage medium

Citations (19)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2003315356A (en) * 2002-04-26 2003-11-06 Toyota Motor Corp Sensor device
KR20120020051A (en) * 2010-08-27 2012-03-07 야마하 가부시키가이샤 Pedometer, sampling device, and waveform analyzer
FR3012597A1 (en) * 2013-10-24 2015-05-01 Commissariat Energie Atomique INTERNAL AND EXTERNAL LOCALIZATION METHOD AND PORTABLE DEVICE IMPLEMENTING SAID METHOD
CN105004349A (en) * 2015-06-30 2015-10-28 深圳市元征科技股份有限公司 Step calculation method
CN105043410A (en) * 2015-06-30 2015-11-11 深圳市元征科技股份有限公司 Pedometer
CN105067215A (en) * 2015-08-05 2015-11-18 合肥美的电冰箱有限公司 Method and system for acquiring drop impact test data
CN105351511A (en) * 2015-11-10 2016-02-24 中国北方车辆研究所 Dynamic estimation method of longitudinal acceleration of automatic mechanical transmission vehicle
KR20160020915A (en) * 2014-08-14 2016-02-24 경희대학교 산학협력단 Apparatus and method for counting step in smartphone
WO2016071759A1 (en) * 2014-11-04 2016-05-12 Xsens Holding B.V. Pedestrian dead reckoning position tracker
KR20170111408A (en) * 2016-03-28 2017-10-12 인하대학교 산학협력단 Apparatus and method for step calculation
CN107270931A (en) * 2016-12-23 2017-10-20 浙江从泰网络科技有限公司 A kind of IOS and the general gait auto-correlation pedometer of Android platform
CN110017836A (en) * 2019-04-24 2019-07-16 保定开拓精密仪器制造有限责任公司 Accelerometer digital sample sliding window filters cross clock domain synchronous data transmission method
CN110068322A (en) * 2019-04-18 2019-07-30 中国电子科技集团公司电子科学研究院 A kind of pedestrian's localization method and pedestrian's positioning device based on terminal
CN111238527A (en) * 2020-01-15 2020-06-05 桂林市优创电子科技有限公司 Step counting method based on three-axis acceleration sensor
CN111366170A (en) * 2020-02-19 2020-07-03 维沃移动通信有限公司 State determination method and electronic equipment
CN111442785A (en) * 2020-03-27 2020-07-24 广东工业大学 Step counting method, device and equipment based on inertia and storage medium
CN111854738A (en) * 2020-06-22 2020-10-30 厦门亿联网络技术股份有限公司 Human motion state detection method and device based on three-axis accelerometer
CN111964668A (en) * 2020-08-12 2020-11-20 中移(杭州)信息技术有限公司 Article state detection method and device
CN112212861A (en) * 2020-09-21 2021-01-12 哈尔滨工业大学(深圳) Track restoration method based on single inertial sensor

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11015954B2 (en) * 2017-10-16 2021-05-25 Uti Limited Partnership Step detection using IMU and magnetometer data fusion

Patent Citations (19)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2003315356A (en) * 2002-04-26 2003-11-06 Toyota Motor Corp Sensor device
KR20120020051A (en) * 2010-08-27 2012-03-07 야마하 가부시키가이샤 Pedometer, sampling device, and waveform analyzer
FR3012597A1 (en) * 2013-10-24 2015-05-01 Commissariat Energie Atomique INTERNAL AND EXTERNAL LOCALIZATION METHOD AND PORTABLE DEVICE IMPLEMENTING SAID METHOD
KR20160020915A (en) * 2014-08-14 2016-02-24 경희대학교 산학협력단 Apparatus and method for counting step in smartphone
WO2016071759A1 (en) * 2014-11-04 2016-05-12 Xsens Holding B.V. Pedestrian dead reckoning position tracker
CN105043410A (en) * 2015-06-30 2015-11-11 深圳市元征科技股份有限公司 Pedometer
CN105004349A (en) * 2015-06-30 2015-10-28 深圳市元征科技股份有限公司 Step calculation method
CN105067215A (en) * 2015-08-05 2015-11-18 合肥美的电冰箱有限公司 Method and system for acquiring drop impact test data
CN105351511A (en) * 2015-11-10 2016-02-24 中国北方车辆研究所 Dynamic estimation method of longitudinal acceleration of automatic mechanical transmission vehicle
KR20170111408A (en) * 2016-03-28 2017-10-12 인하대학교 산학협력단 Apparatus and method for step calculation
CN107270931A (en) * 2016-12-23 2017-10-20 浙江从泰网络科技有限公司 A kind of IOS and the general gait auto-correlation pedometer of Android platform
CN110068322A (en) * 2019-04-18 2019-07-30 中国电子科技集团公司电子科学研究院 A kind of pedestrian's localization method and pedestrian's positioning device based on terminal
CN110017836A (en) * 2019-04-24 2019-07-16 保定开拓精密仪器制造有限责任公司 Accelerometer digital sample sliding window filters cross clock domain synchronous data transmission method
CN111238527A (en) * 2020-01-15 2020-06-05 桂林市优创电子科技有限公司 Step counting method based on three-axis acceleration sensor
CN111366170A (en) * 2020-02-19 2020-07-03 维沃移动通信有限公司 State determination method and electronic equipment
CN111442785A (en) * 2020-03-27 2020-07-24 广东工业大学 Step counting method, device and equipment based on inertia and storage medium
CN111854738A (en) * 2020-06-22 2020-10-30 厦门亿联网络技术股份有限公司 Human motion state detection method and device based on three-axis accelerometer
CN111964668A (en) * 2020-08-12 2020-11-20 中移(杭州)信息技术有限公司 Article state detection method and device
CN112212861A (en) * 2020-09-21 2021-01-12 哈尔滨工业大学(深圳) Track restoration method based on single inertial sensor

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
An improved indoor localization method using smartphone inertial sensors;Jiuchao Qian;《International Conference on Indoor Positioning and Indoor Navigation》;1-7 *
基于实时步长匹配的行人室内定位方法;钟立扬;《计算机系统应用》;第26卷(第4期);236-240 *

Also Published As

Publication number Publication date
CN113008242A (en) 2021-06-22

Similar Documents

Publication Publication Date Title
US9730029B2 (en) Unsupervised indoor localization and heading directions estimation
Xie et al. A reliability-augmented particle filter for magnetic fingerprinting based indoor localization on smartphone
CN113008242B (en) User behavior data processing method, device, equipment and storage medium
Mladenov et al. A step counter service for Java-enabled devices using a built-in accelerometer
JP6674791B2 (en) Congestion degree estimation method, number of persons estimation method, congestion degree estimation program, number of persons estimation program, and number of persons estimation system
US10508920B2 (en) Pedestrian dead reckoning position tracker
CN104580660B (en) A kind of mobile intelligent terminal and its step-recording method, system
US9639999B2 (en) System and method for estimating speed of a vehicle
CN106840163A (en) A kind of indoor orientation method and system
US10533874B2 (en) Inertial positioning and navigation device featuring a novel walk detection method
CN105444763A (en) IMU indoor positioning method
CN105022055A (en) IMU indoor positioning method
CN108882169B (en) WiFi position fingerprint data acquisition method and device and robot
CN110231592A (en) Indoor orientation method, device, computer readable storage medium and terminal device
Marron et al. Multi sensor system for pedestrian tracking and activity recognition in indoor environments
Azevedo et al. An analysis of human mobility using real traces
Kang et al. Reduction of mixed noise from wearable sensors in human-motion estimation
Qian et al. RPNOS: Reliable pedestrian navigation on a smartphone
CN110455284A (en) A kind of pedestrian movement patterns' recognition methods and device based on MEMS-IMU
CN105157722A (en) Geographic position monitoring method and equipment
US9185523B2 (en) Method of correcting global position error
CN110612503B (en) Intelligent context sub-sampling device system
Li et al. An indoor collaborative pedestrian dead reckoning system
CN108225368B (en) Step counting device and step counting method
Zhou et al. Indoor route and location inference using smartphone IMU sensors

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant