Trên GitHub, facebookresearch/dino đã đạt 7.6k sao, ngôn ngữ Python. PyTorch code for Vision Transformers training with the Self-Supervised learning method DINO
Tóm tắt dựng từ metadata GitHub của chính dự án — chưa có bài review TopGit. Trang sẽ tự động cập nhật khi bài review đầy đủ được xuất bản.
VÌ SAO CHƯA CÓ REVIEW
TopGit viết bài đầy đủ cho repo có nhiều sao nhất và được yêu cầu nhiều nhất. Trang này là snapshot trong thời gian chờ — xem README gốc ở tab READ ME.
:new: Please check out our more recent DINOv2 effort in the same line of work.
Self-Supervised Vision Transformers with DINO
PyTorch implementation and pretrained models for DINO. For details, see Emerging Properties in Self-Supervised Vision Transformers.
[blogpost] [arXiv] [Yannic Kilcher's video]
Pretrained models
You can choose to download only the weights of the pretrained backbone used for downstream tasks, or the full checkpoint which contains backbone and projection head weights for both student and teacher networks. We also provide the backbone in onnx format, as well as detailed arguments and training/evaluation logs. Note that DeiT-S and ViT-S names refer exactly to the same architecture.
arch
params
k-nn
linear
download
ViT-S/16
21M
74.5%
77.0%
backbone only
full ckpt
onnx
args
logs
eval logs
ViT-S/8
21M
78.3%
79.7%
backbone only
full ckpt
onnx
args
logs
eval logs
ViT-B/16
85M
76.1%
78.2%
backbone only
full ckpt
onnx
args
logs
eval logs
ViT-B/8
85M
77.4%
80.1%
backbone only
full ckpt
onnx
args
logs
eval logs
ResNet-50
23M
67.5%
75.3%
backbone only
full ckpt
onnx
args
logs
eval logs
We also release XCiT models ([arXiv] [code]) trained with DINO:
Please install PyTorch and download the ImageNet dataset. This codebase has been developed with python version 3.6, PyTorch version 1.7.1, CUDA 11.0 and torchvision 0.8.2. The exact arguments to reproduce the models presented in our paper can be found in the args column of the pretrained models section. For a glimpse at the full documentation of DINO training please run:
python main_dino.py --help
Vanilla DINO training :sauropod:
Run DINO with ViT-small network on a single node with 8 GPUs for 100 epochs with the following command. Training time is 1.75 day and the resulting checkpoint should reach 69.3% on k-NN eval and 74.0% on linear eval. We provide training and linear evaluation logs (with batch size 256 at evaluation time) for this run to help reproducibility.
The resulting pretrained model should reach 73.3% on k-NN eval and 76.0% on linear eval. Training time is 2.6 days with 16 GPUs. We provide training and linear evaluation logs (with batch size 256 at evaluation time) for this run to help reproducibility.
ResNet-50 and other convnets trainings
This code also works for training DINO on convolutional networks, like ResNet-50 for example. We highly recommend to adapt some optimization arguments in this case. For example following is a command to train DINO on ResNet-50 on a single node with 8 GPUs for 100 epochs. We provide training logs and final checkpoint for this run.
If you choose not to specify --pretrained_weights, then DINO reference weights are used by default. If you want instead to evaluate checkpoints from a run of your own, you can run for example:
Evaluation: Image Retrieval on revisited Oxford and Paris
Step 1: Prepare revisited Oxford and Paris by following this repo.
Step 2: Image retrieval (if you do not specify weights with --pretrained_weights then by default DINO weights pretrained on Google Landmark v2 dataset will be used).
Step 2 (opt): Prepare a set of image distractors and a set of images on which to learn the whitening operator.
In our paper, we use 10k random images from YFCC100M as distractors and 20k random images from YFCC100M (different from the distractors) for computing the whitening operation.
We report result on the strong subset. For example in the stdout from the command above we get: eval on strong mAP=0.858.
License
This repository is released under the Apache 2.0 license as found in the LICENSE file.
Citation
If you find this repository useful, please consider giving a star :star: and citation :t-rex::
@inproceedings{caron2021emerging,
title={Emerging Properties in Self-Supervised Vision Transformers},
author={Caron, Mathilde and Touvron, Hugo and Misra, Ishan and J\'egou, Herv\'e and Mairal, Julien and Bojanowski, Piotr and Joulin, Armand},
booktitle={Proceedings of the International Conference on Computer Vision (ICCV)},
year={2021}
}
Trang TopGit này là một snapshot — tab "Readme" hiển thị nguyên văn README của repo (đã bỏ link, giữ ảnh). Repo GitHub ở github.com/facebookresearch/dino là nguồn chính thức.
facebookresearch/dino có bao nhiêu sao?
facebookresearch/dino có 7.6k sao GitHub — tải lại trang để xem số mới nhất, hoặc xem trực tiếp github.com/facebookresearch/dino. TopGit phản chiếu số sao của GitHub nhưng không cam kết đến từng phút.
facebookresearch/dino có phải mã nguồn mở không?
Có — facebookresearch/dino phát hành theo license Apache-2.0, nghĩa là mã nguồn mở để đọc, fork và (tùy license) tái sử dụng. Mã: github.com/facebookresearch/dino.
facebookresearch/dino còn đang phát triển không?
Commit gần nhất trên facebookresearch/dino là 2.4 năm trước (theo timestamp GitHub). Repo có 1.1k fork — một chỉ báo về mức độ quan tâm của cộng đồng.
facebookresearch/dino là gì?
facebookresearch/dino (facebookresearch/dino) là dự án Python trên GitHub. Theo mô tả gốc: PyTorch code for Vision Transformers training with the Self-Supervised learning method DINO
Đọc đầy đủ README ở tab phía trên.
dino có đáng để bạn bỏ thời gian?
ChatGPT, Claude và Perplexity đều đọc được trang này. Hỏi thử xem họ nghĩ gì về dino.