ESRGAN-tensorflow icon indicating copy to clipboard operation
ESRGAN-tensorflow copied to clipboard

Choose GPU to use?

Open yl-to opened this issue 5 years ago • 2 comments

Hi, could I add some code at the beginning of train.py to choose which GPU to use? Like set the os.environ.

yl-to avatar Jul 24 '19 21:07 yl-to

As you said, the GPU to use can be set by means of CUDA_VISIBLE_DEVICES environment variable.

e.g. (Inside script) os.environ['CUDA_VISIBLE_DEVICES'] = "0"

or

(outside script) export CUDA_VISIBLE_DEVICES="0"

Later, I will update the code to set GPU by tf.ConfigProto as another option.

hiram64 avatar Jul 25 '19 10:07 hiram64

Is cpu ok?

lzzlxxlsz avatar Dec 11 '19 02:12 lzzlxxlsz