mirror of
https://github.com/linyqh/NarratoAI.git
synced 2025-12-11 18:42:49 +00:00
- 重构 VideoProcessor 类,优化内存使用和性能 - 添加分批处理逻辑,支持大视频文件的处理 - 使用 MiniBatchKMeans 替代 KMeans,减少内存消耗 - 优化镜头边界检测和关键帧提取算法 - 增加日志记录和错误处理,提高程序的健壮性
39 lines
739 B
YAML
39 lines
739 B
YAML
x-common: &common
|
|
build:
|
|
context: .
|
|
dockerfile: Dockerfile
|
|
image: linyq1/narratoai:latest
|
|
volumes:
|
|
- ./:/NarratoAI
|
|
environment:
|
|
- VPN_PROXY_URL=http://host.docker.internal:7890
|
|
- PYTHONUNBUFFERED=1
|
|
- PYTHONMALLOC=malloc
|
|
- OPENCV_OPENCL_RUNTIME=disabled
|
|
- OPENCV_CPU_DISABLE=0
|
|
restart: always
|
|
mem_limit: 4g
|
|
mem_reservation: 2g
|
|
memswap_limit: 6g
|
|
cpus: 2.0
|
|
cpu_shares: 1024
|
|
|
|
services:
|
|
webui:
|
|
<<: *common
|
|
container_name: webui
|
|
ports:
|
|
- "8501:8501"
|
|
command: ["webui"]
|
|
logging:
|
|
driver: "json-file"
|
|
options:
|
|
max-size: "200m"
|
|
max-file: "3"
|
|
tmpfs:
|
|
- /tmp:size=1G
|
|
ulimits:
|
|
nofile:
|
|
soft: 65536
|
|
hard: 65536
|