Update README.md
Browse files
README.md
CHANGED
@@ -1,3 +1,162 @@
|
|
1 |
---
|
2 |
license: mit
|
3 |
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
---
|
2 |
license: mit
|
3 |
---
|
4 |
+
# Model Card for CLIP-convnext_base_w-320.laion_aesthetic-s13B-b82k-augreg
|
5 |
+
|
6 |
+
# Table of Contents
|
7 |
+
|
8 |
+
1. [Model Details](#model-details)
|
9 |
+
2. [Uses](#uses)
|
10 |
+
3. [Training Details](#training-details)
|
11 |
+
4. [Evaluation](#evaluation)
|
12 |
+
5. [Acknowledgements](#acknowledgements)
|
13 |
+
6. [Citation](#citation)
|
14 |
+
7. [How To Get Started With the Model](#how-to-get-started-with-the-model)
|
15 |
+
|
16 |
+
|
17 |
+
# Model Details
|
18 |
+
|
19 |
+
## Model Description
|
20 |
+
|
21 |
+
A series of CLIP ConvNeXt-Base (w/ wide embed dim) models trained on subsets LAION-5B (https://laion.ai/blog/laion-5b/) using OpenCLIP (https://github.com/mlfoundations/open_clip).
|
22 |
+
|
23 |
+
The models utilize the [timm](https://github.com/rwightman/pytorch-image-models) [ConvNeXt-Base](https://arxiv.org/abs/2201.03545) model (`convnext_base`) as the image tower, and the same text tower as the RN50x4 (depth 12, embed dim 640) model from OpenAI CLIP. The base models are trained at 256x256 image resolution and roughly match the RN50x4 models on FLOPs and activation counts. The models with `320` in the name are trained at 320x320.
|
24 |
+
|
25 |
+
| Model | Dataset | Resolution | AugReg | Top-1 ImageNet Zero-Shot |
|
26 |
+
| ----- | ------- | ---------- | ------------ | --------- |
|
27 |
+
| [convnext_base_w.laion2b_s13b_b82k](https://huggingface.co/laion/CLIP-convnext_base_w-laion2B-s13B-b82K) | LAION-2B | 256x256 | RRC (0.9, 1.0) | 70.8 |
|
28 |
+
| [convnext_base_w.laion2b_s13b_b82k_augreg](https://huggingface.co/laion/CLIP-convnext_base_w-laion2B-s13B-b82K-augreg) | LAION-2B | 256x256 | RRC (0.33, 1.0), RE (0.35), SD (0.1) | 71.5 |
|
29 |
+
| [convnext_base_w.laion_aesthetic_s13b_b82k](https://huggingface.co/laion/CLIP-convnext_base_w-laion_aesthetic-s13B-b82K) | LAION-A | 256x256 | RRC (0.9, 1.0) | 71.0 |
|
30 |
+
| [convnext_base_w_320.laion_aesthetic_s13b_b82k](https://huggingface.co/laion/CLIP-convnext_base_w_320-laion_aesthetic-s13B-b82K) | LAION-A | 320x320 | RRC (0.9, 1.0) | 71.7 |
|
31 |
+
| [convnext_base_w_320.laion_aesthetic_s13b_b82k_augreg](https://huggingface.co/laion/CLIP-convnext_base_w_320-laion_aesthetic-s13B-b82K-augreg) | LAION-A | 320x320 | RRC (0.33, 1.0), RE (0.35), SD (0.1) | 71.3 |
|
32 |
+
|
33 |
+
RRC = Random Resize Crop (crop pcts), RE = Random Erasing (prob), SD = Stochastic Depth (prob) -- image tower only
|
34 |
+
|
35 |
+
LAION-A = LAION Aesthetic, an ~900M sample subset of LAION-2B with pHash dedupe and asthetic score filtering.
|
36 |
+
|
37 |
+
Model training done by Ross Wightman across both the [stability.ai](https://stability.ai/) cluster and the [JUWELS Booster](https://apps.fz-juelich.de/jsc/hps/juwels/booster-overview.html) supercomputer. See acknowledgements below.
|
38 |
+
|
39 |
+
# Uses
|
40 |
+
|
41 |
+
As per the original [OpenAI CLIP model card](https://github.com/openai/CLIP/blob/d50d76daa670286dd6cacf3bcd80b5e4823fc8e1/model-card.md), this model is intended as a research output for research communities. We hope that this model will enable researchers to better understand and explore zero-shot, arbitrary image classification. We also hope it can be used for interdisciplinary studies of the potential impact of such model.
|
42 |
+
|
43 |
+
The OpenAI CLIP paper includes a discussion of potential downstream impacts to provide an example for this sort of analysis. Additionally, the LAION-5B blog (https://laion.ai/blog/laion-5b/) and upcoming paper include additional discussion as it relates specifically to the training dataset.
|
44 |
+
|
45 |
+
## Direct Use
|
46 |
+
|
47 |
+
Zero-shot image classification, image and text retrieval, among others.
|
48 |
+
|
49 |
+
## Downstream Use
|
50 |
+
|
51 |
+
Image classification and other image task fine-tuning, linear probe image classification, image generation guiding and conditioning, among others.
|
52 |
+
|
53 |
+
## Out-of-Scope Use
|
54 |
+
|
55 |
+
As per the OpenAI models,
|
56 |
+
|
57 |
+
**Any** deployed use case of the model - whether commercial or not - is currently out of scope. Non-deployed use cases such as image search in a constrained environment, are also not recommended unless there is thorough in-domain testing of the model with a specific, fixed class taxonomy. This is because our safety assessment demonstrated a high need for task specific testing especially given the variability of CLIP’s performance with different class taxonomies. This makes untested and unconstrained deployment of the model in any use case currently potentially harmful.
|
58 |
+
|
59 |
+
Certain use cases which would fall under the domain of surveillance and facial recognition are always out-of-scope regardless of performance of the model. This is because the use of artificial intelligence for tasks such as these can be premature currently given the lack of testing norms and checks to ensure its fair use.
|
60 |
+
|
61 |
+
Since the model has not been purposefully trained in or evaluated on any languages other than English, its use should be limited to English language use cases.
|
62 |
+
|
63 |
+
Further the above notice, the LAION-5B dataset used in training of these models has additional considerations, see below.
|
64 |
+
|
65 |
+
# Training Details
|
66 |
+
|
67 |
+
## Training Data
|
68 |
+
|
69 |
+
This model was trained with the 2 Billion sample English subset of LAION-5B (https://laion.ai/blog/laion-5b/).
|
70 |
+
|
71 |
+
**IMPORTANT NOTE:** The motivation behind dataset creation is to democratize research and experimentation around large-scale multi-modal model training and handling of uncurated, large-scale datasets crawled from publically available internet. Our recommendation is therefore to use the dataset for research purposes. Be aware that this large-scale dataset is uncurated. Keep in mind that the uncurated nature of the dataset means that collected links may lead to strongly discomforting and disturbing content for a human viewer. Therefore, please use the demo links with caution and at your own risk. It is possible to extract a “safe” subset by filtering out samples based on the safety tags (using a customized trained NSFW classifier that we built). While this strongly reduces the chance for encountering potentially harmful content when viewing, we cannot entirely exclude the possibility for harmful content being still present in safe mode, so that the warning holds also there. We think that providing the dataset openly to broad research and other interested communities will allow for transparent investigation of benefits that come along with training large-scale models as well as pitfalls and dangers that may stay unreported or unnoticed when working with closed large datasets that remain restricted to a small community. Providing our dataset openly, we however do not recommend using it for creating ready-to-go industrial products, as the basic research about general properties and safety of such large-scale models, which we would like to encourage with this release, is still in progress.
|
72 |
+
|
73 |
+
## Training Procedure
|
74 |
+
|
75 |
+
TODO
|
76 |
+
|
77 |
+
# Evaluation
|
78 |
+
|
79 |
+
Evaluation done with code in the [LAION CLIP Benchmark suite](https://github.com/LAION-AI/CLIP_benchmark).
|
80 |
+
|
81 |
+
## Testing Data, Factors & Metrics
|
82 |
+
|
83 |
+
### Testing Data
|
84 |
+
|
85 |
+
The testing is performed with VTAB+ (A combination of VTAB (https://arxiv.org/abs/1910.04867) w/ additional robustness datasets) for classification and COCO and Flickr for retrieval.
|
86 |
+
|
87 |
+
## Results
|
88 |
+
|
89 |
+
The models achieve between 70.8 and 71.7 zero-shot top-1 accuracy on ImageNet-1k.
|
90 |
+
|
91 |
+
![](convnext_base_w_zero_shot.png)
|
92 |
+
|
93 |
+
An initial round of benchmarks have been performed on a wider range of datasets, to be viewable at https://github.com/LAION-AI/CLIP_benchmark/blob/main/benchmark/results.ipynb
|
94 |
+
|
95 |
+
# Acknowledgements
|
96 |
+
|
97 |
+
Acknowledging [stability.ai](https://stability.ai/) and the Gauss Centre for Supercomputing e.V. (http://gauss-centre.eu) for funding this part of work by providing computing time through the John von Neumann Institute for Computing (NIC) on the GCS Supercomputer JUWELS Booster at Jülich Supercomputing Centre (JSC).
|
98 |
+
|
99 |
+
# Citation
|
100 |
+
|
101 |
+
**BibTeX:**
|
102 |
+
|
103 |
+
In addition to forthcoming LAION-5B (https://laion.ai/blog/laion-5b/) paper, please cite:
|
104 |
+
|
105 |
+
|
106 |
+
OpenCLIP software
|
107 |
+
```bibtex
|
108 |
+
@software{ilharco_gabriel_2021_5143773,
|
109 |
+
author = {Ilharco, Gabriel and
|
110 |
+
Wortsman, Mitchell and
|
111 |
+
Wightman, Ross and
|
112 |
+
Gordon, Cade and
|
113 |
+
Carlini, Nicholas and
|
114 |
+
Taori, Rohan and
|
115 |
+
Dave, Achal and
|
116 |
+
Shankar, Vaishaal and
|
117 |
+
Namkoong, Hongseok and
|
118 |
+
Miller, John and
|
119 |
+
Hajishirzi, Hannaneh and
|
120 |
+
Farhadi, Ali and
|
121 |
+
Schmidt, Ludwig},
|
122 |
+
title = {OpenCLIP},
|
123 |
+
month = jul,
|
124 |
+
year = 2021,
|
125 |
+
note = {If you use this software, please cite it as below.},
|
126 |
+
publisher = {Zenodo},
|
127 |
+
version = {0.1},
|
128 |
+
doi = {10.5281/zenodo.5143773},
|
129 |
+
url = {https://doi.org/10.5281/zenodo.5143773}
|
130 |
+
}
|
131 |
+
```
|
132 |
+
|
133 |
+
OpenAI CLIP paper
|
134 |
+
```bibtex
|
135 |
+
@inproceedings{Radford2021LearningTV,
|
136 |
+
title={Learning Transferable Visual Models From Natural Language Supervision},
|
137 |
+
author={Alec Radford and Jong Wook Kim and Chris Hallacy and A. Ramesh and Gabriel Goh and Sandhini Agarwal and Girish Sastry and Amanda Askell and Pamela Mishkin and Jack Clark and Gretchen Krueger and Ilya Sutskever},
|
138 |
+
booktitle={ICML},
|
139 |
+
year={2021}
|
140 |
+
}
|
141 |
+
```
|
142 |
+
|
143 |
+
```bibtex
|
144 |
+
@Article{liu2022convnet,
|
145 |
+
author = {Zhuang Liu and Hanzi Mao and Chao-Yuan Wu and Christoph Feichtenhofer and Trevor Darrell and Saining Xie},
|
146 |
+
title = {A ConvNet for the 2020s},
|
147 |
+
journal = {Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR)},
|
148 |
+
year = {2022},
|
149 |
+
}
|
150 |
+
```
|
151 |
+
|
152 |
+
```bibtex
|
153 |
+
@misc{rw2019timm,
|
154 |
+
author = {Ross Wightman},
|
155 |
+
title = {PyTorch Image Models},
|
156 |
+
year = {2019},
|
157 |
+
publisher = {GitHub},
|
158 |
+
journal = {GitHub repository},
|
159 |
+
doi = {10.5281/zenodo.4414861},
|
160 |
+
howpublished = {\url{https://github.com/rwightman/pytorch-image-models}}
|
161 |
+
}
|
162 |
+
```
|