swift
swift copied to clipboard
关于训练数据集数量与steps的问题
请问在微调中我们使用的数据集有29450条,batch_size=1, train_dataset_sample=-1, 为什么训练一个epoch使用约1800steps?
按我的理解batch_size=1每次加载一条数据,step应该与数据数量一致?
感谢您的回答!
默认会设置梯度累加的, 使得total_batch_size >= 16
Steps per epoch = Total number of samples / (batch size * gradient accumulation steps)