upload files

This commit is contained in:
Plachta
2023-02-16 15:56:03 +08:00
parent 8d0698261c
commit d60c12e9e5
7 changed files with 356 additions and 29 deletions
+11
View File
@@ -0,0 +1,11 @@
from google.colab import files
import shutil
import os
basepath = os.getcwd()
uploaded = files.upload() # 上传文件
upload_path = "./custom_character_voice/"
if not os.path.exists(upload_path):
os.mkdir(upload_path)
for filename in uploaded.keys():
#将上传的文件移动到指定的位置上
shutil.move(os.path.join(basepath, filename), os.path.join(upload_path, filename))