Context

Context is an application variable that passes through each active module during image processing.

In Code module, it is possible to develop custom solutions for your project using Python and context data.

The user can add or modify custom attributes

Do not to change their structure when modifying.

Context Data in PEKAT VISION Projects

A series of context data examples displayed in PEKAT VISION projects (JSON Format), is available at our Inspection module article, as shown on example below:

Context Data Glossary

Image [Numpy Array]

Image in numpy array.

DetectedRectangles [Array]

A field containing the detected objects.

The last detected objects have the attribute ‘detectedAsLast=True’

Exit [Boolean]

Early termination, for details read the article Code.

It is not returned in response to an HTTP request, nor does it appear in the inspection.

Heatmaps [Array of Numpy Array]

A field containing numpy arrays that represent heatmaps.

Items

Internal argument.

Appears during processing, but does not respond to the HTTP request, nor does it appear in the inspection.

Production_Mode [Boolean]

If an image received through the HTTP API is processed, the parameter becomes True, otherwise False.