Skip to content
This repository was archived by the owner on Nov 8, 2022. It is now read-only.
This repository was archived by the owner on Nov 8, 2022. It is now read-only.

Performance issue in the definition of _inference, examples/memn2n_dialogue/memn2n_dialogue.py(P1) #227

Description

@DLPerf

Hello, I found a performance issue in the difinition of _inference, examples/memn2n_dialogue/memn2n_dialogue.py, tf.nn.embedding_lookup will be calculated repeately during the program execution, resulting in reduced efficiency. So I think it should be created before the loop.

The same issue exist in tf.reduce_sum in line 187 and 200.

Looking forward to your reply. Btw, I am very glad to create a PR to fix it if you are too busy.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions