Skip to content

A small problem in the maxPool2D initializer #551

@cdhcs1516

Description

@cdhcs1516

Issue Description

We run the code of srgan with tensorflow 0.1.1 and tensorlayer 1.8.5, and we meet an error shown as:

File "/home/deeplearning/.local/lib/python2.7/site-packages/tensorlayer/layers/pooling.py", line 205, in init
raise Exception("len(strides) should be 2.")
Exception: len(strides) should be 2.

Then we go to the implemention of the pooling.py and find some confusion. The Line 248-249 of pooling.py demonstrated as follows:

if len(strides) == 2:
    raise Exception("len(strides) should be 2.")

Obviously it is invalid. Maybe it should be:

if len(strides) != 2:
    raise Exception("len(strides) should be 2.")

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions