Two GPUs

Discussion of anything and everything relating to chess playing software and machines.

Moderators: hgm, Harvey Williamson, bob

Forum rules
This textbox is used to restore diagrams posted with the [d] tag before the upgrade.
Post Reply
Werewolf
Posts: 1183
Joined: Thu Sep 18, 2008 8:24 pm

Two GPUs

Post by Werewolf » Thu Jan 17, 2019 6:55 pm

Just trying an experiment with Lc0.

To use two graphics cards, should they be set to run in SLI or independently?

Thanks

smatovic
Posts: 775
Joined: Wed Mar 10, 2010 9:18 pm
Location: Hamburg, Germany
Full name: Srdja Matovic
Contact:

Re: Two GPUs

Post by smatovic » Thu Jan 17, 2019 7:12 pm

Werewolf wrote:
Thu Jan 17, 2019 6:55 pm
Just trying an experiment with Lc0.

To use two graphics cards, should they be set to run in SLI or independently?

Thanks
SLI has only effect for rendering graphics in video games,
so you do not need to set up SLI for Cuda or OpenCL.

--
Srdja

Javier Ros
Posts: 181
Joined: Fri Oct 12, 2012 10:48 am
Location: Seville (SPAIN)
Full name: Javier Ros

Re: Two GPUs

Post by Javier Ros » Thu Jan 17, 2019 11:04 pm

Werewolf wrote:
Thu Jan 17, 2019 6:55 pm
Just trying an experiment with Lc0.

To use two graphics cards, should they be set to run in SLI or independently?

Thanks
You must choose which GPU to use, or both, gpu=0 is for the first GPU and gpu=1 the second, for example in Cutechess

-engine name="Lc0201_32644" cmd="lc0.exe" option.Threads=4 nodes=8000 option.Backend=multiplexing option.BackendOptions="(backend=cudnn,gpu=0),(backend=cudnn,gpu=1)"

for use both GPU in Arena you must set:

Backend: Multiplexing
BackendOptions: (backend=cudnn,gpu=0),(backend=cudnn,gpu=1)
The love relationship between a chess engine tester and his computer can be summarized in one sentence:
Until heat do us part.

Werewolf
Posts: 1183
Joined: Thu Sep 18, 2008 8:24 pm

Re: Two GPUs

Post by Werewolf » Fri Jan 18, 2019 8:46 am

Javier Ros wrote:
Thu Jan 17, 2019 11:04 pm


for use both GPU in Arena you must set:

Backend: Multiplexing
BackendOptions: (backend=cudnn,gpu=0),(backend=cudnn,gpu=1)
For the RTX cards presumably it'd look like this:

Backend: Multiplexing
BackendOptions: (backend=cudnn-fp16,gpu=0),(backend=cudnn-fp16,gpu=1)

Javier Ros
Posts: 181
Joined: Fri Oct 12, 2012 10:48 am
Location: Seville (SPAIN)
Full name: Javier Ros

Re: Two GPUs

Post by Javier Ros » Fri Jan 18, 2019 9:00 am

Werewolf wrote:
Fri Jan 18, 2019 8:46 am
Javier Ros wrote:
Thu Jan 17, 2019 11:04 pm


for use both GPU in Arena you must set:

Backend: Multiplexing
BackendOptions: (backend=cudnn,gpu=0),(backend=cudnn,gpu=1)
For the RTX cards presumably it'd look like this:

Backend: Multiplexing
BackendOptions: (backend=cudnn-fp16,gpu=0),(backend=cudnn-fp16,gpu=1)
Yes
The love relationship between a chess engine tester and his computer can be summarized in one sentence:
Until heat do us part.

User avatar
mclane
Posts: 15835
Joined: Thu Mar 09, 2006 5:40 pm
Location: US of Europe, germany
Full name: Thorsten Czub
Contact:

Re: Two GPUs

Post by mclane » Fri Jan 18, 2019 7:11 pm

Javier Ros wrote:
Fri Jan 18, 2019 9:00 am
Werewolf wrote:
Fri Jan 18, 2019 8:46 am
Javier Ros wrote:
Thu Jan 17, 2019 11:04 pm


for use both GPU in Arena you must set:

