# Unique text generation per-GPU

**URL:** <https://discuss.huggingface.co/t/unique-text-generation-per-gpu/18887>\
**Category:** Beginners\
**Created:** [June 9, 2022, 2:35am UTC](https://discuss.huggingface.co/t/unique-text-generation-per-gpu/18887 "2022-06-09T02:35:21Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![enzokro](https://avatars.discourse-cdn.com/v4/letter/e/a587f6/32.png) [@enzokro](https://discuss.huggingface.co/u/enzokro)\
**Post date:** [June 9, 2022, 2:35am UTC](https://discuss.huggingface.co/t/unique-text-generation-per-gpu/18887/1 "2022-06-09T02:35:21Z")

</div>

Hello,

I had a quick question about properly generating text on multiple GPUs.  
Right now I am generating texts by splitting GPT-j-6B across a few nodes.

Usually I set a fixed seed for my jobs. When I do that, the generated output text from each job is identical so it only makes sense to save one of them. I believe that is done in the last step of this `deepspeed` example: [deepspeed for GPT-Neo-2.7B](https://www.deepspeed.ai/tutorials/inference-tutorial/#end-to-end-gpt-neo-27b-inference)

But when I don’t set an explicit seed each job gets different RNG settings. Thanks to this I instead get as many unique text outputs as there are GPUs.

Is not setting the shared seed a valid way to “cheat” and increase text generation throughput? Or should seeds be set for another reason (i.e. something in `synced_gpus=True` or deepspeed needs it).

Apologies if this has been asked before I could not find it via keywords.

Thank you!
