Documentation for C-Werk 2.0.

Previous page Types of requests and their parameters  Define 'familiar face'-'stranger' attribute from image Next page

This search type compares every recognized face with all faces in the camera database over 30 days (or for the current archive depth if it is less than 30 days) and sets the number of days over which this face was recognized by the camera. The search decides if this is a “familiar face” or a “stranger” by the specified criteria.

The POST request is used for search start (see Search request), search type is stranger, request body is empty.

The following parameters are available:

ParameterRequiredDescription
accuracyNo

Sets face similarity level in the range [0,1] (1 means complete match). If this parameter is not set, then the default value (0.9) is in use. If the compared face was in the camera field of view on a specific day and it was recognized with accuracy that is not less than specified one, then this face is considered to be present on that day. Otherwise, the algorithm considers this face was absent on that day. 

Important!

The accuracy parameter value can also be specified in the request body. In this case, it has higher priority over the value specified in the search line.

thresholdNo

Defines the threshold value to recognize a face as a “stranger”. The value is set in the range from 0 to 1 and it defines the number of days within which the face was absent to be considered as a “stranger”: 30-30*threshold. For instance, the value 0.8 means “the required object appeared in the search area within (30 - 30 * 0.8 = 6) days”. All faces that appeared within 6 and more days will be defined as “familiar faces”, others – as “strangers”.

Important!

The threshold and op parameters should only be used together. If any of parameters is not set or has incorrect value, then both parameters will be ignored.

opNoDefines search direction.
Allowable values:
lt – “familiar face” search (based on threshold parameter).
gt – “stranger” search.

Sample request:

POST http://127.0.0.1:80/search/stranger/SERVER1/AVDetector.2/EventSupplier/past/future?accuracy=0.7

GET http://127.0.0.1:80/search/stranger/2e69ba76-23f1-4d07-a812-fee86e994b8e/result

Sample response:

{
   "events" : [
      {
         "rate" : 0.90591877698898315,
         "origin" : "hosts/SERVER1/DeviceIpint.2/SourceEndpoint.video:0:0",
         "position" : {
            "bottom" : 0.10694444444444445,
            "left" : 0.69687500000000002,
            "right" : 0.74687500000000007,
            "top" : 0.018055555555555554
         },
         "timestamp" : "20160914T085307.499000"
      },
      {
         "rate" : 0.90591877698898315,
         "origin" : "hosts/SERVER1/DeviceIpint.2/SourceEndpoint.video:0:0",
         "position" : {
            "bottom" : 0.10694444444444445,
            "left" : 0.69687500000000002,
            "right" : 0.74687500000000007,
            "top" : 0.018055555555555554
         },
         "timestamp" : "20160914T085830.392000"
      }
}
ParameterDescription
originCamera channel to take analyzed video stream from.
timestampTime stamp of a frame with a face detected by the detection tool.
rateRate of identifying a face as a “stranger”, the value in the [0,1] range. 1 means a complete stranger.
positionCoordinates of a frame border enclosing face on a video frame.
  • No labels