Skip to content

Conversation

@jroesch
Copy link
Member

@jroesch jroesch commented Dec 12, 2018

I'm starting the process of upstreaming the bits and pieces of Relay we developed while prototyping new features. This PR is composed of bug fixes and refactors which should make it easier to port those changes.

bool FunctionNode::IsPrimitive() const {
NodeRef res = FunctionGetAttr(GetRef<Function>(this), "Primitive");
const ir::IntImm* pval = res.as<ir::IntImm>();
return pval && pval->value != 0;
Copy link
Contributor

Choose a reason for hiding this comment

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

I think the indentation is not needed.

Copy link
Contributor

Choose a reason for hiding this comment

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

also fix this since it's failing CI lint test.

*
* \return Whether the function is primitive or not.
*/
bool IsPrimitive() const;
Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Member Author

Choose a reason for hiding this comment

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

Yeah I was cherry-picking changes from an old branch 😄 got distracted at TVM conference while working on this PR.

Copy link
Contributor

@wweic wweic left a comment

Choose a reason for hiding this comment

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

Thanks! LGTM

@tqchen tqchen merged commit 395804e into apache:master Dec 22, 2018
@tqchen
Copy link
Member

tqchen commented Dec 22, 2018

Thanks, @wweic @jroesch , this is now merged

FrozenGene pushed a commit to FrozenGene/tvm that referenced this pull request Dec 27, 2018
wweic pushed a commit to neo-ai/tvm that referenced this pull request Feb 20, 2019
wweic pushed a commit to neo-ai/tvm that referenced this pull request Feb 20, 2019
@jroesch jroesch deleted the expr-refactor branch February 4, 2021 04:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants