kwargs_ )  [
[source]  ](_modules/torch/nn/quantized/dynamic/modules/rnn.html#LSTM) ¶

    

A dynamic quantized LSTM module with floating point tensor as inputs and
outputs. We adopt the same interface as  torch.nn.LSTM  , please see [
https://pytorch.org/docs/stable/nn.html#torch.nn.LSTM
](https://pytorch.org/docs/stable/nn.html#torch.nn.LSTM) for documentation.

Examples:

    
    
    >>> rnn = nn.LSTM(10, 20, 2)
    >>> input = torch.randn(5, 3, 10)
    >>> h0 = torch.randn(2, 3, 20)
    >>> c0 = torch.randn(2, 3, 20)
    >>> output, (hn, cn) = rnn(input, (h0, c0))
    

[ Next ![](_static/images/chevron-right-orange.svg) ](rpc.html "Distributed
RPC Framework") [ ![](_static/images/chevron-right-orange.svg) Previous
](complex_numbers.html "Complex Numbers")

* * *

© Copyright 2019, Torch Contributors.

Built with [ Sphinx ](http://sphinx-doc.org/) using a [ theme
](https://github.com/rtfd/sphinx_rtd_theme) provided by [ Read the Docs
](https://readthedocs.org) .

  * Quantization 
    * Introduction to Quantization 
    * Quantized Tensors 
    * Operation coverage 
      * Quantized ` torch.Tensor  ` operations 
      * ` torch.nn.functional  `
      * ` torch.nn.intrinsic  `
      * ` torch.nn.qat  `
      * ` torch.quantization  `
      * ` torch.nn.quantized  `
      * ` torch.nn.quantized.dynamic  `
      * ` torch.nn.quantized.functional  `
      * Quantized dtypes and quantization schemes 
    * Quantization Workflows 
    * Model Preparation for Quantization 
    * torch.quantization 
      * Top-level quantization APIs 
      * Preparing model for quantization 
      * Utility functions 
      * Observers 
      * Debugging utilities 
    * torch.nn.intrinsic 
      * ConvBn1d 
      * ConvBn2d 
      * ConvBnReLU1d 
      * ConvBnReLU2d 
      * ConvReLU1d 
      * ConvReLU2d 
      * ConvReLU3d 
      * LinearReLU 
    * torch.nn.instrinsic.qat 
      * ConvBn2d 
      * ConvBnReLU2d 
      * ConvReLU2d 
      * LinearReLU 
    * torch.nn.intrinsic.quantized 
      * ConvReLU2d 
      * ConvReLU3d 
      * LinearReLU 
    * torch.nn.qat 
      * Conv2d 
      * Linear 
    * torch.nn.quantized 
      * Functional interface 
      * ReLU 
      * ReLU6 
      * ELU 
      * Hardswish 
      * Conv1d 
      * Conv2d 
      * Conv3d 
      * FloatFunctional 
      * QFunctional 
      * Quantize 
      * DeQuantize 
      * Linear 
      * BatchNorm2d 
      * BatchNorm3d 
      * LayerNorm 
      * GroupNorm 
      * InstanceNorm1d 
      * InstanceNorm2d 
      * InstanceNorm3d 
    * torch.nn.quantized.dynamic 
      * Linear 
      * LSTM 

![](https://www.googleadservices.com/pagead/conversion/795629140/?label=txkmCPmdtosBENSssfsC&guid=ON&script=0)

##  Docs

Access comprehensive developer documentation for PyTorch

[ View Docs ](https://pytorch.org/docs/stable/index.html)

##  Tutorials

Get in-depth tutorials for beginners and advanced developers

[ View Tutorials ](https://pytorch.org/tutorials)

##  Resources

Find development resources and get your questions answered

[ View Resources ](https://pytorch.org/resources)

[ ](https://pytorch.org/)

  * [ PyTorch ](https://pytorch.org/)
  * [ Get Started ](https://pytorch.org/get-started)
  * [ Features ](https://pytorch.org/features)
  * [ Ecosystem ](https://pytorch.org/ecosystem)
  * [ Blog ](https://pytorch.org/blog/)
  * [ Contributing ](https://github.com/pytorch/pytorch/blob/master/CONTRIBUTING.md)

  * [ Resources ](https://pytorch.org/resources)
  * [ Tutorials ](https://pytorch.org/tutorials)
  * [ Docs ](https://pytorch.org/docs/stable/index.html)
  * [ Discuss ](https://discuss.pytorch.org)
  * [ Github Issues ](https://github.com/pytorch/pytorch/issues)
  * [ Brand Guidelines ](https://pytorch.org/assets/brand-guidelines/PyTorch-Brand-Guidelines.pdf)

  * Stay Connected 
  * Email Address 

[ ](https://www.facebook.com/pytorch) [ ](https://twitter.com/pytorch) [
](https://www.youtube.com/pytorch)

To analyze traffic and optimize your experience