Skip to content

Commit 3f58fa2

Browse files
Merge pull request #212264 from srasool/main
Remove threshold from SA operation config
2 parents 26c6f6c + 4f87d09 commit 3f58fa2

File tree

1 file changed

+5
-15
lines changed

1 file changed

+5
-15
lines changed

articles/cognitive-services/Computer-vision/spatial-analysis-operations.md

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,6 @@ The following is an example of a JSON input for the SPACEANALYTICS_CONFIG parame
238238
"type": "count",
239239
"config": {
240240
"trigger": "event",
241-
"threshold": 13.00,
242241
"focus": "footprint"
243242
}
244243
}
@@ -253,7 +252,7 @@ The following is an example of a JSON input for the SPACEANALYTICS_CONFIG parame
253252
| `zones` | list| List of zones. |
254253
| `name` | string| Friendly name for this zone.|
255254
| `polygon` | list| Each value pair represents the x,y for vertices of a polygon. The polygon represents the areas in which people are tracked or counted. Polygon points are based on normalized coordinates (0-1), where the top left corner is (0.0, 0.0) and the bottom right corner is (1.0, 1.0).
256-
| `threshold` | float| Events are egressed when the person is greater than this number of pixels inside the zone. |
255+
| `threshold` | float| Events are egressed when the person is greater than this number of pixels inside the zone. This is an optional field and value is in ratio (0-1). For example, value 0.0253 will be 13 pixels on a video with image width = 512 (0.0253 X 512 = ~13).|
257256
| `type` | string| For **cognitiveservices.vision.spatialanalysis-personcount**, this should be `count`.|
258257
| `trigger` | string| The type of trigger for sending an event. Supported values are `event` for sending events when the count changes or `interval` for sending events periodically, irrespective of whether the count has changed or not.
259258
| `output_frequency` | int | The rate at which events are egressed. When `output_frequency` = X, every X event is egressed, ex. `output_frequency` = 2 means every other event is output. The `output_frequency` is applicable to both `event` and `interval`. |
@@ -283,7 +282,6 @@ The following is an example of a JSON input for the `SPACEANALYTICS_CONFIG` para
283282
"type": "linecrossing",
284283
"config": {
285284
"trigger": "event",
286-
"threshold": 13.00,
287285
"focus": "footprint"
288286
}
289287
}
@@ -300,7 +298,7 @@ The following is an example of a JSON input for the `SPACEANALYTICS_CONFIG` para
300298
| `line` | list| The definition of the line. This is a directional line allowing you to understand "entry" vs. "exit".|
301299
| `start` | value pair| x, y coordinates for line's starting point. The float values represent the position of the vertex relative to the top left corner. To calculate the absolute x, y values, you multiply these values with the frame size. |
302300
| `end` | value pair| x, y coordinates for line's ending point. The float values represent the position of the vertex relative to the top left corner. To calculate the absolute x, y values, you multiply these values with the frame size. |
303-
| `threshold` | float| Events are egressed when the person is greater than this number of pixels inside the zone. The default value is 13. This is the recommended value to achieve maximum accuracy. |
301+
| `threshold` | float| Events are egressed when the person is greater than this number of pixels inside the zone. This is an optional field and value is in ratio (0-1). For example, value 0.0253 will be 13 pixels on a video with image width = 512 (0.0253 X 512 = ~13).|
304302
| `type` | string| For **cognitiveservices.vision.spatialanalysis-personcrossingline**, this should be `linecrossing`.|
305303
|`trigger`|string|The type of trigger for sending an event.<br>Supported Values: "event": fire when someone crosses the line.|
306304
| `focus` | string| The point location within person's bounding box used to calculate events. Focus's value can be `footprint` (the footprint of person), `bottom_center` (the bottom center of person's bounding box), `center` (the center of person's bounding box). The default value is footprint.|
@@ -319,7 +317,6 @@ This is an example of a JSON input for the `SPACEANALYTICS_CONFIG` parameter tha
319317
"type": "zonecrossing",
320318
"config":{
321319
"trigger": "event",
322-
"threshold": 38.00,
323320
"focus": "footprint"
324321
}
325322
}]
@@ -331,7 +328,6 @@ This is an example of a JSON input for the `SPACEANALYTICS_CONFIG` parameter tha
331328
"type": "zonedwelltime",
332329
"config":{
333330
"trigger": "event",
334-
"threshold": 13.00,
335331
"focus": "footprint"
336332
}
337333
}]
@@ -345,7 +341,7 @@ This is an example of a JSON input for the `SPACEANALYTICS_CONFIG` parameter tha
345341
| `name` | string| Friendly name for this zone.|
346342
| `polygon` | list| Each value pair represents the x,y for vertices of polygon. The polygon represents the areas in which people are tracked or counted. The float values represent the position of the vertex relative to the top left corner. To calculate the absolute x, y values, you multiply these values with the frame size.
347343
| `target_side` | int| Specifies a side of the zone defined by `polygon` to measure how long people face that side while in the zone. 'dwellTimeForTargetSide' will output that estimated time. Each side is a numbered edge between the two vertices of the polygon that represents your zone. For example, the edge between the first two vertices of the polygon represents the first side, 'side'=1. The value of `target_side` is between `[0,N-1]` where `N` is the number of sides of the `polygon`. This is an optional field. |
348-
| `threshold` | float| Events are egressed when the person is greater than this number of pixels inside the zone. The default value is 38 when the type is `zonecrossing` and 13 when time is `DwellTime`. These are the recommended values to achieve maximum accuracy. |
344+
| `threshold` | float| Events are egressed when the person is greater than this number of pixels inside the zone. This is an optional field and value is in ratio (0-1). For example, value 0.074 will be 38 pixels on a video with image width = 512 (0.074 X 512 = ~38).|
349345
| `type` | string| For **cognitiveservices.vision.spatialanalysis-personcrossingpolygon** this should be `zonecrossing` or `zonedwelltime`.|
350346
| `trigger`|string|The type of trigger for sending an event<br>Supported Values: "event": fire when someone enters or exits the zone.|
351347
| `focus` | string| The point location within person's bounding box used to calculate events. Focus's value can be `footprint` (the footprint of person), `bottom_center` (the bottom center of person's bounding box), `center` (the center of person's bounding box). The default value is footprint.|
@@ -366,8 +362,7 @@ This is an example of a JSON input for the `SPACEANALYTICS_CONFIG` parameter tha
366362
"output_frequency":1,
367363
"minimum_distance_threshold":6.0,
368364
"maximum_distance_threshold":35.0,
369-
"aggregation_method": "average"
370-
"threshold": 13.00,
365+
"aggregation_method": "average",
371366
"focus": "footprint"
372367
}
373368
}]
@@ -380,7 +375,7 @@ This is an example of a JSON input for the `SPACEANALYTICS_CONFIG` parameter tha
380375
| `zones` | list| List of zones. |
381376
| `name` | string| Friendly name for this zone.|
382377
| `polygon` | list| Each value pair represents the x,y for vertices of polygon. The polygon represents the areas in which people are counted and the distance between people is measured. The float values represent the position of the vertex relative to the top left corner. To calculate the absolute x, y values, you multiply these values with the frame size.
383-
| `threshold` | float| Events are egressed when the person is greater than this number of pixels inside the zone. |
378+
| `threshold` | float| Events are egressed when the person is greater than this number of pixels inside the zone. This is an optional field and value is in ratio (0-1). For example, value 0.0253 will be 13 pixels on a video with image width = 512 (0.0253 X 512 = ~13).|
384379
| `type` | string| For **cognitiveservices.vision.spatialanalysis-persondistance**, this should be `persondistance`.|
385380
| `trigger` | string| The type of trigger for sending an event. Supported values are `event` for sending events when the count changes or `interval` for sending events periodically, irrespective of whether the count has changed or not.
386381
| `output_frequency` | int | The rate at which events are egressed. When `output_frequency` = X, every X event is egressed, ex. `output_frequency` = 2 means every other event is output. The `output_frequency` is applicable to both `event` and `interval`.|
@@ -412,7 +407,6 @@ The following is an example of a JSON input for the `SPACEANALYTICS_CONFIG` para
412407
"type": "linecrossing",
413408
"config": {
414409
"trigger": "event",
415-
"threshold": 13.00,
416410
"focus": "footprint"
417411
}
418412
}
@@ -431,7 +425,6 @@ The following is an example of a JSON input for the `SPACEANALYTICS_CONFIG` para
431425
"output_frequency": 1,
432426
"minimum_distance_threshold": 6.0,
433427
"maximum_distance_threshold": 35.0,
434-
"threshold": 13.00,
435428
"focus": "footprint"
436429
}
437430
},
@@ -440,21 +433,18 @@ The following is an example of a JSON input for the `SPACEANALYTICS_CONFIG` para
440433
"config": {
441434
"trigger": "event",
442435
"output_frequency": 1,
443-
"threshold": 13.00,
444436
"focus": "footprint"
445437
}
446438
},
447439
{
448440
"type": "zonecrossing",
449441
"config": {
450-
"threshold": 38.00,
451442
"focus": "footprint"
452443
}
453444
},
454445
{
455446
"type": "zonedwelltime",
456447
"config": {
457-
"threshold": 13.00,
458448
"focus": "footprint"
459449
}
460450
}

0 commit comments

Comments
 (0)