Skip to content

Commit 954a413

Browse files
committed
add wait support
1 parent 1b8caf1 commit 954a413

File tree

3 files changed

+9
-1
lines changed

3 files changed

+9
-1
lines changed

get_models.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,10 +59,11 @@ then
5959
echo
6060

6161
echo 'Checking for Google Coral Edge TPU data files...'
62-
targets=( 'coco_indexed.names' 'ssd_mobilenet_v2_coco_quant_postprocess_edgetpu.tflite' 'ssdlite_mobiledet_coco_qat_postprocess_edgetpu.tflite')
62+
targets=( 'coco_indexed.names' 'ssd_mobilenet_v2_coco_quant_postprocess_edgetpu.tflite' 'ssdlite_mobiledet_coco_qat_postprocess_edgetpu.tflite' 'ssd_mobilenet_v2_face_quant_postprocess_edgetpu.tflite')
6363
sources=('https://dl.google.com/coral/canned_models/coco_labels.txt'
6464
'https://github.com/google-coral/edgetpu/raw/master/test_data/ssd_mobilenet_v2_coco_quant_postprocess_edgetpu.tflite'
6565
'https://github.com/google-coral/test_data/raw/master/ssdlite_mobiledet_coco_qat_postprocess_edgetpu.tflite'
66+
'https://github.com/google-coral/test_data/raw/master/ssd_mobilenet_v2_face_quant_postprocess_edgetpu.tflite'
6667
)
6768

6869

mlapi.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -219,6 +219,8 @@ def post(self):
219219
#bbox,label,conf = m.detect(image)
220220

221221
stream_options['mid'] = mid
222+
if not stream_options.get('delay') and g.config.get('wait'):
223+
stream_options['delay'] = g.config.get('wait')
222224
g.log.Debug (1, f'Calling detect streams')
223225
#print (f'************************ {args}')
224226
matched_data,all_matches = m.detect_stream(stream=stream, options=stream_options, ml_overrides=ml_overrides)

modules/common_params.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,11 @@
109109
'default': './db',
110110
'type': 'string',
111111
},
112+
'wait': {
113+
'section': 'general',
114+
'default':'0',
115+
'type': 'int'
116+
},
112117
'mlapi_secret_key':{
113118
'section': 'general',
114119
'default': None,

0 commit comments

Comments
 (0)