CN113391741A - Operation checking method and device, storage medium and electronic equipment - Google Patents

Operation checking method and device, storage medium and electronic equipment Download PDF

Info

Publication number
CN113391741A
CN113391741A CN202011270498.5A CN202011270498A CN113391741A CN 113391741 A CN113391741 A CN 113391741A CN 202011270498 A CN202011270498 A CN 202011270498A CN 113391741 A CN113391741 A CN 113391741A
Authority
CN
China
Prior art keywords
screenshot
pixel point
screenshots
parameter set
pixel
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.)
Granted
Application number
CN202011270498.5A
Other languages
Chinese (zh)
Other versions
CN113391741B (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.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen 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 Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN202011270498.5A priority Critical patent/CN113391741B/en
Publication of CN113391741A publication Critical patent/CN113391741A/en
Application granted granted Critical
Publication of CN113391741B publication Critical patent/CN113391741B/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/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/04845Interaction 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 for image manipulation, e.g. dragging, rotation, expansion or change of colour

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Debugging And Monitoring (AREA)
  • Tests Of Electronic Circuits (AREA)

Abstract

The invention discloses an operation checking method and device, a storage medium and electronic equipment. Wherein, the method comprises the following steps: acquiring a plurality of operation screenshots; determining a common pixel point parameter set and a difference pixel point parameter set of a plurality of operation screenshots; verifying a target operation screenshot to be verified through the common pixel point parameter set and the difference pixel point parameter set, wherein the target operation screenshot is a screenshot of a result interface obtained after target operation is performed on a target operation area; and under the condition that the target operation screenshot reaches the verification condition, determining that the target operation is normal operation. The invention solves the technical problem of low operation checking accuracy.

Description

Operation checking method and device, storage medium and electronic equipment
Technical Field
The invention relates to the field of computers, in particular to an operation checking method and device, a storage medium and electronic equipment.
Background
In the prior art, in the process of verifying whether the target operation is normal, whether the target operation to be verified is normal may be determined by comparing the similarity between the screenshot of the result obtained after the target operation to be verified is executed and the screenshot of the result obtained after the normal target operation is executed.
However, merely comparing the similarity of the pictures to check whether the target operation is normal does not result in an accurate check result, which results in low accuracy of operation check.
In view of the above problems, no effective solution has been proposed.
Disclosure of Invention
The embodiment of the invention provides an operation checking method and device, a storage medium and electronic equipment, and aims to at least solve the technical problem of low operation checking accuracy.
According to an aspect of an embodiment of the present invention, there is provided an operation checking method, including: acquiring a plurality of operation screenshots, wherein each operation screenshot in the operation screenshots is a screenshot of a result interface obtained after an operation is performed on a target operation area in an operation interface; determining a common pixel point parameter set and a difference pixel point parameter set of the multiple operation screenshots, wherein the common pixel point parameter set comprises pixel points with the same pixel value at the same position in the multiple operation screenshots, and the difference pixel point parameter set comprises the number of the pixel points with different pixel values at the same position between every two operation screenshots in the multiple operation screenshots; verifying a target operation screenshot to be verified through the common pixel point parameter set and the difference pixel point parameter set, wherein the target operation screenshot is a screenshot of a result interface obtained after target operation is performed on the target operation area; and under the condition that the target operation screenshot reaches a verification condition, determining that the target operation is a normal operation.
According to another aspect of the embodiments of the present invention, there is also provided an operation checking apparatus, including: the system comprises an acquisition unit, a display unit and a display unit, wherein the acquisition unit is used for acquiring a plurality of operation screenshots, and each operation screenshot in the operation screenshots is a screenshot of a result interface obtained after an operation is performed on a target operation area in an operation interface; the first determining unit is used for determining a common pixel parameter set and a difference pixel parameter set of the multiple operation screenshots, wherein the common pixel parameter set comprises pixels with the same pixel value at the same position in the multiple operation screenshots, and the difference pixel parameter set comprises the number of pixels with different pixel values at the same position between every two operation screenshots in the multiple operation screenshots; the verification unit is used for verifying a target operation screenshot to be verified through the public pixel point parameter set and the difference pixel point parameter set, wherein the target operation screenshot is a screenshot of a result interface obtained after target operation is performed on the target operation area; and the second determining unit is used for determining that the target operation is normal operation under the condition that the target operation screenshot reaches a verification condition.
As an alternative example, the first determining unit includes: a third obtaining module, configured to obtain a pixel matrix of each of the operation screenshots, where the pixel matrix includes a pixel value of each pixel point of the operation screenshot and a position of each pixel point; and a second determining module, configured to determine, in a plurality of pixel matrices, a pixel point at a second position as a pixel point in the common pixel parameter set when pixel values of the pixel points at the second position are the same, where the second position is any one position in the pixel matrices.
As an alternative example, the first determining unit includes: the processing module is used for taking any one of the operation screenshots as a first operation screenshot, taking each operation screenshot except the first operation screenshot in the operation screenshots as a second operation screenshot in sequence, and executing the following operations on the first operation screenshot and the second operation screenshot: and under the condition that the pixel values of the pixel points at the same positions in the first operation screenshot and the second operation screenshot are different, adding 1 to a statistical parameter, wherein the initial value of the statistical parameter is zero, the statistical parameter is used for representing the number of the pixel points with different pixel values of the pixel points at the same positions in the first operation screenshot and the second operation screenshot, and after traversing each pixel point of the first operation screenshot and the second operation screenshot, the statistical parameter is used as one parameter in the parameter set of the difference pixel points.
As an alternative example, the first determining unit includes: the fourth obtaining module is used for obtaining a plurality of first screenshots under the condition that the common pixel point parameter set and the difference pixel point parameter set of the plurality of operation screenshots are determined, wherein each first screenshot in the plurality of first screenshots is a screenshot of a result interface obtained after the operation is performed on a target operation area in an operation interface; a third determining module, configured to take the multiple operation screenshots and the multiple first screenshots as multiple second screenshots; a fourth determining module, configured to determine the common pixel parameter set and the difference pixel parameter set of the multiple second screenshots; and a fifth determining module, configured to determine the common pixel point parameter set and the difference pixel point parameter set of the second screenshot as the common pixel point parameter set and the difference pixel point parameter set of the multiple operation screenshots when the common pixel point parameter set of the second screenshot is the same as the common pixel point parameter sets of the multiple operation screenshots and the difference pixel point parameter set of the second screenshot is the same as the difference pixel point parameter sets of the multiple operation screenshots.
According to another aspect of the embodiments of the present invention, there is also provided a computer-readable storage medium, in which a computer program is stored, wherein the computer program is configured to execute the operation checking method when running.
According to another aspect of the embodiments of the present invention, there is also provided an electronic device, including a memory and a processor, where the memory stores a computer program, and the processor is configured to execute the operation checking method through the computer program.
In the embodiment of the invention, a plurality of operation screenshots are obtained, wherein each operation screenshot in the operation screenshots is a screenshot of a result interface obtained after an operation is performed on a target operation area in an operation interface; determining a common pixel point parameter set and a difference pixel point parameter set of the multiple operation screenshots, wherein the common pixel point parameter set comprises pixel points with the same pixel value at the same position in the multiple operation screenshots, and the difference pixel point parameter set comprises the number of the pixel points with different pixel values at the same position between every two operation screenshots in the multiple operation screenshots; verifying a target operation screenshot to be verified through the common pixel point parameter set and the difference pixel point parameter set, wherein the target operation screenshot is a screenshot of a result interface obtained after target operation is performed on the target operation area; in the method, in the process of verifying the target operation, a plurality of operation screenshots after the operation is performed on the target area are obtained, and the target operation screenshot of the target operation is verified through the common pixel point parameter set and the difference pixel point parameter set of the plurality of operation screenshots, so that the target operation screenshot can be verified from the common pixel part and the difference pixel part, the verification accuracy of the target operation screenshot is improved, and the technical problem of low operation verification accuracy is solved.
Drawings
The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the invention and together with the description serve to explain the invention without limiting the invention. In the drawings:
FIG. 1 is a schematic diagram of an application environment of an alternative operation verification method according to an embodiment of the invention;
FIG. 2 is a schematic diagram of an application environment of an alternative operation verification method according to an embodiment of the invention;
FIG. 3 is a flow chart diagram of an alternative operation verification method according to an embodiment of the invention;
FIG. 4 is an operation acquisition diagram of an alternative operation verification method according to an embodiment of the present invention;
fig. 5 is a schematic diagram of a common pixel parameter set of an alternative operation checking method according to an embodiment of the present invention;
fig. 6 is a schematic diagram of comparing a common pixel parameter set with a first pixel point set according to an optional operation checking method of the embodiment of the present invention;
FIG. 7 is a schematic diagram of obtaining a first quantity of an alternative operation checking method according to an embodiment of the present invention;
FIG. 8 is a flow chart diagram of an alternative operation verification method according to an embodiment of the present invention;
FIG. 9 is a schematic diagram of a verification target operation screenshot of an alternative operation verification method according to an embodiment of the present invention;
FIG. 10 is a schematic diagram of an alternative operational verification device, in accordance with embodiments of the present invention;
fig. 11 is a schematic structural diagram of an alternative electronic device according to an embodiment of the invention.
Detailed Description
In order to make the technical solutions of the present invention better understood, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
It should be noted that the terms "first," "second," and the like in the description and claims of the present invention and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the invention described herein are capable of operation in sequences other than those illustrated or described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
According to an aspect of the embodiments of the present invention, an operation checking method is provided, and optionally, as an optional implementation manner, the operation checking method may be applied, but not limited, to the environment shown in fig. 1.
As shown in fig. 1, the terminal device 102 includes a memory 104 for storing various data generated during the operation of the terminal device 102, a processor 106 for processing and operating the various data, and a display 108 for displaying the verification result. An application client may be run on the terminal device 102. Terminal device 102 may interact with server 112 via network 110. The terminal device 102 may send a plurality of operation screenshots and target operation screenshots to the server 112 through S102, and in S104, the server 112 may verify the target operation screenshots and issue a verification result to the terminal device 102 through S106, so that the terminal device 102 displays the verification result. The server 112 includes a database 114 for storing the operation screenshot and the target operation screenshot, and a processing engine 116 for determining a verification result. The terminal device 102 may display the verification result.
As an alternative embodiment, the operation checking method described above may be applied, but not limited to, in the environment shown in fig. 2.
As shown in fig. 2, the terminal device 202 includes a memory 204 for storing various data generated during the operation of the terminal device 202, a processor 206 for processing and operating the various data, and a display 208 for displaying the verification result. Terminal device 202 may execute S202 to S208 to obtain the common pixel point parameter set and the difference pixel point parameter set of the multiple operation screenshots, check the target operation screenshot to obtain a check result, and display the check result.
Optionally, in this embodiment, the terminal device 102 or the terminal device 202 may be a terminal device configured with a target client, and may include, but is not limited to, at least one of the following: mobile phones (such as Android phones, iOS phones, etc.), notebook computers, tablet computers, palm computers, MID (Mobile Internet Devices), PAD, desktop computers, smart televisions, etc. The target client may be a video client, an instant messaging client, a browser client, an educational client, etc. Such networks may include, but are not limited to: a wired network, a wireless network, wherein the wired network comprises: a local area network, a metropolitan area network, and a wide area network, the wireless network comprising: bluetooth, WIFI, and other networks that enable wireless communication. The server may be a single server, a server cluster composed of a plurality of servers, or a cloud server. The above is merely an example, and this is not limited in this embodiment.
Optionally, as an optional implementation manner, as shown in fig. 3, the operation checking method includes:
s302, acquiring a plurality of operation screenshots, wherein each operation screenshot in the operation screenshots is a screenshot of a result interface obtained after an operation is performed on a target operation area in an operation interface;
s304, determining a common pixel point parameter set and a difference pixel point parameter set of a plurality of operation screenshots, wherein the common pixel point parameter set comprises pixel points with the same pixel value at the same position in the plurality of operation screenshots, and the difference pixel point parameter set comprises the number of the pixel points with different pixel values at the same position between every two operation screenshots in the plurality of operation screenshots;
s306, verifying a target operation screenshot to be verified through the common pixel point parameter set and the difference pixel point parameter set, wherein the target operation screenshot is a screenshot of a result interface obtained after target operation is executed on a target operation area;
and S308, determining that the target operation is normal operation under the condition that the screenshot of the target operation reaches the verification condition.
Optionally, the operation checking method may be, but is not limited to, in the process of applying and checking whether the operation is normal. For example, the operation may be one or a combination of several of a single click, a double click, a continuous click, a drag, a slide, and a hold performed through the input device, and the verifying whether the operation is normal may include verifying whether an operation position and an operation type of the operation are normal, for example, verifying whether the target operation is a click operation performed on a button of the target operation area, or verifying whether the target operation is normal may be verifying whether an operation result after the target operation is performed is normal. For example, whether the result obtained after the click operation is performed on the button of the target operation area is normal is verified. And if the operation result of executing the target operation is verified to be normal, the executed target operation is the same as the operation executed when the plurality of operation screenshots are acquired.
Optionally, the operation scenario of the operation verification method is not limited. For example, it may be applied in the context of an application or system or a combination of both.
If the application is applied to the process of judging whether the target operation of the application program is normal, a plurality of operation screenshots for executing the operation on the application program can be obtained, the common pixel point parameter set and the difference pixel point parameter set of the plurality of operation screenshots are obtained, then the target operation is executed on the application program, and the target operation screenshot is verified, so that whether the target operation is normal is determined.
For another example, whether the operation result of the target operation of the system is normal or not may be determined, and multiple operation screenshots of the operation performed on the system may be obtained, for example, a right click-check operation is performed on the system, and multiple operation screenshots are obtained. And then acquiring a common pixel point parameter set and a difference pixel point parameter set of a plurality of operation screenshots, and then executing one-time right-click-viewing operation, namely target operation to obtain a target operation screenshot. And checking the screenshot of the target operation through the common pixel point parameter set and the difference pixel point parameter set to determine whether the target operation is normal. If the system has problems, such as right key failure or checking operation failure, the target operation screenshot is determined to be abnormal after verification, and then the target operation is determined to be abnormal. It can be determined that the operation result of the target operation is abnormal and that the function corresponding to the execution of the target operation is abnormal.
Optionally, the target operation area in the present application may be a display interface, or may be an area in the display interface. Performing an operation in a display interface may cause a change in the display interface. In the embodiment of the application, the screenshot of the result interface obtained after the operation is executed is a picture obtained after the operation is executed in the target operation area. A time value can be preset, for example, 3 seconds after the execution of the operation is finished, screenshot is carried out, and an operation screenshot is obtained.
Optionally, in this embodiment of the present application, the executed operation may be a single operation, or may be a combination of operations. The operation combination comprises a plurality of operations, the operations can be the same or different, and the operations can be consecutive or have intervals in the middle. For example, click once every two seconds, and click three times in total.
Taking the combination operation as an example, as shown in fig. 4, the holding button 402 is dragged from the initial position to the target position within the target operation area to release the button 402, and the corresponding combination operation 404 is obtained.
Optionally, in this embodiment of the present application, if it is determined that the target operation screenshot meets the verification condition, that is, the verification result is normal, it may be determined that the target operation is normal. If the process is a process of checking the function, such as a system function or an application function, if the checking result is normal, it indicates that the system function or the application function is normal. If the operation result is the process of verifying the operation result, if the verification result of the target operation picture is normal, the operation result after the target operation is executed is normal.
This is explained with reference to a specific example. For example, a search button is clicked on a display interface of an application program to obtain a search result, and screenshot is performed on the search result for one operation to obtain a plurality of operation screenshots. And determining a common pixel point parameter set and a difference pixel point parameter set of the multiple operation screenshots. In the testing process, clicking a search button on a display interface of an application program at a certain time to obtain a search result, checking the search result through a common pixel point parameter set and a difference pixel point parameter set to obtain a target operation screenshot, and obtaining a checking result so as to check whether the result obtained by clicking the search button on the display interface of the application program in the testing process is normal or not. If the search function is unresponsive, or the network is disconnected, the search results should be unusual. It is further possible to determine that the search button is abnormal.
In some embodiments, a plurality of reference operation screenshots can be provided in advance to determine a common pixel point parameter set and a difference pixel point parameter set of the plurality of reference operation screenshots, then the operation screenshots obtained in the test are checked through the common pixel point parameter set and the difference pixel point parameter set, the common pixel point parameter set and the difference pixel point parameter set can be customized according to the will or business requirements of a user through the mode of providing the reference operation screenshots in advance, the user-defined requirements are met, and the detection pertinence is stronger. In other embodiments, multiple operation screenshots may be obtained in the using or testing process, the common pixel point parameter set and the difference pixel point parameter set of the multiple operation screenshots are automatically determined according to the multiple operation screenshots, and the target operation screenshot is checked through the common pixel point parameter set and the difference pixel point parameter set, and may be one of the multiple operation screenshots or obtained by the user in other manners.
By the method, the verification result of the target operation screenshot can be determined by using the common pixel point parameter set and the difference pixel point parameter set of the multiple operation screenshots, so that whether the target operation is normal or not is determined, and the effect of improving the accuracy of the verification operation is achieved.
As an optional implementation manner, verifying the target operation screenshot to be verified by using the common pixel point parameter set and the difference pixel point parameter set includes:
acquiring a first pixel point set of a target operation screenshot, wherein the positions of pixel points in the first pixel point set in the target operation screenshot are the same as the positions of pixel points in any one operation screenshot of pixel points in a common pixel point parameter set;
acquiring a first number of pixel points with different pixel values at the same position between a target operation screenshot and any one operation screenshot to obtain a plurality of first numbers;
and under the condition that the pixel values of the pixel points at the same positions in the first pixel point set and the common pixel point parameter set are the same and a plurality of first quantities all belong to the difference pixel point parameter set, determining that the target operation screenshot meets the verification condition.
Optionally, the purpose of obtaining the first pixel point set is to compare the first pixel point set with the common pixel point parameter set, so as to verify the first pixel set by using the common pixel point parameter set, that is, to verify the target operation screenshot by using the common pixel point parameter set. The common pixel parameter set may include a plurality of pixels having the same pixel value at the same position in the operation screenshot. The common pixel parameter set may be a pixel value matrix of pixels, and pixels with different pixel values may be set to a specific value, such as 0 or-1. As shown in fig. 5, fig. 5 is an alternative common pixel point parameter set. In fig. 5, the pixel point with a positive value indicates that the pixel points at the same position in all the operation pictures are the values in the common pixel point parameter set. And the pixel point with the numerical value of-1 shows that the pixel values of the pixel points at the corresponding positions in at least two operation pictures are different. Fig. 5 is merely an example, and the pixels of the operation picture are much more than the representation of fig. 5. Comparing the first pixel point set with the common pixel point parameter set, for example, as shown in fig. 6, the left side of fig. 6 is the first pixel point set, and the right side of fig. 6 is the common pixel point parameter set. And comparing whether the pixel values of the first pixel point set and the common pixel point parameter set are the same or not. During comparison, only the pixel values of the pixel points with the pixel values not being-1 need to be compared. The pixel value of the pixel point with the pixel value of-1 is still-1 after the comparison. In fig. 6, the case 602 is a case where the pixel values are the same, and the case 604 is a case where the pixel values are different. As long as the common pixel point parameter set and the first pixel point set have the condition that the pixel values are different according to the above condition 604, the verification of the target operation picture does not reach the verification condition. One of the verification conditions requires that the common pixel point parameter set is identical to the pixel value of the pixel point at the same position of the first pixel point set (excluding the position where the pixel value is-1).
Optionally, the target operation screenshot is verified by using the difference pixel point parameter set, and the target operation screenshot and a first number of each of the plurality of operation screenshots may be obtained first. The first quantity is the quantity of pixel points with different pixel values at the same position in the comparison operation screenshot and any one of the operation screenshots. For example, for any one operation screenshot, the pixel values of the pixel points at the same position in the operation screenshot and the target operation screenshot are compared. As shown in fig. 7, the left side in fig. 7 is the pixel value of the pixel point of the operation screenshot, and the right side is the pixel value of the pixel point of the target operation screenshot. The pixel values 702 in fig. 7 are different and the first number needs to be counted. The first number is counted as 4.
And if the pixel values of the pixels at the same positions of the first pixel point set and the common pixel point parameter set are the same and the first number belongs to the difference pixel point parameter set, the target operation screenshot passes verification and the target operation screenshot is considered to reach the verification condition. Through the embodiment, the target operation screenshot can be accurately checked, and the checking accuracy is improved.
As an optional implementation, obtaining the first pixel point set of the target operation screenshot includes:
acquiring a first position of each pixel point in the public pixel point parameter set;
acquiring a first pixel point at a first position from a target operation screenshot;
and determining the first pixel points as pixel points in the first pixel point set.
Optionally, since the pixel values of the pixels in the first pixel point set of the target operation screenshot and the common pixel point parameter set of the multiple operation screenshots need to be compared, the pixels at the same positions as the pixels in the common pixel point parameter set need to be obtained from the target operation screenshot.
Or, if the common pixel parameter set is a pixel value matrix of the pixels, the pixels with the pixel values as original values in the common pixel parameter set can also be obtained, and then the pixels with the same positions as the pixels with the pixel values as original values in the common pixel parameter set in the target operation screenshot are determined as the pixels in the first pixel set. That is to say, in the process of comparing the first pixel point set with the common pixel point parameter set, only the pixel points with the original pixel values in the common pixel point parameter set and the corresponding pixel points in the target operation screenshot need to be compared, so that the comparison efficiency is improved.
As an optional implementation manner, the obtaining of the first number of pixel points with different pixel values at the same position between the target operation screenshot and any one operation screenshot includes:
determining any one operation screenshot as a current operation screenshot, and executing the following operations on the target operation screenshot and the current operation screenshot: under the condition that the pixel values of pixel points at any one same position of the target operation screenshot and the current operation screenshot are different, increasing 1 for the first number of the target operation screenshot and the current operation screenshot, wherein the initial value of the first number of the target operation screenshot and the current operation screenshot is zero.
That is to say, the pixel values of the pixel points at the same positions of the target operation screenshot and the current operation screenshot are compared, if the pixel values of the pixel points at the same positions are the same, no recording is made, and if the pixel values of the pixel points at the same positions are different, the first number is added by 1, so that the number of the pixel points at the same positions in the target operation screenshot and the current operation screenshot, which are different in pixel value, is recorded. And judging whether the first quantity belongs to the difference pixel point parameter set. Since there may be a plurality of first quantities, it is necessary to determine whether each of the first quantities belongs to the disparity pixel parameter set. And if the first quantity does not belong to the difference pixel point parameter set, the verification of the target operation screenshot is not passed, and the verification condition is not met.
As an optional implementation, determining a common pixel point parameter set of the multiple operation screenshots includes:
acquiring a pixel matrix of each operation screenshot of a plurality of operation screenshots, wherein the pixel matrix comprises a pixel value of each pixel point of the operation screenshot and a position of each pixel point;
and determining the pixel point at the second position as one pixel point in the parameter set of the public pixel points under the condition that the pixel values of the pixel points at the second position in the pixel matrixes are the same, wherein the second position is any position in the pixel matrixes.
Optionally, determining the common pixel point parameter set may first determine whether the pixel values of the pixel points at the same position in each of the multiple operation screenshots are the same. And if the pixel values of the pixel points at the same position of the multiple operation screenshots are the same, the multiple operation screenshots are the same operation screenshots. If the pixel values of some pixel points at the same position are different, the multiple operation screenshots are different. The common pixel point parameter set is used for storing the positions and the pixel values of the lower pixel points which are the same. Through the embodiment, the effect of improving the accuracy of the common pixel point parameter set can be achieved.
As an optional implementation, determining the difference pixel point parameter sets of the multiple operation screenshots includes:
taking any one of the operation screenshots as a first operation screenshot, taking each operation screenshot except the first operation screenshot of the operation screenshots as a second operation screenshot in sequence, and executing the following operations on the first operation screenshot and the second operation screenshot: and under the condition that the pixel values of the pixel points at the same positions in the first operation screenshot and the second operation screenshot are different, adding 1 to the statistical parameter, wherein the initial value of the statistical parameter is zero, the statistical parameter is used for representing the number of the pixel points with different pixel values of the pixel points at the same positions in the first operation screenshot and the second operation screenshot, and after traversing each pixel point of the first operation screenshot and the second operation screenshot, the statistical parameter is used as one parameter in the parameter set of the difference pixel points.
Optionally, when comparing the difference pixel point parameter sets, after obtaining a plurality of operation screenshots, the statistical parameters between every two operation screenshots need to be obtained. I.e. the number of pixels with different pixel values at the same position. And comparing every two operation screenshots from the first pixel point, if the pixel values are the same, not processing, if the pixel values are different, adding 1 to the statistical parameter, and traversing every two operation screenshots to obtain the statistical parameter of every two operation screenshots. And taking the statistical parameter as one parameter in the difference pixel point parameter set.
As an optional implementation, determining the common pixel point parameter set and the difference pixel point parameter set of the multiple operation screenshots includes:
under the condition that a common pixel point parameter set and a difference pixel point parameter set of a plurality of operation screenshots are determined, a plurality of first screenshots are obtained, wherein each first screenshot in the plurality of first screenshots is a screenshot of a result interface obtained after an operation is performed on a target operation area in an operation interface;
taking the plurality of operation screenshots and the plurality of first screenshots as a plurality of second screenshots;
determining a common pixel point parameter set and a difference pixel point parameter set of a plurality of second screenshots;
and under the condition that the common pixel point parameter set of the second screenshot is the same as the common pixel point parameter sets of the multiple operation screenshots, and the difference pixel point parameter set of the second screenshot is the same as the difference pixel point parameter sets of the multiple operation screenshots, determining the common pixel point parameter set and the difference pixel point parameter set of the second screenshot as the common pixel point parameter set and the difference pixel point parameter set of the multiple operation screenshots.
Optionally, in this embodiment of the application, after obtaining the multiple operation screenshots and determining the common pixel point parameter set and the difference pixel point parameter set, one or more operation screenshots may be obtained again, and the obtained operation screenshots and new common pixel point parameter sets and difference pixel point parameter sets of the multiple operation screenshots are determined. For example, two or more operation screenshots, taking two operation screenshots as an example, as an operation screenshot 1 and an operation screenshot 2, are obtained, a common pixel point parameter set and a difference pixel point parameter set of the operation screenshot 1 and the operation screenshot 2 are determined, and then an operation screenshot 3 is obtained, and the common pixel point parameter set and the difference pixel point parameter set of the operation screenshots 1-3 are determined. And if the common pixel point parameter set and the difference pixel point parameter set of the operation screenshot 1-3 are different from those of the operation screenshot 1 and the operation screenshot 2, the common pixel point parameter set and the difference pixel point parameter set of the operation screenshot 1-3 are reserved. And then, the operation screenshot 4 can be obtained, and the common pixel point parameter set and the difference pixel point parameter set of the operation screenshot 1-4 are determined. And if the common pixel point parameter set and the difference pixel point parameter set of the operation screenshot 1-4 are different from those of the operation screenshot 1-3, keeping the common pixel point parameter set and the difference pixel point parameter set of the operation screenshot 1-4. And if the common pixel point parameter set and the difference pixel point parameter set of the operation screenshot 1-4 are the same as those of the operation screenshot 1-3, the situation that the parameter sets are the same for one time is considered to occur. If the same parameter sets continuously occur for multiple times, for example, the common pixel point parameter set and the difference pixel point parameter set of the operation screenshots 1-5 are the same as the common pixel point parameter set and the difference pixel point parameter set of the operation screenshots 1-4, it can be considered that the current common pixel point parameter set and the difference pixel point parameter set are the common pixel point parameter set and the difference pixel point parameter set which meet the requirements, the common pixel point parameter set and the difference pixel point parameter set which meet the requirements are determined as the common pixel point parameter set and the difference pixel point parameter set of the multiple operation screenshots, and the common pixel point parameter set and the difference pixel point parameter set of the multiple operation screenshots are used for verifying the target operation screenshots. The above-mentioned case where the parameter sets are the same for a plurality of consecutive occurrences may be set according to practical situations, for example, to 3. By the embodiment, the accuracy of the determined common pixel point parameter set and the difference pixel point parameter set is improved.
As an optional implementation, acquiring multiple operation screenshots includes:
acquiring an operation executed on a target operation area in an operation interface;
performing screenshot on the result interface under the condition of automatically executing the operation to obtain the result interface of the operation to obtain one operation screenshot in a plurality of operation screenshots;
and repeatedly executing the operation, and carrying out screenshot on the result interface to obtain a plurality of operation screenshots.
Optionally, in this embodiment of the application, an operation performed by a user in the target operation area may be recorded. Such as recording operation content, operation track, etc. And then automatic playback is carried out, and the automatic playback can automatically execute the operation which is already executed by the user without executing the operation again by the user. And after automatic playback, screenshot can be carried out to obtain an operation screenshot.
For example, after the user performs one operation, the operation is saved, then the playback number is set, for example, 100 times, and then after the user clicks the start, the system automatically plays back the operation performed by the user and automatically captures a picture, resulting in 100 operation screenshots. Through the embodiment, the effect of improving the efficiency of obtaining the operation screenshot is achieved.
The above operation checking method is explained below with reference to a specific example.
In the embodiment of the application, the common pixel point parameter set and the difference pixel point parameter set of the operation screenshot can be determined to be capable of learning in advance. And after learning to obtain the common pixel point parameter set and the difference pixel point parameter set, using the common pixel point parameter set and the difference pixel point parameter set. It should be noted that the embodiment of the present application does not necessarily have to be explicitly demarcated for learning and using at the time of execution, but is explained by two stages of learning and using.
A recording engine: an engine for recording user behavior. The operations performed by the user may be recorded.
A playback engine: an engine for playing back user behavior can automatically play back operations performed by a user, namely, automatically perform the operations performed by the user.
In the recording process, a user can click to start recording and end recording to perform recording, record the recorded operation and add a unique identifier. Such as by operating to click a button on the screen. After the recording is completed, the recorded operation may be saved. The operation may be played back by the playback engine. The process of the playback operation does not need the participation of the user, and only needs the user to set the playback times. If 100 times, click the button 100 times. During playback, a screenshot can be taken of the result of each playback. For example, clicking once the button to capture a screenshot obtains an operation screenshot. Of course, the operation screenshots obtained by recording different operations and playing back different operations need to be distinguished and saved. In the present embodiment, an explanation is given taking an example relating to one operation. The gray-scale image of the operation screenshot can be used as the operation screenshot. The comparison pixel value can also be a comparison gray scale value.
After the operation screenshot of the operation is obtained, learning of the common pixel point parameter set and the difference pixel point parameter set can be performed. For example, if the pixel values of the pixel points at a position of each operation screenshot are the same, for example, the pixel values of the pixel points at row 1 and column 3 of each operation screenshot are all 175, the pixel points at the position should be stored in the common pixel point parameter set. The common pixel parameter set records the position and the pixel value of the pixel. If the pixel values of any at least two operation screenshots at a position are different, the pixel point at the position in the common pixel point parameter set can be set to be-1. And after comparing the three operation screenshots, obtaining a common pixel point parameter set of the three operation screenshots. The difference pixel point parameter set is the number of pixel points with different pixel values at the same position between every two of the three operation screenshots. And if the pixel values of the pixel points in the first row and the first column are different in the first operation screenshot and the second operation screenshot, counting from 0, and increasing the count by 1 each time the pixel value of one pixel point is different until the first operation screenshot and the second operation screenshot are traversed to obtain the number of the pixel points with different pixel values at the same position of the first operation screenshot and the second operation screenshot. This number is used as one parameter in the difference pixel parameter set. The difference pixel point parameter set has a plurality of parameters, and if the parameters are the same, the parameters are combined into one parameter. For example, three operation screenshots result in a difference pixel point parameter set: {12575,2254,11355}.
Of course, the common pixel parameter set and the difference pixel parameter set of the three operation screenshots may be unstable. If the fourth operation screenshot is obtained, the common pixel point parameter set and the difference pixel point parameter set of the first to fourth operation screenshots are determined, and if the common pixel point parameter set and the difference pixel point parameter set of the three operation screenshots are different, a new common pixel point parameter set and a new difference pixel point parameter set need to be stored. For example, the new delta pixel parameter set may be {12575, 2254,11355, 2700, 5900, 10600 }. And if the fifth operation screenshot is obtained, then the public pixel point parameter set and the difference pixel point parameter set of the first to fifth operation screenshots are obtained, and the new public pixel point parameter set and the new difference pixel point parameter set are stored. If the operation screenshots are continuously obtained, if a sixth operation screenshot, a seventh operation screenshot and an eighth operation screenshot are obtained, the public pixel point parameter sets and the difference pixel point parameter sets of the first to sixth operation screenshots, the public pixel point parameter sets and the difference pixel point parameter sets of the first to seventh operation screenshots, and the public pixel point parameter sets and the difference pixel point parameter sets of the first to eighth operation screenshots are not changed any more and are the same as the public pixel point parameter set and the difference pixel point parameter set of the fifth operation screenshot, the public pixel point parameter set and the difference pixel point parameter set of the current operation screenshot are considered to be stable. That is to say, the continuously obtained common pixel point parameter sets and the difference pixel point parameter sets of the operation screenshots are stable if no change occurs for many times. If the operation screenshot is continuously obtained subsequently, for example, if the target operation screenshot is obtained, the common pixel point parameter set and the difference pixel point parameter set of the stable operation screenshot can be used for verifying the target operation screenshot.
The flowchart may be as shown in steps S802 to S816 of fig. 8. S802, recording user operation, S804, playing back the user operation to obtain an operation screenshot, S806, determining a public pixel point parameter set and a difference pixel point parameter set, S808, continuously obtaining the operation screenshot to obtain a stable public pixel point parameter set and a difference pixel point parameter set, S810, storing the public pixel point parameter set and the difference pixel point parameter set, S812, obtaining a target operation screenshot, 814, verifying the target operation screenshot by using the public pixel point parameter set and the difference pixel point parameter set, S816, and displaying a verification result. Specifically, after the recording engine finishes recording a scene, that is, after the recording engine records a user operation, the background server already acquires all information of the scene, such as specific information of an operation track, an operation type, and the like, and automatically issues a specified number of learning tasks (configurable, default is 3), that is, automatically executes the operation three times. The playback engine completes the analysis execution, automatically executes three times of operations, and reports screenshot information after the execution of each operation is completed. According to the operation screenshot obtained each time, the algorithm firstly carries out data iteration on all submitted operation screenshots to calculate a public part, namely a public pixel point parameter set, the result is a two-dimensional matrix, the original value is reserved if the operation screenshots are the same, the operation screenshots are counted as-1 if the operation screenshots are different, secondly, the screenshots are compared in pairs to obtain a difference pixel number list, namely a difference pixel point parameter set. And finally, if the public two-dimensional matrix and the difference pixel number list are not changed in the 3 times of newly reported screenshots, the mode is stable, the learning stage is finished, and the mode is stored. In this mode, that is, in the user operation, if the user operation is executed again to obtain the target operation screenshot, the saved mode may be used to verify the target operation screenshot. The modes can be user operations, and different user operations correspond to different modes. The results can be seen in fig. 9. For one target operation screenshot, the target operation screenshot may be identical to one of the operation screenshots. If the two-dimensional matrix of the gray value or the two-dimensional matrix of the pixel value of the target operation screenshot is completely the same as one of the operation screenshots S902, comparing the pixel value of the two-dimensional matrix with the gray value. If the target operation screenshot and the operation screenshot have the same content, the same part is compared with the common pixel parameter set, that is, S904, and the pixel value or the gray value of the two-dimensional matrix of the common part is compared. For the differential portion, it may be compared whether the number of the pixels of the differential portion belongs to the differential pixel parameter set, for example, in S906, whether the number of the pixels of the two-dimensional matrix of the differential portion is in the differential pixel parameter set, or in S908, whether the number of the pixels of the two-dimensional matrix of the differential portion is in the sum of the differential pixel parameter set and the error value. For example, if one parameter of the difference pixel parameter set is 50000, and the values +2000 and-2000 are set as error values, the number of the difference pixels is considered to be in the difference pixel parameter set as long as the number of the difference pixels is between 48000 and 52000. It should be noted that the steps S902 to S908 may be executed alternatively or in a selected manner, and the execution order is not limited.
In the verification process, when the playback engine receives a verification task, the screenshot record is imported into a verification table. When the picture checking engine finds that tasks to be verified in the verification table are to be verified, the algorithm of the verification stage is executed, the pictures to be verified are subjected to public two-dimensional matrix matching, and the difference pixel number calculation is carried out on the pictures to be verified and the pictures in any learning stage.
It should be noted that, for simplicity of description, the above-mentioned method embodiments are described as a series of acts or combination of acts, but those skilled in the art will recognize that the present invention is not limited by the order of acts, as some steps may occur in other orders or concurrently in accordance with the invention. Further, those skilled in the art should also appreciate that the embodiments described in the specification are preferred embodiments and that the acts and modules referred to are not necessarily required by the invention.
According to another aspect of the embodiment of the present invention, there is also provided an operation verification apparatus for implementing the operation verification method described above. As shown in fig. 10, the apparatus includes:
the acquiring unit 1002 is configured to acquire multiple operation screenshots, where each operation screenshot in the multiple operation screenshots is a screenshot of a result interface obtained after an operation is performed on a target operation area in an operation interface;
the first determining unit 1004 is configured to determine a common pixel parameter set and a differential pixel parameter set of the multiple operation screenshots, where the common pixel parameter set includes pixels with the same pixel value at the same position in the multiple operation screenshots, and the differential pixel parameter set includes the number of pixels with different pixel values at the same position between every two operation screenshots in the multiple operation screenshots;
the verification unit 1006 is configured to verify a target operation screenshot to be verified through the common pixel point parameter set and the difference pixel point parameter set, where the target operation screenshot is a screenshot of a result interface obtained after a target operation is performed on a target operation area;
the second determining unit 1008 is configured to determine that the target operation is a normal operation when the target operation screenshot reaches the verification condition.
Optionally, the operation checking device may be, but not limited to, in the process of applying and checking whether the operation is normal. For example, the operation may be one or a combination of several of a single click, a double click, a continuous click, a drag, a slide, and a hold performed through the input device, and the verifying whether the operation is normal may include verifying whether an operation position and an operation type of the operation are normal, for example, verifying whether the target operation is a click operation performed on a button of the target operation area, or verifying whether the target operation is normal may be verifying whether an operation result after the target operation is performed is normal. For example, whether the result obtained after the click operation is performed on the button of the target operation area is normal is verified. And if the operation result of executing the target operation is verified to be normal, the executed target operation is the same as the operation executed when the plurality of operation screenshots are acquired.
Optionally, the operation scenario of the operation verification method is not limited. For example, it may be applied in the context of an application or system or a combination of both.
If the application is applied to the process of judging whether the target operation of the application program is normal, a plurality of operation screenshots for executing the operation on the application program can be obtained, the common pixel point parameter set and the difference pixel point parameter set of the plurality of operation screenshots are obtained, then the target operation is executed on the application program, and the target operation screenshot is verified, so that whether the target operation is normal is determined.
For another example, whether the operation result of the target operation of the system is normal or not may be determined, and multiple operation screenshots of the operation performed on the system may be obtained, for example, a right click-check operation is performed on the system, and multiple operation screenshots are obtained. And then acquiring a common pixel point parameter set and a difference pixel point parameter set of a plurality of operation screenshots, and then executing one-time right-click-viewing operation, namely target operation to obtain a target operation screenshot. And checking the screenshot of the target operation through the common pixel point parameter set and the difference pixel point parameter set to determine whether the target operation is normal. If the system has problems, such as right key failure or checking operation failure, the target operation screenshot is determined to be abnormal after verification, and then the target operation is determined to be abnormal. It can be determined that the operation result of the target operation is abnormal and that the function corresponding to the execution of the target operation is abnormal.
For other examples of this embodiment, please refer to the above examples, which are not described herein again.
According to another aspect of the embodiment of the present invention, there is also provided an electronic device for implementing the operation verification method, where the electronic device may be a terminal device or a server shown in fig. 11. The present embodiment takes the electronic device as an example for explanation. As shown in fig. 11, the electronic device comprises a memory 1102 and a processor 1104, wherein the memory 1102 stores a computer program and the processor 1104 is arranged to execute the steps of any of the above method embodiments by means of the computer program.
Optionally, in this embodiment, the electronic device may be located in at least one network device of a plurality of network devices of a computer network.
Optionally, in this embodiment, the processor may be configured to execute the following steps by a computer program:
acquiring a plurality of operation screenshots, wherein each operation screenshot in the operation screenshots is a screenshot of a result interface obtained after an operation is performed on a target operation area in an operation interface;
determining a common pixel point parameter set and a difference pixel point parameter set of a plurality of operation screenshots, wherein the common pixel point parameter set comprises pixel points with the same pixel value at the same position in the plurality of operation screenshots, and the difference pixel point parameter set comprises the number of the pixel points with different pixel values at the same position between every two operation screenshots in the plurality of operation screenshots;
verifying a target operation screenshot to be verified through the common pixel point parameter set and the difference pixel point parameter set, wherein the target operation screenshot is a screenshot of a result interface obtained after target operation is performed on a target operation area;
and under the condition that the target operation screenshot reaches the verification condition, determining that the target operation is normal operation.
Alternatively, it can be understood by those skilled in the art that the structure shown in fig. 11 is only an illustration, and the electronic device may also be a terminal device such as a smart phone (e.g., an Android phone, an iOS phone, etc.), a tablet computer, a palmtop computer, a Mobile Internet Device (MID), a PAD, and the like. Fig. 11 is a diagram illustrating a structure of the electronic device. For example, the electronics may also include more or fewer components (e.g., network interfaces, etc.) than shown in FIG. 11, or have a different configuration than shown in FIG. 11.
The memory 1102 may be used to store software programs and modules, such as program instructions/modules corresponding to the operation checking method and apparatus in the embodiments of the present invention, and the processor 1104 executes various functional applications and data processing by running the software programs and modules stored in the memory 1102, that is, the operation checking method described above is implemented. The memory 1102 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 1102 can further include memory located remotely from the processor 1104 and such remote memory can be coupled to the terminal via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof. The memory 1102 may be specifically, but not limited to, used for storing information such as an operation screenshot and a target operation screenshot. As an example, as shown in fig. 11, the memory 1102 may include, but is not limited to, an obtaining unit 1002, a first determining unit 1004, a verifying unit 1006, and a second determining unit 1008 in the operation verifying apparatus. In addition, the operation verification device may further include, but is not limited to, other module units in the operation verification device, which is not described in detail in this example.
Optionally, the transmitting device 1106 is used for receiving or transmitting data via a network. Examples of the network may include a wired network and a wireless network. In one example, the transmission device 1106 includes a Network adapter (NIC) that can be connected to a router via a Network cable to communicate with the internet or a local area Network. In one example, the transmission device 1106 is a Radio Frequency (RF) module, which is used for communicating with the internet in a wireless manner.
In addition, the electronic device further includes: a display 1108 for displaying the verification result; and a connection bus 1110 for connecting the respective module components in the above-described electronic apparatus.
In other embodiments, the terminal device or the server may be a node in a distributed system, where the distributed system may be a blockchain system, and the blockchain system may be a distributed system formed by connecting a plurality of nodes through a network communication. Nodes can form a Peer-To-Peer (P2P, Peer To Peer) network, and any type of computing device, such as a server, a terminal, and other electronic devices, can become a node in the blockchain system by joining the Peer-To-Peer network.
According to a further aspect of an embodiment of the present invention, there is also provided a computer-readable storage medium having a computer program stored thereon, wherein the computer program is arranged to perform the steps of any of the above method embodiments when executed.
Alternatively, in the present embodiment, the above-mentioned computer-readable storage medium may be configured to store a computer program for executing the steps of:
acquiring a plurality of operation screenshots, wherein each operation screenshot in the operation screenshots is a screenshot of a result interface obtained after an operation is performed on a target operation area in an operation interface;
determining a common pixel point parameter set and a difference pixel point parameter set of a plurality of operation screenshots, wherein the common pixel point parameter set comprises pixel points with the same pixel value at the same position in the plurality of operation screenshots, and the difference pixel point parameter set comprises the number of the pixel points with different pixel values at the same position between every two operation screenshots in the plurality of operation screenshots;
verifying a target operation screenshot to be verified through the common pixel point parameter set and the difference pixel point parameter set, wherein the target operation screenshot is a screenshot of a result interface obtained after target operation is performed on a target operation area;
and under the condition that the target operation screenshot reaches the verification condition, determining that the target operation is normal operation.
Alternatively, in this embodiment, a person skilled in the art may understand that all or part of the steps in the methods of the foregoing embodiments may be implemented by a program instructing hardware associated with the terminal device, where the program may be stored in a computer-readable storage medium, and the storage medium may include: flash disks, Read-Only memories (ROMs), Random Access Memories (RAMs), magnetic or optical disks, and the like.
The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
The integrated unit in the above embodiments, if implemented in the form of a software functional unit and sold or used as a separate product, may be stored in the above computer-readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for causing one or more computer devices (which may be personal computers, servers, network devices, etc.) to execute all or part of the steps of the method according to the embodiments of the present invention.
In the above embodiments of the present invention, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
In the several embodiments provided in the present application, it should be understood that the disclosed client may be implemented in other manners. The above-described embodiments of the apparatus are merely illustrative, and for example, the division of the units is only one type of division of logical functions, and there may be other divisions when actually implemented, for example, a plurality of units or components may be combined or may be integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, units or modules, and may be in an electrical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The foregoing is only a preferred embodiment of the present invention, and it should be noted that, for those skilled in the art, various modifications and decorations can be made without departing from the principle of the present invention, and these modifications and decorations should also be regarded as the protection scope of the present invention.

Claims (15)

1. An operation checking method, comprising:
acquiring a plurality of operation screenshots, wherein each operation screenshot in the operation screenshots is a screenshot of a result interface obtained after an operation is performed on a target operation area in an operation interface;
determining a common pixel point parameter set and a difference pixel point parameter set of the multiple operation screenshots, wherein the common pixel point parameter set comprises pixel points with the same pixel value at the same position in the multiple operation screenshots, and the difference pixel point parameter set comprises the number of pixel points with different pixel values at the same position between every two operation screenshots in the multiple operation screenshots;
verifying a target operation screenshot to be verified through the common pixel point parameter set and the difference pixel point parameter set, wherein the target operation screenshot is a screenshot of a result interface obtained after target operation is performed on the target operation area;
and under the condition that the target operation screenshot reaches a verification condition, determining that the target operation is a normal operation.
2. The method of claim 1, wherein the verifying the target operation screenshot to be verified through the common pixel parameter set and the difference pixel parameter set comprises:
acquiring a first pixel point set of the target operation screenshot, wherein the positions of the pixel points in the first pixel point set in the target operation screenshot are the same as the positions of the pixel points in the common pixel point parameter set in any one of the pixel points in the operation screenshot;
acquiring a first number of pixel points with different pixel values at the same position between the target operation screenshot and any one of the operation screenshots to obtain a plurality of the first numbers;
and under the condition that the pixel values of the pixels at the same positions in the first pixel point set and the common pixel point parameter set are the same and a plurality of first numbers all belong to the difference pixel point parameter set, determining that the target operation screenshot reaches the verification condition.
3. The method of claim 2, wherein said obtaining a first set of pixel points of the target operation screenshot comprises:
acquiring a first position of each pixel point in the public pixel point parameter set;
acquiring a first pixel point of the first position from the target operation screenshot;
and determining the first pixel points as pixel points in the first pixel point set.
4. The method of claim 2, wherein the obtaining a first number of pixels with different pixel values at a same position between the target operation screenshot and any one of the operation screenshots comprises:
determining any one of the operation screenshots as a current operation screenshot, and executing the following operations on the target operation screenshot and the current operation screenshot: under the condition that the pixel values of pixel points at any one same position of the target operation screenshot and the current operation screenshot are different, increasing the first number of the target operation screenshot and the current operation screenshot by 1, wherein the initial value of the first number of the target operation screenshot and the current operation screenshot is zero.
5. The method of claim 1, wherein determining a common set of pixel points for the plurality of operation screenshots comprises:
acquiring a pixel matrix of each operation screenshot of the multiple operation screenshots, wherein the pixel matrix comprises a pixel value of each pixel point of the operation screenshot and a position of each pixel point;
and under the condition that the pixel values of the pixel points at the second position in the pixel matrixes are the same, determining the pixel point at the second position as one pixel point in the public pixel point parameter set, wherein the second position is any position in the pixel matrixes.
6. The method of claim 1, wherein determining the differential pixel point parameter sets for the plurality of operation screenshots comprises:
taking any one of the operation screenshots as a first operation screenshot, taking each operation screenshot except the first operation screenshot of the operation screenshots as a second operation screenshot in sequence, and executing the following operations on the first operation screenshot and the second operation screenshot: adding 1 to a statistical parameter under the condition that pixel values of pixel points at the same position in the first operation screenshot and the second operation screenshot are different, wherein an initial value of the statistical parameter is zero, the statistical parameter is used for representing the number of the pixel points at the same position in the first operation screenshot and the second operation screenshot, and the statistical parameter is used as one parameter in the difference pixel point parameter set after traversing each pixel point in the first operation screenshot and the second operation screenshot.
7. The method of claim 1, wherein determining the common pixel parameter set and the differential pixel parameter set for the plurality of operation screenshots comprises:
under the condition that a common pixel point parameter set and a difference pixel point parameter set of the operation screenshots are determined, acquiring a plurality of first screenshots, wherein each first screenshot in the first screenshots is a screenshot of a result interface obtained after the operation is performed on a target operation area in an operation interface;
taking the operation screenshots and the first screenshots as second screenshots;
determining a common pixel point parameter set and a difference pixel point parameter set of the plurality of second screenshots;
and under the condition that the common pixel point parameter set of the second screenshot is the same as the common pixel point parameter sets of the multiple operation screenshots, and the difference pixel point parameter set of the second screenshot is the same as the difference pixel point parameter sets of the multiple operation screenshots, determining the common pixel point parameter set and the difference pixel point parameter set of the second screenshot as the common pixel point parameter set and the difference pixel point parameter set of the multiple operation screenshots.
8. The method of any one of claims 1 to 7, wherein the obtaining a plurality of operation screenshots comprises:
acquiring the operation executed on the target operation area in the operation interface;
performing screenshot on a result interface under the condition that the operation is automatically executed to obtain the result interface of the operation to obtain one of the operation screenshots;
and repeatedly executing the operation, and performing screenshot on the result interface to obtain the plurality of operation screenshots.
9. An operation verification apparatus, comprising:
the device comprises an acquisition unit, a display unit and a display unit, wherein the acquisition unit is used for acquiring a plurality of operation screenshots, and each operation screenshot in the plurality of operation screenshots is a screenshot of a result interface obtained after an operation is performed on a target operation area in an operation interface;
the first determining unit is used for determining a common pixel parameter set and a difference pixel parameter set of the multiple operation screenshots, wherein the common pixel parameter set comprises pixels with the same pixel value at the same position in the multiple operation screenshots, and the difference pixel parameter set comprises the number of pixels with different pixel values at the same position between every two operation screenshots in the multiple operation screenshots;
the verification unit is used for verifying a target operation screenshot to be verified through the common pixel point parameter set and the difference pixel point parameter set, wherein the target operation screenshot is a screenshot of a result interface obtained after target operation is performed on the target operation area;
and the second determining unit is used for determining that the target operation is normal operation under the condition that the target operation screenshot reaches a verification condition.
10. The apparatus of claim 9, wherein the verification unit comprises:
a first obtaining module, configured to obtain a first pixel point set of the target operation screenshot, where positions of pixel points in the first pixel point set in the target operation screenshot are the same as positions of pixel points in any one of the operation screenshots of pixel points in the common pixel point parameter set;
a second obtaining module, configured to obtain a first number of pixel points with different pixel values at the same position between the target operation screenshot and any one of the operation screenshots, to obtain a plurality of the first numbers;
a first determining module, configured to determine that the target operation screenshot meets the verification condition when pixel values of pixels at the same position in the first pixel point set and the common pixel point parameter set are the same and a plurality of the first numbers all belong to the difference pixel point parameter set.
11. The apparatus of claim 10, wherein the first obtaining module comprises:
the first obtaining submodule is used for obtaining a first position of each pixel point in the public pixel point parameter set;
the second obtaining submodule is used for obtaining a first pixel point of the first position from the target operation screenshot;
and the first determining submodule is used for determining the first pixel point as the pixel point in the first pixel point set.
12. The apparatus of claim 10, wherein the second obtaining module comprises:
a second determining submodule, configured to determine any one of the operation screenshots as a current operation screenshot, and execute the following operations on the target operation screenshot and the current operation screenshot: under the condition that the pixel values of pixel points at any one same position of the target operation screenshot and the current operation screenshot are different, increasing the first number of the target operation screenshot and the current operation screenshot by 1, wherein the initial value of the first number of the target operation screenshot and the current operation screenshot is zero.
13. The apparatus according to any one of claims 9 to 12, wherein the obtaining unit comprises:
a fifth obtaining module, configured to obtain the operation performed on the target operation area in the operation interface;
the first screenshot module is used for screenshot the result interface under the condition that the operation is automatically executed to obtain the result interface of the operation to obtain one of the operation screenshots;
and the second screenshot module is used for repeatedly executing the operation and screenshot the result interface to obtain the plurality of operation screenshots.
14. A computer-readable storage medium, in which a computer program is stored, which computer program, when running, performs the method of any one of claims 1 to 8.
15. An electronic device comprising a memory and a processor, characterized in that the memory has stored therein a computer program, the processor being arranged to execute the method of any of claims 1 to 8 by means of the computer program.
CN202011270498.5A 2020-11-13 2020-11-13 Operation verification method and device, storage medium and electronic equipment Active CN113391741B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011270498.5A CN113391741B (en) 2020-11-13 2020-11-13 Operation verification method and device, storage medium and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011270498.5A CN113391741B (en) 2020-11-13 2020-11-13 Operation verification method and device, storage medium and electronic equipment

Publications (2)

Publication Number Publication Date
CN113391741A true CN113391741A (en) 2021-09-14
CN113391741B CN113391741B (en) 2023-08-29

Family

ID=77616507

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011270498.5A Active CN113391741B (en) 2020-11-13 2020-11-13 Operation verification method and device, storage medium and electronic equipment

Country Status (1)

Country Link
CN (1) CN113391741B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113934353A (en) * 2021-09-30 2022-01-14 北京五八信息技术有限公司 Information processing method and device
CN114327203A (en) * 2021-12-28 2022-04-12 傲网信息科技(厦门)有限公司 User operation restoration method and device, and recording method and device

Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0261584A2 (en) * 1986-09-25 1988-03-30 The Board of Trustees of the University of Illinois Method for controlling cells and pixels of plasma panels, plasma display panels, electroluminescent panels, lcd's or that like and a circuit for carrying out the method
EP1288847A1 (en) * 2001-08-30 2003-03-05 Matsushita Electric Industrial Co., Ltd. Method and apparatus for identifying identical images
JP2013254394A (en) * 2012-06-07 2013-12-19 Ntt Data Corp Image verification method, image verification device, and program
US20150086115A1 (en) * 2013-09-20 2015-03-26 Oracle International Corporation Screenshot database for application verification
US9418284B1 (en) * 2014-04-09 2016-08-16 Vortex Intellectual Property Holding LLC Method, system and computer program for locating mobile devices based on imaging
WO2017005148A1 (en) * 2015-07-03 2017-01-12 上海触乐信息科技有限公司 Automatic software-testing method and device
US20170322637A1 (en) * 2016-05-09 2017-11-09 National Central University Mouse action capture and replay system and method, recording medium, and program product
CN107562589A (en) * 2017-08-29 2018-01-09 上海与德科技有限公司 A kind of touch-screen pixel point detecting method and system based on mobile terminal
US20180174330A1 (en) * 2016-12-20 2018-06-21 International Business Machines Corporation Mobile user interface design testing tool
CN108510502A (en) * 2018-03-08 2018-09-07 华南理工大学 Melanoma picture tissue segmentation methods based on deep neural network and system
CN110163201A (en) * 2019-03-01 2019-08-23 腾讯科技(深圳)有限公司 Image measurement method and apparatus, storage medium and electronic device
US20200311896A1 (en) * 2019-03-29 2020-10-01 Konica Minolta, Inc. Inspection Device, Inspection Method, And Recording Medium

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0261584A2 (en) * 1986-09-25 1988-03-30 The Board of Trustees of the University of Illinois Method for controlling cells and pixels of plasma panels, plasma display panels, electroluminescent panels, lcd's or that like and a circuit for carrying out the method
EP1288847A1 (en) * 2001-08-30 2003-03-05 Matsushita Electric Industrial Co., Ltd. Method and apparatus for identifying identical images
JP2013254394A (en) * 2012-06-07 2013-12-19 Ntt Data Corp Image verification method, image verification device, and program
US20150086115A1 (en) * 2013-09-20 2015-03-26 Oracle International Corporation Screenshot database for application verification
US9418284B1 (en) * 2014-04-09 2016-08-16 Vortex Intellectual Property Holding LLC Method, system and computer program for locating mobile devices based on imaging
WO2017005148A1 (en) * 2015-07-03 2017-01-12 上海触乐信息科技有限公司 Automatic software-testing method and device
US20170322637A1 (en) * 2016-05-09 2017-11-09 National Central University Mouse action capture and replay system and method, recording medium, and program product
US20180174330A1 (en) * 2016-12-20 2018-06-21 International Business Machines Corporation Mobile user interface design testing tool
CN107562589A (en) * 2017-08-29 2018-01-09 上海与德科技有限公司 A kind of touch-screen pixel point detecting method and system based on mobile terminal
CN108510502A (en) * 2018-03-08 2018-09-07 华南理工大学 Melanoma picture tissue segmentation methods based on deep neural network and system
CN110163201A (en) * 2019-03-01 2019-08-23 腾讯科技(深圳)有限公司 Image measurement method and apparatus, storage medium and electronic device
US20200311896A1 (en) * 2019-03-29 2020-10-01 Konica Minolta, Inc. Inspection Device, Inspection Method, And Recording Medium

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113934353A (en) * 2021-09-30 2022-01-14 北京五八信息技术有限公司 Information processing method and device
CN114327203A (en) * 2021-12-28 2022-04-12 傲网信息科技(厦门)有限公司 User operation restoration method and device, and recording method and device
CN114327203B (en) * 2021-12-28 2023-08-04 傲网信息科技(厦门)有限公司 User operation restoration method and device, and recording method and device

Also Published As

Publication number Publication date
CN113391741B (en) 2023-08-29

Similar Documents

Publication Publication Date Title
CN110378488B (en) Client-side change federal training method, device, training terminal and storage medium
CN110809175B (en) Video recommendation method and device
CN110474820B (en) Flow playback method and device and electronic equipment
CN105630977B (en) Application program recommended method, apparatus and system
EP3864516B1 (en) Veto-based model for measuring product health
CN111522922A (en) Log information query method and device, storage medium and computer equipment
CN113391741B (en) Operation verification method and device, storage medium and electronic equipment
CN111325417A (en) Method and device for realizing privacy protection and realizing multi-party collaborative updating of business prediction model
JP7046073B2 (en) Real-time data processing method and equipment
CN105682759A (en) Electronic game provision device, electronic game device, electronic game provision program, and electronic game program
CN110334544A (en) Federal model degeneration processing method, device, federal training system and storage medium
CN116827774A (en) Service analysis method, device, equipment and storage medium
CN112799955B (en) Method and device for detecting model change, storage medium and electronic equipment
CN111193945A (en) Advertisement playing processing method and device
CN112437034A (en) False terminal detection method and device, storage medium and electronic device
CN113296666A (en) Anchor exposure data reporting method and device, terminal equipment and storage medium
CN113468274A (en) Data storage method and device, storage medium and electronic equipment
CN115774707B (en) Object attribute-based data processing method and device, electronic equipment and storage medium
CN110719526B (en) Video playing method and device
CN114546814A (en) Recording playback method, recording playback device and storage medium
CN116680480A (en) Product recommendation method and device, electronic equipment and readable storage medium
CN108664484A (en) Media content recommendations method and device
CN108647139B (en) System test method, device, storage medium and electronic device
CN104281675A (en) Method and equipment for acquiring media files
CN114222154A (en) Associated account recommendation method and device, storage medium and electronic equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
REG Reference to a national code

Ref country code: HK

Ref legal event code: DE

Ref document number: 40052818

Country of ref document: HK

SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant