TurboDiffusion icon indicating copy to clipboard operation
TurboDiffusion copied to clipboard

4090 - 24G出现 OOM

Open yy99299 opened this issue 10 months ago • 3 comments

使用4090显卡进行720p的推理时,报错OOM,使用的torch为2.8.0,这张显卡上我还有一个380MB的显存被其他进程给占用,和这个有关系吗?

Image

yy99299 avatar Jan 05 '26 09:01 yy99299

建议参考 https://github.com/thu-ml/TurboDiffusion/issues/6 和 https://github.com/thu-ml/TurboDiffusion/issues/61. 24G 显存推理 720p 应该是比较极限的, 如果有额外占用有概率会失败

whx1003 avatar Jan 05 '26 23:01 whx1003

HI, 4090 的卡你是通过什么方式安装的,进行 pip install turbodiffusion --no-build-isolation 时有 类似这样的报错吗 nvcc fatal : Unsupported gpu architecture 'compute_120a' ninja: build stopped: subcommand failed.

lifei160177 avatar Jan 07 '26 09:01 lifei160177

[5/5] /usr/local/cuda-12.4/bin/nvcc --generate-dependencies-with-compile --dependency-output /tmp/pip-install-mdch8p6u/turbodiffusion_56f05382417943d5823fbee3ef0cf52e/build/temp.linux-x86_64-cpython-312/turbodiffusion/ops/quant/quant.o.d -I/tmp/pip-install-mdch8p6u/turbodiffusion_56f05382417943d5823fbee3ef0cf52e/turbodiffusion/ops/cutlass/include -I/tmp/pip-install-mdch8p6u/turbodiffusion_56f05382417943d5823fbee3ef0cf52e/turbodiffusion/ops/cutlass/tools/util/include -I/tmp/pip-install-mdch8p6u/turbodiffusion_56f05382417943d5823fbee3ef0cf52e/turbodiffusion/ops -I/home/tubor/lib/python3.12/site-packages/torch/include -I/home/tubor/lib/python3.12/site-packages/torch/include/torch/csrc/api/include -I/home/tubor/lib/python3.12/site-packages/torch/include/TH -I/home/tubor/lib/python3.12/site-packages/torch/include/THC -I/usr/local/cuda-12.4/include -I/home/tubor/include -I/usr/include/python3.12 -c -c /tmp/pip-install-mdch8p6u/turbodiffusion_56f05382417943d5823fbee3ef0cf52e/turbodiffusion/ops/quant/quant.cu -o /tmp/pip-install-mdch8p6u/turbodiffusion_56f05382417943d5823fbee3ef0cf52e/build/temp.linux-x86_64-cpython-312/turbodiffusion/ops/quant/quant.o -D__CUDA_NO_HALF_OPERATORS__ -D__CUDA_NO_HALF_CONVERSIONS__ -D__CUDA_NO_BFLOAT16_CONVERSIONS__ -D__CUDA_NO_HALF2_OPERATORS__ --expt-relaxed-constexpr --compiler-options ''"'"'-fPIC'"'"'' -O3 -std=c++17 -U__CUDA_NO_HALF_OPERATORS__ -U__CUDA_NO_HALF_CONVERSIONS__ -U__CUDA_NO_BFLOAT16_OPERATORS__ -U__CUDA_NO_BFLOAT16_CONVERSIONS__ -U__CUDA_NO_BFLOAT162_OPERATORS__ -U__CUDA_NO_BFLOAT162_CONVERSIONS__ --expt-relaxed-constexpr --expt-extended-lambda --use_fast_math --ptxas-options=--verbose,--warn-on-local-memory-usage -lineinfo -DCUTLASS_DEBUG_TRACE_LEVEL=0 -DNDEBUG -Xcompiler -fPIC -DEXECMODE=0 -gencode arch=compute_120a,code=sm_120a -gencode arch=compute_90,code=sm_90 -gencode arch=compute_89,code=sm_89 -gencode arch=compute_80,code=sm_80 --threads 4 -DTORCH_API_INCLUDE_EXTENSION_H '-DPYBIND11_COMPILER_TYPE="gcc"' '-DPYBIND11_STDLIB="libstdcpp"' '-DPYBIND11_BUILD_ABI="cxxabi1011"' -DTORCH_EXTENSION_NAME=turbo_diffusion_ops -D_GLIBCXX_USE_CXX11_ABI=0 FAILED: [code=1] /tmp/pip-install-mdch8p6u/turbodiffusion_56f05382417943d5823fbee3ef0cf52e/build/temp.linux-x86_64-cpython-312/turbodiffusion/ops/quant/quant.o /usr/local/cuda-12.4/bin/nvcc --generate-dependencies-with-compile --dependency-output /tmp/pip-install-mdch8p6u/turbodiffusion_56f05382417943d5823fbee3ef0cf52e/build/temp.linux-x86_64-cpython-312/turbodiffusion/ops/quant/quant.o.d -I/tmp/pip-install-mdch8p6u/turbodiffusion_56f05382417943d5823fbee3ef0cf52e/turbodiffusion/ops/cutlass/include -I/tmp/pip-install-mdch8p6u/turbodiffusion_56f05382417943d5823fbee3ef0cf52e/turbodiffusion/ops/cutlass/tools/util/include -I/tmp/pip-install-mdch8p6u/turbodiffusion_56f05382417943d5823fbee3ef0cf52e/turbodiffusion/ops -I/home/tubor/lib/python3.12/site-packages/torch/include -I/home/tubor/lib/python3.12/site-packages/torch/include/torch/csrc/api/include -I/home/tubor/lib/python3.12/site-packages/torch/include/TH -I/home/tubor/lib/python3.12/site-packages/torch/include/THC -I/usr/local/cuda-12.4/include -I/home/tubor/include -I/usr/include/python3.12 -c -c /tmp/pip-install-mdch8p6u/turbodiffusion_56f05382417943d5823fbee3ef0cf52e/turbodiffusion/ops/quant/quant.cu -o /tmp/pip-install-mdch8p6u/turbodiffusion_56f05382417943d5823fbee3ef0cf52e/build/temp.linux-x86_64-cpython-312/turbodiffusion/ops/quant/quant.o -D__CUDA_NO_HALF_OPERATORS -D__CUDA_NO_HALF_CONVERSIONS_ -D__CUDA_NO_BFLOAT16_CONVERSIONS__ -D__CUDA_NO_HALF2_OPERATORS__ --expt-relaxed-constexpr --compiler-options ''"'"'-fPIC'"'"'' -O3 -std=c++17 -U__CUDA_NO_HALF_OPERATORS__ -U__CUDA_NO_HALF_CONVERSIONS__ -U__CUDA_NO_BFLOAT16_OPERATORS__ -U__CUDA_NO_BFLOAT16_CONVERSIONS__ -U__CUDA_NO_BFLOAT162_OPERATORS__ -U__CUDA_NO_BFLOAT162_CONVERSIONS__ --expt-relaxed-constexpr --expt-extended-lambda --use_fast_math --ptxas-options=--verbose,--warn-on-local-memory-usage -lineinfo -DCUTLASS_DEBUG_TRACE_LEVEL=0 -DNDEBUG -Xcompiler -fPIC -DEXECMODE=0 -gencode arch=compute_120a,code=sm_120a -gencode arch=compute_90,code=sm_90 -gencode arch=compute_89,code=sm_89 -gencode arch=compute_80,code=sm_80 --threads 4 -DTORCH_API_INCLUDE_EXTENSION_H '-DPYBIND11_COMPILER_TYPE="_gcc"' '-DPYBIND11_STDLIB="_libstdcpp"' '-DPYBIND11_BUILD_ABI="_cxxabi1011"' -DTORCH_EXTENSION_NAME=turbo_diffusion_ops -D_GLIBCXX_USE_CXX11_ABI=0 nvcc fatal : Unsupported gpu architecture 'compute_120a' ninja: build stopped: subcommand failed. Traceback (most recent call last): File "/home/tubor/lib/python3.12/site-packages/torch/utils/cpp_extension.py", line 2209, in _run_ninja_build subprocess.run( File "/usr/lib/python3.12/subprocess.py", line 571, in run raise CalledProcessError(retcode, process.args, subprocess.CalledProcessError: Command '['ninja', '-v']' returned non-zero exit status 1.

lifei160177 avatar Jan 07 '26 09:01 lifei160177