CN113220208B - Data processing method and device and electronic equipment - Google Patents

Data processing method and device and electronic equipment Download PDF

Info

Publication number
CN113220208B
CN113220208B CN202110456261.4A CN202110456261A CN113220208B CN 113220208 B CN113220208 B CN 113220208B CN 202110456261 A CN202110456261 A CN 202110456261A CN 113220208 B CN113220208 B CN 113220208B
Authority
CN
China
Prior art keywords
mode
track
sliding
information
handwriting input
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
CN202110456261.4A
Other languages
Chinese (zh)
Other versions
CN113220208A (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.)
Beijing Sogou Technology Development Co Ltd
Original Assignee
Beijing Sogou Technology Development 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 Beijing Sogou Technology Development Co Ltd filed Critical Beijing Sogou Technology Development Co Ltd
Priority to CN202110456261.4A priority Critical patent/CN113220208B/en
Publication of CN113220208A publication Critical patent/CN113220208A/en
Application granted granted Critical
Publication of CN113220208B publication Critical patent/CN113220208B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0487Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
    • G06F3/0488Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures
    • G06F3/04883Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures for inputting data by handwriting, e.g. gesture or text
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/0485Scrolling or panning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0487Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
    • G06F3/0488Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures
    • G06F3/04886Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using a touch-screen or digitiser, e.g. input of commands through traced gestures by partitioning the display area of the touch-screen or the surface of the digitising tablet into independently controllable areas, e.g. virtual keyboards or menus
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Abstract

The embodiment of the invention provides a data processing method, a data processing device and electronic equipment, wherein the method comprises the following steps: acquiring sliding track information corresponding to sliding operation of an input method keyboard; predicting a handwriting input mode of interaction intention according to the sliding track information; responding to the handwriting input mode of the interaction intention; and then a plurality of handwriting input modes can be started at the same time; therefore, a user can directly use any handwriting input mode according to the requirement without starting setting, and the input efficiency of the user can be improved.

Description

Data processing method and device and electronic equipment
Technical Field
The present invention relates to the field of data processing technologies, and in particular, to a data processing method, a data processing device, and an electronic device.
Background
With the development of computer technology, electronic devices such as mobile phones and tablet computers are becoming more popular, and great convenience is brought to life, study and work of people. These electronic devices are typically installed with an input method application (input method for short) so that a user can input information using the input method.
At present, the input method has many functions added to simplify user operation and improve user input efficiency and user input experience. Such as handwriting input functions; the handwriting input function may include a plurality of handwriting input modes, such as a keyboard handwriting mode, and after the mode is started, a user can perform handwriting input of text and expressions in other keyboards besides the handwriting keyboard; as another example, a cursor control mode, which when enabled, the user may control the position of a cursor in the edit by sliding in the keyboard; a screen character mode is also adopted, and after the mode is started, a user can slide up a screen number or symbol in an input method keyboard; etc. However, several of these handwriting input modes are mutually exclusive, e.g., after the user enables the keyboard handwriting mode, the cursor control mode cannot be enabled; furthermore, when the user needs to use a handwriting input mode different from the current handwriting input mode, starting setting is needed, and the input efficiency of the user is reduced.
Disclosure of Invention
The embodiment of the invention provides a data processing method for improving input efficiency.
Correspondingly, the embodiment of the invention also provides a data processing device and electronic equipment, which are used for ensuring the realization and application of the method.
In order to solve the above problems, an embodiment of the present invention discloses a data processing method, which specifically includes: acquiring sliding track information corresponding to sliding operation of an input method keyboard; predicting a handwriting input mode of interaction intention according to the sliding track information; responding to the handwriting input mode of the interaction intention.
Optionally, the predicting the handwriting input mode of the interaction intention according to the sliding track information includes: extracting track characteristic information based on the sliding track information; inputting the track characteristic information into a preset classification model to obtain a mode label output by the classification model; and determining the handwriting input mode of the interaction intention based on the mode label output by the classification model.
Optionally, the sliding track information includes coordinate information of a plurality of track points, and the extracting track feature information based on the sliding track information includes: carrying out statistical analysis on coordinate information of a plurality of track points in the sliding track information, and extracting track statistical characteristic information; and/or, carrying out track structure analysis on the coordinate information of a plurality of track points in the sliding track information, and extracting track structure characteristic information; and generating track characteristic information according to the track statistical characteristic information and/or the track structure characteristic information.
Optionally, the determining the handwriting input mode of the interaction intention based on the mode label output by the classification model includes: if the mode label output by the classification model is a first mode label, determining that the handwriting input mode of the interaction intention is a keyboard handwriting mode; if the mode label output by the classification model is a second mode label, determining that the handwriting input mode of the interaction intention is a cursor control mode; and if the mode label output by the classification model is a third mode label, determining that the handwriting input mode of the interaction intention is a character screen-on mode.
Optionally, the responding to the handwriting input mode of the interaction intention includes: if the handwriting input mode of the interaction intention is a keyboard handwriting mode, carrying out stroke matching based on the sliding track information, and determining a corresponding matching candidate; the candidate is shown.
Optionally, the responding to the handwriting input mode of the interaction intention includes: if the handwriting input mode of the interaction intention is a keyboard handwriting mode, generating a hand-drawn graph based on the sliding track information; the hand drawn graphic is shown.
Optionally, the responding to the handwriting input mode of the interaction intention includes: if the handwriting input mode of the interaction intention is a keyboard handwriting mode, searching for a matched expression based on the sliding track information; and displaying the matched expression.
Optionally, the responding to the handwriting input mode of the interaction intention includes: and if the handwriting input mode of the interaction intention is a cursor control mode, moving the position of a cursor in the editing frame based on the sliding track information.
Optionally, the moving the position of the cursor in editing based on the sliding track information includes: determining a sliding direction and a sliding length corresponding to the sliding operation based on the sliding track information; and moving a cursor in the editing frame according to the sliding direction and the sliding length.
Optionally, the responding to the handwriting input mode of the interaction intention includes: if the handwriting input mode of the interaction intention is determined to be a character screen mode, determining a character to be screen on the basis of the sliding track information, wherein the character comprises punctuation or numbers or letters; and displaying the character to be displayed on the screen in an editing frame.
Optionally, the method further comprises the step of training the classification model: collecting training samples, wherein the training samples comprise sliding track information corresponding to the sliding operation of the input method keyboard in a keyboard handwriting mode, sliding track information corresponding to the sliding operation of the input method keyboard in a cursor control mode and sliding track information corresponding to the sliding operation of the input method keyboard in a character screen mode; extracting training track characteristic information of the training sample, and labeling the training track characteristic information with a corresponding reference mode label; and training the classification model according to the training track characteristic information and the corresponding reference mode label.
The embodiment of the invention also discloses a data processing device, which specifically comprises: the acquisition module is used for acquiring sliding track information corresponding to the sliding operation of the input method keyboard; the prediction module is used for predicting the handwriting input mode of the interaction intention according to the sliding track information; and the response module is used for responding to the handwriting input mode of the interaction intention.
Optionally, the prediction module includes: the characteristic extraction submodule is used for extracting track characteristic information based on the sliding track information; the label output sub-module is used for inputting the track characteristic information into a preset classification model to obtain a mode label output by the classification model; and the mode determining submodule is used for determining the handwriting input mode of the interaction intention based on the mode label output by the classification model.
Optionally, the sliding track information includes coordinate information of a plurality of track points, and the feature extraction submodule is used for performing statistical analysis on the coordinate information of the plurality of track points in the sliding track information and extracting track statistical feature information; and/or, carrying out track structure analysis on the coordinate information of a plurality of track points in the sliding track information, and extracting track structure characteristic information; and generating track characteristic information according to the track statistical characteristic information and/or the track structure characteristic information.
Optionally, the mode determining submodule is configured to determine that the handwriting input mode of the interaction intention is a keyboard handwriting mode if the mode label output by the classification model is a first mode label; if the mode label output by the classification model is a second mode label, determining that the handwriting input mode of the interaction intention is a cursor control mode; and if the mode label output by the classification model is a third mode label, determining that the handwriting input mode of the interaction intention is a character screen-on mode.
Optionally, the response module includes: a candidate response sub-module, configured to, if the handwriting input mode of the interaction intent is a keyboard handwriting mode, perform stroke matching based on the sliding track information, and determine a corresponding matched candidate; the candidate is shown.
Optionally, the response module includes: the graph response sub-module is used for generating a hand-drawn graph based on the sliding track information if the handwriting input mode of the interaction intention is a keyboard handwriting mode; the hand drawn graphic is shown.
Optionally, the response module includes: the expression response sub-module is used for searching matched expressions based on the sliding track information if the handwriting input mode of the interaction intention is a keyboard handwriting mode; and displaying the matched expression.
Optionally, the response module includes: and the cursor position moving sub-module is used for moving the position of a cursor in the editing frame based on the sliding track information if the handwriting input mode of the interaction intention is a cursor control mode.
Optionally, the cursor position moving submodule is configured to determine a sliding direction and a sliding length corresponding to the sliding operation based on the sliding track information; and moving a cursor in the editing frame according to the sliding direction and the sliding length.
Optionally, the response module includes: the character screen sub-module is used for determining characters to be screen-displayed based on the sliding track information if the handwriting input mode of the interaction intention is determined to be a character screen mode, wherein the characters comprise punctuation or numbers or letters; and displaying the character to be displayed on the screen in an editing frame.
Optionally, the apparatus further comprises: the training module is used for collecting training samples, wherein the training samples comprise sliding track information corresponding to the sliding operation of the input method keyboard in a keyboard handwriting mode, sliding track information corresponding to the sliding operation of the input method keyboard in a cursor control mode and sliding track information corresponding to the sliding operation of the input method keyboard in a character screen mode; extracting training track characteristic information of the training sample, and labeling the training track characteristic information with a corresponding reference mode label; and training the classification model according to the training track characteristic information and the corresponding reference mode label.
The embodiment of the invention also discloses a readable storage medium, which enables the electronic device to execute the data processing method according to any one of the embodiments of the invention when the instructions in the storage medium are executed by the processor of the electronic device.
The embodiment of the invention also discloses an electronic device, which comprises one or more processors; and one or more readable media having instructions stored thereon that, when executed by the one or more processors, cause the electronic device to perform a data processing method according to any of the embodiments of the present invention.
The embodiment of the invention has the following advantages:
in the embodiment of the invention, the sliding track information corresponding to the sliding operation of the input method keyboard can be obtained in the process that the user executes the sliding operation in the input method keyboard; then predicting the handwriting input mode of the interaction intention according to the sliding track information; responding to the handwriting input mode of the interaction intention, and enabling a plurality of handwriting input modes at the same time; therefore, a user can directly use any handwriting input mode according to the requirement without starting setting, and the input efficiency of the user can be improved.
Drawings
FIG. 1 is a flow chart of steps of an embodiment of a data processing method of the present invention;
FIG. 2 is a flow chart of steps of an alternative embodiment of a data processing method of the present invention;
FIG. 3A is a flowchart illustrating steps of an alternative embodiment of a data processing method of the present invention;
FIG. 3B is an interface diagram of an input method for keyboard handwriting mode response according to an embodiment of the invention;
FIG. 3C is an interface diagram of another input method according to an embodiment of the present invention for keyboard handwriting mode response;
FIG. 4A is a flowchart illustrating steps of yet another alternative embodiment of a data processing method of the present invention;
FIG. 4B is an interface diagram of a keyboard handwriting mode response according to yet another embodiment of the present invention;
FIG. 5A is a flowchart illustrating the steps of yet another alternative embodiment of a data processing method of the present invention;
FIG. 5B is an interface diagram of a keyboard handwriting mode response according to yet another embodiment of the present invention;
FIG. 6A is a flowchart illustrating the steps of an alternative embodiment of a data processing method of the present invention;
FIG. 6B is an interface diagram of an input method for cursor control mode response according to an embodiment of the present invention;
FIG. 6C is an interface diagram of another input method response to a cursor control mode according to an embodiment of the present invention;
FIG. 7A is a flowchart illustrating the steps of an alternative embodiment of a data processing method of the present invention;
FIG. 7B is an interface diagram of an input method for on-screen character mode response according to an embodiment of the present invention;
FIG. 8 is a flow chart of the steps of one embodiment of model training of the present invention;
FIG. 9 is a block diagram of an embodiment of a data processing apparatus of the present invention;
FIG. 10 is a block diagram of an alternative embodiment of a data processing apparatus of the present invention;
FIG. 11 is a block diagram of an electronic device for data processing according to an exemplary embodiment;
Fig. 12 is a schematic structural view of an electronic device for data processing according to another exemplary embodiment of the present invention.
Detailed Description
In order that the above-recited objects, features and advantages of the present invention will become more readily apparent, a more particular description of the invention will be rendered by reference to the appended drawings and appended detailed description.
One of the core ideas of the embodiment of the invention is that in the process of executing sliding operation in an input method keyboard by a user, according to a sliding track corresponding to the sliding operation of the input method keyboard, a handwriting input mode of user interaction intention is judged and responded, and then a plurality of handwriting input modes can be started at the same time; therefore, a user can directly use any handwriting input mode according to the requirement without starting setting, and the input efficiency of the user can be improved.
Referring to fig. 1, a flowchart illustrating steps of an embodiment of a data processing method according to the present invention may specifically include the following steps:
step 102, acquiring sliding track information corresponding to the sliding operation of the input method keyboard.
In the embodiment of the invention, the input method provides a handwriting input function, and a user can perform handwriting input in other types of keyboards besides the handwriting keyboard, such as a Chinese 9-key keyboard, a Chinese 26-key keyboard, an English 26-key keyboard and the like, and the embodiment of the invention is not limited to the above.
The user performs handwriting input on an input method keyboard (may refer to other types of keyboards besides handwriting keyboards), that is, performs sliding operation on the input method keyboard. In the process that a user executes sliding operation in the input method keyboard, the input method keyboard can receive the sliding operation; at this time, the sliding track information corresponding to the sliding operation (may also be referred to as the sliding operation of the input method keyboard) received by the input method keyboard may be obtained. The sliding track information may include coordinate information of a plurality of track points, and the coordinate information may refer to pixel point coordinate information in a display interface and may include an abscissa and an ordinate.
And 104, predicting a handwriting input mode of interaction intention according to the sliding track information.
And then, according to the acquired sliding track information, predicting which handwriting input mode is intended by the user to execute the sliding operation in the input method keyboard. For convenience of subsequent explanation, the handwriting input mode in which the user performs the sliding operation in the input method keyboard may be referred to as the handwriting input mode in which the user interacts with the sliding operation; that is, the interactive intention may refer to an intention of a user to perform a sliding operation in an input method keypad to achieve interaction.
The corresponding characteristic information can be determined by carrying out characteristic analysis on the activity track information; and predicting the handwriting input mode of the interaction intention according to the characteristic information obtained by analysis.
In an alternative embodiment of the present invention, the handwriting input modes may include a plurality of handwriting modes, such as a keyboard handwriting mode (i.e. handwriting input text, graphics), a cursor control mode (i.e. controlling moving cursor position), and a character screen mode (i.e. screen character); etc., and embodiments of the invention are not limited in this regard.
And step 106, responding to the handwriting input mode of the interaction intention.
After determining the handwriting input mode of the interaction intention, the method can respond to the handwriting input mode of the interaction intention, namely, the input function corresponding to the handwriting input mode of the interaction intention is realized. For example, when the handwriting input mode of the interaction intention is a keyboard handwriting mode, corresponding candidates can be displayed; for another example, when the handwriting input mode of the interaction intention is a cursor control mode, the cursor position may be correspondingly moved, and so on.
In summary, in the embodiment of the invention, in the process that a user performs a sliding operation in an input method keyboard, sliding track information corresponding to the sliding operation of the input method keyboard can be obtained; then predicting the handwriting input mode of the interaction intention according to the sliding track information; responding to the handwriting input mode of the interaction intention, and enabling a plurality of handwriting input modes at the same time; therefore, a user can directly use any handwriting input mode according to the requirement without starting setting, and the input efficiency of the user can be improved.
A description is given below of how to predict a handwriting input mode of an interaction intention.
Referring to fig. 2, a flowchart illustrating steps of an alternative embodiment of a data processing method of the present invention may specifically include the steps of:
step 202, acquiring sliding track information corresponding to the sliding operation of the input method keyboard.
In the embodiment of the invention, the sliding track information corresponding to the sliding operation of the input method keyboard can be obtained in real time in the process that the user executes the sliding operation in the input method keyboard; that is, when the user starts to perform the sliding operation, the coordinate information of the track point corresponding to the sliding operation of the input method keyboard is obtained, and then in the process of performing the sliding operation by the user, the coordinate information of the track point corresponding to the sliding operation of the input method keyboard is continuously obtained. After the coordinate information of a track point is obtained, the coordinate information of all track points obtained from the time when the user starts to execute the sliding operation to the current period can be used as the sliding track coordinate information to predict the handwriting input mode of the interaction intention of the user.
The step 204 to step 208 of predicting the handwriting input mode of the interaction intention according to the sliding track information may include:
And 204, extracting track characteristic information based on the sliding track information.
In the embodiment of the present invention, the sliding track information may include coordinate information of a plurality of track points; corresponding track characteristic information can be extracted by analyzing coordinate information in the sliding track information; reference may be made to the following sub-steps 2042 to 2044:
a sub-step 2042 of carrying out statistical analysis on the coordinate information of a plurality of track points in the sliding track information and extracting track statistical characteristic information; and/or carrying out track structure analysis on the coordinate information of a plurality of track points in the sliding track information, and extracting track structure characteristic information.
And 2044, generating track characteristic information according to the track statistical characteristic information and/or the track structure characteristic information.
In one example of the present invention, the track statistics feature information may be extracted based on the coordinate information of a plurality of track points in the sliding track information; the track statistical characteristic information can be used for describing the statistical characteristics of the sliding track corresponding to the sliding operation of the input method keyboard. The method can be used for carrying out statistical analysis on the coordinate information of a plurality of track points in the sliding track information based on a statistical principle, and extracting track statistical characteristic information. Wherein, the statistical parameters such as maximum value, minimum value, skewness, kurtosis, average value, standard deviation, variance, speed, acceleration, shannon entropy and the like can be calculated by adopting the coordinate information of a plurality of track points based on a statistical formula; and then taking the calculated statistical parameters as track statistical characteristic information. Wherein each statistical parameter can be used as a dimension of the track statistical characteristic information; that is, the trajectory statistics may include a plurality of dimensions.
In one example of the present invention, the track structure feature information may be extracted based on the coordinate information of a plurality of track points in the sliding track information; the track structure characteristic information can be used for describing the structure characteristics of a sliding track corresponding to the sliding operation of the input method keyboard. The method comprises the steps of determining structural parameters such as parameter values (used for describing the folding condition) of folding parameters of a sliding track, parameter values (used for describing the dithering condition) of dithering parameters and the like according to coordinate information of a plurality of track points; and then taking the calculated structural parameters as track structural characteristic information. Each structural parameter may be used as one dimension of the track structural feature information, that is, the track structural feature information may also include multiple dimensions.
Then at least one of the track statistics feature information and the track structure feature information can be used as track feature information; correspondingly, the track characteristic information may also include multiple dimensions.
And 206, inputting the track characteristic information into a preset classification model to obtain a mode label output by the classification model.
And step 208, determining the handwriting input mode of the interaction intention based on the mode label output by the classification model.
In the embodiment of the invention, a classification model can be trained in advance, and then the handwriting input mode of the interaction intention is predicted based on the trained classification model (namely a preset classification model); the training method of the classification model is described later.
And the extracted track characteristic information can be input into a trained classification model, the classification model processes the track characteristic information, and a mode label matched with the track characteristic information is output.
Wherein, the mode label can include a plurality of, and a mode label can correspond to a handwriting input mode. In one example, the mode tag may include: a first mode tag, a second mode tag, and a third mode tag. The first mode label can correspond to a handwriting mode of the keyboard, the second mode label can correspond to a cursor control mode, and the third mode label can correspond to a character screen mode. And further, according to the mode label output by the obtained classification model, the handwriting input mode of the interaction intention can be determined.
Of course, other handwriting input modes can be also included, and corresponding mode labels corresponding to the other handwriting input modes can be also included; the embodiments of the present invention are not limited in this regard.
If the mode label output by the classification model is a first mode label, determining that the handwriting input mode of the interaction intention is a keyboard handwriting mode;
if the mode label output by the classification model is a second mode label, determining that the handwriting input mode of the interaction intention is a cursor control mode;
and if the mode label output by the classification model is a third mode label, determining that the handwriting input mode of the interaction intention is a character screen-on mode.
Step 210, responding to the handwriting input mode of the interaction intention.
The handwriting input mode for the user interaction intent may then be responded to, as will be described in subsequent embodiments.
In summary, in the embodiment of the present invention, track feature information may be extracted based on the sliding track information; inputting the track characteristic information into a preset classification model to obtain a mode label output by the classification model, and determining a handwriting input mode of the interaction intention based on the mode label output by the classification model; and further, the model is adopted to predict the handwriting input mode of the user interaction intention, so that the accuracy of prediction can be improved, and the input efficiency of the user is further improved.
Secondly, in the embodiment of the invention, the coordinate information of a plurality of track points in the sliding track information can be subjected to statistical analysis, and track statistical characteristic information is extracted; and/or, carrying out track structure analysis on the coordinate information of a plurality of track points in the sliding track information, and extracting track structure characteristic information; then generating track characteristic information according to the track statistical characteristic information and/or the track structure characteristic information; the track statistical characteristic information and the track structural characteristic information can comprise multiple dimensions, and track characteristic information comprising the multiple dimensions can be extracted, so that the classification model can predict according to more comprehensive characteristics, and the accuracy of prediction is further improved.
The following describes responses to different interactive intention handwriting input modes.
Referring to FIG. 3A, a flowchart of steps of another alternative embodiment of a data processing method of the present invention is shown.
Step 302, acquiring sliding track information corresponding to the sliding operation of the input method keyboard.
And step 304, extracting track characteristic information based on the sliding track information.
Step 306, inputting the track characteristic information into a preset classification model to obtain a mode label output by the classification model.
Steps 302 to 306 may be similar to steps 202 to 206, and are not described herein.
Step 308, if the mode label output by the classification model is the first mode label, determining that the handwriting input mode of the interaction intention is a keyboard handwriting mode.
And 310, carrying out stroke matching based on the sliding track information, and determining a corresponding matching candidate.
Step 312, displaying the candidates.
If the handwriting input mode of the interaction intention is a keyboard handwriting mode, it can be determined that the current sliding operation performed by the user aims at handwriting input of text through the keyboard. At this time, according to the obtained sliding track information, the strokes matched with the sliding track information can be searched from a stroke library; and searching the entry matched with the matched stroke from the lexicon as a candidate and displaying the candidate. In the process of executing the sliding operation by the user, the sliding track information corresponding to the sliding operation of the input method keyboard can be still obtained continuously, and the matching candidates are searched continuously and displayed; that is, in the process of executing the sliding operation by the user, the candidate of matching the sliding track corresponding to the sliding operation received by the input method keyboard can be displayed in real time.
As an example of the present invention, reference may be made to fig. 3B to 3C. The sliding track on the input method keyboard is shown as the track on the 9-key keyboard in fig. 3B, the corresponding "san" is shown in the candidate bar, and after the user continues handwriting "tiger", the sliding track on the input method keyboard is shown as the track on the 9-key keyboard in fig. 3C, the corresponding "show" is shown in the candidate bar.
In summary, in the embodiment of the present invention, when it is determined that the handwriting input mode of the interaction intent is a keyboard handwriting mode, stroke matching may be performed based on the sliding track information, and a candidate corresponding to the matching is determined, and the candidate is displayed; thereby realizing the handwriting input of text by the keyboard.
Referring to FIG. 4A, a flowchart of the steps of yet another alternative embodiment of a data processing method of the present invention is shown.
Step 402, acquiring sliding track information corresponding to the sliding operation of the input method keyboard.
And step 404, extracting track characteristic information based on the sliding track information.
Step 406, inputting the track characteristic information into a preset classification model to obtain a mode label output by the classification model.
Steps 402 to 406 may be similar to steps 202 to 206, and are not described herein.
Step 408, if the mode label output by the classification model is the first mode label, determining that the handwriting input mode of the interaction intention is a keyboard handwriting mode.
Step 410, generating a hand-drawn graph based on the sliding track information.
Step 412, displaying the hand-drawn graph.
If the handwriting input mode of the interaction intention is a keyboard handwriting mode, the purpose of the user for executing the sliding operation currently can be determined to be drawing a graph through keyboard handwriting. At this time, the coordinate information of all track points in the acquired sliding track information can be adopted to generate a corresponding hand-drawn graph; for example, all the track points can be connected in sequence to generate a hand-drawn graph; and displaying the hand-drawn graph. In the process of executing the sliding operation by the user, the sliding track information corresponding to the sliding operation of the input method keyboard can be still obtained continuously, and a hand-painted graph is generated and displayed; that is, in the process of executing the sliding operation by the user, the hand-drawn graph corresponding to the sliding track corresponding to the sliding operation received by the input method keyboard can be displayed in real time.
As an example of the present invention, reference may be made to fig. 4B. The sliding track on the input method keyboard is shown as the track on the 9-key keyboard in fig. 4B, and the corresponding hand drawing shape shown in the candidate bar is shown as the second candidate in the candidate bar in fig. 4B.
In summary, in the embodiment of the present invention, when it is determined that the handwriting input mode of the interaction intent is a keyboard handwriting mode, a hand-drawn graph is generated based on the sliding track information; displaying the hand-drawn graph; thereby realizing the handwriting input of hand-drawn figures by the keyboard.
Referring to FIG. 5A, a flowchart of the steps of yet another alternative embodiment of a data processing method of the present invention is shown.
Step 502, obtaining sliding track information corresponding to the sliding operation of the input method keyboard.
And 504, extracting track characteristic information based on the sliding track information.
Step 506, inputting the track characteristic information into a preset classification model to obtain a mode label output by the classification model.
Steps 502 to 506 may be similar to steps 202 to 206, and are not described herein.
Step 508, if the mode label output by the classification model is the first mode label, determining that the handwriting input mode of the interaction intention is a keyboard handwriting mode.
Step 510, searching for a matched expression based on the sliding track information.
Step 512, displaying the matched expression.
If the handwriting input mode of the interaction intention is the keyboard handwriting mode, the purpose of the current sliding operation of the user can be determined to be to input the expression through the keyboard handwriting. At this time, coordinate information of all track points in the acquired sliding track information can be adopted to match with expressions in an expression library, the expressions matched with the sliding track information can be searched, and the matched expressions can be displayed. In the process of executing the sliding operation by the user, the sliding track information corresponding to the sliding operation of the input method keyboard can be still obtained continuously, and the matched expression is searched and displayed; that is, in the process of executing the sliding operation by the user, the expression matched with the sliding track corresponding to the sliding operation received by the input method keyboard can be displayed in real time.
As an example of the present invention, reference may be made to fig. 5B. The sliding track on the input method keyboard is shown as the track on the 26-key keyboard in fig. 5B, and the corresponding hand drawing shape shown in the candidate bar is shown as the first candidate in the candidate bar in fig. 5B.
In summary, in the embodiment of the present invention, when it is determined that the handwriting input mode of the interaction intent is a keyboard handwriting mode, searching for a matched expression based on the sliding track information, and displaying the matched expression; thereby realizing the handwriting expression input of the keyboard.
Of course, in the embodiment of the present invention, if the handwriting input mode of the interaction intent is a keyboard handwriting mode, stroke matching may be performed based on the sliding track information, a corresponding matching candidate may be determined and displayed, or a hand-drawn graph may be generated and displayed based on the sliding track information; and searching the matched expression based on the sliding track information and displaying the matched expression, which is not limited by the embodiment of the invention.
Referring to FIG. 6A, a flowchart of the steps of yet another alternative embodiment of a data processing method of the present invention is shown.
Step 602, obtaining sliding track information corresponding to the sliding operation of the input method keyboard.
Step 604, extracting track characteristic information based on the sliding track information.
Step 606, inputting the track characteristic information into a preset classification model to obtain a mode label output by the classification model.
Steps 602 to 606 may be similar to steps 202 to 206, and are not described herein.
Step 608, if the mode label output by the classification model is the second mode label, determining that the handwriting input mode of the interaction intention is a cursor control mode.
And 610, moving the position of a cursor in the editing frame based on the sliding track information.
If the handwriting input mode of the interaction intention is a cursor control mode, the purpose of the user currently executing the sliding operation can be determined to be to control the cursor position in the editing frame through a keyboard. At this time, a control manner of the cursor may be determined based on the sliding track information, and then cursor movement may be controlled in accordance with the control manner.
Wherein, the step 610 may include the following substeps 6102 to 6:04:
and a substep 6102, determining a sliding direction and a sliding length corresponding to the sliding operation based on the sliding track information.
Sub-step 6104, moving the cursor in the editing frame according to the sliding direction and the sliding length.
The sliding direction can be determined according to the acquisition time and coordinate information of two adjacent track points; determining the sliding length according to the coordinates of the first acquired track point and the coordinates of the track point obtained currently; and then determining the movement length corresponding to the cursor according to the sliding length and the current position of the cursor in the editing frame. The moving length of the cursor can be used as a unit of characters, and the cursor in the editing frame is moved by the moving length according to the sliding direction. In the process of executing the sliding operation by the user, the sliding track information corresponding to the sliding operation of the input method keyboard is still continuously acquired, and the position of the cursor in the editing frame is moved according to the substeps 6102 to 614; that is, in the process of performing the sliding operation by the user, the position of the cursor in the editing frame can be moved in real time according to the sliding track corresponding to the sliding operation of the input method keyboard.
As an example of the present invention, reference may be made to fig. 6B to 6C. The user slides left on the 9-key keyboard, the sliding track corresponding to the sliding operation in the input method keyboard is shown as the track on the 9-key keyboard in fig. 6B, if the position of the cursor in the edit box is the end of the text, the cursor is moved forward by 2 characters, and the position corresponding to the cursor is shown as the position of the cursor in the edit box in fig. 6B. When the user continuously slides left on the 9-key keyboard, the sliding operation corresponding sliding track in the input method keyboard is shown as the track on the 9-key keyboard in fig. 6C; the cursor may be moved forward by a further 1 character and the position of the corresponding cursor is shown as the cursor position in the edit box in fig. 6C.
In summary, in the embodiment of the present invention, if the handwriting input mode of the interaction intent is a cursor control mode, the position of the cursor in the editing frame is moved based on the sliding track information; and further slide in the keyboard to control the cursor position.
Referring to FIG. 7A, a flowchart of the steps of yet another alternative embodiment of a data processing method of the present invention is shown.
Step 702, obtaining sliding track information corresponding to the sliding operation of the input method keyboard.
And step 704, extracting track characteristic information based on the sliding track information.
Step 706, inputting the track characteristic information into a preset classification model to obtain a mode label output by the classification model.
Steps 702 to 706 may be similar to steps 202 to 206, and are not described herein.
Step 708, if the mode label output by the classification model is a third mode label, determining that the handwriting input mode of the interaction intention is an on-screen character mode.
And step 710, determining a character to be displayed on the screen based on the sliding track information, wherein the character comprises punctuation or numbers or letters.
And step 712, the character to be displayed is displayed on the screen to the editing frame.
If the handwriting input mode of the interaction intention is the on-screen character mode, the purpose of the user for executing the sliding operation currently can be determined to be through handwriting characters in the on-screen keyboard. Wherein the characters may comprise punctuation or numerals or letters. At this time, the character to be displayed may be determined based on the coordinate information of the first track point in the sliding track information. The coordinate information of the first track point can be determined, and the coordinate information belongs to a display area corresponding to which character in the input method keyboard; and determining the character of the display area to which the coordinate information of the first track point belongs as the character to be displayed and displaying the character.
As an example of the present invention, reference may be made to fig. 7B. The user slides up in the 9-key keyboard, and the sliding operation corresponding sliding track in the input method keyboard is shown as the track on the 9-key keyboard in fig. 7B; if the number of the display area to which the first track point of the sliding track belongs is 6, the 6 can be displayed on the screen, as shown by '6' in the edit box of fig. 7B.
In summary, in the embodiment of the present invention, if it is determined that the handwriting input mode of the interaction intent is a character screen mode, determining a character to be screen on the basis of the sliding track information, where the character includes a punctuation mark or a number; the character to be displayed is displayed on the screen to an editing frame; and further realize by sliding the on-screen numbers or characters in the keyboard.
The following describes how the classification model is trained.
Referring to FIG. 8, a flowchart of the steps of one model training embodiment of the present invention is shown.
Step 802, collecting training samples, wherein the training samples comprise sliding track information corresponding to the sliding operation of the input method keyboard in a keyboard handwriting mode, sliding track information corresponding to the sliding operation of the input method keyboard in a cursor control mode and sliding track information corresponding to the sliding operation of the input method keyboard in a character screen mode.
In the embodiment of the invention, the sliding track information corresponding to the sliding operation performed by the user in the input method keyboard under different handwriting input modes can be collected; namely, collecting the sliding track information corresponding to the sliding operation of the input method keyboard under different handwriting modes, and taking the sliding track information as a training sample.
In one example, sliding track information corresponding to the sliding operation of the input method keyboard in the handwriting mode of the keyboard can be collected as a training sample. In the handwriting mode of the keyboard, sliding track information of sliding operation received by the corresponding input method keyboard in the process that a user executes the sliding operation for many times in the input method keyboard can be respectively collected; and a plurality of training samples can be obtained.
In one example, sliding track information corresponding to an input method keyboard sliding operation in a cursor control mode may be collected. In the cursor control mode, sliding track information of sliding operation received by the input method keyboard corresponding to the user in the process of executing the sliding operation for multiple times in the input method keyboard can be collected respectively; and a plurality of training samples can be obtained.
In one example, in the character screen mode, the sliding track information corresponding to the sliding operation of the keyboard of the input method can be input. In the character screen mode, sliding track information of sliding operation received by the input method keyboard corresponding to the user in the process of executing the sliding operation for many times in the input method keyboard can be collected respectively; and a plurality of training samples can be obtained.
Of course, the sliding track information corresponding to the sliding operation of the input method keyboard in other handwriting input modes can be collected as a training sample; and in particular may be determined as desired, as embodiments of the invention are not limited in this regard.
Step 804, extracting training track feature information of the training sample, and labeling the corresponding reference mode label for the training track feature information.
Then, for each training sample, training track feature information corresponding to the training sample may be extracted, which is similar to the above-mentioned sub-steps 2042 to 2044, and will not be described herein. And corresponding reference mode labels can be marked for each training sample; for example, a first mode tag may be set for a training sample generated using sliding track information in keyboard handwriting mode; a second mode tag may be set for a training sample generated using the sliding track information in the cursor control mode; and setting a third mode label by adopting a training sample generated by the sliding track information in the on-screen character mode.
And step 806, training the classification model according to the training track characteristic information and the corresponding reference mode labels.
The training track characteristic information corresponding to one training sample and the corresponding reference mode label can be used as a group of training data; the classification model is then trained using the sets of training data.
The process of training the classification model will now be described using a set of training data as an example. The set of training data may be input into a classification model, which may perform forward computation on training trajectory feature information in the set of training data, outputting a pattern tag. The model labels output by the classification model may then be compared to reference model labels in the set of training data to reverse train the classification model. And training the classification model by adopting each group of training data according to the mode until the trained classification model meets the requirement.
In one example of the invention, the classification model may be Xgboost (eXtreme Gradient Boosting, extreme gradient lifting), which is a lifting tree model that integrates many tree models together to form a strong classifier. In one example, the tree model may be a CART (Classification and Regression Trees, classification and regression tree) model.
Further, through the steps 802 to 804, a classification model required by the embodiment of the present invention and used for predicting the handwriting input mode of the interaction intention can be trained.
It should be noted that, for simplicity of description, the method embodiments are shown as a series of acts, but it should be understood by those skilled in the art that the embodiments are not limited by the order of acts, as some steps may occur in other orders or concurrently in accordance with the embodiments. Further, those skilled in the art will appreciate that the embodiments described in the specification are presently preferred embodiments, and that the acts are not necessarily required by the embodiments of the invention.
Referring to FIG. 9, a block diagram illustrating an embodiment of a data processing apparatus of the present invention may include the following modules:
the acquisition module 902 is configured to acquire sliding track information corresponding to an input method keyboard sliding operation;
a prediction module 904, configured to predict a handwriting input mode of the interaction intent according to the sliding track information;
and a response module 906, configured to respond to the handwriting input mode of the interaction intent.
Referring to FIG. 10, a block diagram of an alternate embodiment of a data processing apparatus of the present invention is shown.
In an alternative embodiment of the present invention, the prediction module 904 includes:
a feature extraction submodule 9042, configured to extract track feature information based on the sliding track information;
the label output submodule 9044 is used for inputting the track characteristic information into a preset classification model to obtain a mode label output by the classification model;
a mode determining sub-module 9046, configured to determine a handwriting input mode of the interaction intent based on the mode label output by the classification model.
In an optional embodiment of the present invention, the sliding track information includes coordinate information of a plurality of track points, and the feature extraction submodule 9042 is configured to perform statistical analysis on the coordinate information of the plurality of track points in the sliding track information, and extract track statistical feature information; and/or, carrying out track structure analysis on the coordinate information of a plurality of track points in the sliding track information, and extracting track structure characteristic information; and generating track characteristic information according to the track statistical characteristic information and/or the track structure characteristic information.
In an optional embodiment of the present invention, the mode determining submodule 9046 is configured to determine that the handwriting input mode of the interaction intention is a keyboard handwriting mode if the mode label output by the classification model is a first mode label; if the mode label output by the classification model is a second mode label, determining that the handwriting input mode of the interaction intention is a cursor control mode; and if the mode label output by the classification model is a third mode label, determining that the handwriting input mode of the interaction intention is a character screen-on mode.
In an alternative embodiment of the present invention, the response module 906 includes:
a candidate response submodule 9062, configured to, if the handwriting input mode of the interaction intent is a keyboard handwriting mode, perform stroke matching based on the sliding track information, and determine a candidate corresponding to the matching; the candidate is shown.
In an alternative embodiment of the present invention, the response module 906 includes:
a graphic response sub-module 9064, configured to generate a hand-drawn graphic based on the sliding track information if the handwriting input mode of the interaction intent is a keyboard handwriting mode; the hand drawn graphic is shown.
In an alternative embodiment of the present invention, the response module 906 includes:
the expression response submodule 9066 is used for searching a matched expression based on the sliding track information if the handwriting input mode of the interaction intention is a keyboard handwriting mode; and displaying the matched expression.
In an alternative embodiment of the present invention, the response module 906 includes:
and a cursor position moving sub-module 9068, configured to, if the handwriting input mode of the interaction intent is a cursor control mode, move the position of the cursor in the editing frame based on the sliding track information.
In an optional embodiment of the present invention, the cursor position moving submodule 9068 is configured to determine a sliding direction and a sliding length corresponding to the sliding operation based on the sliding track information; and moving a cursor in the editing frame according to the sliding direction and the sliding length.
In an alternative embodiment of the present invention, the response module 906 includes:
the character screen sub-module 90610 is configured to determine a character to be screen-printed based on the sliding track information if it is determined that the handwriting input mode of the interaction intention is a character screen mode, where the character includes punctuation or numbers or letters; and displaying the character to be displayed on the screen in an editing frame.
In an alternative embodiment of the present invention, the apparatus further comprises:
the training module 908 is configured to collect training samples, where the training samples include sliding track information corresponding to a sliding operation of the input method keyboard in a handwriting mode of the keyboard, sliding track information corresponding to a sliding operation of the input method keyboard in a cursor control mode, and sliding track information corresponding to a sliding operation of the input method keyboard in a character screen mode; extracting training track characteristic information of the training sample, and labeling the training track characteristic information with a corresponding reference mode label; and training the classification model according to the training track characteristic information and the corresponding reference mode label.
In summary, in the embodiment of the invention, in the process that a user performs a sliding operation in an input method keyboard, sliding track information corresponding to the sliding operation of the input method keyboard can be obtained; then predicting the handwriting input mode of the interaction intention according to the sliding track information; responding to the handwriting input mode of the interaction intention, and enabling a plurality of handwriting input modes at the same time; therefore, a user can directly use any handwriting input mode according to the requirement without starting setting, and the input efficiency of the user can be improved.
For the device embodiments, since they are substantially similar to the method embodiments, the description is relatively simple, and reference is made to the description of the method embodiments for relevant points.
Fig. 11 is a block diagram illustrating a configuration of an electronic device 1100 for data processing according to an example embodiment. For example, electronic device 1100 may be a mobile phone, computer, digital broadcast terminal, messaging device, game console, tablet device, medical device, fitness device, personal digital assistant, smart wearable device, or the like.
Referring to fig. 11, an electronic device 1100 may include one or more of the following components: a processing component 1102, a memory 1104, a power component 1106, a multimedia component 1108, an audio component 1110, an input/output (I/O) interface 1112, a sensor component 1114, and a communication component 1116.
The processing component 1102 generally controls overall operation of the electronic device 1100, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. The processing element 1102 may include one or more processors 1120 to execute instructions to perform all or part of the steps of the methods described above. Further, the processing component 1102 can include one or more modules that facilitate interactions between the processing component 1102 and other components. For example, the processing component 1102 may include a multimedia module to facilitate interaction between the multimedia component 1108 and the processing component 1102.
The memory 1104 is configured to store various types of data to support operations at the electronic device 1100. Examples of such data include instructions for any application or method operating on the electronic device 1100, contact data, phonebook data, messages, pictures, videos, and so forth. The memory 1104 may be implemented by any type or combination of volatile or nonvolatile memory devices such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disk.
The power component 1106 provides power to the various components of the electronic device 1100. The power components 1106 may include a power management system, one or more power sources, and other components associated with generating, managing, and distributing power for the electronic device 1100.
The multimedia component 1108 includes a screen between the electronic device 1100 and the user that provides an output interface. In some embodiments, the screen may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from a user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensor may sense not only the boundary of a touch or slide action, but also the duration and pressure associated with the touch or slide operation. In some embodiments, multimedia component 1108 includes a front camera and/or a rear camera. When the electronic device 1100 is in an operational mode, such as a shooting mode or a video mode, the front-facing camera and/or the rear-facing camera may receive external multimedia data. Each front camera and rear camera may be a fixed optical lens system or have focal length and optical zoom capabilities.
The audio component 1110 is configured to output and/or input an audio signal. For example, the audio component 1110 includes a Microphone (MIC) configured to receive external audio signals when the electronic device 1100 is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signals may be further stored in the memory 1104 or transmitted via the communication component 1116. In some embodiments, the audio component 1110 further comprises a speaker for outputting audio signals.
The I/O interface 1112 provides an interface between the processing component 1102 and peripheral interface modules, which may be keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to: homepage button, volume button, start button, and lock button.
The sensor assembly 1114 includes one or more sensors for providing status assessment of various aspects of the electronic device 1100. For example, the sensor assembly 1114 may detect an on/off state of the electronic device 1100, a relative positioning of components such as a display and keypad of the electronic device 1100, a change in position of the electronic device 1100 or a component of the electronic device 1100, the presence or absence of a user's contact with the electronic device 1100, an orientation or acceleration/deceleration of the electronic device 1100, and a change in temperature of the electronic device 1100. The sensor assembly 1114 may include a proximity sensor configured to detect the presence of nearby objects in the absence of any physical contact. The sensor assembly 1114 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 1114 may also include an acceleration sensor, a gyroscopic sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 1116 is configured to facilitate communication between the electronic device 1100 and other devices, either wired or wireless. The electronic device 1100 may access a wireless network based on a communication standard, such as WiFi,2G, or 3G, or a combination thereof. In one exemplary embodiment, the communication part 1114 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In one exemplary embodiment, the communication component 1114 further includes a Near Field Communication (NFC) module to facilitate short range communications. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, ultra Wideband (UWB) technology, bluetooth (BT) technology, and other technologies.
In an exemplary embodiment, the electronic device 1100 may be implemented by one or more Application Specific Integrated Circuits (ASICs), digital Signal Processors (DSPs), digital Signal Processing Devices (DSPDs), programmable Logic Devices (PLDs), field Programmable Gate Arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic elements for executing the methods described above.
In an exemplary embodiment, a non-transitory computer-readable storage medium is also provided, such as a memory 1104 including instructions executable by the processor 1120 of the electronic device 1100 to perform the above-described method. For example, the non-transitory computer readable storage medium may be ROM, random Access Memory (RAM), CD-ROM, magnetic tape, floppy disk, optical data storage device, etc.
A non-transitory computer readable storage medium, which when executed by a processor of an electronic device, causes the electronic device to perform a data processing method, the method comprising: acquiring sliding track information corresponding to sliding operation of an input method keyboard; predicting a handwriting input mode of interaction intention according to the sliding track information; responding to the handwriting input mode of the interaction intention.
Optionally, the predicting the handwriting input mode of the interaction intention according to the sliding track information includes: extracting track characteristic information based on the sliding track information; inputting the track characteristic information into a preset classification model to obtain a mode label output by the classification model; and determining the handwriting input mode of the interaction intention based on the mode label output by the classification model.
Optionally, the sliding track information includes coordinate information of a plurality of track points, and the extracting track feature information based on the sliding track information includes: carrying out statistical analysis on coordinate information of a plurality of track points in the sliding track information, and extracting track statistical characteristic information; and/or, carrying out track structure analysis on the coordinate information of a plurality of track points in the sliding track information, and extracting track structure characteristic information; and generating track characteristic information according to the track statistical characteristic information and/or the track structure characteristic information.
Optionally, the determining the handwriting input mode of the interaction intention based on the mode label output by the classification model includes: if the mode label output by the classification model is a first mode label, determining that the handwriting input mode of the interaction intention is a keyboard handwriting mode; if the mode label output by the classification model is a second mode label, determining that the handwriting input mode of the interaction intention is a cursor control mode; and if the mode label output by the classification model is a third mode label, determining that the handwriting input mode of the interaction intention is a character screen-on mode.
Optionally, the responding to the handwriting input mode of the interaction intention includes: if the handwriting input mode of the interaction intention is a keyboard handwriting mode, carrying out stroke matching based on the sliding track information, and determining a corresponding matching candidate; the candidate is shown.
Optionally, the responding to the handwriting input mode of the interaction intention includes: if the handwriting input mode of the interaction intention is a keyboard handwriting mode, generating a hand-drawn graph based on the sliding track information; the hand drawn graphic is shown.
Optionally, the responding to the handwriting input mode of the interaction intention includes: if the handwriting input mode of the interaction intention is a keyboard handwriting mode, searching for a matched expression based on the sliding track information; and displaying the matched expression.
Optionally, the responding to the handwriting input mode of the interaction intention includes: and if the handwriting input mode of the interaction intention is a cursor control mode, moving the position of a cursor in the editing frame based on the sliding track information.
Optionally, the moving the position of the cursor in editing based on the sliding track information includes: determining a sliding direction and a sliding length corresponding to the sliding operation based on the sliding track information; and moving a cursor in the editing frame according to the sliding direction and the sliding length.
Optionally, the responding to the handwriting input mode of the interaction intention includes: if the handwriting input mode of the interaction intention is determined to be a character screen mode, determining a character to be screen on the basis of the sliding track information, wherein the character comprises punctuation or numbers or letters; and displaying the character to be displayed on the screen in an editing frame.
Optionally, the method further comprises the step of training the classification model: collecting training samples, wherein the training samples comprise sliding track information corresponding to the sliding operation of the input method keyboard in a keyboard handwriting mode, sliding track information corresponding to the sliding operation of the input method keyboard in a cursor control mode and sliding track information corresponding to the sliding operation of the input method keyboard in a character screen mode; extracting training track characteristic information of the training sample, and labeling the training track characteristic information with a corresponding reference mode label; and training the classification model according to the training track characteristic information and the corresponding reference mode label.
Fig. 12 is a schematic structural view of an electronic device 1200 for data processing according to another exemplary embodiment of the present invention. The electronic device 1200 may be a server, which may vary widely in configuration or performance, and may include one or more central processing units (central processing units, CPU) 1222 (e.g., one or more processors) and memory 1232, one or more storage media 1230 (e.g., one or more mass storage devices) storing applications 1242 or data 1244. Wherein memory 1232 and storage medium 1230 can be transitory or persistent. The program stored on the storage medium 1230 may include one or more modules (not shown), each of which may include a series of instruction operations on a server. Still further, the central processor 1222 may be configured to communicate with a storage medium 1230, executing a series of instruction operations on the storage medium 1230 on a server.
The servers may also include one or more power supplies 1226, one or more wired or wireless network interfaces 1250, one or more input/output interfaces 1258, one or more keyboards 1256, and/or one or more operating systems 1241, such as Windows ServerTM, mac OS XTM, unixTM, linuxTM, freeBSDTM, and the like.
In an exemplary embodiment, the execution of one or more programs by the one or more central processors 1222 by the server is configured to include instructions for: acquiring sliding track information corresponding to sliding operation of an input method keyboard; predicting a handwriting input mode of interaction intention according to the sliding track information; responding to the handwriting input mode of the interaction intention.
Optionally, the predicting the handwriting input mode of the interaction intention according to the sliding track information includes: extracting track characteristic information based on the sliding track information; inputting the track characteristic information into a preset classification model to obtain a mode label output by the classification model; and determining the handwriting input mode of the interaction intention based on the mode label output by the classification model.
Optionally, the sliding track information includes coordinate information of a plurality of track points, and the extracting track feature information based on the sliding track information includes: carrying out statistical analysis on coordinate information of a plurality of track points in the sliding track information, and extracting track statistical characteristic information; and/or, carrying out track structure analysis on the coordinate information of a plurality of track points in the sliding track information, and extracting track structure characteristic information; and generating track characteristic information according to the track statistical characteristic information and/or the track structure characteristic information.
Optionally, the determining the handwriting input mode of the interaction intention based on the mode label output by the classification model includes: if the mode label output by the classification model is a first mode label, determining that the handwriting input mode of the interaction intention is a keyboard handwriting mode; if the mode label output by the classification model is a second mode label, determining that the handwriting input mode of the interaction intention is a cursor control mode; and if the mode label output by the classification model is a third mode label, determining that the handwriting input mode of the interaction intention is a character screen-on mode.
Optionally, the responding to the handwriting input mode of the interaction intention includes: if the handwriting input mode of the interaction intention is a keyboard handwriting mode, carrying out stroke matching based on the sliding track information, and determining a corresponding matching candidate; the candidate is shown.
Optionally, the responding to the handwriting input mode of the interaction intention includes: if the handwriting input mode of the interaction intention is a keyboard handwriting mode, generating a hand-drawn graph based on the sliding track information; the hand drawn graphic is shown.
Optionally, the responding to the handwriting input mode of the interaction intention includes: if the handwriting input mode of the interaction intention is a keyboard handwriting mode, searching for a matched expression based on the sliding track information; and displaying the matched expression.
Optionally, the responding to the handwriting input mode of the interaction intention includes: and if the handwriting input mode of the interaction intention is a cursor control mode, moving the position of a cursor in the editing frame based on the sliding track information.
Optionally, the moving the position of the cursor in editing based on the sliding track information includes: determining a sliding direction and a sliding length corresponding to the sliding operation based on the sliding track information; and moving a cursor in the editing frame according to the sliding direction and the sliding length.
Optionally, the responding to the handwriting input mode of the interaction intention includes: if the handwriting input mode of the interaction intention is determined to be a character screen mode, determining a character to be screen on the basis of the sliding track information, wherein the character comprises punctuation or numbers or letters; and displaying the character to be displayed on the screen in an editing frame.
Optionally, instructions for training the classification model are also included: collecting training samples, wherein the training samples comprise sliding track information corresponding to the sliding operation of the input method keyboard in a keyboard handwriting mode, sliding track information corresponding to the sliding operation of the input method keyboard in a cursor control mode and sliding track information corresponding to the sliding operation of the input method keyboard in a character screen mode; extracting training track characteristic information of the training sample, and labeling the training track characteristic information with a corresponding reference mode label; and training the classification model according to the training track characteristic information and the corresponding reference mode label.
In this specification, each embodiment is described in a progressive manner, and each embodiment is mainly described by differences from other embodiments, and identical and similar parts between the embodiments are all enough to be referred to each other.
Embodiments of the present invention are described with reference to flowchart illustrations and/or block diagrams of methods, terminal devices (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing terminal device to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing terminal device, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While preferred embodiments of the present invention have been described, additional variations and modifications in those embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. It is therefore intended that the following claims be interpreted as including the preferred embodiment and all such alterations and modifications as fall within the scope of the embodiments of the invention.
Further, the age (sex, identification card number, passport number, etc. (adjusted according to need)) and the like according to the embodiments of the present application are not suitable for use of personal information, but are general descriptions.
Finally, it is further noted that relational terms such as first and second, and the like are used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Moreover, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or terminal that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or terminal. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article or terminal device comprising the element.
The foregoing has described in detail a data processing method, a data processing apparatus and an electronic device according to the present invention, and specific examples have been provided herein to illustrate the principles and embodiments of the present invention, the above examples being provided only to assist in understanding the method and core idea of the present invention; meanwhile, as those skilled in the art will have variations in the specific embodiments and application scope in accordance with the ideas of the present invention, the present description should not be construed as limiting the present invention in view of the above.

Claims (16)

1. A method of data processing, comprising:
acquiring sliding track information corresponding to sliding operation of an input method keyboard;
extracting track characteristic information based on the sliding track information;
inputting the track characteristic information into a preset classification model to obtain a mode label output by the classification model; the mode labels comprise a plurality of types, and each mode label corresponds to one handwriting input mode;
determining a handwriting input mode of interaction intention based on the mode label output by the classification model;
responding to the handwriting input mode of the interaction intention;
The sliding track information includes coordinate information of a plurality of track points, and the extracting track feature information based on the sliding track information includes:
carrying out statistical analysis on coordinate information of a plurality of track points in the sliding track information, and extracting track statistical characteristic information, wherein the track statistical characteristic information can be used for describing statistical characteristics of sliding tracks corresponding to sliding operation of an input method keyboard;
carrying out track structure analysis on the coordinate information of a plurality of track points in the sliding track information, and extracting track structure characteristic information;
and generating track characteristic information according to the track statistical characteristic information and the track structure characteristic information.
2. The method of claim 1, wherein the determining the handwriting input mode of the interaction intent based on the mode tag output by the classification model comprises:
if the mode label output by the classification model is a first mode label, determining that the handwriting input mode of the interaction intention is a keyboard handwriting mode;
if the mode label output by the classification model is a second mode label, determining that the handwriting input mode of the interaction intention is a cursor control mode;
And if the mode label output by the classification model is a third mode label, determining that the handwriting input mode of the interaction intention is a character screen-on mode.
3. The method of claim 2, wherein the responding to the handwriting input mode of the interaction intent comprises:
if the handwriting input mode of the interaction intention is a keyboard handwriting mode, carrying out stroke matching based on the sliding track information, and determining a corresponding matching candidate;
the candidate is shown.
4. The method of claim 2, wherein the responding to the handwriting input mode of the interaction intent comprises:
if the handwriting input mode of the interaction intention is a keyboard handwriting mode, generating a hand-drawn graph based on the sliding track information;
the hand drawn graphic is shown.
5. The method of claim 2, wherein the responding to the handwriting input mode of the interaction intent comprises:
if the handwriting input mode of the interaction intention is a keyboard handwriting mode, searching for a matched expression based on the sliding track information;
and displaying the matched expression.
6. The method of claim 2, wherein the responding to the handwriting input mode of the interaction intent comprises:
And if the handwriting input mode of the interaction intention is a cursor control mode, moving the position of a cursor in the editing frame based on the sliding track information.
7. The method of claim 6, wherein moving the position of the cursor in the edit based on the sliding track information comprises:
determining a sliding direction and a sliding length corresponding to the sliding operation based on the sliding track information;
and moving a cursor in the editing frame according to the sliding direction and the sliding length.
8. The method of claim 2, wherein the responding to the handwriting input mode of the interaction intent comprises:
if the handwriting input mode of the interaction intention is determined to be a character screen mode, determining a character to be screen on the basis of the sliding track information, wherein the character comprises punctuation or numbers or letters;
and displaying the character to be displayed on the screen in an editing frame.
9. The method of claim 1, further comprising the step of training the classification model:
collecting training samples, wherein the training samples comprise sliding track information corresponding to the sliding operation of the input method keyboard in a keyboard handwriting mode, sliding track information corresponding to the sliding operation of the input method keyboard in a cursor control mode and sliding track information corresponding to the sliding operation of the input method keyboard in a character screen mode;
Extracting training track characteristic information of the training sample, and labeling the training track characteristic information with a corresponding reference mode label;
and training the classification model according to the training track characteristic information and the corresponding reference mode label.
10. A data processing apparatus, comprising:
the acquisition module is used for acquiring sliding track information corresponding to the sliding operation of the input method keyboard;
the prediction module is used for predicting a handwriting input mode of interaction intention according to the sliding track information;
the response module is used for responding to the handwriting input mode of the interaction intention;
wherein, the prediction module includes:
the characteristic extraction submodule is used for extracting track characteristic information based on the sliding track information;
the label output sub-module is used for inputting the track characteristic information into a preset classification model to obtain a mode label output by the classification model; the mode labels comprise a plurality of types, and each mode label corresponds to one handwriting input mode;
the mode determining submodule is used for determining a handwriting input mode of the interaction intention based on the mode label output by the classification model;
The sliding track information includes coordinate information of a plurality of track points,
the characteristic extraction submodule is used for carrying out statistical analysis on coordinate information of a plurality of track points in the sliding track information and extracting track statistical characteristic information, wherein the track statistical characteristic information can be used for describing statistical characteristics of sliding tracks corresponding to sliding operation of an input method keyboard; carrying out track structure analysis on the coordinate information of a plurality of track points in the sliding track information, and extracting track structure characteristic information; and generating track characteristic information according to the track statistical characteristic information and the track structure characteristic information.
11. The apparatus of claim 10, wherein the device comprises a plurality of sensors,
the mode determining submodule is used for determining that the handwriting input mode of the interaction intention is a keyboard handwriting mode if the mode label output by the classification model is a first mode label; if the mode label output by the classification model is a second mode label, determining that the handwriting input mode of the interaction intention is a cursor control mode; and if the mode label output by the classification model is a third mode label, determining that the handwriting input mode of the interaction intention is a character screen-on mode.
12. The apparatus of claim 11, wherein the response module comprises:
a candidate response sub-module, configured to, if the handwriting input mode of the interaction intent is a keyboard handwriting mode, perform stroke matching based on the sliding track information, and determine a corresponding matched candidate; the candidate is shown.
13. The apparatus of claim 11, wherein the response module comprises:
and the cursor position moving sub-module is used for moving the position of a cursor in the editing frame based on the sliding track information if the handwriting input mode of the interaction intention is a cursor control mode.
14. The apparatus of claim 10, wherein said apparatus further comprises:
the training module is used for collecting training samples, wherein the training samples comprise sliding track information corresponding to the sliding operation of the input method keyboard in a keyboard handwriting mode, sliding track information corresponding to the sliding operation of the input method keyboard in a cursor control mode and sliding track information corresponding to the sliding operation of the input method keyboard in a character screen mode; extracting training track characteristic information of the training sample, and labeling the training track characteristic information with a corresponding reference mode label; and training the classification model according to the training track characteristic information and the corresponding reference mode label.
15. An electronic device, comprising:
one or more processors; and
one or more readable media having instructions stored thereon, which when executed by the one or more processors, cause the electronic device to perform the data processing method of any of claims 1-9.
16. A readable storage medium, characterized in that instructions in said storage medium, when executed by a processor of an electronic device, enable the electronic device to perform the data processing method according to any one of the method claims 1-9.
CN202110456261.4A 2021-04-26 2021-04-26 Data processing method and device and electronic equipment Active CN113220208B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110456261.4A CN113220208B (en) 2021-04-26 2021-04-26 Data processing method and device and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110456261.4A CN113220208B (en) 2021-04-26 2021-04-26 Data processing method and device and electronic equipment

Publications (2)

Publication Number Publication Date
CN113220208A CN113220208A (en) 2021-08-06
CN113220208B true CN113220208B (en) 2023-06-13

Family

ID=77089514

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110456261.4A Active CN113220208B (en) 2021-04-26 2021-04-26 Data processing method and device and electronic equipment

Country Status (1)

Country Link
CN (1) CN113220208B (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103186339A (en) * 2011-12-31 2013-07-03 联想(北京)有限公司 Input method and electronic equipment provided with virtual keyboard
CN104915021A (en) * 2015-05-25 2015-09-16 努比亚技术有限公司 One-hand operation mistaken-touch preventing input method and device and mobile terminal
CN108700996A (en) * 2016-02-23 2018-10-23 迈思慧公司 System and method for multi input management

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104503597B (en) * 2014-12-19 2017-12-12 北京奇虎科技有限公司 stroke input method, device and system

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103186339A (en) * 2011-12-31 2013-07-03 联想(北京)有限公司 Input method and electronic equipment provided with virtual keyboard
CN104915021A (en) * 2015-05-25 2015-09-16 努比亚技术有限公司 One-hand operation mistaken-touch preventing input method and device and mobile terminal
CN108700996A (en) * 2016-02-23 2018-10-23 迈思慧公司 System and method for multi input management

Also Published As

Publication number Publication date
CN113220208A (en) 2021-08-06

Similar Documents

Publication Publication Date Title
US10936798B2 (en) Text editing method, device, and electronic apparatus
US11455491B2 (en) Method and device for training image recognition model, and storage medium
US11138422B2 (en) Posture detection method, apparatus and device, and storage medium
CN113792207B (en) Cross-modal retrieval method based on multi-level feature representation alignment
CN109144285B (en) Input method and device
EP4273742A1 (en) Handwriting recognition method and apparatus, electronic device, and medium
CN107688399B (en) Input method and device and input device
CN110874145A (en) Input method and device and electronic equipment
CN111160047A (en) Data processing method and device and data processing device
CN110764627B (en) Input method and device and electronic equipment
CN107291260B (en) Information input method and device for inputting information
CN113918030A (en) Handwriting input method and device and handwriting input device
CN109388249B (en) Input information processing method and device, terminal and readable storage medium
CN107422921B (en) Input method, input device, electronic equipment and storage medium
CN110858291A (en) Character segmentation method and device
CN108073291B (en) Input method and device and input device
CN111679746A (en) Input method and device and electronic equipment
CN113220208B (en) Data processing method and device and electronic equipment
CN109542244B (en) Input method, device and medium
CN110968246A (en) Intelligent Chinese handwriting input recognition method and device
CN110297678B (en) Input method interface processing method and device
CN113407099A (en) Input method, device and machine readable medium
CN107765884B (en) Sliding input method and device and electronic equipment
CN110554780A (en) sliding input method and device
CN111078022B (en) Input method and device

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
GR01 Patent grant