# ClientApp with multigpu training from pytorch lightning

**URL:** <https://discuss.flower.ai/t/clientapp-with-multigpu-training-from-pytorch-lightning/1210>\
**Category:** Flower Help - Intermediate\
**Tags:** flower\
**Created:** [February 23, 2026, 3:12pm UTC](https://discuss.flower.ai/t/clientapp-with-multigpu-training-from-pytorch-lightning/1210 "2026-02-23T15:12:30Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![paul75](https://dub1.discourse-cdn.com/flex013/user_avatar/discuss.flower.ai/paul75/32/314_2.png) [@paul75](https://discuss.flower.ai/u/paul75)\
**Post date:** [February 23, 2026, 3:12pm UTC](https://discuss.flower.ai/t/clientapp-with-multigpu-training-from-pytorch-lightning/1210/1 "2026-02-23T15:12:30Z")

</div>

Hello  
Im trying to run a training with 1 client that uses 2 or more gpus with DDP strategy.

I have this issue where the DDP strategy interferes with the ClientApp, it spawns/forks additional processes which re-enter the ClientApp runtime and interfere with the grpc ports/tls flags.

The only solution that I found at this point is to move the training logic from the client into a separate script and run it inside the ClientApp using torch run.

Anybody else encountered this issue? What other solutions do I have?

---

<div class="post-metadata">

**Author:** ![javier](https://dub1.discourse-cdn.com/flex013/user_avatar/discuss.flower.ai/javier/32/116_2.png) [@javier](https://discuss.flower.ai/u/javier)\
**Post date:** [February 26, 2026, 11:09am UTC](https://discuss.flower.ai/t/clientapp-with-multigpu-training-from-pytorch-lightning/1210/2 "2026-02-26T11:09:39Z")

</div>

Hi @paul75 , the solution you proposes of launching a subprocess with `torch run` that waits until its completed is probably the easiest approach right now. But i’m curious also to hear if others have attempted something else.

---

<div class="post-metadata">

**Author:** ![paul75](https://dub1.discourse-cdn.com/flex013/user_avatar/discuss.flower.ai/paul75/32/314_2.png) [@paul75](https://discuss.flower.ai/u/paul75)\
**Post date:** [February 27, 2026, 1:14pm UTC](https://discuss.flower.ai/t/clientapp-with-multigpu-training-from-pytorch-lightning/1210/3 "2026-02-27T13:14:33Z")

</div>

Another issue I encountered its how to run the clientapp with multinode gpus

at the moment I dont have a solution

---

<div class="post-metadata">

**Author:** ![adityak714](https://dub1.discourse-cdn.com/flex013/user_avatar/discuss.flower.ai/adityak714/32/319_2.png) [@adityak714](https://discuss.flower.ai/u/adityak714)\
**Post date:** [April 4, 2026, 4:29pm UTC](https://discuss.flower.ai/t/clientapp-with-multigpu-training-from-pytorch-lightning/1210/4 "2026-04-04T16:29:49Z")

</div>

I am also following this thread, as this is also something I want to implement. @javier I will try your suggestion!
