lightly-ai / lightly-ai/lightly

SimMIM and non-ViT backbones

Open
#1,135 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Python
Stars
3.8k
Forks
367
Avg merge
3d 22h
Merged PRs (30d)
5

Description

I'm noticing very subpar performance from SimMIM on my task compared to MAE, and this also seems to be an issue on the Imagenette benchmarks. I was wondering what might be causing this, and whether we'd still see performance issues with a non-ViT backbone. Is it possible to use backbones like convnets and Swin transformers with the current implementation of SimMIM? I'm curious how you'd need to change the `forward_encoder` method to do so, and whether `images_to_tokens` could be generalized to other backbones.

```python
def forward_encoder(self, images, batch_size, idx_mask):
# pass all the tokens to the encoder, both masked and non masked ones
tokens = self.backbone.images_to_tokens(images, prepend_class_token=True)
tokens_masked = utils.mask_at_index(tokens, idx_mask, self.mask_token)
return self.backbone.encoder(tokens_masked)
```

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing the current SimMIM path through forward_encoder, images_to_tokens, and backbone.encoder, then compare it with the Imagenette benchmark behavior described in the issue. Determine which backbone assumptions those entry points make and define the scope needed for convnet and Swin support; done should include a clear compatibility decision and corresponding benchmark evidence.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, pytorch
Domain
computer-vision, machine-learning
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.