Man-machine recognition method, device and equipment and storage medium
By creating visual illusions and target areas with similar colors on the screen area to be filled, and combining the user's sub-area selection results, the problem of the failure of traditional prevention mechanisms is solved, and the accuracy and crack resistance of human-machine recognition are improved.
Patent Information
- Application Number
- CN202411511926.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-28
- Publication Date
- 2025-01-24
AI Technical Summary
Traditional defense mechanisms, such as graphic verification codes, are gradually ineffective, making it difficult to distinguish the differences between humans and robots in visual interactions, resulting in a decrease in human-computer recognition accuracy.
By creating the first target area and the second target area in the area of the screen, the first target area contains the target sub -area containing the visual illusion. Generate prompt information and obtain the user's sub -area selection results to determine whether the user is a real user.
It improves the accuracy of human -machine recognition, enhances the ability to identify the robot, and reduces the difficulty of cracking visual illusion.
Smart Images

Figure CN119356526A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computers, and in particular to a human-computer identification method, device, equipment and storage medium. Background Art
[0002] With the development of artificial intelligence, robots have greatly improved their ability in visual recognition and task execution, and traditional prevention mechanisms (such as graphic verification codes, graphic selection verification codes, image puzzle verification, etc.) have gradually become ineffective. Especially in tasks involving visual illusions, robots can often easily crack the challenges designed by humans through algorithms and computing power. Therefore, a more challenging and technically barrier-free solution is needed to distinguish the differences between humans and robots in visual interaction, thereby improving the accuracy of human-machine recognition. Summary of the invention
[0003] In view of this, the purpose of the present invention is to provide a human-machine identification method, device, equipment and storage medium, which can distinguish the differences between humans and robots in visual interaction, thereby improving the accuracy of human-machine identification. The specific scheme is as follows:
[0004] In a first aspect, the present application discloses a human-machine identification method, comprising:
[0005] When a human-computer interaction request is obtained, a screen area to be filled is generated;
[0006] A first target area and a second target area are created on the screen area to be filled; the first target area includes a target sub-area that can cause a visual illusion to the user, the second target area includes a plurality of first sub-areas and a plurality of second sub-areas, and the actual color of the first sub-area is consistent with the actual color of the target sub-area, and the visually perceived color of the second sub-area is similar to the visually perceived color of the target sub-area;
[0007] generating prompt information for prompting the user to select a sub-region in the second target region whose color is close to that of the target sub-region, and obtaining a corresponding sub-region selection result;
[0008] Based on the area type of the selected sub-area corresponding to the sub-area selection result, it is determined whether the object currently performing the human-computer interaction operation is a real user.
[0009] Optionally, the creating a first target area and a second target area on the screen area to be filled includes:
[0010] Determine a target number of chessboard squares based on a preset chessboard side length number range, and generate a chessboard to be colored based on the target number of chessboard squares;
[0011] Determining a first filling color and a second filling color based on a preset color value range, and dyeing the chessboard to be dyed using the first filling color and the second filling color to obtain a dyed chessboard;
[0012] Determine a target chessboard from the dyed chessboard, and determine a corresponding to-be-processed area including the target chessboard on the dyed chessboard based on the target chessboard and a preset area range, and determine other areas on the dyed chessboard except the to-be-processed area as the second target area;
[0013] The area to be processed is made transparent, the target checkerboard on the area to be processed after the transparency processing is dyed again with the first filling color, and the area to be processed after the current processing is determined as the first target area; wherein the sub-area where the target checkerboard on the current first target area is located is the target sub-area.
[0014] Optionally, the determining a corresponding area to be processed including the target chessboard on the dyed chessboard based on the target chessboard and a preset area range includes:
[0015] An integer is determined from a preset radius range to determine the radius of the target circle, and a target circular area as the area to be processed is determined on the dyed chessboard with the center of the target chessboard as the center and the radius of the target circle as the radius.
[0016] Optionally, the transparent processing of the area to be processed includes:
[0017] determining a target transparency based on a preset transparency range;
[0018] The target circular area is dyed with a third filling color, and the target circular area is transparently processed in a manner that the transparency gradually decreases from the center of the circle to the circumference;
[0019] The third filling color is black, the transparency at the center of the target circular area is the target transparency, and the transparency of the circumference of the target circular area is 0.
[0020] Optionally, determining the first filling color and the second filling color based on a preset color value range includes:
[0021] Determining a first color value based on a first preset color value range, so as to determine a first filling color using the first color value;
[0022] A second color value is determined based on a second preset color value range, and a second filling color is determined based on the first color value and the second color value.
[0023] Optionally, the determining whether the object currently performing the human-computer interaction operation is a real user based on the area type of the selected sub-area corresponding to the sub-area selection result includes:
[0024] Determining whether the selected sub-region corresponding to the sub-region selection result is the second sub-region;
[0025] If the selected sub-region is the first sub-region, determining that the object currently performing the human-computer interaction operation is a robot;
[0026] If the selected sub-region is the second sub-region, it is determined that the object currently performing the human-computer interaction operation is a real user.
[0027] Optionally, the first sub-regions and the second sub-regions are arranged evenly spaced or randomly on the second target region.
[0028] In a second aspect, the present application discloses a human-machine identification device, comprising:
[0029] The area generation module is used to generate a screen area to be filled when a human-computer interaction request is obtained;
[0030] a target area creation module, configured to create a first target area and a second target area on the to-be-filled screen area; the first target area includes a target sub-area that can cause a visual illusion to the user, the second target area includes a plurality of first sub-areas and a plurality of second sub-areas, and the actual color of the first sub-area is consistent with the actual color of the target sub-area, and the visually perceived color of the second sub-area is similar to the visually perceived color of the target sub-area;
[0031] A selection result acquisition module, used to generate prompt information for prompting the user to select a sub-region with a color close to that of the target sub-region in the second target region, and acquire a corresponding sub-region selection result;
[0032] The selection result judgment module is used to determine whether the object currently performing the human-computer interaction operation is a real user based on the area type of the selected sub-area corresponding to the sub-area selection result.
[0033] In a third aspect, the present application discloses an electronic device, comprising:
[0034] Memory, used to store computer programs;
[0035] The processor is used to execute the computer program to implement the steps of the aforementioned human-machine identification method.
[0036] In a fourth aspect, the present application discloses a computer-readable storage medium for storing a computer program; wherein, when the computer program is executed by a processor, the steps of the aforementioned human-computer identification method are implemented.
[0037] In the present application, when human-computer identification is performed, when a human-computer interaction request is obtained, a screen area to be filled is generated; a first target area and a second target area are created on the screen area to be filled; the first target area contains a target sub-area that can cause a visual illusion to the user, and the second target area contains a plurality of first sub-areas and a plurality of second sub-areas, and the actual color of the first sub-area is consistent with the actual color of the target sub-area, and the visually perceived color of the second sub-area is similar to the visually perceived color of the target sub-area; prompt information is generated to prompt the user to select a sub-area with a color close to the color of the target sub-area in the second target area, and the corresponding sub-area selection result is obtained; based on the area type of the selected sub-area corresponding to the sub-area selection result, it is determined whether the object currently performing the human-computer interaction operation is a real user. It can be seen that the present application creates a first target area and a second target area on the generated screen area to be filled, because the target sub-area on the first target area can cause a visual illusion to the user, and the actual color of the first sub-area contained in the second target area is consistent with the actual color of the target sub-area, and the visually perceived color of the second sub-area contained in the second target area is similar to the visually perceived color of the target sub-area. After the user obtains the prompt information prompting to select a sub-region with a color close to the target sub-region in the second target region, if the user is a real user, the area belonging to the second sub-region will be selected as the selected sub-region due to visual perception; if the user is not a real user, the actual color of each area will be accurately identified, thereby selecting the area belonging to the first sub-region as the selected sub-region. At this time, by judging the color difference between the selected sub-region and the target sub-region, it can be judged whether the object currently performing the human-computer interaction operation is a real user. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying creative work.
[0039] Figure 1 A flow chart of a human-machine identification method disclosed in this application;
[0040] Figure 2 A schematic diagram of a target area of a specific human-machine identification method disclosed in this application;
[0041] Figure 3 This is a schematic diagram of the structure of a human-machine identification device disclosed in this application;
[0042] Figure 4 This is a structural diagram of an electronic device disclosed in this application. DETAILED DESCRIPTION
[0043] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0044] With the development of artificial intelligence, traditional graphic verification codes, invisible verification codes, image puzzle verification codes and image selection verification codes are increasingly easy to be cracked by artificial intelligence, resulting in a decrease in the accuracy of human-machine recognition, and traditional prevention mechanisms are gradually becoming ineffective. Especially in tasks involving visual illusions, robots can often easily crack the challenges designed by humans through algorithms and computing power. In order to solve the above technical problems, the present application discloses a human-machine recognition method, device, equipment and storage medium, which can distinguish the differences between humans and robots in visual interaction, thereby improving the accuracy of human-machine recognition.
[0045] See also Figure 1 As shown, the embodiment of the present invention discloses a flow chart of a human-machine identification method, including:
[0046] Step S11: When a human-computer interaction request is obtained, a screen area to be filled is generated.
[0047] In this embodiment, in order to determine whether the user performing the current operation is a real user, a corresponding screen area to be filled may be generated after obtaining a human-computer interaction request, so that the screen area to be filled may be filled to generate an image for human-computer recognition. Specifically, the screen area to be filled may be an area of any shape designed according to user needs, such as a circular, square, sector-shaped area, or an irregularly shaped area.
[0048] Step S12, creating a first target area and a second target area on the screen area to be filled; the first target area contains a target sub-area that can cause a visual illusion to the user, the second target area contains a plurality of first sub-areas and a plurality of second sub-areas, and the actual color of the first sub-area is consistent with the actual color of the target sub-area, and the visually perceived color of the second sub-area is similar to the visually perceived color of the target sub-area.
[0049] In this embodiment, after the screen area to be filled is generated, different areas are divided on the screen area to be filled to create a first target area and a second target area, wherein the first target area includes a target sub-area, which can cause a visual illusion to a real user; the second target area includes a first sub-area and a second sub-area, and the first sub-area has the same actual color as the target sub-area in the first target area, and the visually perceived color of the second sub-area is similar to the visually perceived color of the target sub-area. In addition, in addition to the first sub-area and the second sub-area, the second target area may also include other sub-areas, thereby increasing the color richness of the entire screen and improving the accuracy of the human-machine recognition results.
[0050] In a specific embodiment, creating a first target area and a second target area on a screen area to be filled may include: determining a target number of squares based on a preset range of squares of a side length of the chessboard, and generating a chessboard to be dyed based on the target number of squares; determining a first filling color and a second filling color based on a preset range of color values, and dyeing the chessboard to be dyed using the first filling color and the second filling color to obtain a dyed chessboard; determining a target square from the dyed chessboard, and determining a corresponding area to be processed including the target square on the dyed chessboard based on the target square and a preset area range, and determining other areas on the dyed chessboard except the area to be processed as the second target area; performing a transparent processing on the area to be processed, dyeing the target square on the transparently processed area to be processed again using the first filling color, and determining the currently processed area to be processed as the first target area; wherein the screen area to be filled refers to the chessboard to be dyed, and the sub-area where the target square on the current first target area is located is the target sub-area.
[0051] In order to make the real user believe that the visually perceived color of the second sub-area is closer to the visually perceived color of the target sub-area, when determining the first fill color and the second fill color based on a preset color value range, it can specifically include: determining the first color value based on the first preset color value range, so as to determine the first fill color using the first color value; determining the second color value based on the second preset color value range, and determining the second fill color based on the first color value and the second color value. In a specific embodiment, the value range of the first preset color value Nb may be (100, 150), and the value range of the second preset color value Nc may be (40, 80), so that the determined first color value is lighter than the second color value, and the determined first filling color Gb is RGB (Nb, Nb, Nb) (that is, the color values of the three color channels of Red, Green, and Blue are all Nb), and the second filling color Gc is determined by the first color value and the second color value. The second filling color can be determined by the sum of the first color value and the second color value, that is, RGB (Nb+Nc, Nb+Nc, Nb+Nc). In this case, the second filling color is smaller and darker than the first filling color, and at the same time, it is ensured that the real user can distinguish the first filling color from the second filling color when the first filling color and the second filling color are similar, thereby distinguishing the first sub-area from the second sub-area. In addition, the second filling color can also be a color value obtained by adding the first color value and the second color value according to a certain weighting coefficient.
[0052] In addition, when the chessboard to be dyed is dyed using the first fill color and the second fill color, the chessboard to be dyed can be dyed evenly at intervals using the chessboard dyeing method, or each sub-region can be randomly colored, so that the first sub-region and the second sub-region are arranged evenly or randomly on the second target region.
[0053] It can be understood that determining the corresponding area to be processed including the target chessboard based on the target chessboard and the preset area range on the chessboard after dyeing can include: determining an integer from the preset radius range to determine the target circle radius, and determining a target circular area as the area to be processed on the chessboard after dyeing with the center of the target chessboard as the center of the circle and the target circle radius as the radius.
[0054] Among them, the specific process of making the processed area transparent may include: determining the target transparency based on a preset transparency range; dyeing the target circular area with a third filling color, and making the target circular area transparent in a manner in which the transparency gradually decreases from the center to the circumference; wherein the third filling color is black, the transparency at the center of the target circular area is the target transparency, and the transparency of the circumference of the target circular area is 0, so that the processed target circular area (that is, the first target area) can cause a visual illusion to the real user, making the real user think that the color of the target chessboard is closer to the color of the second sub-area.
[0055] Step S13: Generate prompt information for prompting the user to select a sub-region in the second target region whose color is close to that of the target sub-region, and obtain a corresponding sub-region selection result.
[0056] In this embodiment, after creating the first target area and the second target area, a message can be sent to the current human-computer interaction object to prompt the user to select several sub-areas in the second target area that the user believes are close in color to the target sub-area, and the user's sub-area selection results can be obtained so as to analyze the sub-area selection results and determine whether the current user is a real user.
[0057] Step S14: determining whether the object currently performing the human-computer interaction operation is a real user based on the area type of the selected sub-area corresponding to the sub-area selection result.
[0058] In this embodiment, based on the area type of the selected sub-area corresponding to the sub-area selection result, determining whether the object currently performing the human-computer interaction operation is a real user may include: determining whether the selected sub-area corresponding to the sub-area selection result is the second sub-area; if the selected sub-area is the first sub-area, determining that the object currently performing the human-computer interaction operation is a robot; if the selected sub-area is the second sub-area, determining that the object currently performing the human-computer interaction operation is a real user. Specifically, it is possible to determine whether the area type of the selected area is the second sub-area based on the area mark of the selected sub-area, or to compare the actual color of the selected sub-area with the actual color of the target sub-area, and determine whether the area type of the selected area is the second sub-area based on the difference between the actual color of the selected sub-area and the actual color of the target sub-area, so as to determine whether the object currently performing the human-computer interaction operation is a real user. If the area type of the selected area is the second sub-area, it means that the object currently performing the human-computer interaction operation is a real user, and if the area type of the selected area is not the second sub-area, it means that the object currently performing the human-computer interaction operation is not a real user.
[0059] In addition, in order to avoid judging a real user as a robot in the event of a real user's erroneous operation, a preset number of retries can be set. If the object currently performing human-computer interaction operations has at least one sub-area selection result within the preset number of retries, and the area type of the selected area corresponding to the sub-area selection result is the second sub-area, then the object currently performing human-computer interaction operations is judged to be the real user; if the type of the selected area corresponding to each sub-area selection result is not the second sub-area, then the object currently performing human-computer interaction operations is judged to be a robot.
[0060] It can be seen that the present application creates a first target area and a second target area on the generated screen area to be filled. Since the target sub-area on the first target area can cause a visual illusion to the user, and the actual color of the first sub-area contained in the second target area is consistent with the actual color of the target sub-area, the visually perceived color of the second sub-area contained in the second target area is similar to the visually perceived color of the target sub-area. After the user obtains the prompt information prompting to select a sub-area with a color close to the target sub-area in the second target area, if the user is a real user, the area belonging to the second sub-area will be selected as the selected sub-area due to visual perception; if the user is not a real user, the actual color of each area will be accurately identified, thereby selecting the area belonging to the first sub-area as the selected sub-area. At this time, by judging the color difference between the selected sub-area and the target sub-area, it can be judged whether the object currently performing the human-computer interaction operation is a real user.
[0061] Based on the above embodiment, the present application discloses a human-machine identification method that can distinguish the difference between humans and robots in visual interaction, thereby improving the accuracy of human-machine identification. Next, the human-machine identification process will be described when the screen area to be filled is a chessboard to be dyed.
[0062] See also Figure 2As shown, after obtaining the human-computer interaction request, if it is necessary to determine whether the user performing the current operation is a real user, the target number of chessboard squares is determined based on the preset chessboard side length square number range, and then the chessboard to be dyed is generated based on the target number of chessboard squares. If the chessboard side length square number Na is determined to be 7, the target number of chessboard squares can be determined to be 49, and then a 7*7 square chessboard to be dyed is generated based on the target number of chessboard squares. After the chessboard to be dyed is generated, when determining the first filling color and the second filling color based on the preset color value range, it can specifically include: determining the first color value based on the first preset color value range, so as to determine the first filling color using the first color value; determining the second color value based on the second preset color value range, and determining the second filling color based on the first color value and the second color value. In a specific embodiment, the value range of the first preset color value Nb can be (100, 150), and the first preset color value Nb can be 120. The value range of the second preset color value Nc can be (40, 80), and the second preset color value Nc can be 72, so that the determined first color value is lighter than the second color value, and the determined first filling color Gb is RGB (Nb, Nb, Nb), that is, Gb=RGB (120, 120, 120), and the second filling color Gc is determined by the first color value and the second color value. The second filling color can be the sum of the first color value and the second color value, that is, RGB (Nb+Nc, Nb+Nc, Nb+Nc), Gc=RGB (192, 192, 192). In this case, the second filling color is smaller and darker than the first filling color, and at the same time ensures that the real user can distinguish the first filling color and the second filling color when the first filling color and the second filling color are similar, thereby distinguishing the first sub-area and the second sub-area. After determining the first filling color and the second filling color, the chessboard to be dyed is dyed evenly at intervals using the first filling color and the second filling color, or chessboard squares are randomly selected for dyeing, so that the first sub-region and the second sub-region on the chessboard are arranged evenly or randomly after dyeing.
[0063] After obtaining the dyed chessboard, an integer Nx can be randomly selected from (Na+2, Na*Na-2), that is, (9, 47) as the position of the target chessboard, and the target chessboard is determined from the dyed chessboard using Nx in the order from top to bottom and from left to right. Then, based on the target chessboard and the preset area range, the corresponding area to be processed including the target chessboard is determined on the dyed chessboard, that is, Figure 2The area within the red circle in the figure can be an integer from the preset radius range to determine the radius of the target circle, and the target circular area is determined on the dyed chessboard with the center of the target chessboard as the center and the radius of the target circle as the radius. The area outside the target circular area on the dyed chessboard is the second target area. The preset radius range can be any integer in (160, 200). Since the generated chessboard is used for human-computer recognition, the unit of the target circle radius is preferably pixels, such as 180 pixels, etc. It can also be other units to describe the size of the area to be processed.
[0064] After determining the area to be processed, it is necessary to make the area to be processed transparent to bring about a visual illusion. The specific process may include: determining the target transparency based on a preset transparency range; dyeing the target circular area with a third filling color, and making the target circular area transparent in a manner where the transparency gradually decreases from the center to the circumference; wherein the third filling color is black, the transparency at the center of the target circular area is the target transparency, the transparency of the circumference of the target circular area is 0, and the preset transparency range may be (0.6, 0.9), so that the processed target circular area (i.e., the first target area) can cause a visual illusion to the real user, so that the real user believes that the color of the target checkerboard is closer to the color of the second sub-area. After making the area to be processed transparent, dye the target checkerboard again with the first filling color to obtain the processed area to be processed, and determine the current area to be processed as the first target area, and determine the sub-area where the target checkerboard on the first target area is located as the target sub-area.
[0065] In this embodiment, after obtaining the target sub-region, the current human-computer interaction object is prompted to select a preset number of sub-regions with peripheral checkerboards close to the color of the target sub-region, that is, checkerboards on the second target region with a color close to the target sub-region. Then the user's sub-region selection result is obtained, and the identity of the object currently performing the human-computer interaction operation is determined based on the region type of the selected sub-region corresponding to the sub-region selection result. Figure 2As shown, all odd-numbered checkers are colored with RGB (192, 192, 192), and all even-numbered checkers are colored with RGB (120, 120, 120). It can be seen that the color of the odd-numbered checkers is obviously lighter than that of the even-numbered checkers. If the 17th checkerboard is selected as the target checkerboard, a semi-transparent gradient shadow pattern is drawn with the center of the target checkerboard as the center of the circle, and the target checkerboard is colored with RGB (120, 120, 120), which is the same color as all even-numbered checkers. From the perspective of real user behavior, when it is necessary to select other checkers with a color similar to the target sub-area in the center of the circular area, the real user is likely to choose a light-colored checkerboard, similar to the area where the yellow dot is located in the figure. After the machine accurately identifies the entire chessboard, it finds that the actual color of the target sub-area is consistent with the color of the dark checkerboard, that is, the area where the purple dot is located in the figure, so that the real user and the machine can be distinguished according to the area type of the selected sub-area.
[0066] It can be seen that this application introduces a complex visual illusion and a multi-layer random parameter generation mechanism by processing the area of the screen to be filled multiple times, and the robot needs to face a challenge that is more difficult to predict and calculate. This illusion utilizes the unique characteristics of the human visual system, increases the difficulty of the robot to crack at the visual level, and further improves the anti-cracking ability, so that it can be applied to various human-computer interaction scenarios, especially human-computer challenge fields that require higher security or entertainment, such as games, online exams, anti-cheating systems, etc. Through this unique challenge mechanism, the authenticity of the interaction can be ensured, and the interference of the robot can be effectively prevented.
[0067] See also Figure 3 As shown, the present application discloses a schematic diagram of the structure of a human-machine identification device, including:
[0068] The area generating module 11 is used to generate a screen area to be filled when a human-computer interaction request is obtained;
[0069] The target area creation module 12 is used to create a first target area and a second target area on the to-be-filled screen area; the first target area includes a target sub-area that can cause a visual illusion to the user, the second target area includes a plurality of first sub-areas and a plurality of second sub-areas, and the actual color of the first sub-area is consistent with the actual color of the target sub-area, and the visually perceived color of the second sub-area is similar to the visually perceived color of the target sub-area;
[0070] A selection result acquisition module 13, used to generate prompt information for prompting the user to select a sub-region with a color close to that of the target sub-region in the second target region, and to acquire a corresponding sub-region selection result;
[0071] The selection result judgment module 14 is used to determine whether the object currently performing the human-computer interaction operation is a real user based on the area type of the selected sub-area corresponding to the sub-area selection result.
[0072] It can be seen that the present application creates a first target area and a second target area on the generated screen area to be filled. Since the target sub-area on the first target area can cause a visual illusion to the user, and the actual color of the first sub-area contained in the second target area is consistent with the actual color of the target sub-area, the visually perceived color of the second sub-area contained in the second target area is similar to the visually perceived color of the target sub-area. After the user obtains the prompt information prompting to select a sub-area with a color close to the target sub-area in the second target area, if the user is a real user, the area belonging to the second sub-area will be selected as the selected sub-area due to visual perception; if the user is not a real user, the actual color of each area will be accurately identified, thereby selecting the area belonging to the first sub-area as the selected sub-area. At this time, by judging the color difference between the selected sub-area and the target sub-area, it can be judged whether the object currently performing the human-computer interaction operation is a real user.
[0073] In a specific embodiment, the target area creation module 12 may specifically include:
[0074] A chessboard generation submodule to be dyed is used to determine a target number of chessboard squares based on a preset chessboard side length square number range, and generate a chessboard to be dyed based on the target number of chessboard squares;
[0075] A chessboard dyeing submodule, used for determining a first filling color and a second filling color based on a preset color value range, and dyeing the chessboard to be dyed with the first filling color and the second filling color to obtain a dyed chessboard;
[0076] A region determination submodule, configured to determine a target chessboard from the dyed chessboard, and determine a corresponding to-be-processed region including the target chessboard on the dyed chessboard based on the target chessboard and a preset region range, and determine other regions on the dyed chessboard except the to-be-processed region as the second target region;
[0077] The area processing submodule is used to perform transparency processing on the area to be processed, use the first filling color to re-dye the target checkerboard on the area to be processed after the transparency processing, and determine the currently processed area to be processed as the first target area; wherein the sub-area where the target checkerboard on the current first target area is located is the target sub-area.
[0078] In a specific embodiment, the region determination submodule may specifically include:
[0079] The unit for determining the area to be processed is used to determine an integer from a preset radius range to determine the radius of the target circle, and determine a target circular area as the area to be processed on the dyed chessboard with the center of the target chessboard as the center and the target circle radius as the radius.
[0080] Accordingly, the area processing submodule may specifically include:
[0081] a transparency determination unit, configured to determine the target transparency based on a preset transparency range;
[0082] The transparency processing unit is used to dye the target circular area with a third filling color, and to perform transparency processing on the target circular area in a manner in which the transparency gradually decreases from the center to the circumference; wherein the third filling color is black, the transparency at the center of the target circular area is the target transparency, and the transparency of the circumference of the target circular area is 0.
[0083] In a specific embodiment, the chessboard coloring submodule may specifically include:
[0084] a first color determining unit, configured to determine a first color value based on a first preset color value range, so as to determine a first filling color using the first color value;
[0085] The second color determining unit is used to determine a second color value based on a second preset color value range, and to determine a second filling color based on the first color value and the second color value.
[0086] In a specific embodiment, the selection result judgment module 14 may specifically include:
[0087] an area type determination unit, configured to determine whether the selected sub-area corresponding to the sub-area selection result is the second sub-area;
[0088] a first determination unit, configured to determine that the object currently performing the human-machine interactive operation is a robot if the selected sub-region is the first sub-region;
[0089] The second determination unit is configured to determine that the object currently performing the human-computer interaction operation is a real user if the selected sub-region is the second sub-region.
[0090] Furthermore, the present application also discloses an electronic device. Figure 4 This is a structural diagram of an electronic device 20 according to an exemplary embodiment. The content in the diagram cannot be considered as any limitation on the scope of use of the present application.
[0091] Figure 4The present invention provides a schematic diagram of the structure of an electronic device 20 provided in an embodiment of the present application. The electronic device 20 may specifically include: at least one processor 21, at least one memory 22, a power supply 23, a communication interface 24, an input / output interface 25, and a communication bus 26. The memory 22 is used to store a computer program, which is loaded and executed by the processor 21 to implement the relevant steps in the human-machine identification method disclosed in any of the aforementioned embodiments. In addition, the electronic device 20 in this embodiment may specifically be an electronic computer.
[0092] In this embodiment, the power supply 23 is used to provide working voltage for each hardware device on the electronic device 20; the communication interface 24 can create a data transmission channel between the electronic device 20 and the external device, and the communication protocol it follows is any communication protocol that can be applied to the technical solution of the present application, and is not specifically limited here; the input and output interface 25 is used to obtain external input data or output data to the outside world, and its specific interface type can be selected according to specific application needs and is not specifically limited here.
[0093] In addition, the memory 22, as a carrier for storing resources, can be a read-only memory, a random access memory, a disk or an optical disk, etc. The resources stored thereon can include an operating system 221, a computer program 222, etc., and the storage method can be temporary storage or permanent storage.
[0094] The operating system 221 is used to manage and control the hardware devices and computer programs 222 on the electronic device 20, and can be Windows Server, Netware, Unix, Linux, etc. In addition to including a computer program that can be used to complete the human-machine identification method performed by the electronic device 20 disclosed in any of the aforementioned embodiments, the computer program 222 can further include a computer program that can be used to complete other specific tasks.
[0095] Furthermore, the present application also discloses a computer-readable storage medium for storing a computer program; wherein the computer program, when executed by a processor, implements the human-machine identification method disclosed above. For the specific steps of the method, reference may be made to the corresponding contents disclosed in the above embodiments, and no further description will be given here.
[0096] In this specification, each embodiment is described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the embodiments can be referred to each other. For the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and the relevant parts can be referred to the method part.
[0097] Professionals may further appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of the two. In order to clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the above description according to function. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professionals and technicians may use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0098] The steps of the method or algorithm described in conjunction with the embodiments disclosed herein may be implemented directly using hardware, a software module executed by a processor, or a combination of the two. The software module may be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of storage medium known in the art.
[0099] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the presence of other identical elements in the process, method, article or device including the elements.
[0100] The technical solution provided by the present application is introduced in detail above. Specific examples are used in this article to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method of the present application and its core idea. At the same time, for general technicians in this field, according to the idea of the present application, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.
Claims
1. A human-machine identification method, characterized in that: include: When a human-computer interaction request is obtained, a screen area to be filled is generated; A first target area and a second target area are created on the screen area to be filled; the first target area includes a target sub-area that can cause a visual illusion to the user, the second target area includes a plurality of first sub-areas and a plurality of second sub-areas, and the actual color of the first sub-area is consistent with the actual color of the target sub-area, and the visually perceived color of the second sub-area is similar to the visually perceived color of the target sub-area; generating prompt information for prompting the user to select a sub-region in the second target region whose color is close to that of the target sub-region, and obtaining a corresponding sub-region selection result; Based on the area type of the selected sub-area corresponding to the sub-area selection result, it is determined whether the object currently performing the human-computer interaction operation is a real user.
2. The human-machine identification method according to claim 1, characterized in that: The step of creating a first target area and a second target area on the to-be-filled screen area includes: Determine a target number of chessboard squares based on a preset chessboard side length number range, and generate a chessboard to be colored based on the target number of chessboard squares; Determining a first filling color and a second filling color based on a preset color value range, and dyeing the chessboard to be dyed using the first filling color and the second filling color to obtain a dyed chessboard; Determine a target chessboard from the dyed chessboard, and determine a corresponding to-be-processed area including the target chessboard on the dyed chessboard based on the target chessboard and a preset area range, and determine other areas on the dyed chessboard except the to-be-processed area as the second target area; The area to be processed is made transparent, the target checkerboard on the area to be processed after the transparency processing is dyed again with the first filling color, and the area to be processed after the current processing is determined as the first target area; wherein the sub-area where the target checkerboard on the current first target area is located is the target sub-area.
3. The human-machine identification method according to claim 2, characterized in that: The step of determining a corresponding area to be processed including the target chessboard based on the target chessboard and a preset area range on the dyed chessboard includes: An integer is determined from a preset radius range to determine the radius of the target circle, and a target circular area as the area to be processed is determined on the dyed chessboard with the center of the target chessboard as the center and the radius of the target circle as the radius.
4. The human-machine identification method according to claim 3, characterized in that: The transparent processing of the area to be processed includes: determining a target transparency based on a preset transparency range; The target circular area is dyed with a third filling color, and the target circular area is transparently processed in a manner that the transparency gradually decreases from the center of the circle to the circumference; The third filling color is black, the transparency at the center of the target circular area is the target transparency, and the transparency of the circumference of the target circular area is 0.
5. The human-machine identification method according to claim 2, characterized in that: The determining of the first filling color and the second filling color based on a preset color value range includes: Determining a first color value based on a first preset color value range, so as to determine a first filling color using the first color value; A second color value is determined based on a second preset color value range, and a second filling color is determined based on the first color value and the second color value.
6. The human-machine identification method according to any one of claims 1 to 5, characterized in that: The determining whether the object currently performing the human-computer interaction operation is a real user based on the area type of the selected sub-area corresponding to the sub-area selection result includes: Determining whether the selected sub-region corresponding to the sub-region selection result is the second sub-region; If the selected sub-region is the first sub-region, determining that the object currently performing the human-computer interaction operation is a robot; If the selected sub-region is the second sub-region, it is determined that the object currently performing the human-computer interaction operation is a real user.
7. The human-machine identification method according to any one of claims 1 to 5, characterized in that: The first sub-regions and the second sub-regions are arranged evenly or randomly on the second target region.
8. A human-machine identification device, characterized in that: include: The area generation module is used to generate a screen area to be filled when a human-computer interaction request is obtained; a target area creation module, configured to create a first target area and a second target area on the to-be-filled screen area; the first target area includes a target sub-area that can cause a visual illusion to the user, the second target area includes a plurality of first sub-areas and a plurality of second sub-areas, and the actual color of the first sub-area is consistent with the actual color of the target sub-area, and the visually perceived color of the second sub-area is similar to the visually perceived color of the target sub-area; A selection result acquisition module, used to generate prompt information for prompting the user to select a sub-region with a color close to that of the target sub-region in the second target region, and acquire a corresponding sub-region selection result; The selection result judgment module is used to determine whether the object currently performing the human-computer interaction operation is a real user based on the area type of the selected sub-area corresponding to the sub-area selection result.
9. An electronic device, characterized in that: include: Memory, used to store computer programs; A processor, configured to execute the computer program to implement the human-machine identification method according to any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that: Used to store a computer program, wherein when the computer program is executed by a processor, the human-machine identification method according to any one of claims 1 to 7 is implemented.