Open-Awesome
CategoriesAlternativesStacksSelf-HostedExplore
Open-Awesome

© 2026 Open-Awesome. Curated for the developer elite.

TermsPrivacyAboutGitHubRSS
  1. Home
  2. Machine Learning
  3. rnn

rnn

BSD-3-ClauseLua

A Recurrent Neural Network library for Torch7's nn, providing RNN, LSTM, GRU, and other sequence modeling modules.

GitHubGitHub
942 stars309 forks0 contributors

What is rnn?

rnn is a Recurrent Neural Network library for Torch7's nn package. It provides modules for building and training RNNs, LSTMs, GRUs, and other sequence models, enabling developers to implement complex temporal dependencies in their machine learning models. The library addresses the need for efficient and flexible tools for sequence modeling within the Torch ecosystem.

Target Audience

Machine learning researchers and developers using Torch7 who need to implement recurrent neural networks for tasks like natural language processing, time-series analysis, or sequence prediction.

Value Proposition

rnn offers a comprehensive and modular set of recurrent modules that integrate seamlessly with Torch7's nn package. Its key advantages include support for variable-length sequences, efficient handling of zero-padded inputs, and optimized implementations like FastLSTM, making it a go-to choice for sequence modeling in Torch.

Overview

Recurrent Neural Network library for Torch7's nn

Use Cases

Best For

  • Implementing language models with LSTMs or GRUs
  • Time-series prediction using recurrent networks
  • Building encoder-decoder architectures for sequence-to-sequence tasks
  • Developing visual attention models for image captioning
  • Training bidirectional RNNs for contextual understanding
  • Handling variable-length sequences with padding in batches

Not Ideal For

  • New projects in the Torch ecosystem requiring active maintenance and updates
  • Teams using modern Python-based frameworks like PyTorch or TensorFlow
  • Applications needing the latest RNN advancements or extensive community support
  • Developers unfamiliar with Lua or complex dependency management via luarocks

Pros & Cons

Pros

Comprehensive Module Suite

Includes a wide array of RNN modules such as AbstractRecurrent, LSTM, GRU, Sequencer, and BiSequencer, enabling flexible design of various sequence models as detailed in the README.

Efficient Sequence Handling

Modules like MaskZero and TrimZero optimize processing of variable-length sequences by masking or trimming zero-padded inputs, improving batch efficiency for tasks like language modeling.

Seamless Torch7 Integration

Designed to extend Torch7's nn package, ensuring compatibility with existing neural network components and allowing easy combination with other modules in the ecosystem.

Proven Performance Benchmarks

Examples in the README, such as the noise-contrastive estimate script, demonstrate high throughput (e.g., 20,000 words/second) on large datasets like Google Billion Words using optimized FastLSTM.

Cons

Deprecated and Unmaintained

The library is explicitly marked as deprecated in favor of torch/rnn, meaning no new features, bug fixes, or security updates will be provided, as stated in the README.

Outdated Framework Dependency

Relies on Torch7 and Lua, which have been largely superseded by PyTorch, limiting its relevance and making it less accessible due to a shrinking community and ecosystem.

Complex Setup and Dependency Issues

Installation requires managing dependencies with luarocks and specific Torch modules (e.g., nn, dpnn), which can be error-prone and less straightforward than modern package managers like pip.

Frequently Asked Questions

Quick Stats

Stars942
Forks309
Contributors0
Open Issues74
Last commit8 years ago
CreatedSince 2015

Tags

#deep-learning#neural-networks#torch7#time-series#machine-learning#nlp#lstm#recurrent-neural-networks

Built With

T
Torch7
L
Lua

Included in

Machine Learning72.2k
Auto-fetched 12 hours ago

Related Projects

PyTorch - Tensors and Dynamic neural networks in Python with strong GPU accelerationPyTorch - Tensors and Dynamic neural networks in Python with strong GPU acceleration

Tensors and Dynamic neural networks in Python with strong GPU acceleration

Stars99,591
Forks27,643
Last commit11 hours ago
keraskeras

Deep Learning for humans

Stars64,059
Forks19,760
Last commit1 day ago
streamlitstreamlit

Streamlit — A faster way to build and share data apps.

Stars44,427
Forks4,221
Last commit23 hours ago
gradiogradio

Build and share delightful machine learning apps, all in Python. 🌟 Star to support our work!

Stars42,484
Forks3,428
Last commit2 days ago
Community-curated · Updated weekly · 100% open source

Found a gem we're missing?

Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.

Submit a projectStar on GitHub