# Cost Estimator?

**URL:** <https://discuss.huggingface.co/t/cost-estimator/37735>\
**Category:** Amazon Inferentia & Trainium\
**Created:** [April 26, 2023, 12:46am UTC](https://discuss.huggingface.co/t/cost-estimator/37735 "2023-04-26T00:46:51Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![gosha1128](https://avatars.discourse-cdn.com/v4/letter/g/ad7895/32.png) [@gosha1128](https://discuss.huggingface.co/u/gosha1128)\
**Post date:** [April 26, 2023, 12:46am UTC](https://discuss.huggingface.co/t/cost-estimator/37735/1 "2023-04-26T00:46:51Z")

</div>

Do you have a way to estimate the costs for various kinds of training asks (ie, PT & FT) by inputing the coarse configuration like model type, dataset size, and epochs?

---

<div class="post-metadata">

**Author:** ![philschmid](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/philschmid/32/38022_2.png) [@philschmid](https://discuss.huggingface.co/u/philschmid)\
**Post date:** [April 26, 2023, 6:16am UTC](https://discuss.huggingface.co/t/cost-estimator/37735/2 "2023-04-26T06:16:56Z")

</div>

Thats hard to estimate since you don’t know which batch size fits. Additionally is training time depended on more factors, like if you eval during training or use mixed precision etc.

The best is to give it a try and see what the throughput is

---

<div class="post-metadata">

**Author:** ![gosha1128](https://avatars.discourse-cdn.com/v4/letter/g/ad7895/32.png) [@gosha1128](https://discuss.huggingface.co/u/gosha1128)\
**Post date:** [April 26, 2023, 5:47pm UTC](https://discuss.huggingface.co/t/cost-estimator/37735/3 "2023-04-26T17:47:07Z")

</div>

Thanks @philschmid. These are great points.

Let’s say you’ve wall-timed one training “step” and determined the right batch size and FP precision that works for you. And let’s say you validate after each epoch. Is that closer to something you could ballpark a formula for?
