Skip to content

Commit 9a6f561

Browse files
author
Andrea Palazzi
authored
Update README.md
1 parent 53071ca commit 9a6f561

File tree

1 file changed

+31
-1
lines changed

1 file changed

+31
-1
lines changed

README.md

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,32 @@
11
# ConvLSTM_pytorch
2-
Implementation of Convolutional LSTM in PyTorch.
2+
**[This](https://github.com/ndrplz/ConvLSTM_pytorch/blob/master/convlstm.py)** file **implements of Convolutional LSTM in PyTorch** made by [me](https://github.com/ndrplz) and [DavideA](https://github.com/DavideA).
3+
4+
We started from [this](https://github.com/rogertrullo/pytorch_convlstm/blob/master/conv_lstm.py) implementation and heavily refactored it add added features to match our needs.
5+
6+
### How to Use
7+
The `ConvLSTM` module derives from `nn.Module` so it can be used as any other PyTorch module.
8+
9+
The ConvLSTM class supports an arbitrary number of layers. In this case, it can be specified the hidden dimension (that is, the number of channels) and the kernel size of each layer. In the case more layers are present but a single value is provided, this is replicated for all the layers. For example, in the following snippet each of the three layers has a different hidden dimension but the same kernel size.
10+
11+
Example usage:
12+
```
13+
model = ConvLSTM(input_size=(height, width),
14+
input_dim=channels,
15+
hidden_dim=[64, 64, 128],
16+
kernel_size=(3, 3),
17+
num_layers=3,
18+
batch_first=True
19+
bias=True,
20+
return_all_layers=False)
21+
```
22+
23+
### TODO (in progress...)
24+
- Comment code
25+
- Add docs
26+
- Add example usage on a toy problem
27+
- Implement stateful mechanism
28+
- ...
29+
30+
### Disclaimer
31+
32+
This is still a work in progress and is far from being perfect: if you find any bug please don't hesitate to open an issue.

0 commit comments

Comments
 (0)