set_gpu

static Config.set_gpu(gpu_id)

Set the visible GPU device by setting the CUDA_VISIBLE_DEVICES environment variable.

Warning

Set it before calling Config.set_platform('gpu').

Parameters:

gpu_id (int) – A single GPU ID.