facebookresearch / dinov2

PyTorch code and models for the DINOv2 self-supervised learning method.
Apache License 2.0
9.23k stars 822 forks source link

How do I use DINOv2 to train unlabeled data #382

Closed ChenjieXu closed 8 months ago

ChenjieXu commented 8 months ago

In current training method, dataset is organized in ImageNet format which has label of image. How can I train the model with unlabeled data?

maxmal1 commented 8 months ago

Labels shouldn't matter in the training stage -- you should be able to get away with arbitrarily assigned labels.

ChenjieXu commented 8 months ago

Labels shouldn't matter in the training stage -- you should be able to get away with arbitrarily assigned labels.

Thank you for your reply. Does that mean I can put all unlabeled images in one folder in train stage?

maxmal1 commented 8 months ago

Here is a previous issue that is relevant: https://github.com/facebookresearch/dinov2/issues/142

ChenjieXu commented 8 months ago

Thank you for providing the information.

On Mon, Mar 4, 2024 at 4:28 PM Maxwell Malamut @.***> wrote:

Here is a previous issue that is relevant: #142 https://github.com/facebookresearch/dinov2/issues/142

— Reply to this email directly, view it on GitHub https://github.com/facebookresearch/dinov2/issues/382#issuecomment-1975993277, or unsubscribe https://github.com/notifications/unsubscribe-auth/AHTVJCOL4SB7QJBVWI3NWXTYWQWDBAVCNFSM6AAAAABEBMT5FSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSNZVHE4TGMRXG4 . You are receiving this because you authored the thread.Message ID: @.***>

ayushnangia commented 4 months ago

did you figure out how to just pretrain by initializing the weights from the model weights given? @ChenjieXu

csaroff commented 2 months ago

@ayushnangia You could give my fork a shot!

https://github.com/facebookresearch/dinov2/issues/142#issuecomment-1865134558