haixuantao
commited on
Commit
•
c782e33
1
Parent(s):
6ca4d16
Adding data
Browse files- graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/audio.parquet +3 -0
- graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/bbox.parquet +3 -0
- graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/chatgpt_output_file.parquet +3 -0
- graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/gimbal_control.parquet +3 -0
- graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/image.parquet +3 -0
- graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/mistral_output_file.parquet +3 -0
- graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/position.parquet +3 -0
- graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/raw_file.parquet +3 -0
- graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/saved_file.parquet +3 -0
- graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/whisper_text.parquet +3 -0
- graphs/out/018e2f49-eec4-7d73-b102-cadc02f89a81/bbox.parquet +3 -0
- graphs/out/018e2f49-eec4-7d73-b102-cadc02f89a81/gimbal_control.parquet +3 -0
- graphs/out/018e2f49-eec4-7d73-b102-cadc02f89a81/image.parquet +3 -0
- graphs/out/018e2f49-eec4-7d73-b102-cadc02f89a81/position.parquet +3 -0
- graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/audio.parquet +3 -0
- graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/bbox.parquet +3 -0
- graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/chatgpt_output_file.parquet +3 -0
- graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/control.parquet +3 -0
- graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/gimbal_control.parquet +3 -0
- graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/image.parquet +3 -0
- graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/mistral_output_file.parquet +3 -0
- graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/position.parquet +3 -0
- graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/raw_file.parquet +3 -0
- graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/saved_file.parquet +3 -0
- graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/whisper_text.parquet +3 -0
- graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/audio.parquet +3 -0
- graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/bbox.parquet +3 -0
- graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/chatgpt_output_file.parquet +3 -0
- graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/control.parquet +3 -0
- graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/gimbal_control.parquet +3 -0
- graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/image.parquet +3 -0
- graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/mistral_output_file.parquet +3 -0
- graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/position.parquet +3 -0
- graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/raw_file.parquet +3 -0
- graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/saved_file.parquet +3 -0
- graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/whisper_text.parquet +3 -0
- operators/microphone_op.py +1 -4
- operators/object_detection.py +5 -15
- operators/plot.py +2 -15
- operators/sentence_transformers_op.py +7 -5
- operators/webcam.py +1 -1
- operators/whisper_op.py +1 -1
graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/audio.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:343f636ae37d12138b9f4a8fe841008eb036f5020ad8c41b7cfb179d866fcd05
|
3 |
+
size 419302
|
graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/bbox.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:d95ce6915fe5e80332fc45cf425333c136cc3d6c032e5864e9522acfc53b3b38
|
3 |
+
size 586984
|
graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/chatgpt_output_file.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:d81f1834ba633befce7c67684cdf861e215ed170502a92f358b7501d011b2433
|
3 |
+
size 68570
|
graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/gimbal_control.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:043324568b13fee9bd2497acaefc96ab66af9bd936bf7a8dd7e802ffdbdeec1f
|
3 |
+
size 122476
|
graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/image.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:e2a4609e7c63624e7536f0788bcdb90f8df2dee6c5a3f5cd08ce54176e3528bb
|
3 |
+
size 918130307
|
graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/mistral_output_file.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:bd5d9f4ff8ebac0965e13d9c55be27fb75f7f98e425590c166e363fdebf726d6
|
3 |
+
size 34158
|
graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/position.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:5cdc461cccbe1d4c4ce4fc5a57cb230b6a40c0bbbb0786355326497aa65adbcc
|
3 |
+
size 123029
|
graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/raw_file.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:76def9993da2c6a28118e6ab68e2e954b617adc1347465f6557c80fd64ef10ef
|
3 |
+
size 24422
|
graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/saved_file.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:b389f66986dcfa403f1600188e90af66467852e3e8c09588ff8badc599b0f5a5
|
3 |
+
size 25322
|
graphs/out/018e2f40-fe62-793d-85fe-c5e735b62c86/whisper_text.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:a3905eb202722699f60b7a53b9305810a424de0473f8587b375440191fcb463a
|
3 |
+
size 2955
|
graphs/out/018e2f49-eec4-7d73-b102-cadc02f89a81/bbox.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:0c2c72ccfff5dc3182e8e8b7f13991b9108e3658827ead06665d9542bd7b3abd
|
3 |
+
size 59397
|
graphs/out/018e2f49-eec4-7d73-b102-cadc02f89a81/gimbal_control.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:65ba8df2a669ad146c28e9996668c18fe4e38c6cffb0e3e1a2108f4bb2efd592
|
3 |
+
size 15927
|
graphs/out/018e2f49-eec4-7d73-b102-cadc02f89a81/image.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:847a4f5e116ca5880a9b0cf4dedcf1a763533de6e75a6a0354279c315a43e0b2
|
3 |
+
size 98500348
|
graphs/out/018e2f49-eec4-7d73-b102-cadc02f89a81/position.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:480b2dada4ebfd77e703a6c202decca6e7fa267787e1c257162c400f453cf42a
|
3 |
+
size 15918
|
graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/audio.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:0f3450dbcf9eec46a6a09dd2e29c99867920ba1a76901b16281141353fa320df
|
3 |
+
size 252331
|
graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/bbox.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:580f0cf793219fe70965a9261200c2b4ca8eb723ec7df13f0d1f4005c9f5ea6c
|
3 |
+
size 108430
|
graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/chatgpt_output_file.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:fc4b69c0046cc091e2bed9e5f4f504cb608a973ce0128405f9b26c00a4755ac9
|
3 |
+
size 48786
|
graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/control.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:8f9b5f0199c7fa948fdbcc2e9f5ce6bfe95298602a48ce97187320085850287f
|
3 |
+
size 2024
|
graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/gimbal_control.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:be8f977c25bcb8fc6672f6f545c493f4bb68ea9d407cdd29ec97f12bfa35e9de
|
3 |
+
size 10786
|
graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/image.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:f6a0626f43b149349c82dd559396c4fa0470ca05c1654350e04b771070a8cb63
|
3 |
+
size 321715570
|
graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/mistral_output_file.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:ca0f533831616b42ad282ca1c271a91a70797f8dcdd8c89b4fecbb76647e0bfe
|
3 |
+
size 21943
|
graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/position.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:0d402600eb622d531bc747a52644f118a8ce522f1a93183fc372238b011fbae5
|
3 |
+
size 6421
|
graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/raw_file.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:117463b0c79f273aa87d45186068253c797b37fc7e215d85139aed7eb10d1317
|
3 |
+
size 18216
|
graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/saved_file.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:2d927ed1a3ee1abcb0b89e76866b7bc590bdd952bbfaffbeaccb378028af300a
|
3 |
+
size 18039
|
graphs/out/018e2f4f-9547-7b78-ad2c-9fa27b161193/whisper_text.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:b96cea61267b7693c865bbf83a9eef4b714eed7fe80e8caefe4024e56a2da03b
|
3 |
+
size 2335
|
graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/audio.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:c6b265aaeaffd58052d54b03d439f7c46bb4476d95419392f0e61f8641de5870
|
3 |
+
size 385448
|
graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/bbox.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:7d624358a013f0b9a3e70a76aa6f4849e1cb28fa97357aad93e772f78d0f1232
|
3 |
+
size 197484
|
graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/chatgpt_output_file.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:50da45568990e85a415e5766dc1165b6fb4ff36ffdd84ac39f6678f7427a8646
|
3 |
+
size 41457
|
graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/control.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:c82321d828f12d5b4a87a7648afc793218499cd7a9e0597b1fdf6906e73ab798
|
3 |
+
size 2195
|
graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/gimbal_control.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:cb350934d392259bd1c802f718f5f4bb4be0190b6d89f5c8854acbdb1e2d2608
|
3 |
+
size 37055
|
graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/image.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:1fd28170e2ebc28a4a2ef88ceb289a6be433c76c558f6868548c2a062c37ec74
|
3 |
+
size 1107366206
|
graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/mistral_output_file.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:31d09706296cd98a31e3a9ba203c780f97d00d9ac60c5fa7312e8383b114f6f0
|
3 |
+
size 19540
|
graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/position.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:f3bf3fede7e261b2d0c1146159b0160867824de9c5fe15c8e7919fe4ce01c131
|
3 |
+
size 4172
|
graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/raw_file.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:62fea7d9dcb727985921e6f3c57920203676defe4d82de5144d2908449dc671b
|
3 |
+
size 15577
|
graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/saved_file.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:919816078dc8234cc94c37ca22681963d2d7de174e7a87990f43d602d23c4dbb
|
3 |
+
size 15748
|
graphs/out/018e2f52-4a14-7a03-b087-094b99cc69e3/whisper_text.parquet
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:5954886d05219c9a3e24631563493f0abd1117cd4cf76d4d775ed5d4829e4522
|
3 |
+
size 2372
|
operators/microphone_op.py
CHANGED
@@ -1,9 +1,6 @@
|
|
1 |
# Run this in the consol first :
|
2 |
|
3 |
# pip install sounddevice numpy
|
4 |
-
|
5 |
-
# Don't forget to install whisper
|
6 |
-
|
7 |
import time
|
8 |
|
9 |
import numpy as np
|
@@ -19,7 +16,7 @@ MAX_DURATION = 5
|
|
19 |
|
20 |
class Operator:
|
21 |
"""
|
22 |
-
|
23 |
"""
|
24 |
|
25 |
def on_event(
|
|
|
1 |
# Run this in the consol first :
|
2 |
|
3 |
# pip install sounddevice numpy
|
|
|
|
|
|
|
4 |
import time
|
5 |
|
6 |
import numpy as np
|
|
|
16 |
|
17 |
class Operator:
|
18 |
"""
|
19 |
+
Microphone operator that records the audio
|
20 |
"""
|
21 |
|
22 |
def on_event(
|
operators/object_detection.py
CHANGED
@@ -1,7 +1,3 @@
|
|
1 |
-
#!/usr/bin/env python3
|
2 |
-
# -*- coding: utf-8 -*-
|
3 |
-
|
4 |
-
|
5 |
import numpy as np
|
6 |
import pyarrow as pa
|
7 |
|
@@ -16,7 +12,9 @@ CAMERA_HEIGHT = 540
|
|
16 |
|
17 |
class Operator:
|
18 |
"""
|
19 |
-
Infering object from images
|
|
|
|
|
20 |
"""
|
21 |
|
22 |
def __init__(self):
|
@@ -36,16 +34,7 @@ class Operator:
|
|
36 |
dora_input,
|
37 |
send_output,
|
38 |
) -> DoraStatus:
|
39 |
-
"""Handle image
|
40 |
-
Args:
|
41 |
-
dora_input (dict) containing the "id", value, and "metadata"
|
42 |
-
send_output Callable[[str, bytes | pa.Array, Optional[dict]], None]:
|
43 |
-
Function for sending output to the dataflow:
|
44 |
-
- First argument is the `output_id`
|
45 |
-
- Second argument is the data as either bytes or `pa.Array`
|
46 |
-
- Third argument is dora metadata dict
|
47 |
-
e.g.: `send_output("bbox", pa.array([100], type=pa.uint8()), dora_event["metadata"])`
|
48 |
-
"""
|
49 |
|
50 |
frame = dora_input["value"].to_numpy().reshape((CAMERA_HEIGHT, CAMERA_WIDTH, 3))
|
51 |
frame = frame[:, :, ::-1] # OpenCV image (BGR to RGB)
|
@@ -53,6 +42,7 @@ class Operator:
|
|
53 |
# Process results
|
54 |
boxes = np.array(results[0].boxes.xyxy.cpu())
|
55 |
conf = np.array(results[0].boxes.conf.cpu())
|
|
|
56 |
label = np.array(results[0].boxes.cls.cpu())
|
57 |
# concatenate them together
|
58 |
arrays = np.concatenate((boxes, conf[:, None], label[:, None]), axis=1)
|
|
|
|
|
|
|
|
|
|
|
1 |
import numpy as np
|
2 |
import pyarrow as pa
|
3 |
|
|
|
12 |
|
13 |
class Operator:
|
14 |
"""
|
15 |
+
Object Detection: Infering object from images using Deep Learning model YOLOv8.
|
16 |
+
The output sent is bounding box representing the corners of the bounding box
|
17 |
+
as well as their COCO label.
|
18 |
"""
|
19 |
|
20 |
def __init__(self):
|
|
|
34 |
dora_input,
|
35 |
send_output,
|
36 |
) -> DoraStatus:
|
37 |
+
"""Handle image"""
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
38 |
|
39 |
frame = dora_input["value"].to_numpy().reshape((CAMERA_HEIGHT, CAMERA_WIDTH, 3))
|
40 |
frame = frame[:, :, ::-1] # OpenCV image (BGR to RGB)
|
|
|
42 |
# Process results
|
43 |
boxes = np.array(results[0].boxes.xyxy.cpu())
|
44 |
conf = np.array(results[0].boxes.conf.cpu())
|
45 |
+
# COCO Label
|
46 |
label = np.array(results[0].boxes.cls.cpu())
|
47 |
# concatenate them together
|
48 |
arrays = np.concatenate((boxes, conf[:, None], label[:, None]), axis=1)
|
operators/plot.py
CHANGED
@@ -1,6 +1,3 @@
|
|
1 |
-
#!/usr/bin/env python3
|
2 |
-
# -*- coding: utf-8 -*-
|
3 |
-
|
4 |
import os
|
5 |
from typing import Callable, Optional, Union
|
6 |
|
@@ -29,7 +26,7 @@ writer = cv2.VideoWriter(
|
|
29 |
|
30 |
class Operator:
|
31 |
"""
|
32 |
-
Plot image and
|
33 |
"""
|
34 |
|
35 |
def __init__(self):
|
@@ -54,17 +51,7 @@ class Operator:
|
|
54 |
send_output: Callable[[str, Union[bytes, pa.UInt8Array], Optional[dict]], None],
|
55 |
) -> DoraStatus:
|
56 |
"""
|
57 |
-
|
58 |
-
|
59 |
-
Args:
|
60 |
-
dora_input["id"] (str): Id of the dora_input declared in the yaml configuration
|
61 |
-
dora_input["value"] (arrow array): message of the dora_input
|
62 |
-
send_output Callable[[str, bytes | pa.UInt8Array, Optional[dict]], None]:
|
63 |
-
Function for sending output to the dataflow:
|
64 |
-
- First argument is the `output_id`
|
65 |
-
- Second argument is the data as either bytes or `pa.UInt8Array`
|
66 |
-
- Third argument is dora metadata dict
|
67 |
-
e.g.: `send_output("bbox", pa.array([100], type=pa.uint8()), dora_event["metadata"])`
|
68 |
"""
|
69 |
if dora_input["id"] == "image":
|
70 |
frame = (
|
|
|
|
|
|
|
|
|
1 |
import os
|
2 |
from typing import Callable, Optional, Union
|
3 |
|
|
|
26 |
|
27 |
class Operator:
|
28 |
"""
|
29 |
+
Plot image on window and additional context
|
30 |
"""
|
31 |
|
32 |
def __init__(self):
|
|
|
51 |
send_output: Callable[[str, Union[bytes, pa.UInt8Array], Optional[dict]], None],
|
52 |
) -> DoraStatus:
|
53 |
"""
|
54 |
+
Plot image on window and additional context
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
55 |
"""
|
56 |
if dora_input["id"] == "image":
|
57 |
frame = (
|
operators/sentence_transformers_op.py
CHANGED
@@ -12,13 +12,15 @@ SHOULD_NOT_BE_INCLUDED = [
|
|
12 |
"utils.py",
|
13 |
"sentence_transformers_op.py",
|
14 |
"chatgpt_op.py",
|
15 |
-
"
|
16 |
-
"microphone_op.py",
|
17 |
-
"object_detection_op.py",
|
18 |
-
"webcam.py",
|
19 |
]
|
20 |
|
21 |
-
SHOULD_BE_INCLUDED = [
|
|
|
|
|
|
|
|
|
|
|
22 |
|
23 |
|
24 |
## Get all python files path in given directory
|
|
|
12 |
"utils.py",
|
13 |
"sentence_transformers_op.py",
|
14 |
"chatgpt_op.py",
|
15 |
+
"mistral_op.py",
|
|
|
|
|
|
|
16 |
]
|
17 |
|
18 |
+
SHOULD_BE_INCLUDED = [
|
19 |
+
"planning_op.py",
|
20 |
+
"object_detection_op.py",
|
21 |
+
"plot.py",
|
22 |
+
"microphone_op.py",
|
23 |
+
]
|
24 |
|
25 |
|
26 |
## Get all python files path in given directory
|
operators/webcam.py
CHANGED
@@ -14,7 +14,7 @@ CI = os.environ.get("CI")
|
|
14 |
|
15 |
CAMERA_WIDTH = 960
|
16 |
CAMERA_HEIGHT = 540
|
17 |
-
CAMERA_INDEX = int(os.getenv("CAMERA_INDEX",
|
18 |
|
19 |
font = cv2.FONT_HERSHEY_SIMPLEX
|
20 |
|
|
|
14 |
|
15 |
CAMERA_WIDTH = 960
|
16 |
CAMERA_HEIGHT = 540
|
17 |
+
CAMERA_INDEX = int(os.getenv("CAMERA_INDEX", 2))
|
18 |
|
19 |
font = cv2.FONT_HERSHEY_SIMPLEX
|
20 |
|
operators/whisper_op.py
CHANGED
@@ -16,7 +16,7 @@ model = whisper.load_model("base")
|
|
16 |
|
17 |
class Operator:
|
18 |
"""
|
19 |
-
|
20 |
"""
|
21 |
|
22 |
def on_event(
|
|
|
16 |
|
17 |
class Operator:
|
18 |
"""
|
19 |
+
Transforming Speech to Text using OpenAI Whisper model
|
20 |
"""
|
21 |
|
22 |
def on_event(
|