Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Traceback (most recent call last):
- File "custreg.py", line 24, in <module>
- activity_regularizer=cust_reg))
- File "/usr/local/lib/python2.7/dist-packages/keras/models.py", line 422, in add
- layer(x)
- File "/usr/local/lib/python2.7/dist-packages/keras/engine/topology.py", line 578, in __call__
- regularization_losses = [self.activity_regularizer(x) for x in _to_list(output)]
- File "custreg.py", line 12, in cust_reg
- m = K.dot(K.transpose(w), w) - K.eye(w.shape)
- File "/usr/local/lib/python2.7/dist-packages/keras/backend/tensorflow_backend.py", line 574, in eye
- return variable(np.eye(size), dtype, name)
- File "/usr/local/lib/python2.7/dist-packages/numpy/lib/twodim_base.py", line 180, in eye
- m = zeros((N, M), dtype=dtype)
- TypeError: 'TensorShape' object cannot be interpreted as an index
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement