Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

target_size=None can not work. #16

Closed
kuixu opened this issue Nov 19, 2016 · 2 comments
Closed

target_size=None can not work. #16

kuixu opened this issue Nov 19, 2016 · 2 comments

Comments

@kuixu
Copy link

kuixu commented Nov 19, 2016

I found code about the input shape.

    if target_size:
        input_shape = target_size + (3,)
    else:
        input_shape = (None, None, 3)

When I set target_size=None, error encountered as below:

Traceback (most recent call last):
  File "train.py", line 132, in <module>
    data_dir, label_dir, target_size=target_size, resume_training=True)
  File "train.py", line 102, in train
    batch_size=batch_size, shuffle=True
  File "/data/kuixu/exper/fcn/Keras-FCN/utils/SegDataGenerator.py", line 186, in flow_from_directory
    save_to_dir=save_to_dir, save_prefix=save_prefix, save_format=save_format)
  File "/data/kuixu/exper/fcn/Keras-FCN/utils/SegDataGenerator.py", line 26, in __init__
    self.target_size = tuple(target_size)
TypeError: 'NoneType' object is not iterable

please help

@MarvinTeichmann
Copy link
Owner

MarvinTeichmann commented Jan 12, 2017

I cannot find the line you quoted in my code:

    if target_size:
        input_shape = target_size + (3,)
    else:
        input_shape = (None, None, 3)

Can you point me to the right direction?

@MarvinTeichmann
Copy link
Owner

Please reopen if you can provide a more elaborate problem description.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants