# Trainer: log token count

**URL:** <https://discuss.huggingface.co/t/trainer-log-token-count/59146>\
**Category:** 🤗Transformers\
**Created:** [October 19, 2023, 3:17pm UTC](https://discuss.huggingface.co/t/trainer-log-token-count/59146 "2023-10-19T15:17:05Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![g58892881](https://avatars.discourse-cdn.com/v4/letter/g/74df32/32.png) [@g58892881](https://discuss.huggingface.co/u/g58892881)\
**Post date:** [October 19, 2023, 3:17pm UTC](https://discuss.huggingface.co/t/trainer-log-token-count/59146/1 "2023-10-19T15:17:05Z")

</div>

I would like to log training progress in terms of tokens trained so far, while training.

I have checked whether this number is passed to any of the callbacks, but it seems like it’s not. Is there any way to access this information without subclassing the trainer?
