Skip to content

TypeError: 'numpy.float64' object cannot be interpreted as an index #16

Description

@SeekPoint

python tasks/copy/train.py --iterations=50000
Building Computational Graph ... Traceback (most recent call last):
File "tasks/copy/train.py", line 82, in
batch_size
File "/Users/yike.ke/yike_prj/DNC-tensorflow/tasks/copy/dnc/dnc.py", line 46, in init
self.controller = controller_class(self.input_size, self.output_size, self.read_heads, self.word_size, self.batch_size)
File "/Users/yike.ke/yike_prj/DNC-tensorflow/tasks/copy/dnc/controller.py", line 45, in init
self.network_vars()
File "/Users/yike.ke/yike_prj/DNC-tensorflow/tasks/copy/feedforward_controller.py", line 16, in network_vars
self.W1 = tf.Variable(tf.truncated_normal([input_, 128], stddev=initial_std(input_)), name='layer1_W')
File "/Users/yike.ke/yike_prj/DNC-tensorflow/tasks/copy/feedforward_controller.py", line 13, in
initial_std = lambda in_nodes: np.min(1e-2, np.sqrt(2.0 / in_nodes))
File "/Users/yike.ke/yike_prj/ve_tf0.11_py2/venv/lib/python2.7/site-packages/numpy/core/fromnumeric.py", line 2372, in amin
out=out, **kwargs)
File "/Users/yike.ke/yike_prj/ve_tf0.11_py2/venv/lib/python2.7/site-packages/numpy/core/_methods.py", line 29, in _amin
return umr_minimum(a, axis, None, out, keepdims)
TypeError: 'numpy.float64' object cannot be interpreted as an index

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions