Update model card
Browse files
README.md
ADDED
|
@@ -0,0 +1,71 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
library_name: lucid
|
| 3 |
+
license: apache-2.0
|
| 4 |
+
tags:
|
| 5 |
+
- image-classification
|
| 6 |
+
- maxvit
|
| 7 |
+
- lucid
|
| 8 |
+
datasets:
|
| 9 |
+
- imagenet-1k
|
| 10 |
+
pipeline_tag: image-classification
|
| 11 |
+
model-index:
|
| 12 |
+
- name: maxvit-tiny
|
| 13 |
+
results:
|
| 14 |
+
- task: { type: image-classification }
|
| 15 |
+
dataset: { name: ImageNet-1k, type: imagenet-1k }
|
| 16 |
+
metrics:
|
| 17 |
+
- { type: acc@1, value: 83.62 }
|
| 18 |
+
- { type: acc@5, value: 96.49 }
|
| 19 |
+
---
|
| 20 |
+
|
| 21 |
+
# MaxViT-Tiny
|
| 22 |
+
|
| 23 |
+
> Tu et al., 2022 — *MaxViT: Multi-Axis Vision Transformer* (arXiv:2204.01697)
|
| 24 |
+
|
| 25 |
+
[Lucid](https://github.com/ChanLumerico/lucid) port of `timm/maxvit_tiny_tf_224.in1k`,
|
| 26 |
+
converted to Lucid-native safetensors.
|
| 27 |
+
|
| 28 |
+
## Available weights
|
| 29 |
+
|
| 30 |
+
| Tag | acc@1 | acc@5 | Params | GFLOPs | Size | Source |
|
| 31 |
+
|---|---|---|---|---|---|---|
|
| 32 |
+
| `IN1K` *(default)* | 83.62 | 96.49 | 30.9M | — | 118.18 MB | timm |
|
| 33 |
+
|
| 34 |
+
## Usage
|
| 35 |
+
|
| 36 |
+
```python
|
| 37 |
+
import lucid.models as models
|
| 38 |
+
from lucid.models.vision.resnet import MaxvitTinyWeights
|
| 39 |
+
|
| 40 |
+
# default tag
|
| 41 |
+
model = models.maxvit_tiny_cls(pretrained=True)
|
| 42 |
+
|
| 43 |
+
# explicit tag (enum or string)
|
| 44 |
+
model = models.maxvit_tiny_cls(weights=MaxvitTinyWeights.IN1K)
|
| 45 |
+
model = models.maxvit_tiny_cls(pretrained="IN1K")
|
| 46 |
+
|
| 47 |
+
# preprocessing travels with the weights
|
| 48 |
+
weights = MaxvitTinyWeights.IN1K
|
| 49 |
+
preprocess = weights.transforms()
|
| 50 |
+
logits = model(preprocess(image)[None]).logits
|
| 51 |
+
```
|
| 52 |
+
|
| 53 |
+
## Conversion
|
| 54 |
+
|
| 55 |
+
Converted from `timm/maxvit_tiny_tf_224.in1k` via
|
| 56 |
+
`python -m tools.convert_weights maxvit_tiny --tag IN1K`.
|
| 57 |
+
Key mapping + numerical parity verified against the source.
|
| 58 |
+
|
| 59 |
+
## License
|
| 60 |
+
|
| 61 |
+
`apache-2.0` — inherited from the original weights.
|
| 62 |
+
|
| 63 |
+
## Citation
|
| 64 |
+
|
| 65 |
+
```
|
| 66 |
+
@inproceedings{tu2022maxvit,
|
| 67 |
+
title={MaxViT: Multi-Axis Vision Transformer},
|
| 68 |
+
author={Tu, Zhengzhong and Talebi, Hossein and Zhang, Han and Yang, Feng and Milanfar, Peyman and Bovik, Alan and Li, Yinxiao},
|
| 69 |
+
booktitle={ECCV}, year={2022}
|
| 70 |
+
}
|
| 71 |
+
```
|