blakeblackshear.frigate/frigate
Cody Cutrer ef14a43930
optimize frame-per-second calculations (#6887)
* optimize frame-per-second calculations

FPS is never calculated over differing periods for even given
counter. By only storing timestamps within the period that is
used, we avoid having to iterate 1000 entries every time it's
re-calculated (multiple times per second). 1000 entries would
normally only be needed if something is running at 100fps. A
more common speed - anywhere from 5 to 30fps, only needs 50
to 300 entries.

This isn't a huge improvement in the grand scheme, but when motion
detection is disabled, it takes nearly as much time in a flamegraph
as actually transferring the video frame.

* fix python checks
2023-06-28 05:55:53 -05:00
..
comms Add isort and ruff linter (#6575) 2023-05-29 05:31:17 -05:00
detectors Add isort and ruff linter (#6575) 2023-05-29 05:31:17 -05:00
events Performance: multiprocessing improvement (#6936) 2023-06-28 05:39:39 -05:00
images Replace green screen with error message and force camera_fps to 0 (#4544) 2022-11-28 21:47:20 -06:00
motion reduce grid size for contrast improvement (#6870) 2023-06-21 08:38:51 -05:00
record Optimize stacked recordings (#6809) 2023-06-16 07:09:13 -06:00
test use clahe for contrast improvement (#6835) 2023-06-18 11:56:41 -05:00
track Fix max_frames, improve stationary objects in masked areas (#6815) 2023-06-16 07:32:43 -05:00
__init__.py app container and config schema 2021-01-26 21:40:33 -06:00
__main__.py Add isort and ruff linter (#6575) 2023-05-29 05:31:17 -05:00
app.py Performance: multiprocessing improvement (#6936) 2023-06-28 05:39:39 -05:00
config.py reduce grid size for contrast improvement (#6870) 2023-06-21 08:38:51 -05:00
const.py Load labels dynamically for event filters (#6896) 2023-06-28 05:51:53 -05:00
ffmpeg_presets.py Add API and WebUI to export recordings (#6550) 2023-06-08 07:32:35 -04:00
http.py Load labels dynamically for event filters (#6896) 2023-06-28 05:51:53 -05:00
log.py Performance: multiprocessing improvement (#6936) 2023-06-28 05:39:39 -05:00
models.py Optimization of Sync Records: Implementing Pagination and Temporary Table (#6585) 2023-06-11 08:01:50 -05:00
mypy.ini update deps (#6093) 2023-04-15 14:17:59 -05:00
object_detection.py Fix max_frames, improve stationary objects in masked areas (#6815) 2023-06-16 07:32:43 -05:00
object_processing.py Label attributes (#6829) 2023-06-17 09:56:22 -05:00
output.py Rewrite birdseye auto layout (#6818) 2023-06-16 07:35:36 -05:00
plus.py Add isort and ruff linter (#6575) 2023-05-29 05:31:17 -05:00
ptz.py Add isort and ruff linter (#6575) 2023-05-29 05:31:17 -05:00
stats.py Refactor storage stats calculation to use powers of 2 for more accurate values (#6765) 2023-06-11 14:49:13 -05:00
storage.py Refactor storage stats calculation to use powers of 2 for more accurate values (#6765) 2023-06-11 14:49:13 -05:00
timeline.py Performance: multiprocessing improvement (#6936) 2023-06-28 05:39:39 -05:00
types.py Performance: multiprocessing improvement (#6936) 2023-06-28 05:39:39 -05:00
util.py optimize frame-per-second calculations (#6887) 2023-06-28 05:55:53 -05:00
video.py actually keep track of skipped frames (#6889) 2023-06-28 05:53:28 -05:00
watchdog.py Add isort and ruff linter (#6575) 2023-05-29 05:31:17 -05:00