CN109460771A - Trade mark similarity judgment method, equipment and storage medium based on sliding window - Google Patents

Trade mark similarity judgment method, equipment and storage medium based on sliding window Download PDF

Info

Publication number
CN109460771A
CN109460771A CN201811106692.2A CN201811106692A CN109460771A CN 109460771 A CN109460771 A CN 109460771A CN 201811106692 A CN201811106692 A CN 201811106692A CN 109460771 A CN109460771 A CN 109460771A
Authority
CN
China
Prior art keywords
monitored
image
value
trademark image
trade mark
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
CN201811106692.2A
Other languages
Chinese (zh)
Other versions
CN109460771B (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.)
Guangzhou Yiteng Technology Co Ltd
Original Assignee
Guangzhou Yiteng Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangzhou Yiteng Technology Co Ltd filed Critical Guangzhou Yiteng Technology Co Ltd
Priority to CN201811106692.2A priority Critical patent/CN109460771B/en
Publication of CN109460771A publication Critical patent/CN109460771A/en
Application granted granted Critical
Publication of CN109460771B publication Critical patent/CN109460771B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/40Extraction of image or video features
    • G06V10/56Extraction of image or video features relating to colour
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/22Matching criteria, e.g. proximity measures

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • General Physics & Mathematics (AREA)
  • Artificial Intelligence (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Evolutionary Biology (AREA)
  • Evolutionary Computation (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • General Engineering & Computer Science (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Multimedia (AREA)
  • Image Analysis (AREA)

Abstract

The trade mark similarity judgment method based on sliding window that the invention discloses a kind of, comprising the following steps: establish the standard characters library step of trademark image to be monitored;It establishes the blackaandawhite characterumay string comparison library step of trademark image to be compared: comparing step: the character string of each level in the blackaandawhite characterumay string comparison library of each trademark image to be compared is compared with the character string of the corresponding level in the blackaandawhite characterumay string java standard library of trademark image to be monitored, the height of black and white similarity S1 is judged according to the consistency for the character string for comparing each level;Judge trademark image to be monitored whether be designated color application color logo image;If it is not, then comparing terminates;If so, carrying out color comparison.After this method is by carrying out Fuzzy processing to trademark image, the principle of simulation artificial vision's judgement judges trade mark similarity, reliability with higher is judged to the similitude of trade mark, mitigates the workload that manual retrieval compares analysis, improves retrieval comparison efficiency.

Description

Trade mark similarity judgment method, equipment and storage medium based on sliding window
Technical field
The present invention relates to image identification technical field more particularly to a kind of trade mark similarity judgement sides based on sliding window Method, electronic equipment and computer readable storage medium.
Background technique
Trade mark (trade mark) is the mark that can distinguish the commodity of oneself or service with other people commodity and service, Trade mark is the intangible asset of enterprise, is protected by law, and registrant has private right.
In recent years, with the rapid development of world economy and society, the magnitude of value that trade mark is contained is significantly increased, trade mark note The quantity sustainable growth of volume.After the completion of trade mark registration, owner of trademark is in the maintenance of trade mark legitimate rights and interests, it will usually oneself or committee Agency is ask to carry out query and search to the registered trade mark that trademark office announces within the fixed cycle, to find approximation in time New registration trade mark, targetedly raise an objection and right-safeguarding.Due to trademark office be published once a week update new examination trade mark quantity it is equal At 10,000 or more, and most retrieval and inquisition and similarity comparison work are all manually to compare at present, comparatively, text The inquiry of trade mark and number is fairly simple, and the inquiry comparison workload of figurative mark is big and difficulty is higher, and extremely cumbersome looks into It askes retrieving and needs to expend a large amount of manpower and material resources to complete.
Summary of the invention
For overcome the deficiencies in the prior art, one of the objects of the present invention is to provide a kind of trade marks based on sliding window Similarity judgment method, after carrying out Fuzzy processing to trademark image, the principle of simulation artificial vision's judgement is to trade mark Similarity is judged, judges reliability with higher to the similitude of trade mark, mitigates the work that manual retrieval compares analysis Amount improves retrieval comparison efficiency.
The second object of the present invention is to provide a kind of electronic equipment, by carrying out Fuzzy processing to trademark image Afterwards, simulation artificial vision judgement principle trade mark similarity is judged, to the similitude of trade mark judge it is with higher can By property, mitigate the workload that manual retrieval compares analysis, improves retrieval comparison efficiency.
The third object of the present invention is to provide a kind of computer readable storage medium, the program which is stored When operation by trademark image carry out Fuzzy processing after, simulation artificial vision judgement principle trade mark similarity is sentenced It is disconnected, reliability with higher is judged to the similitude of trade mark, mitigates the workload that manual retrieval compares analysis, improves retrieval ratio To efficiency.
An object of the present invention adopts the following technical scheme that realization:
A kind of trade mark similarity judgment method based on sliding window, comprising the following steps:
Establish the standard characters library step of trademark image to be monitored:
Judge trademark image to be monitored whether be designated color application color logo image;If so, establishing to be monitored The blackaandawhite characterumay string java standard library and color characters string java standard library of trademark image;If it is not, then only establishing trademark image to be monitored Blackaandawhite characterumay string java standard library;
Establish the blackaandawhite characterumay string java standard library of trademark image to be monitored:
(1) binarization of gray value is handled:
Trademark image to be monitored is obtained, binary conversion treatment is carried out thus will be described to be monitored to the trademark image to be monitored Trademark image is converted to trade mark black white image to be monitored;
(2) normalized:
The trade mark black white image to be monitored is divided into M*M grid according to the trademark image size to be monitored, is mentioned The form and aspect H value in the color H SB value of each grid is taken, the form and aspect H value matrix of M level is obtained, M is positive integer;
It is described to obtain gradually to reduce the trade mark black white image to be monitored by the method for normalizing based on sliding window The new images of trade mark black white image to be monitored obtain the corresponding layer of new images of obtained trade mark black white image to be monitored every time The form and aspect H value matrix of grade;
Cryptographic Hash is calculated by each form and aspect H value matrix, obtains the corresponding unique string of each form and aspect H value matrix, and Each character string is stored according to level belonging to each form and aspect H value matrix, establishes the black and white word of the trademark image to be monitored Symbol string java standard library;
Establish the corresponding color characters string java standard library of the trademark image to be monitored:
The trademark image to be monitored is obtained, the trademark image to be monitored is divided into M*M grid, extracts each side Form and aspect H value in the color H SB value of lattice, obtains the form and aspect H value matrix of M level, and M is positive integer;
It is described wait supervise to obtain gradually to reduce the trademark image to be monitored by the method for normalizing based on sliding window The new images of trademark image are surveyed, the form and aspect H value of the corresponding level of new images of obtained trademark image to be monitored every time is obtained Matrix;
Cryptographic Hash is calculated by each form and aspect H value matrix, obtains the corresponding unique string of each form and aspect H value matrix, and Each character string is stored according to level belonging to each form and aspect H value matrix, establishes the color word of the trademark image to be monitored Symbol string java standard library;
Establish the blackaandawhite characterumay string comparison library step of trademark image to be compared:
Trademark image to be compared is established according to the method for the blackaandawhite characterumay string java standard library for establishing trademark image to be monitored Blackaandawhite characterumay string comparison library;
Compare step:
By the character string of each level in the blackaandawhite characterumay string comparison library of each trademark image to be compared and quotient to be monitored The character string of corresponding level in the blackaandawhite characterumay string java standard library of logo image is compared, according to the character string for comparing each level Consistency judge the height of black and white similarity S1;
Judge trademark image to be monitored whether be designated color application color logo image;
If it is not, then comparing terminates;
If so, black and white similarity S1 to be reached to the color logo image in the trademark image to be compared of preset threshold or more It extracts, and each to be compared to establish according to the method for the color characters string java standard library for establishing the trademark image to be monitored The color characters string comparison library of color logo image;It will be each in the color characters string java standard library of the trademark image to be monitored Character string is compared with the character string of the corresponding level in the color characters string comparison library of each color logo image to be compared, The height of color similarity S2 is judged according to the consistency for the character string for comparing each level.
Further, by the method for normalizing based on sliding window gradually reduce the trade mark black white image to be monitored or The trademark image to be monitored is to obtain the new images or the trademark image to be monitored of the trade mark black white image to be monitored It is corresponding to obtain every time the new images of the new images of obtained trade mark black white image to be monitored or trademark image to be monitored for new images Level form and aspect H value matrix specifically:
On the trade mark black white image to be monitored or trademark image to be monitored for being divided into M*M grid, it is with N*N grid Sliding window redefines the sliding window according to preset rules according to the form and aspect H value of all grids in sliding window The form and aspect H value of first grid, sliding window are slided one by one to retrieve the form and aspect H value of (M-N+1) * (M-N+1) a grid, Trade mark black white image to be monitored or trademark image to be monitored are reduced into the new of (M-N+1) * (M-N+1) a grid by M*M grid Image extracts the form and aspect H value of each grid, obtains (M-N+1) * (M-N+1) form and aspect H value matrix of M-N+1 level, wherein N It is positive integer less than M, N and M;
It repeats the above steps on the new images of trade mark black white image to be monitored or the new images of trademark image to be monitored, no The new images of the disconnected new images for obtaining diminishing trade mark black white image to be monitored or trademark image to be monitored are to constantly obtain Take the form and aspect H of the corresponding level of new images of the new images or trademark image to be monitored of obtained trade mark black white image to be monitored Value matrix.
Further, the N is equal to 2, i.e. sliding window is 2*2 grid.
Further, when process object is trade mark black white image to be monitored, all sides according in sliding window The form and aspect H value of lattice redefines the form and aspect H value of first grid of the sliding window according to preset rules specifically: seeks sliding The average value of the form and aspect H value of all pixels point in dynamic 2*2 grid of window, and the average value is carried out after binary conversion treatment to locate Manage the form and aspect H value for first grid that end value is 2*2 grid of sliding window, wherein the binary conversion treatment and the gray scale Binary conversion treatment mode in binary conversion treatment step is identical;
It is described to be pressed according to the form and aspect H value of all grids in sliding window when process object is trademark image to be detected The form and aspect H value of first grid of the sliding window is redefined according to preset rules specifically: seek 2*2 side of sliding window The average value of the form and aspect H value of all pixels point in lattice, and using the average value as first grid of 2*2 grid of sliding window Form and aspect H value.
Further, described that binary conversion treatment is carried out to the trademark image to be monitored thus by the trademark image to be monitored As being converted to trade mark black white image to be monitored specifically: be limited with a certain threshold value, gray value is high in the trademark image to be monitored 255 are converted into the gray value of the pixel of threshold value, gray value is lower than the pixel of threshold value in the trademark image to be monitored Gray value is converted into 0.
Further, the threshold value is 128.
Further, the judgment formula of similarity S are as follows:
Wherein, similarity S can be the character string of trademark image to be monitored for black and white similarity S1 or color similarity S2, X Consistent highest level is compared with the character string of trademark image to be compared, Y is trademark image to be monitored and trademark image to be compared The level sum that can be compared, X and Y are positive integer.
The second object of the present invention adopts the following technical scheme that realization:
A kind of electronic equipment, the electronic equipment include: processor and memory, and the memory is stored with can be described The computer program run on processor, the processor are realized above-mentioned based on sliding window when executing the computer program Trade mark similarity judgment method.
The third object of the present invention adopts the following technical scheme that realization:
A kind of computer readable storage medium, the computer-readable recording medium storage have executable computer program, The computer program can realize the above-mentioned trade mark similarity judgment method based on sliding window when running.
Compared with prior art, the beneficial effects of the present invention are:
The trade mark similarity judgment method based on sliding window is by establishing the blackaandawhite characterumay string of trademark image to be monitored Then java standard library and color characters string java standard library periodically obtain the new audit trademark image announced according to the bulletin time of trademark office Picture establishes the blackaandawhite characterumay string comparison library and color characters string comparison library of new audit trademark image, by trademark image to be monitored The blackaandawhite characterumay string comparison library and color word of blackaandawhite characterumay string java standard library and color characters string java standard library and new audit trademark image The character string for according with corresponding level in string comparison library is compared, thus the new audit trademark image of judgement and trademark image to be monitored Similarity;After this method is by carrying out Fuzzy processing to trademark image, the principle of simulation artificial vision's judgement is similar to trade mark Degree is judged, realizes that automation compares, and judges reliability with higher to the similitude of trade mark, is mitigated manual retrieval and is compared The workload of analysis improves retrieval comparison efficiency.
Detailed description of the invention
Fig. 1 is a kind of flow diagram of the trade mark similarity judgment method based on sliding window provided by the invention;
Fig. 2 is the flow diagram of the blackaandawhite characterumay string java standard library for establishing trademark image to be monitored in Fig. 1;
Fig. 3 is the flow diagram of the color characters string java standard library for establishing trademark image to be monitored in Fig. 1;
Fig. 4 is the example pattern of trademark image grid division provided by the invention.
Specific embodiment
In the following, being described further in conjunction with attached drawing and specific embodiment to the present invention, it should be noted that not Under the premise of conflicting, new implementation can be formed between various embodiments described below or between each technical characteristic in any combination Example.
It please refers to Fig.1 to Fig.3, a kind of trade mark similarity judgment method based on sliding window, comprising the following steps:
S1, the standard characters library step for establishing trademark image to be monitored:
Judge trademark image to be monitored whether be designated color application color logo image;If so, establishing to be monitored The blackaandawhite characterumay string java standard library and color characters string java standard library of trademark image;If it is not, then only establishing trademark image to be monitored Blackaandawhite characterumay string java standard library;
S11, the blackaandawhite characterumay string java standard library for establishing trademark image to be monitored:
(1) binarization of gray value is handled:
S111, trademark image to be monitored is obtained, binary conversion treatment is carried out to trademark image to be monitored thus by quotient to be monitored Logo image is converted to trade mark black white image to be monitored;By binary conversion treatment, by the gray value of trademark image, it is with a certain threshold value Limit, is converted to 0 or 255, i.e., black and white figure eliminates extra background, noise.Specific 128 or more the present invention is converted into 255,128 or less are converted into 0.
(2) normalized:
S112, trade mark black white image to be monitored is divided by M*M grid according to trademark image size to be monitored, extracted every Form and aspect H value in the color H SB value of a grid, obtains the form and aspect H value matrix of M level, and M is positive integer.For example, according to trade mark Trademark image is divided into 10*10 grid spaces by image size, then obtains the matrix of 100 grid spaces;It is divided into 100* 100 grid spaces, then obtain the matrix of 10000 grid spaces;Or it is divided into 200*200,500*500,1000*1000 A grid spaces etc. are specifically divided into how many a grid spaces, are imitated according to the judgement after the size and division of trademark image Fruit could be adjusted to determine, no matter what shape trademark image is, grid spaces matrix is established using square.Specifically Ground, first estimate divide a proper grid quantity, by calculate after recognition effect judge the quantity grid whether Expected better effects can be reached, tested if cannot be further added by or reduce, until arithmetic speed and calculated result It is all proper under comprehensively considering to be divided with regard to corresponding using the grid of the quantity.For irregular trade mark equally with correspondence The grid quantity set divides, and only according to fixed bit placement location trade mark since first point, image is not Regular domain corresponds to the grid of blank.
S113, trade mark black white image to be monitored is reduced gradually to obtain wait supervise by the method for normalizing based on sliding window The new images of trade mark black white image are surveyed, the corresponding level of new images of obtained trade mark black white image to be monitored is obtained every time Form and aspect H value matrix;
S114, cryptographic Hash is calculated by each form and aspect H value matrix, obtains the corresponding unique character of each form and aspect H value matrix String, and each character string is stored according to level belonging to each form and aspect H value matrix, establish the black of the trademark image to be monitored White character string java standard library;
S12, the corresponding color characters string java standard library of trademark image to be monitored is established:
S121, trademark image to be monitored is obtained, trademark image to be monitored is divided into M*M grid, extracts each grid Color H SB value in form and aspect H value, obtain the form and aspect H value matrix of M level, M is positive integer;
S122, trademark image to be monitored is gradually reduced by the method for normalizing based on sliding window to obtain quotient to be monitored The new images of logo image obtain the form and aspect H value matrix of the corresponding level of new images of obtained trademark image to be monitored every time;
S123, cryptographic Hash is calculated by each form and aspect H value matrix, obtains the corresponding unique character of each form and aspect H value matrix String, and each character string is stored according to level belonging to each form and aspect H value matrix, establish the face of the trademark image to be monitored Color character string java standard library;
S2, the blackaandawhite characterumay string comparison library step for establishing trademark image to be compared:
As the blackaandawhite characterumay string java standard library for establishing trademark image to be monitored, specifically includes the following steps:
(1) binarization of gray value processing step:
New audit trademark image is periodically obtained, binary conversion treatment is carried out to new audit trademark image, is converted to new audit quotient Mark black white image;
(2) normalized step:
New audit trade mark black white image is divided into N*N grid according to new audit trademark image size, extracts each side Form and aspect H value in the color H SB value of lattice obtains N*N form and aspect H value matrix;
Reduce new audit trade mark black white image gradually by slip window sampling to obtain the new of new audit trade mark black white image Image obtains every time the form and aspect H value matrix of the corresponding level of new images of obtained new audit trade mark black white image;
Cryptographic Hash is calculated by each form and aspect H value matrix, obtains the corresponding unique string of each form and aspect H value matrix, and Each character string is stored according to level belonging to each form and aspect H value matrix, establishes the black and white word of the new audit trademark image Symbol string comparison library;
Compare step:
S3, by the character string of each level in the blackaandawhite characterumay string comparison library of each trademark image to be compared with it is to be monitored The character string of corresponding level in the blackaandawhite characterumay string java standard library of trademark image is compared, according to the character for comparing each level The consistency of string judges the height of black and white similarity S1;In addition, also according to black and white similarity S1 from high to low by it is each to Trademark image is compared to be ranked up;
S4, judge trademark image to be monitored whether be designated color application color logo image;
S5, if it is not, then compare terminate;
S6, if so, carry out color comparison, specifically: black and white similarity S1 is reached into the to be compared of preset threshold or more Color logo image zooming-out in trademark image comes out, it is preferable that preset threshold can be set as 80%, and according to establishing quotient to be monitored The method of the color characters string java standard library of logo image establishes the color characters string comparison library of each color logo image to be compared, That is: trademark image to be monitored is replaced with into color logo image to be compared, executes step S121 to S123, generate color characters string Comparison library;By in the color characters string java standard library of trademark image to be monitored each character string and each color logo figure to be compared The character string of corresponding level in the color characters string comparison library of picture is compared, according to the consistent of the character string for comparing each level Property come judge the height of color similarity S2 to according to the height of color similarity S2 come by each color logo figure to be compared As being ranked up.
The trade mark similarity judgment method based on sliding window is by establishing the blackaandawhite characterumay string of trademark image to be monitored Then java standard library and color characters string java standard library periodically obtain the new audit trademark image announced according to the bulletin time of trademark office Picture establishes the blackaandawhite characterumay string comparison library and color characters string comparison library of new audit trademark image, by trademark image to be monitored The blackaandawhite characterumay string comparison library and color word of blackaandawhite characterumay string java standard library and color characters string java standard library and new audit trademark image The character string for according with corresponding level in string comparison library is compared, thus the new audit trademark image of judgement and trademark image to be monitored Similarity;It realizes that trade mark automatic monitoring compares, reliability with higher is judged to the similitude of trade mark, will newly audit trade mark Image is arranged according to the sequence of similarity, mitigates the workload that manual retrieval compares analysis, is improved retrieval and is compared effect Rate, user directly can check each similar brand according to similarity list, and the trade mark high for similarity is mentioned to trademark office in time Objection is played, safeguards the legitimate rights and interests of itself trade mark.
As a preferred embodiment, passing through the normalizing based on sliding window in step S113 and step S122 Change method gradually reduces trademark image to be monitored, and (trademark image to be monitored is the trade mark to be monitored obtained by binarization of gray value The original image of black white image or trademark image to be monitored) to obtain the new images of trademark image to be monitored, obtained by obtaining every time Trademark image to be monitored the corresponding level of new images form and aspect H value matrix specifically:
On the trademark image to be monitored for being divided into M*M grid, using N*N grid as sliding window, according to sliding window The form and aspect H value of all grids in mouthful redefines the form and aspect H value of first grid of the sliding window according to preset rules, Sliding window is slided one by one to retrieve the form and aspect H value of (M-N+1) * (M-N+1) a grid, and trademark image to be monitored is by M*M A grid is reduced into the new images of (M-N+1) * (M-N+1) a grid, extracts the form and aspect H value of each grid, obtains M-N+1 layers (M-N+1) * (M-N+1) form and aspect H value matrix of grade;Preferably, N is equal to 2, i.e. sliding window is 2*2 grid.Namely with 2* 2 grids are that sliding window slides from left to right from top to bottom, constantly do the content in every 2*2 grid at blurring Reason, i.e., constantly redefine the 1st according to preset rules according to the form and aspect H value of pixel point each in every 2*2 grid spaces The form and aspect H value of a grid, to finally obtain the form and aspect H value matrix of new (M-1) * (M-1) a grid;According to above-mentioned side Method trademark image to be monitored is constantly reduced obtain from (M-1) * (M-1) again to ((M-1) -1) * ((M-1) -1) to the last only The grid for remaining next 1*1 obtains the form and aspect H value matrix of multiple levels.
As a preferred embodiment, when process object is trade mark black white image to be monitored, it is described according to sliding The form and aspect H value of all grids in window redefines the form and aspect H of first grid of the sliding window according to preset rules Value specifically: seek the average value of the form and aspect H value of all pixels point in 2*2 grid of sliding window, and the average value is carried out Using processing result value as the form and aspect H value of first grid of 2*2 grid of sliding window after binary conversion treatment, wherein the two-value It is identical as the binary conversion treatment mode in the binarization of gray value processing step to change processing.Due to carry out binary conversion treatment be with 128 be boundary, and form and aspect H value is greater than 128 and is converted to 255, when form and aspect H value is less than 128, is then converted to 0, that is to say, that work as 2*2 When the grid number that form and aspect H value in a grid is 255 is greater than 2, the average value of the form and aspect H value in all grids is greater than certainly 128, therefore the form and aspect H value of first grid in the 2*2 grid is set as 255;When the form and aspect H value in 2*2 grid is 255 Grid number when being less than or equal to 2, the form and aspect H value in all grids is less than 128, then first side in the 2*2 grid The form and aspect H value of lattice is set as 0, for this situation, the coding 0 and 1 of 0 and 255 corresponding computers can redefined sliding window First grid form and aspect H value when, it is only necessary to judging to have in the corresponding data of each grid 21 or more, then value is 1, i.e., Form and aspect H value is 255, and otherwise value is 0, i.e., form and aspect H value is 0.
It is described to be pressed according to the form and aspect H value of all grids in sliding window when process object is trademark image to be detected The form and aspect H value of first grid of the sliding window is redefined according to preset rules specifically: seek 2*2 side of sliding window The average value of the form and aspect H value of all pixels point in lattice, and using the average value as first grid of 2*2 grid of sliding window Form and aspect H value.
Specifically, it is illustrated by taking a trademark image as an example, refering to Fig. 4, trademark image is subjected to homogenization processing, by quotient The grid spaces that logo image is divided into 200*200 obtain the matrix (1) of 40000 grid spaces, extract in each grid spaces Form and aspect H value, so that it may obtain the form and aspect H value matrix of 40000 grid.From top to bottom, it slides from left to right, according to matrix (1) the form and aspect H value of all pixels point in every 2*2 grid spaces (tetra- grid spaces abcd in such as matrix (1)) is put down Mean value, if black white image then needs the result after average value progress binary conversion treatment redefining the 1st grid (i.e. square Battle array (2) in corresponding grid a1) form and aspect H value, if color image then directly with average value be the 1st grid form and aspect H value; The number that the form and aspect H value of the point in tetra- grid spaces bedf in matrix (1) is 255 is redefined according to the above method First grid (corresponding 2nd grid b1 i.e. in matrix (2) grid) form and aspect H value of the sliding window, constantly repeats above-mentioned side Method is extracted each to the matrix that the grid spaces for obtaining a such as 199*199 of matrix (2) include 39601 grid spaces Form and aspect H value in grid obtains the form and aspect H value matrix of 39601 grid.The above method is constantly repeated trademark image to be monitored The grid spaces of a grid are constantly reduced and establish 198*198,197*197 ..., only remain next 1*1 grid to the end until obtaining Grid spaces, extract the form and aspect H value of each grid in the grid matrix that obtains each time, altogether available 200 layers The form and aspect H value matrix of grade.
As a preferred embodiment, the judgment formula of similarity S are as follows:
Wherein, similarity S can be the character string of trademark image to be monitored for black and white similarity S1 or color similarity S2, X Consistent highest level is compared with the character string of trademark image to be compared, Y is trademark image to be monitored and trademark image to be compared The level sum that can be compared, X and Y are positive integer.
For example, then Y is 200 when the number of levels of trademark image to be monitored and new audit trademark image is 200, when When this level of 200*200 compares consistent, X 200, similarity 100%;When this level of 199*199 compares consistent, X is 199, and similarity 199/200*100%, i.e. similarity are 99.5%, and so on.It is when trademark image to be monitored and newly careful When the number of levels of core trademark image is inconsistent, such as number of levels of trademark image to be monitored is 128, and newly audits the layer of trademark image Series is 64, that is to say, that the 64*64 of trademark image to be monitored level below can be with the respective layer of new audit trademark image Grade is compared, and the level of 128*128 to 65*65 does not have corresponding level in newly audit trademark image, can not be compared, At this point, Y is 64, and when this level of 64*64 compares consistent, X 64, similarity 100%;When in this level of 63*63 When comparing consistent, X 63, similarity 63/64*100%, i.e. similarity are 98.4%.The number of levels of new audit trademark image Than trademark image to be monitored number of levels more than be also and so on.
The present invention also provides a kind of electronic equipment, electronic equipment includes: processor and memory, and memory is stored with can The computer program run on a processor, processor realize the above-mentioned trade mark based on sliding window when executing computer program Similarity judgment method.
In addition, computer-readable recording medium storage has can the present invention also provides a kind of computer readable storage medium Computer program is executed, computer program can realize the above-mentioned trade mark similarity judgment method based on sliding window when running.
The above embodiment is only the preferred embodiment of the present invention, and the scope of protection of the present invention is not limited thereto, The variation and replacement for any unsubstantiality that those skilled in the art is done on the basis of the present invention belong to institute of the present invention Claimed range.

Claims (9)

1. a kind of trade mark similarity judgment method based on sliding window, which comprises the following steps:
Establish the standard characters library step of trademark image to be monitored:
Judge trademark image to be monitored whether be designated color application color logo image;If so, establishing trade mark to be monitored The blackaandawhite characterumay string java standard library and color characters string java standard library of image;If it is not, then only establishing the black and white of trademark image to be monitored Character string java standard library;
Establish the blackaandawhite characterumay string java standard library of trademark image to be monitored:
(1) binarization of gray value is handled:
Trademark image to be monitored is obtained, binary conversion treatment is carried out to the trademark image to be monitored thus by the trade mark to be monitored Image is converted to trade mark black white image to be monitored;
(2) normalized:
The trade mark black white image to be monitored is divided into M*M grid according to the trademark image size to be monitored, is extracted every Form and aspect H value in the color H SB value of a grid, obtains the form and aspect H value matrix of M level, and M is positive integer;
It is described wait supervise to obtain gradually to reduce the trade mark black white image to be monitored by the method for normalizing based on sliding window The new images of trade mark black white image are surveyed, the corresponding level of new images of obtained trade mark black white image to be monitored is obtained every time Form and aspect H value matrix;
Cryptographic Hash is calculated by each form and aspect H value matrix, obtains the corresponding unique string of each form and aspect H value matrix, and will be each Character string is stored according to level belonging to each form and aspect H value matrix, establishes the blackaandawhite characterumay string of the trademark image to be monitored Java standard library;
Establish the corresponding color characters string java standard library of the trademark image to be monitored:
The trademark image to be monitored is obtained, the trademark image to be monitored is divided into M*M grid, extracts each grid Form and aspect H value in color H SB value, obtains the form and aspect H value matrix of M level, and M is positive integer;
Reduce the trademark image to be monitored gradually by the method for normalizing based on sliding window to obtain the quotient to be monitored The new images of logo image obtain the form and aspect H value matrix of the corresponding level of new images of obtained trademark image to be monitored every time;
Cryptographic Hash is calculated by each form and aspect H value matrix, obtains the corresponding unique string of each form and aspect H value matrix, and will be each Character string is stored according to level belonging to each form and aspect H value matrix, establishes the color characters string of the trademark image to be monitored Java standard library;
Establish the blackaandawhite characterumay string comparison library step of trademark image to be compared:
The black and white of trademark image to be compared is established according to the method for the blackaandawhite characterumay string java standard library for establishing trademark image to be monitored Character string comparison library;
Compare step:
By the character string of each level in the blackaandawhite characterumay string comparison library of each trademark image to be compared and trademark image to be monitored The character string of corresponding level in the blackaandawhite characterumay string java standard library of picture is compared, according to the one of the character string for comparing each level Cause property judges the height of black and white similarity S1;
Judge trademark image to be monitored whether be designated color application color logo image;
If it is not, then comparing terminates;
If so, black and white similarity S1 to be reached to the color logo image zooming-out in the trademark image to be compared of preset threshold or more Out, and according to the method for the color characters string java standard library for establishing the trademark image to be monitored each colour to be compared is established The color characters string comparison library of trademark image;By each character in the color characters string java standard library of the trademark image to be monitored String is compared with the character string of the corresponding level in the color characters string comparison library of each color logo image to be compared, according to The consistency of the character string of each level is compared to judge the height of color similarity S2.
2. the trade mark similarity judgment method based on sliding window as described in claim 1, which is characterized in that by based on cunning The method for normalizing of dynamic window reduces the trade mark black white image to be monitored or the trademark image to be monitored gradually to obtain The new images of trade mark black white image to be monitored or the new images of the trademark image to be monitored are stated, are obtained obtained wait supervise every time Survey the form and aspect H value matrix of the corresponding level of new images of the new images or trademark image to be monitored of trade mark black white image specifically:
It is sliding with N*N grid on the trade mark black white image to be monitored or trademark image to be monitored for being divided into M*M grid Window redefines the first of the sliding window according to preset rules according to the form and aspect H value of all grids in sliding window The form and aspect H value of a grid, sliding window are slided one by one to retrieve the form and aspect H value of (M-N+1) * (M-N+1) a grid, wait supervise It surveys trade mark black white image or trademark image to be monitored is reduced into the new images of (M-N+1) * (M-N+1) a grid by M*M grid, The form and aspect H value for extracting each grid obtains (M-N+1) * (M-N+1) form and aspect H value matrix of M-N+1 level, wherein N is less than M, N and M are positive integer;
It repeats the above steps on the new images of trade mark black white image to be monitored or the new images of trademark image to be monitored, constantly obtains The new images of diminishing trade mark black white image to be monitored or the new images of trademark image to be monitored are obtained to constantly obtain institute The form and aspect H value square of the corresponding level of new images of the new images or trademark image to be monitored of obtained trade mark black white image to be monitored Battle array.
3. the trade mark similarity judgment method based on sliding window as claimed in claim 2, which is characterized in that the N is equal to 2, i.e. sliding window is 2*2 grid.
4. the trade mark similarity judgment method based on sliding window as claimed in claim 3, which is characterized in that work as process object When for trade mark black white image to be monitored, the form and aspect H value according to all grids in sliding window is according to preset rules come weight Newly determine the form and aspect H value of first grid of the sliding window specifically: seek all pixels point in 2*2 grid of sliding window Form and aspect H value average value, and to the average value carry out binary conversion treatment after using processing result value as 2*2 grid of sliding window First grid form and aspect H value, wherein the binary conversion treatment in the binary conversion treatment and the binarization of gray value processing step Mode is identical;
When process object is trademark image to be detected, the form and aspect H value according to all grids in sliding window is according to pre- If the regular form and aspect H value to redefine first grid of the sliding window specifically: seek in 2*2 grid of sliding window The average value of the form and aspect H value of all pixels point, and using the average value as the form and aspect of first grid of 2*2 grid of sliding window H value.
5. such as the described in any item trade mark similarity judgment methods based on sliding window of Claims 1-4, which is characterized in that It is described that binary conversion treatment is carried out to which the trademark image to be monitored is converted to quotient to be monitored to the trademark image to be monitored Mark black white image specifically: be limited with a certain threshold value, gray value is higher than the pixel of the threshold value in the trademark image to be monitored The gray value of point is converted into 255, and gray value turns lower than the gray value of the pixel of the threshold value in the trademark image to be monitored Turn to 0.
6. the trade mark similarity judgment method based on sliding window as claimed in claim 5, which is characterized in that the threshold value is 128。
7. the trade mark similarity judgment method based on sliding window as claimed in claim 5, which is characterized in that similarity S's Judgment formula are as follows:
Wherein, similarity S can be black and white similarity S1 or color similarity S2, X be trademark image to be monitored character string with to The character string for comparing trademark image compares consistent highest level, and Y is that trademark image to be monitored and trademark image to be compared can be into The level sum that row compares, X and Y are positive integer.
8. a kind of electronic equipment, which is characterized in that the electronic equipment includes: processor and memory, the memory storage There is the computer program that can be run on the processor, is realized when the processor executes the computer program as right is wanted Seek 1 to 7 described in any item trade mark similarity judgment methods based on sliding window.
9. a kind of computer readable storage medium, which is characterized in that the computer-readable recording medium storage has executable meter Calculation machine program, the computer program can realize the quotient as described in any one of claim 1 to 7 based on sliding window when running Mark similarity judgment method.
CN201811106692.2A 2018-09-21 2018-09-21 Trademark similarity judging method and device based on sliding window and storage medium Active CN109460771B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811106692.2A CN109460771B (en) 2018-09-21 2018-09-21 Trademark similarity judging method and device based on sliding window and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811106692.2A CN109460771B (en) 2018-09-21 2018-09-21 Trademark similarity judging method and device based on sliding window and storage medium

Publications (2)

Publication Number Publication Date
CN109460771A true CN109460771A (en) 2019-03-12
CN109460771B CN109460771B (en) 2021-02-02

Family

ID=65606814

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811106692.2A Active CN109460771B (en) 2018-09-21 2018-09-21 Trademark similarity judging method and device based on sliding window and storage medium

Country Status (1)

Country Link
CN (1) CN109460771B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110472002A (en) * 2019-08-14 2019-11-19 腾讯科技(深圳)有限公司 A kind of text similarity acquisition methods and device

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101162470A (en) * 2007-11-16 2008-04-16 北京交通大学 Video frequency advertisement recognition method based on layered matching
US20100220924A1 (en) * 2009-03-02 2010-09-02 Gwo Giun Lee Method and System of Extracting A Perceptual Feature Set
CN102622420A (en) * 2012-02-22 2012-08-01 哈尔滨工程大学 Trademark image retrieval method based on color features and shape contexts
CN102819582A (en) * 2012-07-26 2012-12-12 华数传媒网络有限公司 Quick searching method for mass images
CN106126572A (en) * 2016-06-17 2016-11-16 中国科学院自动化研究所 Image search method based on area validation
CN106375847A (en) * 2015-07-23 2017-02-01 无锡天脉聚源传媒科技有限公司 Template generation method, template generation device, video updating method and video updating device
CN107610106A (en) * 2017-08-31 2018-01-19 移康智能科技(上海)股份有限公司 A kind of detection method, device, electronic equipment and computer-readable recording medium

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101162470A (en) * 2007-11-16 2008-04-16 北京交通大学 Video frequency advertisement recognition method based on layered matching
US20100220924A1 (en) * 2009-03-02 2010-09-02 Gwo Giun Lee Method and System of Extracting A Perceptual Feature Set
CN102622420A (en) * 2012-02-22 2012-08-01 哈尔滨工程大学 Trademark image retrieval method based on color features and shape contexts
CN102819582A (en) * 2012-07-26 2012-12-12 华数传媒网络有限公司 Quick searching method for mass images
CN106375847A (en) * 2015-07-23 2017-02-01 无锡天脉聚源传媒科技有限公司 Template generation method, template generation device, video updating method and video updating device
CN106126572A (en) * 2016-06-17 2016-11-16 中国科学院自动化研究所 Image search method based on area validation
CN107610106A (en) * 2017-08-31 2018-01-19 移康智能科技(上海)股份有限公司 A kind of detection method, device, electronic equipment and computer-readable recording medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110472002A (en) * 2019-08-14 2019-11-19 腾讯科技(深圳)有限公司 A kind of text similarity acquisition methods and device

Also Published As

Publication number Publication date
CN109460771B (en) 2021-02-02

Similar Documents

Publication Publication Date Title
CN101799921B (en) Cloud detection method of optic remote sensing image
CN105068918B (en) A kind of page method of testing and device
CN104408483B (en) SAR texture image classification methods based on deep neural network
CN109960737A (en) Remote Sensing Images search method of the semi-supervised depth confrontation from coding Hash study
CN108769079A (en) A kind of Web Intrusion Detection Techniques based on machine learning
CN108985363A (en) A kind of cracks in reinforced concrete bridge classifying identification method based on RBPNN
Kanjanawanishkul et al. Novel fast color reduction algorithm for time-constrained applications
Zhang et al. A Study of Image Classification of Remote Sensing Based on Back‐Propagation Neural Network with Extended Delta Bar Delta
CN102938069A (en) Pure and mixed pixel automatic classification method based on information entropy
Yang et al. Content-based image retrieval using local visual attention feature
CN108241663A (en) A kind of graphic collection method based on image retrieval
CN104462526A (en) Multi-user online collaboration rapid vectorization method for high-resolution remote sensing images
CN115641327A (en) Building engineering quality supervision and early warning system based on big data
Baluyan et al. Novel approach for rooftop detection using support vector machine
CN109460771A (en) Trade mark similarity judgment method, equipment and storage medium based on sliding window
CN114913422A (en) Karst rocky mountain area soil and water loss field monitoring device
CN109919843A (en) Skin image texture evaluation method and system based on adaptive quartering method
Chen et al. Structural feature modeling of high-resolution remote sensing images using directional spatial correlation
CN109409748B (en) Checking method and system for farmland quality evaluation index relevance
CN116011061A (en) Three-dimensional reconstruction model monomer segmentation method, system and terminal for multi-target building
CN115564970A (en) Network attack tracing method, system and storage medium
CN104462413A (en) Method for distinguishing patterns and colors of marbles
CN113239944B (en) Image feature extraction method and device, electronic equipment and medium
Yu Quality assessment in point feature generalization with pattern preserved
Bao et al. An automatic extraction method for individual tree crowns based on self-adaptive mutual information and tile computing

Legal Events

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