Skip to content

Commit

Permalink
feat: add torch._VF.lstm frontend
Browse files Browse the repository at this point in the history
  • Loading branch information
Sam-Armstrong committed Aug 8, 2024
1 parent e4c130f commit 7ff6f98
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion ivy/functional/backends/tensorflow/layers.py
Original file line number Diff line number Diff line change
Expand Up @@ -790,7 +790,7 @@ def lstm_update(
recurrent_bias = (
recurrent_bias.data if recurrent_bias is not None else recurrent_bias
)
if "cpu" in dev:
if "cpu" in dev.lower():
outputs, new_states = _cpu_lstm(
x,
init_h,
Expand Down
4 changes: 4 additions & 0 deletions ivy/functional/frontends/torch/_VF/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
import ivy.functional.frontends.torch as torch_frontend

def lstm(*args, **kwargs):
return torch_frontend.lstm(*args, **kwargs)
1 change: 1 addition & 0 deletions ivy/functional/frontends/torch/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -268,6 +268,7 @@ def promote_types_of_torch_inputs(
from .nn.functional import softmax, relu, lstm
from . import special
from . import tensor
from . import _VF
from .tensor import *
from . import blas_and_lapack_ops
from .blas_and_lapack_ops import *
Expand Down

0 comments on commit 7ff6f98

Please sign in to comment.