Code Monkey home page Code Monkey logo

vit's Introduction

1. Pre-trained Models

DROP_PROB = 0.1
N_LAYERS = 6
HIDDEN_SIZE = 384
MLP_SIZE = 384
N_HEADS = 12
PATCH_SIZE = 4
BASE_LR = 1e-3
BETA1 = 0.9
BETA2 = 0.999
WEIGHT_DECAY = 5e-5
WARMUP_EPOCHS = 5
SMOOTHING = 0.1
CUTMIX = False
CUTOUT = False
HIDE_AND_SEEK = False
BATCH_SIZE = 2048
N_EPOCHS = 300

1) Trained on CIFAR-10 Dataset for 300 Epochs

2) Trained on CIFAR-100 Dataset for 256 Epochs

2. Implementation Details

  • F.gelu()nn.Dropout()의 순서가 되도록 Architecture를 변경했습니다. 순서를 반대로 할 경우 미분 값이 0이 되어 학습이 이루어지지 않는 현상이 발생함을 확인했습니다.
  • CIFAR-100에 대해서 N_LAYERS = 6, HIDDEN_SIZE = 384, N_HEADS = 6일 때, PATCH_SIZE = 16일 때보다 PATCH_SIZE = 8일 때, 그리고 PATCH_SIZE = 4일 때 성능이 향상됐습니다.
  • CIFAR-10과 CIFAR-100에 대해서 공통적으로 ViT-Base보다 작은 크기의 모델을 사용할 때 성능이 더 높았습니다.

3. Studies

1) Attention Map

  • Original image
  • head_fusion: "max", discard_ratio: 0.85

2) Position Embedding Similarity

vit's People

Contributors

kimrass avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.