Download the PHP package xsolve-pl/face-validator-bundle without Composer

On this page you can find all versions of the php package xsolve-pl/face-validator-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package face-validator-bundle


XSolve Face Validator Bundle

Build Status Scrutinizer Code Quality

============================

Table of contents

Introduction

This Symfony3 bundle allows to validate whether an image (for instance uploaded by a user of your app) contains person's face. Internally it uses MS Azure Face API so in order to use it you need an account in MS Azure. In free plan the API allows to make 30 000 requests per month and 20 per minute so it should be enough to be useful for low traffic apps.

All the following features are configurable on the constraint level and can be easily enabled/disabled:

Licence

This library is under the MIT license. See the complete license in LICENSE file.

Getting started

Add the bundle to your Symfony3 project using Composer:

You'll need also to register the bundle in your kernel:

In the configuration file you must provide your MS Azure subscription key for Face API and the region name (can be taken from the Endpoint section in MS Azure portal). Available regions can be previewed by running:

Example configuration:

Usage

Check this documentation if you'd like to know how to allow users to upload files using Symfony forms and validation. Assuming in your application you already have some model representing a user (for instance Doctrine entity) and it's used in a form to gather the data from users and perform validation, it already contains a profile picture:

or with YML:

For other validation config formats please check dedicated documentation section

Now when executing regular validation, for instance in your controller:

the image will be validated whether it contains a face. The way the face is being validated is customizable, all the possible options with their default values are shown on the example below:

Note that you can omit any (or even all) of the options listed above, then the defaults will be used.

For blur and noise levels the possible options are:

It's also possible, just like with any other Symfony validator, to use it directly against given value (either file path or an instance of \SplFileInfo).


All versions of face-validator-bundle with dependencies

PHP Build Version
Package Version
Requires php Version >=7.0.0
guzzlehttp/guzzle Version ~6.3
myclabs/php-enum Version ~1.5
symfony/http-kernel Version 3.3.*
symfony/config Version 3.3.*
symfony/dependency-injection Version 3.3.*
symfony/validator Version 3.3.*
symfony/property-access Version 3.3.*
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package xsolve-pl/face-validator-bundle contains the following files

Loading the files please wait ....