Coder Social home page Coder Social logo

Comments (2)

batzner avatar batzner commented on July 17, 2024

Hi @makai281, thanks for reaching out. I tried to reproduce your code, but it didn't raise an error. Could you provide a minimal code example that raises an error?

Here is my code:

import tensorflow as tf

from ind_rnn_cell import IndRNNCell

sess = tf.Session()

time_steps = 100
hidden_size = 10
batch_size = 32
inputs = tf.random_uniform([batch_size, time_steps, 20])

recurrent_max = pow(2, 1.0 / time_steps)
fw_rnn_cell = IndRNNCell(hidden_size, recurrent_max_abs=recurrent_max)
bw_rnn_cell = IndRNNCell(hidden_size, recurrent_max_abs=recurrent_max)
bi_states, _ = tf.nn.bidirectional_dynamic_rnn(
    fw_rnn_cell,
    bw_rnn_cell,
    inputs,
    dtype=tf.float32
)

sess.run(tf.global_variables_initializer())
output_fw, output_bw = sess.run(bi_states)
print(output_fw.shape, output_bw.shape)
# prints (32, 100, 10) (32, 100, 10)

Thanks!

from indrnn.

makai281 avatar makai281 commented on July 17, 2024

sorry for late reply. I seems there are some sub-standard usages in my code, but when I moved the build function to call , the error disappeared. So strange.

from indrnn.

Related Issues (16)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.