Commit Graph

353 Commits

Author SHA1 Message Date
Nicolas Mowen
c6d0e93157
Allow customization of tooltip capitalization (#7172) 2023-07-16 07:44:05 -05:00
Nicolas Mowen
07155b1fa9
Show / Download Exported recordings UI (#7171)
* Start with getting list of exports

* List downloadable exports in export page

* Fix downloading

* use swr instead of effect
2023-07-15 15:13:53 -05:00
Nicolas Mowen
5c12762cb5
Fix Birdseye Width & PTZ control panel (#7118)
* Cleanup birdseye UI

* Cleanup

* Fix reversed condition
2023-07-14 06:29:57 -05:00
Sergey Krashevich
6d34f2229b
WebUI: Show label & sub labels values next to the score (#7121)
* Refactor event label and sub-label score display in Events.jsx to include the event label and sub-label percentage

* Revert "Refactor event label and sub-label score display in Events.jsx to include the event label and sub-label percentage"

This reverts commit 87c23adf1e.

* Refactor event label and sub label score display in Events component
2023-07-14 06:25:53 -05:00
Bernt Christian Egeland
a94346e17e
Improve date and time formatting with fallback for unsupported Intl.DateTimeFormat features (#7099)
* Intl.DateTimeFormat fallback

* only set timezone when available or in config
2023-07-11 06:19:58 -05:00
Sergey Krashevich
20415bb5e0
Refactor code in Events.jsx to conditionally render event zones in the event card view (#7120) 2023-07-11 06:10:29 -05:00
Blake Blackshear
7c0d25f9da
Attribute scores (#7100)
* rework attributes to get scores

* show sublabel score

* formatting
2023-07-09 11:40:39 -05:00
Nicolas Mowen
00b9a490bb
Hide birdseye width button on mobile devices (#7077)
* Hide birdseye width button on mobile devices

* Update Birdseye.jsx
2023-07-07 07:35:53 -05:00
Sergey Krashevich
5259d51c04
UI Improvement: Full-width birdseye (if no PTZ cameras) (#6817)
* Refactor video player div class names in Birdseye.jsx to be more responsive

* let's JSMpegPlayer dont takes up the entire screen

* Update Birdseye.jsx

* Add useState hook and toggle button for dynamic width adjustment and refactor code for readability in env.js and Birdseye.jsx

* fix stupid typo

* Swapped the controls around

* Remove useless comments

Co-authored-by: Nicolas Mowen <nickmowen213@gmail.com>

* Add button styles to the Birdseye component's toggle width button

---------

Co-authored-by: Nicolas Mowen <nickmowen213@gmail.com>
2023-07-07 07:09:55 -05:00
Nicolas Mowen
04aada8720
Fix webUI presets (#7065) 2023-07-07 07:07:46 -05:00
Sergey Krashevich
f48dd8c1ab
Feature: camera debug/config enhancements (#6920)
* Add functionality to update YAML config file with PUT request in HTTP endpoint

* Refactor copying of text to clipboard with Clipboard API and fallback to document.execCommand('copy') in CameraMap.jsx file

* Update YAML file from URL query parameters in frigate/http.py and add functionality to save motion masks, zones, and object masks in CameraMap.jsx

* formatting

* fix merging fuckup

* Refactor camera zone coordinate saving to use single query parameter per zone in CameraMap.jsx

* remove unnecessary print statements in util.py

* Refactor update_yaml_file function to separate the logic for updating YAML data into a new function update_yaml().

* fix merge errors

* Refactor code to improve error handling and add dependencies to useEffect hooks
2023-07-06 13:54:26 -05:00
Sergey Krashevich
1171f01683
Refactor camera rendering logic in System component to only render enabled cameras (#6992) 2023-07-03 09:49:14 -05:00
Nicolas Mowen
c3b313a70d
Audio events (#6848)
* Initial audio classification model implementation

* fix mypy

* Keep audio labelmap local

* Cleanup

* Start adding config for audio

* Add the detector

* Add audio detection process keypoints

* Build out base config

* Load labelmap correctly

* Fix config bugs

* Start audio process

* Fix startup issues

* Try to cleanup restarting

* Add ffmpeg input args

* Get audio detection working

* Save event to db

* End events if not heard for 30 seconds

* Use not heard config

* Stop ffmpeg when shutting down

* Fixes

* End events correctly

* Use api instead of event queue to save audio events

* Get events working

* Close threads when stop event is sent

* remove unused

* Only start audio process if at least one camera is enabled

* Add const for float

* Cleanup labelmap

* Add audio icon in frontend

* Add ability to toggle audio with mqtt

* Set initial audio value

* Fix audio enabling

* Close logpipe

* Isort

* Formatting

* Fix web tests

* Fix web tests

* Handle cases where args are a string

* Remove log

* Cleanup process close

* Use correct field

* Simplify if statement

* Use var for localhost

* Add audio detectors docs

* Add restream docs to mention audio detection

* Add full config docs

* Fix links to other docs

---------

Co-authored-by: Jason Hunter <hunterjm@gmail.com>
2023-07-01 08:18:33 -05:00
Bernt Christian Egeland
f1dc3a639c
fixed TimeAgo abbreviation (#6977)
* fixed TimeAgo abbreviation

* Update web/src/components/TimeAgo.tsx

Co-authored-by: Blake Blackshear <blakeb@blakeshome.com>

---------

Co-authored-by: Blake Blackshear <blakeb@blakeshome.com>
2023-07-01 08:16:19 -05:00
Blake Blackshear
2f401bd8da
update deps (#6973)
* update web deps

* update python deps
2023-07-01 07:47:16 -05:00
Nicolas Mowen
0a8249d6fb
Fix Bad Resize For Camera Snapshot (#6797)
* Catch cases where incorrect size is requested

* Set a default if calculated height is incorrect
2023-06-30 07:34:10 -05:00
Nicolas Mowen
bd17e7d824
Show object attributes when hovering or tapping timeline bounding box (#6879)
* Show overlay when hovering on timeline box

* Make it work with mobile too

* Fix lint

* Fix ratio

* Update web/src/components/TimelineEventOverlay.jsx

Co-authored-by: Blake Blackshear <blakeb@blakeshome.com>

* Show overlay when hovering on timeline box

* Make it work with mobile too

* Fix lint

* Fix ratio

* Remove label and make overlay respect selected theme

---------

Co-authored-by: Blake Blackshear <blakeb@blakeshome.com>
2023-06-30 07:15:19 -05:00
Nicolas Mowen
ece070fee1
Load labels dynamically for event filters (#6896)
* Load labels dynamically to include custom events and audio, do not include attribute labels

* Formatting

* Fix sorting

* Also filter tracked object list on camera page

* isort

* Don't fail before load
2023-06-28 05:51:53 -05:00
spacebares
3d40ed5d47
fix tooltip not showing if too far left (#6909) 2023-06-28 05:45:54 -05:00
Nicolas Mowen
ff1b5c87aa
Fix stream name not being used for MSE (#6796) 2023-06-14 06:49:32 -06:00
Sergey Krashevich
a8f282515f
Bugfix: Refactor date and time initialization in Export.jsx (#6794)
* Refactor date and time initialization in Export.jsx to use local timezone

* Update error message to include specific reason for failure in Export.jsx
2023-06-14 07:32:36 -05:00
Sergey Krashevich
dfd574beeb
Refactor storage stats calculation to use powers of 2 for more accurate values (#6765)
* "Refactor storage stats calculation to use powers of 2 for more accurate values"

* replace 1000000 to 2^20

* Refactor storage unit size display to use binary prefixes

This commit updates the display of storage unit sizes in both the camera storage stats and the Storage component in the web UI to use binary prefixes (MiB and GiB) instead of decimal prefixes (MB and GB). This provides more accurate and consistent representation of storage sizes
2023-06-11 14:49:13 -05:00
Bernt Christian Egeland
b359ff1b8e
[Feature] Add timepicker to calendar (#5183)
* added timepicker as children to calendar

* new timepicker component

* Add timepicker

* new timePicker component

* timepicker as calendar child

* hover:border and rounded

* adjusted width

* complete rework

* more code comments

* memorization

* preselect hover, transition

* numberOfDaysSelected has minimum of 1

* prefill hours when component mounts

* persist hours when component mount

* accommodate for the new timePicker

* add reset state

* scroll into view

* reuse before, after

* fix LastDayInRange when a time is selected

* do not add hours if before is zero

* use hours instead of days

* useeffect to reset hour. check timerange before scroll

* scroll to last element, not first
2023-06-11 14:48:45 -05:00
Nicolas Mowen
32569842d3
Option to enable / disable stats that require external processes (#6615)
* Add option for network bandwidth and only calculate if enabled

* Don't show network bandwidth in system stats page if not enabled

* Formatting

* Hide other rows as well

* Add docs

* Add config options for AMD and Intel GPU stats

* Fix stats access

* Update docs

* Use correct bool syntax

Co-authored-by: Blake Blackshear <blakeb@blakeshome.com>

---------

Co-authored-by: Blake Blackshear <blakeb@blakeshome.com>
2023-06-11 08:26:34 -05:00
Sergey Krashevich
7459a1cdde
Enhancement: Add Date and Time Inputs to Export Component with Time Validation (#6750)
* Add date and time inputs to Export component and ensure end time is larger than start time

* Update web/src/routes/Export.jsx

Co-authored-by: Blake Blackshear <blakeb@blakeshome.com>

---------

Co-authored-by: Blake Blackshear <blakeb@blakeshome.com>
2023-06-11 08:01:16 -05:00
Nicolas Mowen
d3949eebfa
Add API and WebUI to export recordings (#6550)
* Add ability to export frigate clips

* Add http endpoint

* Add dir to nginx

* Add webUI

* Formatting

* Cleanup unused

* Optimize timelapse

* Fix pts

* Use JSON body for params

* Use hwaccel to encode when available

* Print ffmpeg command when fail

* Print ffmpeg command when fail

* Add separate ffmpeg preset for timelapse

* Add docs outlining the export directory

* Add export docs

* Use ''

* Fix playlist max time

* Lower max playlist time

* Add api docs for export

* isort fixes
2023-06-08 07:32:35 -04:00
Blake Blackshear
699248d769
Update deps (#6669)
* fix gh host key

* python deps

* update web deps

* update docs deps
2023-06-01 06:59:50 -05:00
Nicolas Mowen
53d63e0f75
Update go2rtc to 1.5.0 (#5814)
* Update go2rtc to 1.3.0

* Increment to 1.3.1

* Increment to 1.3.2

* Update webrtc player to match latest

* Update version to 1.4.0

* Update mse player

* Update birdseye mse player

* remove logs

* Update docs to link to new version

* Final web lint fixes

* Update versions
2023-05-21 06:53:25 -06:00
Blake Blackshear
42f3ee3de5 sync master 2023-05-19 05:47:49 -05:00
Nicolas Mowen
e357715a8c
Ability to manually create events through the API (#3184)
* Move to events package

* Improve handling of external events

* Handle external events in the event queue

* Pass in event processor

* Check event json

* Fix json parsing and change defaults

* Fix snapshot saving

* Hide % score when not available

* Correct docs and add json example

* Save event png db

* Adjust image

* Formatting

* Add catch for failure ending event

* Add init to modules

* Fix naming

* Formatting

* Fix http creation

* fix test

* Change to PUT and include response in docs

* Add ability to set bounding box locations in snapshot

* Support multiple box annotations

* Cleanup docs example response

Co-authored-by: Blake Blackshear <blake@frigate.video>

* Cleanup docs wording

Co-authored-by: Blake Blackshear <blake@frigate.video>

* Store full frame for thumbnail

* Formatting

* Set thumbnail height to 175

* Formatting

---------

Co-authored-by: Blake Blackshear <blake@frigate.video>
2023-05-19 05:16:11 -05:00
Sergey Krashevich
6d0c2ec5c8
Add go2rtc & remote detectors network bandwidth usage to System table (#6526)
* Add network bandwidth usage to System table display in System.jsx and update get_bandwidth_stats function in util.py to include go2rtc processes

* black...

* Add network bandwidth usage to system table in web UI and improve regex in get_bandwidth_stats function to include frigate detector processes

* black...

* Update bandwidth calculation to include both incoming and outgoing traffic

* black:(
2023-05-18 06:40:24 -05:00
Korneliusz Jarzębski
17e8a46c7d
add ffmpeg bandwidth stats (#6492)
* add ffmpeg bandwidth stats

* add ffmpeg bandwidth stats

* Change column name

Co-authored-by: Nicolas Mowen <nickmowen213@gmail.com>

* fix lint formatting

---------

Co-authored-by: Korneliusz Jarzębski <k.jarzebski@netverse.pl>
Co-authored-by: Nicolas Mowen <nickmowen213@gmail.com>
2023-05-17 20:01:56 -05:00
Sergey Krashevich
5fb96c777a
Add cmdline information to CPU usage stats in get_cpu_stats() function and display it in the System page's ffmpeg table with a copy-to-clipboard button (#6430) 2023-05-15 07:39:03 -05:00
Nicolas Mowen
5951a740d2
Prevent recordings from being turned on if disabled in config (#6444)
* Prevent enabling recordings if not enabled in config

* Fix conflict

* Fix spacing

* Update wording

* Update wording

---------

Co-authored-by: Blake Blackshear <blakeb@blakeshome.com>
2023-05-15 07:36:26 -05:00
Blake Blackshear
e3b9998879
Upgrade deps (#6395)
* update js build tools

* update frontend deps

* python updates

* update requests again
2023-05-05 07:45:13 -05:00
Sergey Krashevich
f52b1212cd
add go2rtc version (#6390)
Update System.jsx
2023-05-04 21:04:06 -05:00
Nicolas Mowen
aded314f3c
Timeline UI optimizations (#6367)
* Fix centering of bottom_center

* Make bottom_center overlap vertically

* Fix timeline icon behavior

* Make disclaimer hidden under aria label

* Don't literally say disclaimer
2023-05-04 17:34:48 -06:00
Stephen Horvath
0751358e5b
Fix site.webmanifest + add svg as favicon (#6304) 2023-05-04 18:04:24 -05:00
Peeter N
17b92aa657
Do not show the loader during recordings api call (#6366)
* Do not show the loader during recordings api call

Showing the loader during the recordings API call will rerender the recordings list and rerenders the video player

* Fix defauting to 0 seekSeconds if recordings results are missings
2023-05-04 18:02:48 -05:00
Nicolas Mowen
ef50af03f2
Add icon to explain in more detail the system stats / storage info (#6358)
* Add info icon with additional info for each process.

* Specify single CPU core

* Include storage in tooltips
2023-05-04 18:01:27 -05:00
Sergey Krashevich
02f577347d
Hide PTZ Controls in Birdseye when no cameras support it (#6353)
* Refactor filter logic to exclude cameras with empty onvif host address

* Refactor filter logic to exclude cameras with empty onvif host address-2

* Apply suggestions from code review

Co-authored-by: Nicolas Mowen <nickmowen213@gmail.com>

---------

Co-authored-by: Nicolas Mowen <nickmowen213@gmail.com>
2023-05-04 18:00:18 -05:00
Sergey Krashevich
2add675d42
Refactor Process Stats and Bugfixes (#6344)
* test refactor process stats

* Update util.py

* bugfix

* black formatting

* add missing processes field to StatsTrackingTypes class

* fix python checks and tests...

* use psutil for calcilate cpu utilization on get_cpu_stats

* black...black...black...

* add cpu average

* calculate statiscts for logger process

* add P-ID for other processes in System.jsx

* Apply suggestions from code review

Co-authored-by: Nicolas Mowen <nickmowen213@gmail.com>

* make page beautiful again :)

---------

Co-authored-by: Nicolas Mowen <nickmowen213@gmail.com>
2023-05-04 17:58:59 -05:00
Nicolas Mowen
ad52e238ce
Refactor events to be more generic (#6320)
* Organize event table to be more generalized

* Add appropriate fields to data

* Move tracked object logic to own function

* Add source type to event queue

* rename enum

* Fix types that are used in webUI

* remove redundant

* Formatting

* fix typing

* Rename enum
2023-04-30 12:07:14 -05:00
Nicolas Mowen
37360edbc1
Show other system processes in system page (#6276) 2023-04-28 07:47:49 -05:00
Nicolas Mowen
b48f6d750f
Add annotation support (#6288) 2023-04-28 06:02:06 -05:00
Blake Blackshear
6dc82b6cef
dependency updates (#6246)
* python

* easy web deps
2023-04-26 06:20:29 -05:00
Nicolas Mowen
43ade86796
Support Controlling PTZ Cameras Via WebUI (#4715)
* Add support for ptz commands via websocket

* Fix startup issues

* Fix bugs

* Set config manually

* Add more commands

* Add presets

* Add zooming

* Fixes

* Set name

* Cleanup

* Add ability to set presets from UI

* Add ability to set preset from UI

* Cleanup for errors

* Ui tweaks

* Add visual design for pan / tilt

* Add pan/tilt support

* Support zooming

* Try to set wsdl

* Fix duplicate logs

* Catch auth errors

* Don't init onvif for disabled cameras

* Fix layout sizing

* Don't comment out

* Fix formatting

* Add ability to control camera with keyboard shortcuts

* Disallow user selection

* Fix mobile pressing

* Remove logs

* Substitute onvif password

* Add ptz controls ot birdseye

* Put wsdl back

* Add padding

* Formatting

* Catch onvif error

* Optimize layout for mobile and web

* Place ptz controls next to birdseye view in large layout

* Fix pt support

* Center text titles

* Update tests

* Update docs

* Write camera docs for PTZ

* Add MQTT docs for PTZ

* Add ptz info docs for http

* Fix test

* Make half width when full screen

* Fix preset panel logic

* Fix parsing

* Update mqtt.md

* Catch preset error

* Add onvif example to docs

* Remove template example from main camera docs
2023-04-26 06:08:53 -05:00
Blake Blackshear
0d16bd0144
False positives (#6217)
* add false positive submission

* switch timeline events to x,y,w,h

* update docs

* fix type checks

* convert to upsert

* fix config test
2023-04-24 07:24:28 -05:00
Nicolas Mowen
7f96d89ec4
Use correct method for retrieving current unix time (#6218) 2023-04-24 05:19:38 -05:00
Nicolas Mowen
04a22f8283
Fix timeline event overlay when recordings mode is not all (#6215)
* Fix case where not all segments are saved in recording for timeline overlay

* Remove unused vars
2023-04-23 15:02:52 -05:00