Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update CPU-only support for building the project. 更新对仅CPU构建的支持 #1214

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Tianyuan-Wang
Copy link

Setup.py adds CUDA extensions based on whether there is a GPU or not. If not presented, add CPU extensions only. Also added exception handling for module importing where error may occur.

在setup.py中添加了判断有没有GPU以决定是否添加GPU相关扩展。将nms_cpu的构建工具改为torch.utils.cpp_extensionCppExtension。在使用构建的模块的地方添加了try-except以防止程序因找不到模块而中断。

Setup.py adds CUDA extensions based on whether there is a GPU or not. If not presented, add CPU extensions only. Also added exception handling for module importing where error may occur.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant