Module Configuration File
Each module is configured in a file of its own, <module name>.json. The name of the file without
.json, in lower case, is the module’s name on the Data Layer:
hdvisionsystems/lumiscan-calibration/<module name>. The application ships one example,
example.json: the module example.
The configuration defines how 2D image coordinates are converted into 3D coordinates on the calibrated plane, and optionally a stream of points to convert.
{
"$schema": "schemas/lumiscan-calibration-module.schema.json",
"meta": {
"inputFileType": "LumiScan-CtrlX-Calibration-Module",
"inputFileVersion": "1.0.0",
"targetMachine": "MachineName",
"programName": "LumiScan-Calibration",
"programVersion": "1.0.0"
},
"transform": {
"name": "PlanarProjectionExample",
"type": "from2dTo3d",
"subtype": "lookUpTable",
"relativePathToTiff": "example.tiff",
"interpolationMethod": "linear4Neighbors",
"offsetX": 0.0,
"offsetY": 0.0,
"scaleX": 1.0,
"scaleY": 1.0
},
"stream": {
"address": "hdvisionsystems/lumiscan-ai-object-matching/example/control/subscribe/output/stream",
"onEntry": [
{
"kind": "remap",
"node": "result",
"array": "instances",
"x": "oriented_bounding_box.center_x",
"y": "oriented_bounding_box.center_y"
}
],
"enable": true,
"keepLatestOutput": true,
"queueSize": 64
}
}
The parameters are described in Table 5. The file may contain comments
(// and /* */).
The example’s stream section reads the results of LumiScan AI Object Matching’s example module,
example, from the start: the node result of its stream folder, and in it the list instances.
It transforms the centre of each box found on the image stream, and also writes the points to the
regular output. The results of AI Object Matching are always read this way,
with a remap step in onEntry. For a module that reads another source, change the section or
remove it: without one, a module streams plain. See
Transforming a Stream.
| Parameter | Description |
|---|---|
|
Metadata of the file. |
|
The file type. For a module configuration file, the value must be
|
|
The version of the file format. Currently, only |
|
Optional. The name of the machine the configuration is intended for. |
|
Optional. The application that uses the file: |
|
Optional. The application version the configuration was made for. |
|
The coordinate transformation. |
|
The transformation’s name, as the log shows it. It does not change the module’s name on the Data Layer. |
|
The transformation type. Currently, only |
|
The transformation subtype. Currently, only |
|
The path of the TIFF file with the calibration data, relative to this file. See Tiff File. |
|
How a value between calibrated points is found: |
|
Offsets subtracted from the input coordinates before the table is looked up. The default is |
|
Factors the input coordinates are scaled by, after the offset, before the table is looked up.
The default is |
|
Optional, experimental. A stream of points to convert as they arrive: the source and stream mode,
and in |
|
After changing the file, reset the module ( If the file or its TIFF file cannot be loaded, the module is still served, but reports status |
Complete reference
Every setting of this file as its JSON Schema lumiscan-calibration-module.schema.json defines it, generated for version 2.0.0:
| Setting | Type | Default | Allowed values | Description |
|---|---|---|---|---|
|
object |
Required. |
||
|
string |
not empty |
Required. |
|
|
string |
not empty |
Required. |
|
|
string |
not empty |
Required. |
|
|
string |
not empty |
Required. |
|
|
string |
not empty |
Required. |
|
|
object |
Required. |
||
|
string |
pattern |
Required. only [a-Z], [0-9], '-' and '_' are allowed. Unique ID of the camera configuration. This is used to identify different camera on datalayer. |
|
|
string |
|
Required. |
|
|
string |
|
Required. |
|
|
string |
not empty |
Required. |
|
|
string |
|
Required. |
|
|
number |
Required. |
||
|
number |
Required. |
||
|
number |
Required. |
||
|
number |
Required. |