Skip to content

The following problems occurred when running train.py. Would you please help me? Thank you very much. #6

Open

Description

@zhp66

Traceback (most recent call last):
File "C:/Users/58413/Desktop/ODL-master/ODL-master/src/train.py", line 61, in
model.compile(optimizer=optim, loss = ['mse','mse','mse'], hedge = True, loss_weights = [1.0/3]*3, metrics =['accuracy'])
File "C:\Anaconda3\lib\site-packages\keras\engine\training.py", line 684, in compile
total_loss = K.sum(K.dot(self.holder, self.metrics_tensors))
File "C:\Anaconda3\lib\site-packages\keras\backend\tensorflow_backend.py", line 790, in dot
if ndim(x) is not None and (ndim(x) > 2 or ndim(y) > 2):
File "C:\Anaconda3\lib\site-packages\keras\backend\tensorflow_backend.py", line 396, in ndim
dims = x.get_shape()._dims
AttributeError: 'list' object has no attribute 'get_shape'

Activity

  1. phquang commented on Sep 30, 2020

    @phquang
    Contributor

    Hi, it seems like you are using Tensorflow backend while our implementation only supports Theano backend. Moreover, please check and use the correct dependencies versions.

  2. zhp66 commented on Sep 30, 2020

    @zhp66
    Author

    Thank you very much for your reply. I have another question: can onn solve the regression problem?

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

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions