A kind of ticket-checked device and method based on recognition of face
Technical field
The invention belongs to the ticket checking fields of public transport, and in particular to a kind of ticket-checked device and side based on recognition of face
Method.
Background technique
With society be constantly progressive and an urgent demand of the various aspects for quickly and effectively auto authentication, face
Identification has obtained development at full speed in recent decades, and recognition of face is due to having directly, friendly, convenient feature, user
Without any mental handicape, it is easy to be received by user, so that extensive research and application have been obtained, to be paid with recognition of face
It substitutes mobile phone and various function cards carries out mobile payment, just become inexorable trend.
It is existing take bus, the subway means of payment mainly has cash, card, mobile phone two-dimension code etc., the payment of card-like
Mode is all NFC technique, although efficient and convenient, supplementing with money, aspect is comparatively laborious, can only arrive fixed recharge point and supplement with money,
And mobile phone two-dimension code is troublesome in poeration, time-consuming, poor user experience, also user information it is easily stolen take, these experience all can
It causes much to perplex to user.
At present face recognition technology product be although widely used in finance, the administration of justice, army, public security, frontier inspection, government, space flight,
The fields such as electric power, factory, education, medical treatment and numerous enterprises and institutions, but for public transport or field of track traffic,
Existing face recognition technology and identification process are not still able to satisfy the requirement of peak period crowd-flow rate and rapid payment experience.
Summary of the invention
The present invention provides a kind of ticket-checked device and method based on recognition of face, and to solve in ticketing process, passenger makes
Long with ticket card or mobile phone brush gate ticket checking short time consumption, the interaction safety of cumbersome and conventional face's identification information is low, uses
Experience poor problem in family.
To achieve the above object, the present invention provides a kind of ticket-checked device based on recognition of face, including camera module, deposits
Module, communication module, serial port module, infrared sensor module, central processing unit are stored up, the camera module contains for acquiring
There are the image or video flowing of face, and the detection and tracking face in image or video flowing automatically, and then to the face detected
It is identified;The memory module is used for store transaction information and human face image information;The communication module is used to take with rear end
Business device exchanges data, and the serial port module controls the closure of gate door for connecting gate controller;The infrared sensor
The camera module automatic collection facial image or video flowing are triggered when judging human body close to gate for incuding;The center
Processing unit is used to carry out operation to facial image or video flowing to be identified and given out effective result.
Preferably, the camera module is binocular In vivo detection wide-angle high-definition camera.
Preferably, the central processing unit of the ticket-checked device and face database carry out Face datection, image preprocessing,
Feature extraction, match cognization confirm user identity later, and generate an identification code for confirming identity at random.
Preferably, it includes customer consumption that the central processing unit of the ticket-checked device is obtained by network rear end server
The data packet of voucher, for judging in the data packet obtained containing the identification code, while when confirming the legal identity of transaction, so
After parse the customer consumption voucher, further verify the legitimacy of the user and the information of remaining sum.
The present invention also provides a kind of ticket checking methods based on recognition of face, include the following steps:
S1: user logs in mobile intelligent terminal APP client, register account number and facial image of taking pictures in the APP client
Back-end server is uploaded to, the back-end server saves the facial image and establishes face database;
S2: when user is close to ticket-checked device, infrared sensor module triggers camera module automatic collection facial image or video
Stream;
S3: the central processing unit of ticket-checked device and face database carry out Face datection, image preprocessing, feature extraction,
With identification, user identity is confirmed later, and generates an identification code for confirming identity at random;
S4: ticket-checked device obtains the data packet comprising customer consumption voucher by network rear end server, when central processing list
When containing the identification code in the data packet that member judgement obtains, and confirm the legal identity of this transaction, then ticket-checked device parses
The customer consumption voucher further verifies the legitimacy of the user and the information of remaining sum;
S5: if the verification passes, then gate controller is sent a signal to by serial port module, gate checks and clearance of opening the door;
S6: after the completion of ticket checking, Transaction Information is uploaded to back-end server by network by ticket-checked device, is carried out by back-end server
Sorting and clearing;
S7: back-end server sends mobile intelligent terminal APP client, the APP client by network for transaction results
It shows information corresponding to transaction results code, the information of " Sorry, your ticket has not enough value " is shown as if transaction results code " 1 ".
Preferably, the transaction results of the S7 China be pay successfully, Sorry, your ticket has not enough value, pay fail one of.
Compared with prior art, the invention has the benefit that
Using the technical identification mode of recognition of face In vivo detection, solve traditional face recognition technology be easy by photo and
Video attack, so as to cause biggish erroneous judgement possibility, in order to ensure transaction security, while not being needed using face recognition technology
Mobile phone, subway ticket, bank card are carried, face is exactly subway ticket, greatly improves ticket checking payment speed, improves user's body
It tests.
To enable the above objects, features and advantages of the present invention to be clearer and more comprehensible, preferred embodiment is cited below particularly, and cooperate
Appended attached drawing, is described in detail below.
Detailed description of the invention
The attached drawing constituted part of this application is used to provide further understanding of the present invention, schematic reality of the invention
It applies example and its explanation is used to explain the present invention, do not constitute improper limitations of the present invention.In the accompanying drawings:
Fig. 1 is ticket-checked device structural schematic diagram of one of the embodiment based on recognition of face;
Fig. 2 is the flow chart of steps that enters the station of underground ticket checking method of one of the embodiment based on recognition of face;
Fig. 3 is the outbound flow chart of steps of underground ticket checking method of one of the embodiment based on recognition of face.
Specific embodiment
Following will be combined with the drawings in the embodiments of the present invention, and technical solution in the embodiment of the present invention carries out clear, complete
Site preparation description, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.It is based on
Embodiment in the present invention, it is obtained by those of ordinary skill in the art without making creative efforts every other
Embodiment shall fall within the protection scope of the present invention.
The present embodiment provides a kind of ticket-checked device (as shown in Figure 1) based on recognition of face, including camera module, storage
Module, communication module, serial port module, infrared sensor module, central processing unit, the camera module contain for acquiring
The image or video flowing of face, and the detection and tracking face in image or video flowing automatically, so to the face detected into
Row identification;The memory module is used for store transaction information and human face image information;The communication module is used for and back-end services
Device exchanges data, and the serial port module controls the closure of gate door for connecting gate controller;The infrared sensor is used
The camera module automatic collection facial image or video flowing are triggered when induction judges human body close to gate;The centre
Reason unit is used to carry out operation to facial image or video flowing to be identified and given out effective result.
The camera module is binocular In vivo detection wide-angle high-definition camera.
The central processing unit of the ticket-checked device carries out Face datection, image preprocessing, feature with face database and mentions
It takes, match cognization, confirms user identity later, and generate an identification code for confirming identity at random.
The central processing unit of the ticket-checked device is obtained by network rear end server comprising customer consumption voucher
Then data packet is parsed for judging in the data packet obtained containing the identification code, while when confirming the legal identity of transaction
The customer consumption voucher further verifies the legitimacy of the user and the information of remaining sum.
The present embodiment also provides a kind of ticket checking method based on recognition of face, it is necessary first to explanation, as new user
When primary experience, before entering the station, user downloads with mobile intelligent terminal and registers certain APP client, in the APP client account
Open payment method in family, the payment method include it is pre- supplement with money, post-paid, the mode for exempting from close payment.
The present embodiment is suitable for the application scenarios such as underground ticket checking, bus ticket checking, high-speed rail ticket checking, airport ticket checking.
In order to which the techniqueflow of the present embodiment is explained further, below by taking underground ticket checking application scenarios as an example, when user into
When standing, a kind of underground ticket checking method and step (as shown in Figure 2) based on recognition of face is as follows:
S11: user's login account in mobile intelligent terminal APP client, and facial image of taking pictures, the facial image is at once
Back-end server is uploaded to, back-end server saves the facial image and establishes face database;
S12: when user enters the station ticket-checked device close to subway, infrared sensor module triggers camera module automatic collection face figure
Picture or video flowing;
S13: subway enter the station ticket-checked device central processing unit and face database carry out Face datection, image preprocessing, spy
Sign extraction, match cognization, confirm user identity, and generate an identification code for confirming identity at random later;
S14: subway enters the station ticket-checked device by data packet of the server acquisition in network rear end comprising customer consumption voucher, in the middle
When containing the identification code in the data packet that Central Processing Unit judgement obtains, and confirming the legal identity of this transaction, then subway
The ticket-checked device that enters the station parses the customer consumption voucher, further verifies the legality message of the user;
S15: if the verification passes, then gate controller is sent a signal to by serial port module, gate checks and clearance of opening the door.
When user is outbound, step (as shown in Figure 3) is as follows:
S21: when outbound close to the subway ticket-checked device of user, infrared sensor module triggers camera module automatic collection face figure
Picture or video flowing;
S22: the central processing unit and face database of the outbound ticket-checked device of subway carry out Face datection, image preprocessing, spy
Sign extraction, match cognization, confirm user identity, and generate an identification code for confirming identity at random later;
S23: the outbound ticket-checked device of subway is obtained by network rear end server comprising customer consumption voucher and the information that enters the station
Data packet, when central processing unit judgement obtain data packet in contain the identification code, and confirm this transaction legal body
When part, then the outbound ticket-checked device of subway parses the customer consumption voucher and the information that enters the station, and further verifies the legal of the user
Property and/or balance information;
S24: if the verification passes, then gate controller is sent a signal to by serial port module, gate checks and clearance of opening the door;
S25: after the completion of ticket checking, Transaction Information is uploaded to back-end server by network by the outbound ticket-checked device of subway, by rear end
Server carries out sorting and clearing;
S26: back-end server sends mobile intelligent terminal APP client, the APP client by network for transaction results
It shows information corresponding to transaction results code, the information of " paying successfully " is shown as if transaction results code " 1 ".
The transaction results of the S26 China be pay successfully, Sorry, your ticket has not enough value, pay fail one of.
Therefore, underground ticket checking work using recognition of face In vivo detection technology replace existing brush subway ticket, swipe the card or
Brush mobile phone etc. checks mode, convenient and efficient, improves ticket checking payment speed, improves user experience;The present invention can also solve biography
The face recognition technology of system is easy to be attacked by photos and videos, so as to cause the problem of brushing is missed, it is ensured that transaction security.
The above content it cannot be assumed that the present invention specific implementation be only limited to these instructions, technology belonging to the present invention is led
For the those of ordinary skill in domain, under the premise of not departing from present inventive concept, a number of simple deductions or replacements can also be made, all
It shall be regarded as belonging to present invention scope of patent protection determined by the appended claims.