Commit Graph

3234 Commits

Author SHA1 Message Date
Nicolas Mowen
18bf7f93fa
Improve rocm handling of different models (#14072)
* Improve rocm handling of different models

* Formatting

* Fix type check
2024-09-30 16:40:46 -05:00
Nicolas Mowen
c73f694c63
Improve gamma filter (#14065)
* Improve gamma filter

* Fix tests
2024-09-30 11:42:51 -06:00
Josh Hawkins
3688a3bc67
Misc fixes (#14064)
* Add loading indicator when explore view is revalidating

* Portal tooltip in object lifecycle pane

* Better config file handling

* Only manually set aspect ratio when using alert videos
2024-09-30 07:32:54 -06:00
Stepan Legachev
775a3a1c22
docs: fix argument spelling (#13366) 2024-09-28 18:17:32 -06:00
gtsiam
bbbb3b4a06
Split config.py into multiple files (#14038)
* Replace logging.warn with logging.warning

* Install config global state early

* Split config.py into more manageable pieces
2024-09-28 14:21:42 -05:00
Nicolas Mowen
576191cd4e
Remove debug log (#14037) 2024-09-28 10:26:11 -05:00
Nicolas Mowen
38d398c967
Dynamic attributes config (#14035)
* Add config for attribute map and generate all labels from the map

* Update docs

* Formatting

* Use the dynamic label map

* Fix check

* Fix docs typo
2024-09-28 07:49:04 -06:00
Josh Hawkins
7da44115d3
Clarify storage metrics values with a popover (#14034) 2024-09-28 08:24:14 -05:00
Nokius
b54032bdc7
make the hailo user instalation script a bit more failsafe (#13992)
This will checks if the firmware folder is present if not it will created it informs the user to reboot to load the firmware for the hailo8l detector.
2024-09-28 05:55:17 -06:00
Nicolas Mowen
cab497e81e
Fix dynamic api ordering (#14022)
* Fix dynamic api ordering

* Formatting
2024-09-27 12:09:53 -06:00
Nicolas Mowen
50e9c67609
Update Templates (#14019)
* Update general support template

* Update camera support

* Update config-support.yml

* Update detector support

* Update general-support.yml

* Update hardware-acceleration-support.yml

* Create pull_request_template.md
2024-09-27 10:48:51 -05:00
Josh Hawkins
bd57ea0110
Revert all cameras switches behavior (#14015) 2024-09-27 08:13:15 -06:00
Nicolas Mowen
05fe7f8a48
Fixes & Tweaks (#14013)
* Rework to create util for onnx initialization

* Fix shm log

* Fix onClick exceptoins
2024-09-27 07:41:48 -06:00
gtsiam
c0bd3b362c
Custom classes for Process and Metrics (#13950)
* Subclass Process for audio_process

* Introduce custom mp.Process subclass

In preparation to switch the multiprocessing startup method away from
"fork", we cannot rely on os.fork cloning the log state at fork time.
Instead, we have to set up logging before we run the business logic of
each process.

* Make camera_metrics into a class

* Make ptz_metrics into a class

* Fixed PtzMotionEstimator.ptz_metrics type annotation

* Removed pointless variables

* Do not start audio processor when no audio cameras are configured
2024-09-27 07:53:23 -05:00
Josh Hawkins
1f328be1bd
UI fixes (#14010)
* Fix export time picker on iOS

* Fix dialog on iPad
2024-09-27 07:52:31 -05:00
Nicolas Mowen
ddfdb71783
Fix snapshot access (#13996) 2024-09-26 20:05:48 -05:00
Nicolas Mowen
da1478c0c1
Update object_detectors.md (#13994)
* Update object_detectors.md

* Use info

* Move CPU detector to bottom

* Moce CPU to bottom

* Add missing detector keys
2024-09-26 18:58:58 -05:00
Josh Hawkins
40fe3b4358
Search functionality and UI tweaks (#13978)
* Portal tooltips

* Add ability to time_range filter chroma searches

* centering and padding consistency

* add event id back to chroma metadata

* query sqlite first and pass those ids to chroma for embeddings search

* ensure we pass timezone to the api call

* remove object lifecycle from search details for non-object events

* simplify hour calculation

* fix query without filters

* bump chroma version

* chroma 0.5.7

* fix selecting camera group in cameras filter button
2024-09-26 15:30:56 -05:00
Nicolas Mowen
20fd1db0f4
Update hailo driver to 4.18 (#13991) 2024-09-26 12:16:08 -06:00
Nicolas Mowen
a65aaab849
Fixes (#13990)
* Fix ROCm input name

* Fix incorrect parsing of None
2024-09-26 12:42:21 -05:00
Nicolas Mowen
a5595189ed
Fix ROCm inference (#13988) 2024-09-26 12:16:26 -05:00
Nicolas Mowen
4a1da3ebc5
Fix saving config (#13985) 2024-09-26 11:19:37 -05:00
Nicolas Mowen
35a4460334
Tweaks (#13983)
* Add onConnect to mqtt and doucment

* Add play pause via mouse click
2024-09-26 09:12:15 -05:00
Nicolas Mowen
a6ccb37683
Fix config saving api (#13969) 2024-09-25 17:22:11 -05:00
Josh Hawkins
68465aed49
Increase healthcheck start period to 5 minutes (#13968) 2024-09-25 15:14:10 -06:00
Nicolas Mowen
fc3aac96f2
Remove incorrect (#13966) 2024-09-25 14:53:17 -05:00
Josh Hawkins
32c7669b28
Search UI tweaks (#13965)
* Prevent keyboard shortcuts from running when input is focused

* fix reset button and update time pickers when using input

* simplify css

* consistent button order and spacing
2024-09-25 12:45:42 -06:00
Nicolas Mowen
fef30bc671
Peroparly handle text based responses (#13964) 2024-09-25 13:35:30 -05:00
Josh Hawkins
ae547d27e4
Use not instead of is None (#13962) 2024-09-25 11:53:25 -06:00
Josh Hawkins
be3e1831d4
Add ability to use 12 hour time in input time filter (#13961) 2024-09-25 12:15:08 -05:00
Nicolas Mowen
45aceea53b
Return version as html (#13960) 2024-09-25 10:06:17 -06:00
Nicolas Mowen
25819584bd
Add ability to filter search by time range (#13946)
* Add ability to filter by time range

* Cleanup

* Handle input with tags

* fix input for time_range filter

* fix before and after filters

* clean up

* Ensure the default value works as expected

* Handle time range in am/pm based on browser

* Fix arrow

* Fix text

* Handle midnight case

* fix width

* Fix bg

* Fix bg

* Fix mobile spacing

* y spacing

* remove left padding

---------

Co-authored-by: Josh Hawkins <32435876+hawkeye217@users.noreply.github.com>
2024-09-25 10:05:40 -06:00
Nicolas Mowen
4c24b70d47
Do not use a default value of datetime for params (#13957)
* Do not use a default value of datetime for params

* Formatting

* Remove unused

* Undo
2024-09-25 10:49:54 -05:00
Josh Hawkins
4c12673fbb
Add ability to restrict genai to objects and zones at the camera level (#13958)
* Add ability to restrict genai to labels and zones at the camera level

* fix comment

* clarify docs

* use objects instead of labels

* docs

* object list
2024-09-25 09:42:39 -06:00
Nicolas Mowen
e935db5075
Api fixes (#13955)
* Fix false positive submission

* Make sure None is not sent as rate limit
2024-09-25 08:01:08 -05:00
Josh Hawkins
a7f1f8d327
Add 1s timeout to metadata subscriber in embeddings maintainer (#13947) 2024-09-24 19:08:12 -05:00
Josh Hawkins
8c540d7210
Add error logging to genai clients (#13943) 2024-09-24 14:04:35 -06:00
Nicolas Mowen
4c4b884f8e
Review api fixes (#13942)
* Fix order of review api

* remove uneccesary params
2024-09-24 14:32:50 -05:00
Josh Hawkins
1ae521f560
regenerate description fixes (#13940) 2024-09-24 12:34:29 -06:00
Nicolas Mowen
7854e1c2c1
Fix plus api (#13937)
* Fix plus api

* Fix regenerate api
2024-09-24 12:22:11 -05:00
Nicolas Mowen
a9ff795948
More api fixes (#13936)
* Set correect return type for raw config

* Simplify parsing

* Formatting
2024-09-24 09:54:03 -06:00
Nicolas Mowen
a8e2f97260
Improve performance of image fetching (#13933) 2024-09-24 09:50:20 -05:00
Nicolas Mowen
d17253b023
Fix apis (#13932) 2024-09-24 09:27:10 -05:00
Josh Hawkins
ecbf0410eb
Regenerate genai tracked object descriptions (#13930)
* add genai to frigateconfig

* add regenerate button if genai is enabled

* add endpoint and new zmq pub/sub model

* move publisher to app

* dont override

* logging

* debug timeouts

* clean up

* clean up

* allow saving of empty description

* ensure descriptions can be empty

* update search detail when results change

* revalidate explore page on focus

* global mutate hook

* description websocket hook and dispatcher

* revalidation and mutation

* fix merge conflicts

* update tests

* fix merge conflicts

* fix response message

* fix response message

* fix fastapi

* fix test

* remove log

* json content

* fix content response

* more json content fixes

* another one
2024-09-24 08:14:51 -06:00
Rui Alves
cffc431bf0
Frigate HTTP API using FastAPI (#13871)
* POC: Added FastAPI with one endpoint (get /logs/service)

* POC: Revert error_log

* POC: Converted preview related endpoints to FastAPI

* POC: Converted two more endpoints to FastAPI

* POC: lint

* Convert all media endpoints to FastAPI. Added /media prefix (/media/camera && media/events && /media/preview)

* Convert all notifications API endpoints to FastAPI

* Convert first review API endpoints to FastAPI

* Convert remaining review API endpoints to FastAPI

* Convert export endpoints to FastAPI

* Fix path parameters

* Convert events endpoints to FastAPI

* Use body for multiple events endpoints

* Use body for multiple events endpoints (create and end event)

* Convert app endpoints to FastAPI

* Convert app endpoints to FastAPI

* Convert auth endpoints to FastAPI

* Removed flask app in favour of FastAPI app. Implemented FastAPI middleware to check CSRF, connect and disconnect from DB. Added middleware x-forwared-for headers

* Added starlette plugin to expose custom headers

* Use slowapi as the limiter

* Use query parameters for the frame latest endpoint

* Use query parameters for the media snapshot.jpg endpoint

* Use query parameters for the media MJPEG feed endpoint

* Revert initial nginx.conf change

* Added missing even_id for /events/search endpoint

* Removed left over comment

* Use FastAPI TestClient

* severity query parameter should be a string

* Use the same pattern for all tests

* Fix endpoint

* Revert media routers to old names. Order routes to make sure the dynamic ones from media.py are only used whenever there's no match on auth/etc

* Reverted paths for media on tsx files

* Deleted file

* Fix test_http to use TestClient

* Formatting

* Bind timeline to DB

* Fix http tests

* Replace filename with pathvalidate

* Fix latest.ext handling and disable uvicorn access logs

* Add cosntraints to api provided values

* Formatting

* Remove unused

* Remove unused

* Get rate limiter working

---------

Co-authored-by: Nicolas Mowen <nickmowen213@gmail.com>
2024-09-24 07:05:30 -06:00
gtsiam
dc54981784
Move more things out of FrigateApp (#13897)
* Moved FrigateApp.init_config() into FrigateConfig.load()

* Move frigate config loading into main

* Store PlusApi in FrigateConfig

* Register SIGTERM handler in main

* Ensure logging is setup during config parsing

* Removed pointless try

* Moved config initialization out of FrigateApp

* Made FrigateApp.shm_frame_count into a function

* Removed log calls from signal handlers

python's logging calls are not re-entrant, which caused at least one of
these to deadlock randomly.

* Reopen stdout/err on process fork

This helps avoid deadlocks (https://github.com/python/cpython/issues/91776).

* Make mypy happy

* Whoops. I might have forgotten to save.

Truly an amateur mistake.

* Always call FrigateApp.stop()
2024-09-24 07:07:47 -05:00
Josh Hawkins
a7ed90f042
try deleting zoom spaces if disabled (#13915) 2024-09-23 15:34:08 -05:00
Nicolas Mowen
08941ab39a
Improve hailo docs (#13910)
* Fix command for hailo8 install

* Update object_detectors.md
2024-09-23 09:53:54 -05:00
ofcedwards
b81a8d26e4
Disable keepalive for Safari in nginx vod location (#13909) 2024-09-23 08:02:50 -06:00
Nicolas Mowen
af84af7b7a
Don't print error for requesting camera info (#13905) 2024-09-23 08:49:34 -05:00