# Multiclass Classification: "labels" format

**URL:** <https://discuss.huggingface.co/t/multiclass-classification-labels-format/25021>\
**Category:** Beginners\
**Created:** [October 26, 2022, 3:09pm UTC](https://discuss.huggingface.co/t/multiclass-classification-labels-format/25021 "2022-10-26T15:09:14Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![LoadedFries](https://avatars.discourse-cdn.com/v4/letter/l/77aa72/32.png) [@LoadedFries](https://discuss.huggingface.co/u/LoadedFries)\
**Post date:** [October 26, 2022, 3:09pm UTC](https://discuss.huggingface.co/t/multiclass-classification-labels-format/25021/1 "2022-10-26T15:09:14Z")

</div>

Hello Community,

I fine-tuned a BERTforSequenceClassification with the Huggingface Trainer  
i have a question regarding the format of the “labels” in my dataset. I read through a lot of postings and threads, but i am still a bit confused.

I have a dataset with 5 labels and it is a multiclass classification problem. So a text has exact one value of (0,1,2,3,4). I read everywhere that the format has to be a tensor with 0’s and 1’s. However, i finetuned a BERT model with the Huggingface Trainer and let the labels have the values from 0 to 4.

My Question:

does the trainer autoformat these labels or does it accept normal integers aswell? I dont get any error, can predict values without problems. The results seem reliable aswell.

I hope you can help me with this, because i didnt find a reliable source anywhere that confirms this.  
Thank you very much 🙂
