Giter VIP home page Giter VIP logo

Comments (7)

tianyu06030020 avatar tianyu06030020 commented on July 27, 2024

你好, 编译的时候报cublas_device找不到,具体如下:

Environment

TensorRT Version: 7.2.3.4
CUDA Version: 10.2
CUDNN Version: 7.4
Operating System: ubuntu18.04
Python Version (if applicable): 3.7
PyTorch Version (if applicable): 1.8
错误信息:
[ 97%] Linking CXX shared library ../../bin/libfwd_torch.so
[ 97%] Built target fwd_torch
Scanning dependencies of target forward
[ 98%] Building CXX object source/py_fwd/CMakeFiles/forward.dir/py_forward.cpp.o
[100%] Linking CXX shared module ../../bin/forward.cpython-37m-x86_64-linux-gnu.so
/usr/bin/x86_64-linux-gnu-ld: cannot find -lCUDA_cublas_device_LIBRARY-NOTFOUND
collect2: error: ld returned 1 exit status
source/py_fwd/CMakeFiles/forward.dir/build.make:117: recipe for target 'bin/forward.cpython-37m-x86_64-linux-gnu.so' failed
make[2]: *** [bin/forward.cpython-37m-x86_64-linux-gnu.so] Error 1
CMakeFiles/Makefile2:687: recipe for target 'source/py_fwd/CMakeFiles/forward.dir/all' failed
make[1]: *** [source/py_fwd/CMakeFiles/forward.dir/all] Error 2
Makefile:83: recipe for target 'all' failed
cublas_device这个库找不到,cuda10以后这个库就废弃了吧。

这个问题我解决了,是cmake版本比较低,升级一下就可以了。

最后生成了python库,但是我导入的时候,报错了:
ImportError: forward.cpython-37m-x86_64-linux-gnu.so: undefined symbol: _ZN5torch3jit8toIValueEN8pybind116handleERKSt10shared_ptrIN3c104TypeEENS4_8optionalIiEE

from forward.

yuanzexi avatar yuanzexi commented on July 27, 2024

你的 CMAKE 命令是怎样的呢?以及 CMake 的 Output 信息方便提供一下吗?

from forward.

tianyu06030020 avatar tianyu06030020 commented on July 27, 2024

你的 CMAKE 命令是怎样的呢?以及 CMake 的 Output 信息方便提供一下吗?

谢谢回复,这个我也解决了,pytorch版本的问题。但是我模型转换engine的时候遇到问题了:

2021-06-17 10:12:21,342 INFO [default] TrtActivationDesc::CreateLayer
2021-06-17 10:12:21,342 INFO [default] TrtOutputDesc::CreateLayer
2021-06-17 10:12:21,342 INFO [default] maxWorkSpaceSize = 1073741824
2021-06-17 10:12:27,247 INFO [default] [TRT] Some tactics do not have sufficient workspace memory to run. Increasing workspace size may increase performance, please check verbose output.
2021-06-17 10:12:40,996 FATAL [default] [TRT] Assertion failed: cublasStatus == CUBLAS_STATUS_SUCCESS
../rtSafe/cublas/cublasLtWrapper.cpp:279
Aborting...
2021-06-17 10:12:40,997 WARN [default] Aborting application. Reason: Fatal log at [project/Forward/source/trt_engine/trt_common/trt_logger.cpp:58]
Aborted (core dumped)

这个看不出哪里出错了

from forward.

tianyu06030020 avatar tianyu06030020 commented on July 27, 2024

你的 CMAKE 命令是怎样的呢?以及 CMake 的 Output 信息方便提供一下吗?

谢谢回复,这个我也解决了,pytorch版本的问题。但是我模型转换engine的时候遇到问题了:

2021-06-17 10:12:21,342 INFO [default] TrtActivationDesc::CreateLayer
2021-06-17 10:12:21,342 INFO [default] TrtOutputDesc::CreateLayer
2021-06-17 10:12:21,342 INFO [default] maxWorkSpaceSize = 1073741824
2021-06-17 10:12:27,247 INFO [default] [TRT] Some tactics do not have sufficient workspace memory to run. Increasing workspace size may increase performance, please check verbose output.
2021-06-17 10:12:40,996 FATAL [default] [TRT] Assertion failed: cublasStatus == CUBLAS_STATUS_SUCCESS
../rtSafe/cublas/cublasLtWrapper.cpp:279
Aborting...
2021-06-17 10:12:40,997 WARN [default] Aborting application. Reason: Fatal log at [project/Forward/source/trt_engine/trt_common/trt_logger.cpp:58]
Aborted (core dumped)

这个看不出哪里出错了

btw: 我转换的模型就是pix2pix_hd模型!!

from forward.

yuanzexi avatar yuanzexi commented on July 27, 2024

@tianyu06030020 这个应该是 CUDA 10.2 的 CUBLAS 需要打两个补丁。 https://developer.nvidia.com/cuda-10.2-download-archive?target_os=Windows&target_arch=x86_64&target_version=10&target_type=exelocal
直接下载的 CUDA 10.2.89 版本在对 CublasLt 的支持上有问题。需要打补丁支持。
image

from forward.

tianyu06030020 avatar tianyu06030020 commented on July 27, 2024

@tianyu06030020 这个应该是 CUDA 10.2 的 CUBLAS 需要打两个补丁。 https://developer.nvidia.com/cuda-10.2-download-archive?target_os=Windows&target_arch=x86_64&target_version=10&target_type=exelocal
直接下载的 CUDA 10.2.89 版本在对 CublasLt 的支持上有问题。需要打补丁支持。
image

@yuanzexi 非常感谢,装了补丁之后可以转成功了,但是加速不太明显,v100上大概只有10%左右的提升。请问,你们对GAN网络有测试过加速性能吗。

from forward.

yuanzexi avatar yuanzexi commented on July 27, 2024

@tianyu06030020 这个应该是 CUDA 10.2 的 CUBLAS 需要打两个补丁。 https://developer.nvidia.com/cuda-10.2-download-archive?target_os=Windows&target_arch=x86_64&target_version=10&target_type=exelocal
直接下载的 CUDA 10.2.89 版本在对 CublasLt 的支持上有问题。需要打补丁支持。
image

@yuanzexi 非常感谢,装了补丁之后可以转成功了,但是加速不太明显,v100上大概只有10%左右的提升。请问,你们对GAN网络有测试过加速性能吗。

@tianyu06030020 FP32 模式加速可能只有 10 %左右,你可以试试看 FP16 和 int8 的加速。应该会加速明显一些。

from forward.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.