Skip to content

gelu layer setName using util::node_info(n).c_str() #459

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

Merged
merged 1 commit into from
May 13, 2021

Conversation

itsliupeng
Copy link
Contributor

Description

Set name of Gelu layer to "util::node_info(n).c_str()" instead of string "gelu", to prevent "Repeated layer name: gelu (layers must have distinct names)" error when building tensorrt engine from a module with multiple gelu layers.

Also format "trtorch::core::util::node_info(n).c_str()" to "util::node_info(n).c_str()".

Type of change

Please delete options that are not relevant and/or add your own.

  • Bug fix (non-breaking change which fixes an issue)

Checklist:

  • My code follows the style guidelines of this project (You can use the linters)
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas and hacks
  • I have made corresponding changes to the documentation
  • I have added tests to verify my fix or my feature
  • New and existing unit tests pass locally with my changes

Copy link
Collaborator

@peri044 peri044 left a comment

Choose a reason for hiding this comment

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

Thanks for catching this. LGTM

@peri044
Copy link
Collaborator

peri044 commented May 13, 2021

Please sign off your last commit to fix DCO

@narendasan narendasan merged commit c7c9785 into pytorch:master May 13, 2021
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