Miscellaneous fixes (0.17 beta) (#21867)
CI / ARM Build (push) Waiting to run
CI / Jetson Jetpack 6 (push) Waiting to run
CI / AMD64 Extra Build (push) Blocked by required conditions
CI / ARM Extra Build (push) Blocked by required conditions
CI / Synaptics Build (push) Blocked by required conditions
CI / Assemble and push default build (push) Blocked by required conditions
CI / AMD64 Build (push) Waiting to run

* Adjust title prompt to have less rigidity

* Improve motion boxes handling for features that don't require motion

* Improve handling of classes starting with digits

* Improve vehicle nuance

* tweak lpr docs

* Improve grammar

* Don't allow # in face name

* add password requirements to new user dialog

* change password requirements

* Clenaup

---------

Co-authored-by: Josh Hawkins <32435876+hawkeye217@users.noreply.github.com>
This commit is contained in:
Nicolas Mowen
2026-02-03 08:31:00 -06:00
committed by GitHub
co-authored by Josh Hawkins
parent e4fe021279
commit 2d83992284
17 changed files with 256 additions and 145 deletions
+5 -2
View File
@@ -129,7 +129,9 @@ def get_ffmpeg_arg_list(arg: Any) -> list:
return arg if isinstance(arg, list) else shlex.split(arg)
def load_labels(path: Optional[str], encoding="utf-8", prefill=91):
def load_labels(
path: Optional[str], encoding="utf-8", prefill=91, indexed: bool | None = None
):
"""Loads labels from file (with or without index numbers).
Args:
path: path to label file.
@@ -146,11 +148,12 @@ def load_labels(path: Optional[str], encoding="utf-8", prefill=91):
if not lines:
return {}
if lines[0].split(" ", maxsplit=1)[0].isdigit():
if indexed != False and lines[0].split(" ", maxsplit=1)[0].isdigit():
pairs = [line.split(" ", maxsplit=1) for line in lines]
labels.update({int(index): label.strip() for index, label in pairs})
else:
labels.update({index: line.strip() for index, line in enumerate(lines)})
return labels