Skip to content

Commit 82cd902

Browse files
committed
Update README
1 parent c9e6bc6 commit 82cd902

File tree

1 file changed

+39
-2
lines changed

1 file changed

+39
-2
lines changed

README.md

Lines changed: 39 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,51 @@
1111

1212
# Keras Image Models
1313

14-
## Description
14+
## Introduction
1515

1616
**K**eras **Im**age **M**odels (`kimm`) is a collection of image models, blocks and layers written in Keras 3. The goal is to offer SOTA models with pretrained weights in a user-friendly manner.
1717

18+
## Features
19+
20+
- 🚀 Almost all models have pre-trained weights on ImageNet
21+
22+
> **Note:**
23+
> The accuracy of the exported models can be found at [results-imagenet.csv (timm)](https://github.com/huggingface/pytorch-image-models/blob/main/results/results-imagenet.csv)
24+
25+
- 🧰 All models have a common API identical to `keras.applications.*`
26+
27+
```python
28+
model = kimm.models.RegNetY002(
29+
input_tensor: keras.KerasTensor = None,
30+
input_shape: typing.Optional[typing.Sequence[int]] = None,
31+
include_preprocessing: bool = True,
32+
include_top: bool = True,
33+
pooling: typing.Optional[str] = None,
34+
dropout_rate: float = 0.0,
35+
classes: int = 1000,
36+
classifier_activation: str = "softmax",
37+
weights: typing.Optional[str] = "imagenet",
38+
name: str = "RegNetY002",
39+
)
40+
```
41+
42+
- 🔥 All models support feature extraction (`feature_extractor=True`)
43+
44+
```python
45+
from keras import random
46+
import kimm
47+
48+
model = kimm.models.ConvNeXtAtto(feature_extractor=True)
49+
x = random.uniform([1, 224, 224, 3])
50+
y = model(x, training=False)
51+
# y becomes a dict
52+
for k, v in y.items():
53+
print(k, v.shape)
54+
```
55+
1856
## Installation
1957

2058
```bash
21-
# In a working [jax/tensorflow/torch/numpy] backend environment
2259
pip install keras kimm
2360
```
2461

0 commit comments

Comments
 (0)