Backend: Multiplexing
BackendOptions: (backend=cudnn,gpu=0),(backend=cudnn,gpu=1)
For the RTX cards presumably it'd look like this:

Backend: Multiplexing
BackendOptions: (backend=cudnn-fp16,gpu=0),(backend=cudnn-fp16,gpu=1)
Yes
What is the difference in these two parameters ??
I do have an old pc with an old GTX 690.
It has 2 gpu cores.
I tried the first parameters and it looks like then both gpus are running 100 %.
What seems like a fairy tale today may be reality tomorrow.
Here we have a fairy tale of the day after tomorrow....

Javier Ros
Posts: 181
Joined: Fri Oct 12, 2012 10:48 am
Location: Seville (SPAIN)
Full name: Javier Ros

Re: Two GPUs

Post by Javier Ros » Fri Jan 18, 2019 8:10 pm

mclane wrote:
Fri Jan 18, 2019 7:11 pm
Javier Ros wrote:
Fri Jan 18, 2019 9:00 am
Werewolf wrote:
Fri Jan 18, 2019 8:46 am
Javier Ros wrote:
Thu Jan 17, 2019 11:04 pm


for use both GPU in Arena you must set:

Backend: Multiplexing
BackendOptions: (backend=cudnn,gpu=0),(backend=cudnn,gpu=1)
For the RTX cards presumably it'd look like this:

Backend: Multiplexing
BackendOptions: (backend=cudnn-fp16,gpu=0),(backend=cudnn-fp16,gpu=1)
Yes
What is the difference in these two parameters ??
I do have an old pc with an old GTX 690.
It has 2 gpu cores.
I tried the first parameters and it looks like then both gpus are running 100 %.
These parameters are for two physically different cards, on a motherboard that supports two PCIE slots.
The love relationship between a chess engine tester and his computer can be summarized in one sentence:
Until heat do us part.

User avatar
M ANSARI
Posts: 3398
Joined: Thu Mar 16, 2006 6:10 pm

Re: Two GPUs

Post by M ANSARI » Sat Jan 19, 2019 7:24 am

I am also thinking of setting up 2 GPU's for LC0. So is this code to be added to the .dll files? How do you get Leela to use both GPU's on CB GUI? Just install the UCI engine and add an edited .txt file?

How about if you do setup in SLI, will LC0 consider 2 x GPU's as one GPU if SLI or Crossfire is used?

Javier Ros
Posts: 181
Joined: Fri Oct 12, 2012 10:48 am
Location: Seville (SPAIN)
Full name: Javier Ros

Re: Two GPUs

Post by Javier Ros » Sat Jan 19, 2019 9:31 am

M ANSARI wrote:
Sat Jan 19, 2019 7:24 am
I am also thinking of setting up 2 GPU's for LC0. So is this code to be added to the .dll files? How do you get Leela to use both GPU's on CB GUI? Just install the UCI engine and add an edited .txt file?

How about if you do setup in SLI, will LC0 consider 2 x GPU's as one GPU if SLI or Crossfire is used?

I do not know the answer to the last question.

No SLI required, no txt file, in Chessbase you must only Create UCI Engine,
in Parameter, you must set Backend to Multiplexing and in BackendOptions you must write
(backend=cudnn,gpu=0),(backend=cudnn,gpu=1)

It is advisable to add to the name the version 32xxx and set Priority to Below Normal (recommended for all engines)
The love relationship between a chess engine tester and his computer can be summarized in one sentence:
Until heat do us part.

smatovic
Posts: 775
Joined: Wed Mar 10, 2010 9:18 pm
Location: Hamburg, Germany
Full name: Srdja Matovic
Contact:

Re: Two GPUs

Post by smatovic » Sat Jan 19, 2019 11:47 am

M ANSARI wrote:
Sat Jan 19, 2019 7:24 am
How about if you do setup in SLI, will LC0 consider 2 x GPU's as one GPU if SLI or Crossfire is used?
SLI and Crossfire are only used for generating graphics, Cuda and OpenCL con not use these.

SLI was introduced with the Vodoo 2 3D-accelerator cards by 3dfx,
the technique splits the graphics workload across the gpus,
imagine that one gpu renders only the odd frames and one gpu renders only the even frames.

https://en.wikipedia.org/wiki/Scalable_Link_Interface

--
Srdja

Post Reply