mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-05-09 15:05:26 +03:00
Compare commits
3 Commits
1a09423831
...
42b44485ad
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
42b44485ad | ||
|
|
a182385618 | ||
|
|
317d1acfe1 |
@ -32,11 +32,14 @@ RUN echo /opt/rocm/lib|tee /opt/rocm-dist/etc/ld.so.conf.d/rocm.conf
|
|||||||
FROM deps AS deps-prelim
|
FROM deps AS deps-prelim
|
||||||
|
|
||||||
COPY docker/rocm/debian-backports.sources /etc/apt/sources.list.d/debian-backports.sources
|
COPY docker/rocm/debian-backports.sources /etc/apt/sources.list.d/debian-backports.sources
|
||||||
RUN apt-get update && \
|
# install_deps.sh upgraded libstdc++6 from trixie for Battlemage; the matching
|
||||||
|
# -dev package must also come from trixie or apt refuses to satisfy it.
|
||||||
|
RUN echo "deb http://deb.debian.org/debian trixie main" > /etc/apt/sources.list.d/trixie.list && \
|
||||||
|
apt-get update && \
|
||||||
apt-get install -y libnuma1 && \
|
apt-get install -y libnuma1 && \
|
||||||
apt-get install -qq -y -t bookworm-backports mesa-va-drivers mesa-vulkan-drivers && \
|
apt-get install -qq -y -t bookworm-backports mesa-va-drivers mesa-vulkan-drivers && \
|
||||||
# Install C++ standard library headers for HIPRTC kernel compilation fallback
|
apt-get install -qq -y -t trixie libstdc++-14-dev && \
|
||||||
apt-get install -qq -y libstdc++-12-dev && \
|
rm -f /etc/apt/sources.list.d/trixie.list && \
|
||||||
rm -rf /var/lib/apt/lists/*
|
rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
WORKDIR /opt/frigate
|
WORKDIR /opt/frigate
|
||||||
|
|||||||
@ -40,6 +40,11 @@ from frigate.util.time import get_dst_transitions
|
|||||||
|
|
||||||
logger = logging.getLogger(__name__)
|
logger = logging.getLogger(__name__)
|
||||||
|
|
||||||
|
# Pre-computed constants for resolution-independent datetime-to-epoch conversion
|
||||||
|
# (pandas 3.0+ stores datetime64 as microseconds, not nanoseconds)
|
||||||
|
_EPOCH = pd.Timestamp("1970-01-01")
|
||||||
|
_ONE_SECOND = pd.Timedelta("1s")
|
||||||
|
|
||||||
router = APIRouter(tags=[Tags.review])
|
router = APIRouter(tags=[Tags.review])
|
||||||
|
|
||||||
|
|
||||||
@ -659,7 +664,7 @@ def motion_activity(
|
|||||||
df.iloc[i : i + chunk, 0] = 0.0
|
df.iloc[i : i + chunk, 0] = 0.0
|
||||||
|
|
||||||
# change types for output
|
# change types for output
|
||||||
df.index = df.index.astype(int) // (10**9)
|
df.index = (df.index - _EPOCH) // _ONE_SECOND
|
||||||
normalized = df.reset_index().to_dict("records")
|
normalized = df.reset_index().to_dict("records")
|
||||||
return JSONResponse(content=normalized)
|
return JSONResponse(content=normalized)
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user