# Kosmos-2 Fine tuning

**URL:** </static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fkosmos-2-fine-tuning%2F75691%3E%5C
**Category:** 🤗Transformers\
**Created:** [March 3, 2024, 12:54pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fkosmos-2-fine-tuning%2F75691 "2024-03-03T12:54:01Z")\
**Posts on this page:** 1\
**Showing post:** 16

<div class="post-metadata">

**Author:** ![Mit1208](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/mit1208/32/32368_2.png) [@Mit1208](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Fu%2FMit1208)%5C
**Post date:** [March 15, 2024, 3:48pm UTC](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fkosmos-2-fine-tuning%2F75691%2F16 "2024-03-15T15:48:19Z")

</div>

@ydshieh, I added labels in model itself because I found one discussion around it e.g. [Finetune BLIP on customer dataset #20893 - #2 by dxlong2000](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Ffinetune-blip-on-customer-dataset-20893%2F28446%2F2).

To be honest, I wasn’t too clear on that. Can you give me code snippet to create `labels` if you can. If not give me some sort of python code which I can refer and I will taking from there.

This model works on next token prediction so I thought to use Data Collator but there is None that supports multimodel as of now.

I really appreciate your help and it’s always very useful.

And, I think if my code will then @cdh code will work too because we both are trying to achieve almost similar things in different way.

---

_[View the full topic](/static-proxy?url=https%3A%2F%2Fdiscuss.huggingface.co%2Ft%2Fkosmos-2-fine-tuning%2F75691)._
