About batch_size_forward and gradient_accumulation_steps param in papers
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 3k
- Forks
- 234
- PR merge metrics
- No merged PRs in 30d
Description
Hi @EasternJournalist ,
I have a question regarding the batch size setting.
When you mention a batch size of 128, does this refer to the total effective batch size, i.e.
batch_size_total = batch_size_forward × gradient_accumulation_steps × accelerator.num_processes
or does it mean that batch_size_forward itself is set to 128?
I’m asking because in my experiments, using batch_size_forward = 4 already consumes around 50 GB of GPU memory, so I want to make sure I’m interpreting the batch size correctly.
Looking forward to your clarification.
Thanks in advance!
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No file, test, or entry point is named. Start by reviewing the paper or training documentation that defines batch size, batch_size_forward, gradient_accumulation_steps, and accelerator.num_processes. Done means documenting which interpretation of batch size 128 is intended and clarifying the memory-related distinction.
Written by the indexing model from the issue text.
Assessment
- Domain
- documentation, machine-learning
- Issue type
- Documentation
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100