Skip to content

Commit 2b6ea48

Browse files
committed
new dashboard + env
1 parent 0d05f0c commit 2b6ea48

File tree

6 files changed

+8
-7
lines changed

6 files changed

+8
-7
lines changed

.gitignore

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,9 @@ __pycache__
22
.ipynb_checkpoints
33
drafts
44
logs
5-
**.mp4
5+
test_videos/videos_extra
66
**.engine
77
videos_out
8-
test_videos
98
test.ipynb
109
myenv
1110
web.py

configs/app_config.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ show_node:
6262
overlay_transparent_mask: False # Заливка регионов при show_roi=True (медленная операция)
6363
show_only_yolo_detections : False # Отображать лишь результаты детекции без учета трекинга и прочей логики кода
6464
show_track_id_different_colors: False # Отображать цвет бокса согласно id трека, а не логике прибытия объекта
65-
show_info_statistics: True # Вывод информации о статистике в отдельном окне справа от кадра
65+
show_info_statistics: False # Вывод информации о статистике в отдельном окне справа от кадра
6666

6767

6868
video_saver_node:
@@ -87,4 +87,4 @@ video_server_node:
8787
host_ip: 0.0.0.0 # где именно поднять сервис (localhost или "0.0.0.0")
8888
port: 8100 # На каком порту поднять
8989
template_folder: ../utils_local/templates # Путь до templates (там где html файл)
90-
90+
output_size : [800, 470] # ресайз для отображения в flask

docker-compose.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ services:
1111
- VIDEO_SRC=test_videos/test_video.mp4
1212
- ROADS_JSON=configs/entry_exit_lanes.json
1313
- TABLE_NAME=traffic_info
14-
- DROP_TABLE=True
14+
- DROP_TABLE=False
1515
volumes:
1616
- .:/app
1717
ports:

nodes/FlaskServerVideoNode.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,9 @@ def __init__(self, config):
2828
self.host_ip = config_server["host_ip"]
2929
self.port = config_server["port"]
3030
self.index_page = config_server["index_page"]
31-
self._frame = np.zeros(shape=(640, 480), dtype=np.uint8)
31+
self.output_size = config_server["output_size"]
32+
33+
self._frame = np.zeros(shape=(self.output_size[1], self.output_size[0]), dtype=np.uint8)
3234
self.run()
3335

3436
def _index(self) -> str:
@@ -45,7 +47,7 @@ def _update_page(self) -> Response:
4547
return Response(self._gen(), mimetype='multipart/x-mixed-replace; boundary=frame')
4648

4749
def update_image(self, image: np.array):
48-
self._frame = image
50+
self._frame = cv2.resize(image, self.output_size)
4951

5052
def run(self):
5153
self.app_thread = Thread(target=self.app.run, daemon=True, args=(self.host_ip, self.port))

services/grafana/grafana.db

52 KB
Binary file not shown.

test_videos/longer_example.mp4

79.4 MB
Binary file not shown.

0 commit comments

Comments
 (0)