Ecosyste.ms: Awesome

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

Awesome Lists | Featured Topics | Projects

https://github.com/nachiket273/vistrans

Implementations of transformers based models for different vision tasks
https://github.com/nachiket273/vistrans

botnet computer-vision pretrained-models python3 pytorch transformers vision-transformers

Last synced: 23 days ago
JSON representation

Implementations of transformers based models for different vision tasks

Awesome Lists containing this project

README

        

# VisTrans
Implementations of transformers based models for different vision tasks

## Install
1) Install from PyPI

```Python
pip install vistrans
```
2) Install from Anaconda

```Python
conda install -c nachiket273 vistrans
```

## Version 0.003 (06/30/2021)
------------------------------
[![PyPI version](https://badge.fury.io/py/vistrans.svg)](https://badge.fury.io/py/vistrans)

Minor fixes to fix issues with existing models.

## Version 0.002 (04/17/2021)
------------------------------
[![PyPI version](https://badge.fury.io/py/vistrans.svg)](https://badge.fury.io/py/vistrans)

Pretrained Pytorch Bottleneck Transformers for Visual Recognition including following


* botnet50
* botnet101
* botnet152


Implementation based off Official Tensorflow Implementation

## Usage
---------------------
pip install vistrans
```
1) List Pretrained Models.
```Python
from vistrans import BotNet
BotNet.list_pretrained()
```
2) Create Pretrained Models.
```Python
from vistrans import BotNet
model = BotNet.create_pretrained(name, img_size, in_ch, num_classes,
n_heads, pos_enc_type)
```
3) Create Custom Model
```Python
from vistrans import BotNet
model = BotNet.create_model(layers, img_size, in_ch, num_classes, groups,
norm_layer, n_heads, pos_enc_type)
```

## Version 0.001 (03/04/2021)
-----------------------------
[![PyPI version](https://badge.fury.io/py/vistrans.svg)](https://badge.fury.io/py/vistrans)

Pretrained Pytorch Vision Transformer Models including following


* vit_s16_224
* vit_b16_224
* vit_b16_384
* vit_b32_384
* vit_l16_224
* vit_l16_384
* vit_l32_384


Implementation based off official jax repository and timm's implementation

## Usage
---------------------
1) List Pretrained Models.
```Python
from vistrans import VisionTransformer
VisionTransformer.list_pretrained()
```
2) Create Pretrained Models.
```Python
from vistrans import VisionTransformer
model = VisionTransformer.create_pretrained(name, img_size, in_ch, num_classes)
```
3) Create Custom Model
```Python
from vistrans import VisionTransformer
model = VisionTransformer.create_model(img_size, patch_size, in_ch, num_classes,
embed_dim, depth, num_heads, mlp_ratio,
drop_rate, attention_drop_rate, hybrid,
norm_layer, bias)
```