Skip to content

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