{"action":"closed","issue":{"url":"https://api.github.com/repos/titu1994/keras-coordconv/issues/6","repository_url":"https://api.github.com/repos/titu1994/keras-coordconv","labels_url":"https://api.github.com/repos/titu1994/keras-coordconv/issues/6/labels{/name}","comments_url":"https://api.github.com/repos/titu1994/keras-coordconv/issues/6/comments","events_url":"https://api.github.com/repos/titu1994/keras-coordconv/issues/6/events","html_url":"https://github.com/titu1994/keras-coordconv/issues/6","id":345179578,"node_id":"MDU6SXNzdWUzNDUxNzk1Nzg=","number":6,"title":"ValueError: setting an array element with a sequence","user":{"login":"socathie","id":22270063,"node_id":"MDQ6VXNlcjIyMjcwMDYz","avatar_url":"https://avatars3.githubusercontent.com/u/22270063?v=4","gravatar_id":"","url":"https://api.github.com/users/socathie","html_url":"https://github.com/socathie","followers_url":"https://api.github.com/users/socathie/followers","following_url":"https://api.github.com/users/socathie/following{/other_user}","gists_url":"https://api.github.com/users/socathie/gists{/gist_id}","starred_url":"https://api.github.com/users/socathie/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/socathie/subscriptions","organizations_url":"https://api.github.com/users/socathie/orgs","repos_url":"https://api.github.com/users/socathie/repos","events_url":"https://api.github.com/users/socathie/events{/privacy}","received_events_url":"https://api.github.com/users/socathie/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-07-27T10:44:23Z","updated_at":"2018-07-27T17:18:12Z","closed_at":"2018-07-27T17:18:12Z","author_association":"NONE","body":"This is the beginning of my network.\r\n\r\n```\r\nX = Input(shape=(x,y,z,1))\r\nout = CoordinateChannel3D()(X)\r\nout = ...\r\n```\r\n\r\nwhile x,y,z are some predefined dimensions, x!=y!=z.\r\n\r\nwhen I try to compile, I get the following error:\r\n\r\n```\r\n~\\Anaconda3\\lib\\site-packages\\keras\\engine\\topology.py in __call__(self, inputs, **kwargs)\r\n    601 \r\n    602             # Actually call the layer, collecting output(s), mask(s), and shape(s).\r\n--> 603             output = self.call(inputs, **kwargs)\r\n    604             output_mask = self.compute_mask(inputs, previous_mask)\r\n    605 \r\n\r\n~\\Documents\\GitHub\\decoding-fmri\\cnn\\coord.py in call(self, inputs, training, mask)\r\n    141             batch_shape, dim1, dim2, dim3, channels = input_shape\r\n    142 \r\n--> 143             xx_ones = K.ones(K.stack([batch_shape, dim3]), dtype='int32')\r\n    144             xx_ones = K.expand_dims(xx_ones, axis=-1)\r\n    145 \r\n\r\n~\\Anaconda3\\lib\\site-packages\\keras\\backend\\tensorflow_backend.py in ones(shape, dtype, name)\r\n    697         dtype = floatx()\r\n    698     tf_dtype = tf.as_dtype(dtype)\r\n--> 699     return variable(tf.constant_initializer(1., dtype=tf_dtype)(shape),\r\n    700                     dtype, name)\r\n    701 \r\n\r\n~\\Anaconda3\\lib\\site-packages\\tensorflow\\python\\ops\\init_ops.py in __call__(self, shape, dtype, partition_info, verify_shape)\r\n    215       verify_shape = self._verify_shape\r\n    216     return constant_op.constant(\r\n--> 217         self.value, dtype=dtype, shape=shape, verify_shape=verify_shape)\r\n    218 \r\n    219   def get_config(self):\r\n\r\n~\\Anaconda3\\lib\\site-packages\\tensorflow\\python\\framework\\constant_op.py in constant(value, dtype, shape, name, verify_shape)\r\n    212   tensor_value.tensor.CopyFrom(\r\n    213       tensor_util.make_tensor_proto(\r\n--> 214           value, dtype=dtype, shape=shape, verify_shape=verify_shape))\r\n    215   dtype_value = attr_value_pb2.AttrValue(type=tensor_value.tensor.dtype)\r\n    216   const_tensor = g.create_op(\r\n\r\n~\\Anaconda3\\lib\\site-packages\\tensorflow\\python\\framework\\tensor_util.py in make_tensor_proto(values, dtype, shape, verify_shape)\r\n    428     # If shape is None, numpy.prod returns None when dtype is not set, but raises\r\n    429     # exception when dtype is set to np.int64\r\n--> 430     if shape is not None and np.prod(shape, dtype=np.int64) == 0:\r\n    431       nparray = np.empty(shape, dtype=np_dt)\r\n    432     else:\r\n\r\n~\\Anaconda3\\lib\\site-packages\\numpy\\core\\fromnumeric.py in prod(a, axis, dtype, out, keepdims)\r\n   2564 \r\n   2565     return _methods._prod(a, axis=axis, dtype=dtype,\r\n-> 2566                           out=out, **kwargs)\r\n   2567 \r\n   2568 \r\n\r\n~\\Anaconda3\\lib\\site-packages\\numpy\\core\\_methods.py in _prod(a, axis, dtype, out, keepdims)\r\n     33 \r\n     34 def _prod(a, axis=None, dtype=None, out=None, keepdims=False):\r\n---> 35     return umr_prod(a, axis, dtype, out, keepdims)\r\n     36 \r\n     37 def _any(a, axis=None, dtype=None, out=None, keepdims=False):\r\n\r\nValueError: setting an array element with a sequence.\r\n```\r\n\r\nAny idea where does this error arise?"}}
{"actor":{"display_login":"socathie"}}