1
+ @ echo off && chcp 65001
2
+
3
+ echo working dir is %cd%
4
+ echo downloading requirement aria2 check.
5
+ echo=
6
+ dir /a:d/b | findstr " aria2" > flag.txt
7
+ findstr " aria2" flag.txt > nul
8
+ if %errorlevel% == 0 (
9
+ echo aria2 checked.
10
+ echo=
11
+ ) else (
12
+ echo failed. please downloading aria2 from webpage!
13
+ echo unzip it and put in this directory!
14
+ timeout /T 5
15
+ start https://github.com/aria2/aria2/releases/tag/release-1.36.0
16
+ echo=
17
+ goto end
18
+ )
19
+
20
+ echo envfiles checking start.
21
+ echo=
22
+
23
+ for /f %%x in ('findstr /i /c:" aria2" " flag.txt" ') do (set aria2=%%x )& goto endSch
24
+ :endSch
25
+
26
+ set d32 = f0D32k.pth
27
+ set d40 = f0D40k.pth
28
+ set d48 = f0D48k.pth
29
+ set g32 = f0G32k.pth
30
+ set g40 = f0G40k.pth
31
+ set g48 = f0G48k.pth
32
+
33
+ set dld32 = https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained/f0D32k.pth
34
+ set dld40 = https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained/f0D40k.pth
35
+ set dld48 = https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained/f0D48k.pth
36
+ set dlg32 = https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained/f0G32k.pth
37
+ set dlg40 = https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained/f0G40k.pth
38
+ set dlg48 = https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained/f0G48k.pth
39
+
40
+ set hp2 = HP2-人声vocals+非人声instrumentals.pth
41
+ set hp5 = HP5-主旋律人声vocals+其他instrumentals.pth
42
+
43
+ set dlhp2 = https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/uvr5_weights/HP2-人声vocals+非人声instrumentals.pth
44
+ set dlhp5 = https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/uvr5_weights/HP5-主旋律人声vocals+其他instrumentals.pth
45
+
46
+ set hb = hubert_base.pt
47
+
48
+ set dlhb = https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/hubert_base.pt
49
+
50
+ echo dir check start.
51
+ echo=
52
+
53
+ if exist " %~dp0 pretrained" (
54
+ echo dir .\pretrained checked.
55
+ ) else (
56
+ echo failed. generating dir .\pretrained.
57
+ mkdir pretrained
58
+ )
59
+ if exist " %~dp0 uvr5_weights" (
60
+ echo dir .\uvr5_weights checked.
61
+ ) else (
62
+ echo failed. generating dir .\uvr5_weights.
63
+ mkdir uvr5_weights
64
+ )
65
+
66
+ echo=
67
+ echo dir check finished.
68
+
69
+ echo=
70
+ echo required files check start.
71
+
72
+ echo checking D32k.pth
73
+ if exist " %~dp0 pretrained\D32k.pth" (
74
+ echo D32k.pth in .\pretrained checked.
75
+ echo=
76
+ ) else (
77
+ echo failed. starting download from huggingface.
78
+ %~dp0 %aria2% \aria2c --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained/D32k.pth -d %~dp0 pretrained -o D32k.pth
79
+ if exist " %~dp0 pretrained\D32k.pth" (echo download successful.) else (echo please try again!
80
+ echo=)
81
+ )
82
+ echo checking D40k.pth
83
+ if exist " %~dp0 pretrained\D40k.pth" (
84
+ echo D40k.pth in .\pretrained checked.
85
+ echo=
86
+ ) else (
87
+ echo failed. starting download from huggingface.
88
+ %~dp0 %aria2% \aria2c --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained/D40k.pth -d %~dp0 pretrained -o D40k.pth
89
+ if exist " %~dp0 pretrained\D40k.pth" (echo download successful.) else (echo please try again!
90
+ echo=)
91
+ )
92
+ echo checking D48k.pth
93
+ if exist " %~dp0 pretrained\D48k.pth" (
94
+ echo D48k.pth in .\pretrained checked.
95
+ echo=
96
+ ) else (
97
+ echo failed. starting download from huggingface.
98
+ %~dp0 %aria2% \aria2c --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained/D48k.pth -d %~dp0 pretrained -o D48k.pth
99
+ if exist " %~dp0 pretrained\D48k.pth" (echo download successful.) else (echo please try again!
100
+ echo=)
101
+ )
102
+ echo checking G32k.pth
103
+ if exist " %~dp0 pretrained\G32k.pth" (
104
+ echo G32k.pth in .\pretrained checked.
105
+ echo=
106
+ ) else (
107
+ echo failed. starting download from huggingface.
108
+ %~dp0 %aria2% \aria2c --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained/G32k.pth -d %~dp0 pretrained -o G32k.pth
109
+ if exist " %~dp0 pretrained\G32k.pth" (echo download successful.) else (echo please try again!
110
+ echo=)
111
+ )
112
+ echo checking G40k.pth
113
+ if exist " %~dp0 pretrained\G40k.pth" (
114
+ echo G40k.pth in .\pretrained checked.
115
+ echo=
116
+ ) else (
117
+ echo failed. starting download from huggingface.
118
+ %~dp0 %aria2% \aria2c --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained/G40k.pth -d %~dp0 pretrained -o G40k.pth
119
+ if exist " %~dp0 pretrained\G40k.pth" (echo download successful.) else (echo please try again!
120
+ echo=)
121
+ )
122
+ echo checking G48k.pth
123
+ if exist " %~dp0 pretrained\G48k.pth" (
124
+ echo G48k.pth in .\pretrained checked.
125
+ echo=
126
+ ) else (
127
+ echo failed. starting download from huggingface.
128
+ %~dp0 %aria2% \aria2c --console-log-level=error -c -x 16 -s 16 -k 1M https://huggingface.co/lj1995/VoiceConversionWebUI/resolve/main/pretrained/G48k.pth -d %~dp0 pretrained -o G48k.pth
129
+ if exist " %~dp0 pretrained\G48k.pth" (echo download successful.) else (echo please try again!
130
+ echo=)
131
+ )
132
+
133
+ echo checking %d32%
134
+ if exist " %~dp0 pretrained\%d32% " (
135
+ echo %d32% in .\pretrained checked.
136
+ echo=
137
+ ) else (
138
+ echo failed. starting download from huggingface.
139
+ %~dp0 %aria2% \aria2c --console-log-level=error -c -x 16 -s 16 -k 1M %dld32% -d %~dp0 pretrained -o %d32%
140
+ if exist " %~dp0 pretrained\%d32% " (echo download successful.) else (echo please try again!
141
+ echo=)
142
+ )
143
+ echo checking %d40%
144
+ if exist " %~dp0 pretrained\%d40% " (
145
+ echo %d40% in .\pretrained checked.
146
+ echo=
147
+ ) else (
148
+ echo failed. starting download from huggingface.
149
+ %~dp0 %aria2% \aria2c --console-log-level=error -c -x 16 -s 16 -k 1M %dld40% -d %~dp0 pretrained -o %d40%
150
+ if exist " %~dp0 pretrained\%d40% " (echo download successful.) else (echo please try again!
151
+ echo=)
152
+ )
153
+ echo checking %d48%
154
+ if exist " %~dp0 pretrained\%d48% " (
155
+ echo %d48% in .\pretrained checked.
156
+ echo=
157
+ ) else (
158
+ echo failed. starting download from huggingface.
159
+ %~dp0 %aria2% \aria2c --console-log-level=error -c -x 16 -s 16 -k 1M %dld48% -d %~dp0 pretrained -o %d48%
160
+ if exist " %~dp0 pretrained\%d48% " (echo download successful.) else (echo please try again!
161
+ echo=)
162
+ )
163
+ echo checking %g32%
164
+ if exist " %~dp0 pretrained\%g32% " (
165
+ echo %g32% in .\pretrained checked.
166
+ echo=
167
+ ) else (
168
+ echo failed. starting download from huggingface.
169
+ %~dp0 %aria2% \aria2c --console-log-level=error -c -x 16 -s 16 -k 1M %dlg32% -d %~dp0 pretrained -o %g32%
170
+ if exist " %~dp0 pretrained\%g32% " (echo download successful.) else (echo please try again!
171
+ echo=)
172
+ )
173
+ echo checking %g40%
174
+ if exist " %~dp0 pretrained\%g40% " (
175
+ echo %g40% in .\pretrained checked.
176
+ echo=
177
+ ) else (
178
+ echo failed. starting download from huggingface.
179
+ %~dp0 %aria2% \aria2c --console-log-level=error -c -x 16 -s 16 -k 1M %dlg40% -d %~dp0 pretrained -o %g40%
180
+ if exist " %~dp0 pretrained\%g40% " (echo download successful.) else (echo please try again!
181
+ echo=)
182
+ )
183
+ echo checking %g48%
184
+ if exist " %~dp0 pretrained\%g48% " (
185
+ echo %g48% in .\pretrained checked.
186
+ echo=
187
+ ) else (
188
+ echo failed. starting download from huggingface.
189
+ %~dp0 %aria2% \aria2c --console-log-level=error -c -x 16 -s 16 -k 1M %dlg48% -d %~dp0 \pretrained -o %g48%
190
+ if exist " %~dp0 pretrained\%g48% " (echo download successful.) else (echo please try again!
191
+ echo=)
192
+ )
193
+
194
+ echo checking %hp2%
195
+ if exist " %~dp0 uvr5_weights\%hp2% " (
196
+ echo %hp2% in .\uvr5_weights checked.
197
+ echo=
198
+ ) else (
199
+ echo failed. starting download from huggingface.
200
+ %~dp0 %aria2% \aria2c --console-log-level=error -c -x 16 -s 16 -k 1M %dlhp2% -d %~dp0 \uvr5_weights -o %hp2%
201
+ if exist " %~dp0 uvr5_weights\%hp2% " (echo download successful.) else (echo please try again!
202
+ echo=)
203
+ )
204
+ echo checking %hp5%
205
+ if exist " %~dp0 uvr5_weights\%hp5% " (
206
+ echo %hp5% in .\uvr5_weights checked.
207
+ echo=
208
+ ) else (
209
+ echo failed. starting download from huggingface.
210
+ %~dp0 %aria2% \aria2c --console-log-level=error -c -x 16 -s 16 -k 1M %dlhp5% -d %~dp0 \uvr5_weights -o %HP5%
211
+ if exist " %~dp0 uvr5_weights\%hp5% " (echo download successful.) else (echo please try again!
212
+ echo=)
213
+ )
214
+
215
+ echo checking %hb%
216
+ if exist " %~dp0 %hb% " (
217
+ echo %hb% in .\pretrained checked.
218
+ echo=
219
+ ) else (
220
+ echo failed. starting download from huggingface.
221
+ %~dp0 %aria2% \aria2c --console-log-level=error -c -x 16 -s 16 -k 1M %dlhb% -d %~dp0 -o %hb%
222
+ if exist " %~dp0 %hb% " (echo download successful.) else (echo please try again!
223
+ echo=)
224
+ )
225
+
226
+ echo required files check finished.
227
+ echo envfiles check complete.
228
+ pause
229
+ :end
230
+ del flag.txt
0 commit comments