mxivideo/scripts/install_scenedetect_simple.sh

31 lines
827 B
Bash
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#!/bin/bash
# 简单的PySceneDetect安装脚本
echo "🎬 安装PySceneDetect..."
# 安装PySceneDetect
pip install scenedetect[opencv]
if [ $? -eq 0 ]; then
echo "✅ PySceneDetect安装成功"
# 验证安装
echo "🧪 验证安装..."
python -c "import scenedetect; print(f'PySceneDetect版本: {scenedetect.__version__}')"
if [ $? -eq 0 ]; then
echo "✅ PySceneDetect验证成功"
echo ""
echo "🚀 现在可以使用改进的场景检测功能了:"
echo "- 重新导入视频将使用PySceneDetect进行更准确的分镜"
echo "- 如果PySceneDetect不可用系统会自动回退到OpenCV方法"
else
echo "❌ PySceneDetect验证失败"
exit 1
fi
else
echo "❌ PySceneDetect安装失败"
exit 1
fi