Skip to content

FaceStream v.5.1.20#

Changes

  • Now, along with sending the source frame to LUNA PLATFORM, a header X-Luna-Meta-rescale is sent containing the scaling factor of the source image in the form of a floating-point number.

    Previously, when setting the width of the source frame for scaling (the size_source_frame parameter), it was impossible to determine the coordinates of the bbox on the source image, since only the coordinates of the bbox of the scaled image were sent to the LUNA PLATFORM.

    To determine the real coordinates of the bbox on the scaled source image, it is necessary to divide the size of the obtained image by the obtained scaling factor.

    Note. The real size is calculated with an absolute error of less than 1 / (2 * scaling factor).

    For example, if the obtained image has a size of 200x113, and the scaling factor is 0.104399, then the real size of the source image is 1916x1082 (200/0.104399=1916, 113/0.104399=1082).

    The scaling factor can be found in LUNA PLATFORM:

    • in the response header to the "get image" request to the LUNA API service. The request must be made with the with_meta = 1 query parameter;
    • in the "image_id.meta.json" file located next to the source image in the LUNA Image Store bucket of source images.

    The X-Luna-Meta-rescale header is only sent if sending the source frame is enabled (parameter send_source_frame = 1). The LUNA PLATFORM handler should also have a policy of saving the source image.

    If scaling is not set for the source frame (parameter size_source_frame = 0), then the value of the X-Luna-Meta-rescale response header will be equal to 1.

  • Section <LUNA_STREAMS_HTTP_SETTINGS was added to the LUNA Streams configurations, containing settings responsible for processing HTTP connections.

    The following settings are available:

    • request_timeout - the duration of time between the instant when a new open TCP connection is passed to the server, and the instant when the whole HTTP request is received. Value (in seconds) is integer number, default 60.
    • response_timeout - the duration of time between the instant the server passes the HTTP request to the app, and the instant a HTTP response is sent to the client. Value (in seconds) is integer number, default 600.
    • request_max_size - how big a request may be (bytes). Value (in bytes) is integer number, default 1gb.
    • keep_alive_timeout - http keep alive timeout. Value (in seconds) is integer number, default 15.

    See the following link for details: https://sanic.dev/en/guide/deployment/configuration.html#builtin-values

  • New FORMAT setting was added to all LIM services, which enables you to specify the logging format - default (standard log output format) and json (json log output).

Fixed errors

  • The error was fixed where enabling the send_source_frame parameter could lead to a decrease in FaceStream performance.

  • The error was fixed in the Docker Compose script, due to which the uploading of LUNA Streams settings was performed through the script load_dump.py (the old method used in versions 5.1.12 and below), and not through the migration mechanism (the new method used in versions 5.1.13 and above).

    Note. If the previous version of FaceStream was launched via Docker Compose, then when updating, you must additionally execute the command to upload settings via the migration mechanism for the previous version of LUNA Streams v.0.5.17, and then execute the same command to upload settings for the new version of LUNA Streams v.0.6.2. See the section "Migrate settings" FaceStream update manual.