-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature] Add Tokens-to-Token ViT backbone and converted checkpoints. #467
Conversation
Codecov Report
@@ Coverage Diff @@
## master #467 +/- ##
==========================================
+ Coverage 78.77% 79.42% +0.64%
==========================================
Files 103 106 +3
Lines 5702 5959 +257
Branches 927 962 +35
==========================================
+ Hits 4492 4733 +241
- Misses 1088 1095 +7
- Partials 122 131 +9
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
assert out_indices[i] >= 0, f'Invalid out_indices {index}' | ||
self.out_indices = out_indices | ||
|
||
dpr = [x for x in np.linspace(0, drop_path_rate, num_layers)] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dpr
could be "droppath rates" or "drop rates".
it is better to use droppath_rates
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right, but dpr
is used in VisionTransformer
and SwinTransformer
, and it's a conventional usage.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
…open-mmlab#467) * add t2t backbone * register t2t_vit * add t2t_vit config * [Temp] Align posterize transform with timm. * Fix lint * Refactor t2t-vit * Add config for t2t-vit * Add metafile and README for t2t-vit * Add unit tests * configs * Update metafile and README * Improve docstring * Fix batch size which should be 8x64 instead of 8x128 * Fix typo * Update model zoo * Update training augments config. * Move some arguments of T2TModule to T2TViT * Update docs. * Update unit test Co-authored-by: HIT-cwh <[email protected]>
Motivation
Continue @HIT-cwh's work
Modification
As the title.
This PR depends on #395, please review that PR at first.
BC-breaking (Optional)
No.
Use cases (Optional)
No.
Checklist
Before PR:
After PR: