Giter Site home page Giter Site logo

Comments (3)

yxgeee avatar yxgeee commented on May 27, 2024

When samples_per_bn is smaller than samples_per_gpu, sync bn won't work so it is disabled. And note that the actual samples_per_bn should be at least the same as samples_per_gpu (samples_per_bn=N x samples_per_gpu, N>=1), so the actual samples_per_bn will be the same as samples_per_gpu by default if samples_per_bn<samples_per_gpu.

In source-domain pre-training, the best setup is to train with a batch size of 64 and global sync bn (samples_per_bn=64). And in target-domain fine-tuning on 4 GPUs, the best setup is to train with a batch size of 64 and no sync bn (samples_per_bn=16, 16x4=64). However, when conducting experiments on 8 GPUs (8 batch_size on each GPU), sync bn will be activated since two GPUs need to sync their BNs to perform samples_per_bn=16.

from openunreid.

valencebond avatar valencebond commented on May 27, 2024

hi,@yxgeee, thanks for your detailed explanation, but why in target-domain fine-tuning, the best setup is to train with no sync bn. i am not familiar with domain adaptation, but this is against common practice in general training CNN.

from openunreid.

yxgeee avatar yxgeee commented on May 27, 2024

Such an optimal setup (16 samples for each BN and 64 samples in a mini-batch) was found empirically, as the re-ID dataset is sensitive to the number of batch size.

from openunreid.

Related Issues (20)

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.