Skip to content

Properly setup __name__ on unary refs functions.#79178

Closed
ezyang wants to merge 5 commits intogh/ezyang/1217/basefrom
gh/ezyang/1217/head
Closed

Properly setup __name__ on unary refs functions.#79178
ezyang wants to merge 5 commits intogh/ezyang/1217/basefrom
gh/ezyang/1217/head

Conversation

@ezyang
Copy link
Copy Markdown
Contributor

@ezyang ezyang commented Jun 9, 2022

Stack from ghstack (oldest at bottom):

My hands hurt now. Yes I could have added type annotations if you care do it
yourself.

Signed-off-by: Edward Z. Yang ezyang@fb.com

My hands hurt now.  Yes I could have added type annotations if you care do it
yourself.

Signed-off-by: Edward Z. Yang <ezyang@fb.com>

[ghstack-poisoned]
@facebook-github-bot
Copy link
Copy Markdown
Contributor

facebook-github-bot commented Jun 9, 2022

🔗 Helpful links

✅ No Failures (0 Pending)

As of commit bd7b4b0 (more details on the Dr. CI page):

Expand to see more

💚 💚 Looks good so far! There are no failures yet. 💚 💚


This comment was automatically generated by Dr. CI (expand for details).

Please report bugs/suggestions to the (internal) Dr. CI Users group.

Click here to manually regenerate this comment.

@ezyang ezyang requested review from Chillee and mruberry June 9, 2022 02:11
My hands hurt now.  Yes I could have added type annotations if you care do it
yourself.

Signed-off-by: Edward Z. Yang <ezyangfb.com>

[ghstack-poisoned]
ezyang added a commit that referenced this pull request Jun 9, 2022
My hands hurt now.  Yes I could have added type annotations if you care do it
yourself.

Signed-off-by: Edward Z. Yang <ezyangfb.com>

ghstack-source-id: 3f39fef
Pull Request resolved: #79178
@ezyang ezyang changed the title Properly setup __name__ on refs functions. Properly setup __name__ on unary refs functions. Jun 9, 2022
My hands hurt now.  Yes I could have added type annotations if you care do it
yourself.

Signed-off-by: Edward Z. Yang <ezyangfb.com>

[ghstack-poisoned]
ezyang added a commit that referenced this pull request Jun 9, 2022
My hands hurt now.  Yes I could have added type annotations if you care do it
yourself.

Signed-off-by: Edward Z. Yang <ezyangfb.com>

ghstack-source-id: d27a4d5
Pull Request resolved: #79178
Comment thread torch/_refs/__init__.py Outdated

@_make_elementwise_unary_reference(ELEMENTWISE_TYPE_PROMOTION_KIND.ALWAYS_BOOL)
def signbit(a):
return prims.sign(a)
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

signbit

Copy link
Copy Markdown
Collaborator

@mruberry mruberry left a comment

Choose a reason for hiding this comment

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

Stamp to unblock but test failures are real (see inline comment, refs.signbit is calling sign)

My hands hurt now.  Yes I could have added type annotations if you care do it
yourself.

Signed-off-by: Edward Z. Yang <ezyangfb.com>

[ghstack-poisoned]
ezyang added a commit that referenced this pull request Jun 9, 2022
My hands hurt now.  Yes I could have added type annotations if you care do it
yourself.

Signed-off-by: Edward Z. Yang <ezyangfb.com>

ghstack-source-id: ff188ed
Pull Request resolved: #79178
My hands hurt now.  Yes I could have added type annotations if you care do it
yourself.

Signed-off-by: Edward Z. Yang <ezyangfb.com>

[ghstack-poisoned]
ezyang added a commit that referenced this pull request Jun 9, 2022
My hands hurt now.  Yes I could have added type annotations if you care do it
yourself.

Signed-off-by: Edward Z. Yang <ezyangfb.com>

ghstack-source-id: eaec8f1
Pull Request resolved: #79178
@ezyang
Copy link
Copy Markdown
Contributor Author

ezyang commented Jun 9, 2022

@pytorchbot merge -g

@pytorchmergebot
Copy link
Copy Markdown
Collaborator

@pytorchbot successfully started a merge job. Check the current status here

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jun 9, 2022

Hey @ezyang.
You've committed this PR, but it does not have both a 'release notes: ...' and 'topics: ...' label. Please add one of each to the PR. The 'release notes: ...' label should represent the part of PyTorch that this PR changes (fx, autograd, distributed, etc) and the 'topics: ...' label should represent the kind of PR it is (not user facing, new feature, bug fix, perf improvement, etc). The list of valid labels can be found here for the 'release notes: ...' and here for the 'topics: ...'.
For changes that are 'topic: not user facing' there is no need for a release notes label.

facebook-github-bot pushed a commit that referenced this pull request Jun 10, 2022
Summary:
My hands hurt now.  Yes I could have added type annotations if you care do it
yourself.

Signed-off-by: Edward Z. Yang <ezyangfb.com>

Pull Request resolved: #79178

Approved by: https://github.com/mruberry

Test Plan: contbuild & OSS CI, see https://hud.pytorch.org/commit/pytorch/pytorch/b18ba7e0364f2af4a1831b343681cc5e04ed1e57

Reviewed By: osalpekar

Differential Revision: D37059341

Pulled By: osalpekar

fbshipit-source-id: b8f06c8d070d9c043b1a50ee396a738d2334605c
@facebook-github-bot facebook-github-bot deleted the gh/ezyang/1217/head branch June 13, 2022 14:17
laurentdupin pushed a commit to laurentdupin/pytorch that referenced this pull request Apr 25, 2026
My hands hurt now.  Yes I could have added type annotations if you care do it
yourself.

Signed-off-by: Edward Z. Yang <ezyangfb.com>

Pull Request resolved: pytorch#79178

Approved by: https://github.com/mruberry
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.

4 participants