facebookresearch / facebookresearch/sam2
Redundant arguments in Hiera ?
- Dominant language
- Jupyter Notebook
- Stars
- 19.9k
- Forks
- 2.5k
- PR merge metrics
- No merged PRs in 30d
Description
I'm a little confused by the default arguments passed to the Hiera class. https://github.com/facebookresearch/segment-anything-2/blob/7e1596c0b6462eb1d1ba7e1492430fed95023598/sam2/modeling/backbones/hieradet.py#L184
It seems like `window_spec` is hiding two things at once.
In the first window attention blocks, They have respectively 8 and 4 tokens (That's window attention).
After those, they will have 14 and 7 tokens (That's all the tokens left, so that is global attention).
But then it looks redundant with the `global_att_blocks` parameters.
Can you help me understand those 3 parameters, `window_spec`, `global_att_blocks` and `window_pos_embed_bkg_spatial_size`.
Thanks!
Contributor guide
Assessment
This issue has not been assessed yet.