huanx520 commited on
Commit
2053b58
·
1 Parent(s): 99a0b18

refactor v3: proper Docker Space per official docs (user 1000, Gradio 5.x, Python 3.11)

Browse files
Files changed (3) hide show
  1. Dockerfile +19 -2
  2. README.md +3 -21
  3. requirements.txt +1 -0
Dockerfile CHANGED
@@ -1,2 +1,19 @@
1
- # 强制降级 huggingface_hub 到兼容 Gradio 4.x 的版本
2
- RUN pip install --no-cache-dir --force-reinstall "huggingface_hub>=0.24.0,<0.27.0"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ FROM python:3.11-slim
2
+
3
+ RUN apt-get update && apt-get install -y --no-install-recommends \
4
+ ffmpeg git libsndfile1 sox build-essential \
5
+ && rm -rf /var/lib/apt/lists/*
6
+
7
+ RUN useradd -m -u 1000 user
8
+ WORKDIR /code
9
+
10
+ COPY --chown=user requirements.txt .
11
+ RUN pip install --no-cache-dir -r requirements.txt
12
+ RUN pip install --no-cache-dir "gradio>=5.0.0"
13
+
14
+ COPY --chown=user . .
15
+
16
+ USER user
17
+ ENV HOME=/home/user PATH=/home/user/.local/bin:$PATH
18
+
19
+ CMD ["python", "app.py"]
README.md CHANGED
@@ -1,22 +1,4 @@
1
  ---
2
- title: GPT-SoVITS 达妮娅语音训练
3
- emoji: 🎤
4
- colorFrom: purple
5
- colorTo: pink
6
- sdk: gradio
7
- sdk_version: 4.44.1
8
- app_file: app.py
9
- pinned: false
10
- license: mit
11
- ---
12
-
13
- # 🎤 GPT-SoVITS 训练 - 达妮娅语音
14
-
15
- 数据集: https://huggingface.co/datasets/huanx/daniya-voice-gptsovits
16
-
17
- ## 使用步骤
18
-
19
- 1. 点击 **"1. 设置训练环境"** 安装依赖
20
- 2. 点击 **"2. 下载数据集"** 从 Hugging Face 拉取数据
21
- 3. 点击 **"3. 准备训练数据"** 整理格式
22
- 4. 调整训练参数后点击 **"4. 开始训练"**
 
1
  ---
2
+ sdk: docker
3
+ app_port: 7860
4
+ ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
requirements.txt CHANGED
@@ -1,3 +1,4 @@
 
1
  pandas>=2.0.0
2
  soundfile>=0.12.0
3
  librosa>=0.10.0
 
1
+ huggingface_hub>=0.25.0
2
  pandas>=2.0.0
3
  soundfile>=0.12.0
4
  librosa>=0.10.0