CN114186621A - Product trademark identification method and device based on BP neural network - Google Patents
Product trademark identification method and device based on BP neural network Download PDFInfo
- Publication number
- CN114186621A CN114186621A CN202111462783.1A CN202111462783A CN114186621A CN 114186621 A CN114186621 A CN 114186621A CN 202111462783 A CN202111462783 A CN 202111462783A CN 114186621 A CN114186621 A CN 114186621A
- Authority
- CN
- China
- Prior art keywords
- trademark
- neural network
- prediction model
- network prediction
- picture
- 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.)
- Withdrawn
Links
- 238000013528 artificial neural network Methods 0.000 title claims abstract description 69
- 238000000034 method Methods 0.000 title claims abstract description 31
- 238000012549 training Methods 0.000 claims abstract description 30
- 239000011159 matrix material Substances 0.000 claims abstract description 12
- 238000012360 testing method Methods 0.000 claims abstract description 11
- 238000012795 verification Methods 0.000 claims abstract description 8
- 230000006870 function Effects 0.000 claims description 28
- 230000004913 activation Effects 0.000 claims description 14
- 210000002569 neuron Anatomy 0.000 claims description 9
- 238000012545 processing Methods 0.000 claims description 8
- 238000004590 computer program Methods 0.000 claims description 6
- 238000004422 calculation algorithm Methods 0.000 claims description 5
- 238000005457 optimization Methods 0.000 claims description 4
- 238000013507 mapping Methods 0.000 claims description 3
- 238000012216 screening Methods 0.000 abstract description 3
- 230000000694 effects Effects 0.000 description 4
- 238000010586 diagram Methods 0.000 description 3
- 230000008569 process Effects 0.000 description 3
- 238000004364 calculation method Methods 0.000 description 2
- 238000012937 correction Methods 0.000 description 2
- 238000001514 detection method Methods 0.000 description 2
- 238000011161 development Methods 0.000 description 2
- 238000013508 migration Methods 0.000 description 2
- 230000005012 migration Effects 0.000 description 2
- 230000004075 alteration Effects 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 235000019504 cigarettes Nutrition 0.000 description 1
- 238000013499 data model Methods 0.000 description 1
- 230000003247 decreasing effect Effects 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000005265 energy consumption Methods 0.000 description 1
- 238000000605 extraction Methods 0.000 description 1
- 238000013095 identification testing Methods 0.000 description 1
- 230000008520 organization Effects 0.000 description 1
- 230000000644 propagated effect Effects 0.000 description 1
- 238000002310 reflectometry Methods 0.000 description 1
- 230000003595 spectral effect Effects 0.000 description 1
- 238000013519 translation Methods 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F18/00—Pattern recognition
- G06F18/20—Analysing
- G06F18/24—Classification techniques
- G06F18/241—Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/04—Architecture, e.g. interconnection topology
- G06N3/044—Recurrent networks, e.g. Hopfield networks
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/02—Neural networks
- G06N3/08—Learning methods
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
- G06Q30/00—Commerce
- G06Q30/018—Certifying business or products
- G06Q30/0185—Product, service or business identity fraud
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- Data Mining & Analysis (AREA)
- General Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- Life Sciences & Earth Sciences (AREA)
- Artificial Intelligence (AREA)
- Business, Economics & Management (AREA)
- Evolutionary Computation (AREA)
- Computational Linguistics (AREA)
- Computing Systems (AREA)
- Software Systems (AREA)
- Health & Medical Sciences (AREA)
- Biomedical Technology (AREA)
- Biophysics (AREA)
- Mathematical Physics (AREA)
- General Health & Medical Sciences (AREA)
- Molecular Biology (AREA)
- Bioinformatics & Computational Biology (AREA)
- Economics (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Bioinformatics & Cheminformatics (AREA)
- Entrepreneurship & Innovation (AREA)
- Accounting & Taxation (AREA)
- Development Economics (AREA)
- Evolutionary Biology (AREA)
- Finance (AREA)
- Marketing (AREA)
- Strategic Management (AREA)
- General Business, Economics & Management (AREA)
- Image Analysis (AREA)
- Image Processing (AREA)
Abstract
The invention discloses a product trademark identification method and a device based on a BP neural network, comprising the following steps: acquiring a trademark picture data set for identification, and converting each trademark picture in the data set into RGB three-channel matrix pixel values; dividing the training set, the verification set and the test set according to a certain proportion; constructing a BP neural network prediction model; performing iterative training on the model by using a training set, verifying the trained BP neural network prediction model by using a verification set, setting a minimum mean square error, and obtaining the BP neural network prediction model for trademark identification when the learning precision of the BP neural network prediction model meets the minimum mean square error; and inputting the test set into the BP neural network prediction model for trademark authentication to obtain a trademark authentication result. The invention realizes the identification and classification of the pirated trademarks and can obviously increase the efficiency of intelligently screening the pirated trademarks.
Description
Technical Field
The invention belongs to the technical field of identification, and particularly relates to a product trademark identification method and device based on a BP (Back propagation) neural network.
Background
Trademark and LOGO are unique symbols of a company, an organization, a brand and a product, and a merchant can analyze the development condition of the brand in the whole market and the future development trend by searching and identifying related trademarks and can help an advertiser check the effectiveness of advertisements and determine whether copyright infringement is a problem. However, due to the dramatic increase in the size of internet pictures and video data, effective intelligent authentication of product brands in pictures and videos has become an irrevocable problem.
The trademark comprises elements such as texts, symbols and graphics, and the main difficulties in the conventional trademark detection include that the position and the angle of the trademark in a picture are uncertain, the trademark has great change due to various printing, lighting, shielding, rotating, cutting, size and other factors in a natural scene, the intra-class difference of the trademark is large, the inter-class difference is small, and false detection is easy to bring. At present, a feature extraction algorithm based on a Hu correction moment is adopted in the existing trademark identification, and the obtained correction moment value is basically kept unchanged and has certain stability when the method is used for various states of trademarks, such as rotation, scaling or translation. Aiming at the problem of high resource requirement in the trademark identification process, the trademark identification method based on calculation migration is used for identifying the trademark by an intelligent terminal, and the execution position of a task node is guided by an application cost graph to make a decision, so that the calculation migration in the trademark identification application process is realized, and the energy consumption of the terminal is reduced. Aiming at the identification problem of the laser cigarette pack, the color information of the main body is judged through the spectral reflectivity, and the average value of the chromatic aberration is calculated.
Disclosure of Invention
The purpose of the invention is as follows: aiming at the problems, the invention provides a product trademark authentication method and device based on a BP (back propagation) neural network, which are used for learning and training the image information of the trademark, realizing the identification and classification of the pirated trademark and remarkably increasing the efficiency of intelligently screening the pirated trademark.
The technical scheme is as follows: in order to achieve the purpose of the invention, the invention firstly provides a product trademark identification method based on a BP neural network, which specifically comprises the following steps:
step 2, dividing the trademark picture processing data set in the step 1 into a training set, a verification set and a test set according to a certain proportion;
and 6, inputting the test set in the step 2 into the BP neural network prediction model for trademark authentication to obtain a trademark authentication result.
Further, the BP neural network prediction model in step 3 includes 1 input layer, 8 hidden layers, and 1 output layer, all the layers are connected, and each connection has a weighted value; the number ratio of each layer of neurons in the 8 hidden layers is 2048, 1024, 512, 128, 64, 32, 16 and 8 respectively; wherein, the activation function of the hidden layer is a tanh activation function, and the activation function of the output layer is a softmax function.
Further, in the step 4, an iterative training method of a variable learning rate is used, and a gradient descent optimization algorithm is used for updating weighted values between layers of the BP neural network prediction model; during each training, the initial learning rate a is 0.001, and the step length b is 0.0005.
Further, in step 4, during the iterative training, the loss function is processed by using an L2 regularization, where the L2 regularization formula is as follows:
in the formula, L represents a loss function after L2 regularization; einIs the original loss function without the addition of the L2 regularization term; λ is a regularization parameter; j is the total number of elements in the L2 regularization weight vector w; w is ajRepresenting the jth element in the L2 regularized weight vector w.
Further, the minimum mean square error in step 5 is 1e-8。
The invention also provides a product trademark identification device based on the BP neural network, which comprises the following components:
the picture acquisition module is used for acquiring a trademark picture data set;
the image processing module is used for converting each trademark image in the collected trademark image data set into RGB three-channel matrix pixel values;
the model generation module is used for generating a BP neural network prediction model;
and the picture identification module is used for identifying the true and false information value of the trademark picture.
The invention also provides a computer device, which comprises a memory, a processor and a computer program stored in the memory and capable of running on the processor, wherein the processor executes the computer program to realize the steps of the product trademark authentication method based on the BP neural network.
The invention also proposes a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of a method for product brand authentication based on a BP neural network.
Has the advantages that: compared with the prior art, the technical scheme of the invention has the following beneficial technical effects:
the method is characterized in that a trademark identification device of a full-connection forward feedback neural network is constructed based on BP, identification test is carried out on a test set trademark with a certain scale, a prediction model is constructed, and the model is loaded into the network for iterative training, so that the prediction capability of the network is evaluated, and the trademark is identified more accurately; the method and the device realize the identification and classification of the pirated trademarks and can obviously increase the efficiency of intelligently screening the pirated trademarks.
Drawings
FIG. 1 is a diagram illustrating the basic architecture of the BP neural network according to an embodiment of the present invention;
FIG. 2 is a flow chart of the design of a next BP neural network-based product trademark authentication method according to an embodiment;
FIG. 3 is a block diagram of a BP neural network prediction method according to an embodiment of the present invention;
FIG. 4 is a graph comparing the effect of different activation functions on the learning efficiency of a BP neural network according to an embodiment;
FIG. 5 is a graph comparing learning rate variability with a conventional learning rate training method under an embodiment;
fig. 6 is a schematic diagram of a product trademark authentication result based on a BP neural network according to an embodiment.
Detailed Description
The technical solution of the present invention is further described below with reference to the accompanying drawings and examples.
The invention relates to a product trademark identification method based on a BP neural network, which specifically comprises the following steps with reference to FIG. 2:
step 2, dividing the trademark picture processing data set in the step 1 into a training set, a verification set and a test set according to a certain proportion;
and 6, inputting the test set in the step 2 into the BP neural network prediction model for trademark authentication to obtain a trademark authentication result.
Referring to fig. 1, the basic structure of a neural network is composed of three parts: an input layer, a hidden layer, and an output layer. These layers all employ a fully-connected neural network, in which each neuron in each layer is connected to all neurons in the previous layer. Thus, the output of the preceding layer of neurons is the input to the next layer of neurons, and each connection has a weight value. The goal of each iteration is to update these weights so that the prediction results are closer to the simulated data. There is no connection between neurons in the same layer. In the learning process of the neural network, the learning loss is propagated backward, and can be measured by a mean square error or a linear error.
The neural network framework is constructed as a multi-dimensional input and a one-dimensional output. When the number and size of layers is increased, the volume of the network increases, which means that neurons can cooperate to express more complex functions. However, a larger network, while providing a stronger fitting ability, also provides a negative effect, i.e., overfitting. Over-fitting refers to the network's ability to fit noise in the data without fully considering the eigenrelationships between the data sets. The strategy employed is thus to use regularization techniques to control the over-learning while ensuring the fitting ability of large networks.
Referring to fig. 3, a fully-connected feedforward neural network dedicated to identifying and judging the trademark authenticity information is built, and the input is 128pxX128px gray data values extracted from picture information, and the output is single-value data containing the trademark authenticity information.
The original data adopted by the embodiment is 20 brands of genuine trademarks and 20 pirate trademarks corresponding to the genuine trademarks, the data format is JPG, and the resolution is 400X 400. Referring to fig. 4, we adopt 8 hidden layers, the number ratio of each layer of neurons is 2048, 1024, 512, 128, 64, 32, 16, 8, respectively, the activation function of each hidden layer is a tanh activation function, the activation function of the output layer is a softmax function, and a single value for judging authenticity of the unique hot code is output.
Currently, the most commonly used activation functions for neural networks are Sigmoid, hyperbolic tangent (tanh), and rectified linear element (ReLu). The effect of each activation function on the network learning efficiency in the first 100 iterations of 10000 times was studied. After approximately 10000 iterations, the training loss of each activation function is significantly reduced, while the loss value of tanh is the lowest. These results indicate that tanh is more suitable for the nonlinear data model, and was chosen as the activation function.
The optimization algorithm used in the training is gradient descent optimization. A in the gradient descent algorithm is called the learning rate and the step size. And controlling the speed of weight updating through alpha. Training method using variable learning rate: in each training, the learning rate was decreased from 0.001 with a step size of 0.0005. Referring to fig. 5, such a training pattern may help the network converge to the minimum of the objective function more quickly than conventional training methods.
In the device test, the Mean Square Error (MSE) is used for measuring the fitting capacity of the network, the MSE value lost in the training is reduced to 1e-8 after the training is finished, the fact that the relation between trademark image data and trademark true and false values can be accurately fitted by a BP neural network prediction model obtained through the training is proved, in order to verify the prediction capacity of the network, a group of test trademark data input networks are prepared, and referring to fig. 6, the network accurately judges the true and false information of the trademark.
Claims (8)
1. A product trademark identification method based on a BP neural network is characterized by comprising the following steps:
step 1, acquiring a trademark picture data set for identification, and converting each trademark picture in the data set into RGB three-channel matrix pixel values to obtain a trademark picture processing data set;
step 2, dividing the trademark picture processing data set in the step 1 into a training set, a verification set and a test set according to a certain proportion;
step 3, carrying a BP neural network operation software environment and constructing a BP neural network prediction model; the RGB three-channel matrix pixel value of the trademark picture is used as input, the single-value data containing the trademark authenticity information is used as output, and nonlinear mapping of the RGB three-channel matrix pixel of the trademark picture and the single value containing the trademark authenticity information is established;
step 4, taking the training set in the step 2 as the input and expected output of the BP neural network prediction model in the step 3, and performing iterative training on the BP neural network prediction model until a loss function value is smaller than a preset threshold value to obtain a trained BP neural network prediction model;
step 5, verifying the trained BP neural network prediction model by the verification set in the step 2, setting a minimum mean square error, and obtaining the BP neural network prediction model for trademark identification when the learning precision of the BP neural network prediction model meets the minimum mean square error;
and 6, inputting the test set in the step 2 into the BP neural network prediction model for trademark authentication to obtain a trademark authentication result.
2. The product trademark authentication method based on the BP neural network as claimed in claim 1, wherein the BP neural network prediction model in step 3 comprises 1 input layer, 8 hidden layers and 1 output layer, all the layers are connected, and each connection has a weighted value; the number ratio of each layer of neurons in the 8 hidden layers is 2048, 1024, 512, 128, 64, 32, 16 and 8 respectively; wherein, the activation function of the hidden layer is a tanh activation function, and the activation function of the output layer is a softmax function.
3. The product trademark authentication method based on the BP neural network as claimed in claim 1, wherein in the step 4, an iterative training method of variable learning rate is used, and a gradient descent optimization algorithm is used to update the weighted values between the layers of the BP neural network prediction model; during each training, the initial learning rate a is 0.001, and the step length b is 0.0005.
4. The method for product trademark authentication based on the BP neural network as claimed in claim 1, wherein in the step 4, the loss function is processed by using L2 regularization during iterative training, and the L2 regularization formula is as follows:
in the formula, L represents a loss function after L2 regularization; einIs the original loss function without the addition of the L2 regularization term; λ is a regularization parameter; j is the total number of elements in the L2 regularization weight vector w; w is ajRepresenting the jth element in the L2 regularized weight vector w.
5. The product trademark authentication method based on the BP neural network as claimed in claim 1, wherein the minimum mean square error in step 5 is 1e-8。
6. A product trademark authentication device based on a BP neural network is characterized by comprising:
the picture acquisition module is used for acquiring a trademark picture data set;
the image processing module is used for converting each trademark image in the collected trademark image data set into RGB three-channel matrix pixel values;
the model generation module is used for generating a BP neural network prediction model;
and the picture identification module is used for identifying the true and false information value of the trademark picture.
7. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor when executing the computer program implements the steps of a BP neural network based product trademark authentication method of any one of claims 1 to 5.
8. A computer-readable storage medium, having stored thereon a computer program which, when executed by a processor, implements the steps of a BP neural network-based product trademark authentication method according to any one of claims 1 to 5.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111462783.1A CN114186621A (en) | 2021-11-30 | 2021-11-30 | Product trademark identification method and device based on BP neural network |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111462783.1A CN114186621A (en) | 2021-11-30 | 2021-11-30 | Product trademark identification method and device based on BP neural network |
Publications (1)
Publication Number | Publication Date |
---|---|
CN114186621A true CN114186621A (en) | 2022-03-15 |
Family
ID=80603295
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202111462783.1A Withdrawn CN114186621A (en) | 2021-11-30 | 2021-11-30 | Product trademark identification method and device based on BP neural network |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN114186621A (en) |
-
2021
- 2021-11-30 CN CN202111462783.1A patent/CN114186621A/en not_active Withdrawn
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN112115973B (en) | Convolutional neural network based image identification method | |
Cui et al. | Identifying materials of photographic images and photorealistic computer generated graphics based on deep CNNs. | |
US10311326B2 (en) | Systems and methods for improved image textures | |
CN109359608B (en) | Face recognition method based on deep learning model | |
CN105138973B (en) | The method and apparatus of face authentication | |
CN109063724B (en) | Enhanced generation type countermeasure network and target sample identification method | |
Goodfellow et al. | Multi-prediction deep Boltzmann machines | |
CN113011499A (en) | Hyperspectral remote sensing image classification method based on double-attention machine system | |
CN113111979B (en) | Model training method, image detection method and detection device | |
CN111914728A (en) | Hyperspectral remote sensing image semi-supervised classification method and device and storage medium | |
CN114842267A (en) | Image classification method and system based on label noise domain self-adaption | |
CN111985554A (en) | Model training method, bracelet identification method and corresponding device | |
Luo et al. | Learning from the past: Continual meta-learning with Bayesian graph neural networks | |
US11695898B2 (en) | Video processing using a spectral decomposition layer | |
CN113095333A (en) | Unsupervised feature point detection method and unsupervised feature point detection device | |
CN116188941A (en) | Manifold regularized width learning method and system based on relaxation annotation | |
CN109934270B (en) | Classification method based on local manifold discriminant analysis projection network | |
CN110188621A (en) | A kind of three-dimensional face expression recognition methods based on SSF-IL-CNN | |
CN110717402B (en) | Pedestrian re-identification method based on hierarchical optimization metric learning | |
JP2019023801A (en) | Image recognition device, image recognition method and image recognition program | |
CN116935122A (en) | Image classification method and system based on 3D-WGMobileNet | |
CN114186621A (en) | Product trademark identification method and device based on BP neural network | |
CN115641575A (en) | Leafhopper agricultural pest detection method based on sparse candidate frame | |
US20230394304A1 (en) | Method and Apparatus for Neural Network Based on Energy-Based Latent Variable Models | |
Hu et al. | Learning to detect saliency with deep structure |
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 | ||
WW01 | Invention patent application withdrawn after publication |
Application publication date: 20220315 |
|
WW01 | Invention patent application withdrawn after publication |