Skip to content

Commit

Permalink
[README]
Browse files Browse the repository at this point in the history
  • Loading branch information
Kye committed Jan 6, 2024
1 parent b81d4a5 commit 6089401
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 2 deletions.
36 changes: 36 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@ A novel implementation of fusing ViT with Mamba into a fast, agile, and high per


## Usage

### `MultiModalMambaBlock`
- Basic Block with 1 pass through the vit and Mamba
- Multiple fusion layers
- Deep configuration

```python
# Import the necessary libraries
import torch
Expand Down Expand Up @@ -41,6 +47,36 @@ print(out.shape)

```


### `MMM`, Ready to use Model
- MMM, Fully ready to train Multi-Modal Mamba Model

```python
import torch
from mm_mamba.model import MMM

x = torch.randint(0, 10000, (1, 224))
img = torch.randn(1, 3, 224, 224)

model = MMM(
vocab_size=10000,
dim=512,
depth=6,
dropout=0.1,
heads=8,
d_state=512,
image_size=224,
patch_size=16,
encoder_dim=512,
encoder_depth=6,
encoder_heads=8,
fusion_method="visual_expert",
)

out = model(x, img)
print(out.shape)
```

# License
MIT

Expand Down
4 changes: 2 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api"

[tool.poetry]
name = "mmm-zeta"
version = "0.0.6"
version = "0.0.7"
description = "MMM - Pytorch"
license = "MIT"
authors = ["Kye Gomez <[email protected]>"]
Expand All @@ -27,11 +27,11 @@ packages = [

[tool.poetry.dependencies]
python = "^3.6"
swarms = "*"
torch = "2.1.2"
zetascale = "1.4.0"



[tool.poetry.group.lint.dependencies]
ruff = "^0.1.6"
types-toml = "^0.10.8.1"
Expand Down

0 comments on commit 6089401

Please sign in to comment.