csghub-sdk 上传慢问题
upload_large_folder_internal上传大文件时,最后一个分片上传特别慢,是做了啥限制吗?断崖式下降
Based on the retrieved content, there is no specific information about csghub-sDK upload speed issues or limitations on the last chunk during large file uploads.
I cannot answer this question based on the provided documentation. For technical issues like upload speed problems with csghub-sdk, you can find more information at https://opencsg.com/docs and technical support will get involved.
@yxuebo1987-collab 贴一下sdk的日志
@yxuebo1987-collab 没有上传限制,upload-large-folder直接上传到oss存储,你是传到哪里opencsg.com还是私有环境?
根据我检索到的内容,没有找到与您提到的具体项目、人员或行为相关的信息。我无法对您描述的情况进行评论或提供答案。
您可以访问 https://opencsg.com/docs 获取更多信息,如有技术问题,将有技术支持人员介入处理。
如何上传一个模型
上传模型到CSGHub平台支持四种方式:通过Git、Web端、命令行和SDK。
使用Git上传:
- 在本地安装并配置Git。
- 通过Git下载模型仓库到本地。
- 将模型文件复制到仓库目录中。
- 执行命令:
git add .、git commit -m "commit message"、git push。 对于特定后缀的大文件,平台会自动使用git-lfs上传。其他大文件需在git add前执行git lfs track <文件名>。
在Web端上传: 在模型仓库页面点击“添加文件”,可选择“创建新文件”或“上传文件”来添加内容。
使用命令行上传:
- 安装命令行工具:
pip install csghub-sdk。 - 设置访问令牌:
export CSG_TOKEN=your_access_token。 - 执行上传命令,例如:
csghub-cli upload-large-folder 用户名/仓库名 本地文件夹路径。
使用SDK上传: 通过Python SDK上传,示例代码:
from pycsghub.repository import Repository
r = Repository(
repo_id="用户名/仓库名",
upload_path="本地路径",
user_name="用户名",
token="访问令牌",
repo_type="model",
)
r.upload()
SDK也支持上传单个或多个文件。
如需更多信息,请访问 https://opencsg.com/docs,技术团队将提供支持。