Skip to content

Conversation

@emailweixu
Copy link
Collaborator

No description provided.

.. code-block:: python
concat = seq_concat_layer(a=layer1, b=layer2)
concat = seq_concat_layer(al=layer1, b=layer2)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

al -> a

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done


CHECK_EQ(inputLayers_.size(), 1UL);
numFilters_ = config_.num_filters();
asRowVector_ = config_.user_arg() != "as_col_vec";
Copy link
Contributor

@qingqing01 qingqing01 Jun 16, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

user_arg had been defined in ModelConfig.proto. I note it for the first time. Just mark it. :)

num_repeats,
as_row_vector=True,
name=None,
layer_attr=None):
Copy link
Contributor

@qingqing01 qingqing01 Jun 16, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The activation is implemented in C++ code. Should we add it to the Python interface or remove it in C++ code?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Also remove active_type argument for many layers in config_parser.py because it is automatically
handled by LayerBase.
@qingqing01
Copy link
Contributor

The test_repeat_layer.py was omitted.

Generating  test_repeat_layer
Traceback (most recent call last):
  File "/opt/python/2.7.12/lib/python2.7/runpy.py", line 174, in _run_module_as_main
    "__main__", fname, loader, pkg_name)
  File "/opt/python/2.7.12/lib/python2.7/runpy.py", line 72, in _run_code
    exec code in run_globals
  File "/home/travis/build/PaddlePaddle/Paddle/python/paddle/utils/dump_config.py", line 25, in <module>
    conf = parse_config(sys.argv[1], '')
  File "/home/travis/build/PaddlePaddle/Paddle/python/paddle/trainer/config_parser.py", line 3596, in parse_config
    make_config_environment(trainer_config, config_args))
IOError: [Errno 2] No such file or directory: 'test_repeat_layer.py'

Copy link
Contributor

@lcy-seso lcy-seso left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The codes LGTM, though unittest is failed due to the missing file.

Copy link
Contributor

@lcy-seso lcy-seso left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@qingqing01 qingqing01 merged commit 8266546 into PaddlePaddle:develop Jun 20, 2017
@emailweixu emailweixu deleted the repeat_layer branch March 16, 2018 23:04
chen2016013 pushed a commit to chen2016013/Paddle that referenced this pull request Oct 17, 2025
Co-authored-by: Ace-To-HYB <huangyaobin@foxmail.com>
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

Successfully merging this pull request may close these issues.

3 participants