An open API service indexing awesome lists of open source software.

https://github.com/veb-101/keras-vision

Porting vision models to Keras 3 for easily accessibility. Contains MobileViT v1, MobileViT v2, fastvit
https://github.com/veb-101/keras-vision

cnn computer-vision deep-learning fastvit jax keras keras3 mobilevit mobilevitv1 mobilevitv2 pytorch self-attention tensorflow transformers

Last synced: 2 days ago
JSON representation

Porting vision models to Keras 3 for easily accessibility. Contains MobileViT v1, MobileViT v2, fastvit

Awesome Lists containing this project

README

          

[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/keras-vision)](https://www.python.org/) [![PyPI version](https://badge.fury.io/py/keras-vision.svg)](https://badge.fury.io/py/keras-vision) [![Keras](https://img.shields.io/badge/Keras%203.x-%23D00000.svg?logo=Keras&logoColor=white)](https://github.com/keras-team/keras/releases) ![PyPI - Downloads](https://img.shields.io/pypi/dm/keras-vision?style=plastic&logo=Keras&logoColor=red&link=https%3A%2F%2Fpypi.org%2Fproject%2Fkeras-vision%2F)

Porting all models from everywhere to Keras to leverage multi-backend support.

Cause why not?🤷🏻‍♂️

# Table of Contents

- [Table of Contents](#table-of-contents)
- [Progress](#progress)
- [Updates](#updates)
- [Quick Setup](#quick-setup)
- [Stable PyPi Package](#stable-pypi-package)
- [OR](#or)
- [Latest Git Updates](#latest-git-updates)
- [Models Supported](#models-supported)

## Progress

- Working on adding MobileNet V4

## Updates

1. [2025-03-12] Finished adding **FastViT** image classification model by Apple added. The model weights are available at [url](https://huggingface.co/veb-101/apple-fastvit-Keras-3/tree/main).
2. [2025-02-22] Working (v1) FastViT classification code added.
3. [2024-06-24] Released MobileViT v2 - All Image Classification variants.
4. [2024-05-15] Fixed MobileViT v1 - Now works will all 3 backends. 🎉🎉
5. [2024-05-04] Converted MobileViT to Keras 3 and released weights of all 3 variants.
1. Jax backend currently not working, I'm working on a fix.
2. Release:

## Quick Setup

### Stable PyPi Package

```bash
pip install -U keras-vision
```

### OR

### Latest Git Updates

```bash
pip install git+https://github.com/veb-101/keras-vision.git
```

## Models Supported




# No.


Models


Paper


Additional Materials


Example notebook


Weights URL





1

MobileViT-V1


MobileViT: Light-weight, General-purpose, and Mobile-friendly Vision Transformer


Blogpost: Building MobileViT In Keras 3


Colab link


🤗


2

MobileViT-V2


Separable Self-attention for Mobile Vision Transformers


--


Colab link


🤗



2

FastViT


FastViT: A Fast Hybrid Vision Transformer using Structural Reparameterization


--


Colab link


🤗


## Citation

* MobileViT-v1

```
@inproceedings{mehta2022mobilevit,
title={MobileViT: Light-weight, General-purpose, and Mobile-friendly Vision Transformer},
author={Sachin Mehta and Mohammad Rastegari},
booktitle={International Conference on Learning Representations},
year={2022}
}
```

* MobileViT-v2
```
Mehta, S., & Rastegari, M. (2022). Separable Self-attention for Mobile Vision Transformers. ArXiv. https://arxiv.org/abs/2206.02680
```

* FastViT
```
@inproceedings{vasufastvit2023,
author = {Pavan Kumar Anasosalu Vasu and James Gabriel and Jeff Zhu and Oncel Tuzel and Anurag Ranjan},
title = {FastViT: A Fast Hybrid Vision Transformer using Structural Reparameterization},
booktitle={Proceedings of the IEEE/CVF International Conference on Computer Vision},
year = {2023}
}
```