ChatGLM-6B icon indicating copy to clipboard operation
ChatGLM-6B copied to clipboard

为什么量化后指定不了哪一块儿显卡,运行还是占用第0块儿

Open shangzhensen opened this issue 2 years ago • 3 comments
trafficstars

Is your feature request related to a problem? Please describe.

image

Solutions

1

Additional context

No response

shangzhensen avatar Mar 16 '23 08:03 shangzhensen

try this, add them to the top of your code

import os os.environ['CUDA_VISIBLE_DEVICES'] = '1'

TangYuan96 avatar Mar 16 '23 09:03 TangYuan96

try this, add them to the top of your code

import os os.environ['CUDA_VISIBLE_DEVICES'] = '1'

Is there any way to run the model on 2 gpus?

zxcvbn114514 avatar Mar 20 '23 13:03 zxcvbn114514

import os os.environ['CUDA_VISIBLE_DEVICES'] = '1,2'

@zxcvbn114514

try this, add them to the top of your code import os os.environ['CUDA_VISIBLE_DEVICES'] = '1'

Is there any way to run the model on 2 gpus?

SCAUapc avatar Mar 21 '23 07:03 SCAUapc

import os os.environ['CUDA_VISIBLE_DEVICES'] = '1,2'

@zxcvbn114514

try this, add them to the top of your code import os os.environ['CUDA_VISIBLE_DEVICES'] = '1'

Is there any way to run the model on 2 gpus?

It's not working.The model simply runs at the second gpu after I add the code.

zxcvbn114514 avatar Apr 02 '23 08:04 zxcvbn114514