Skip to content

Correct torch.nn.CrossEntropyLoss output shape specification#79568

Closed
azhx wants to merge 3 commits intopytorch:masterfrom
azhx:update_loss_docs
Closed

Correct torch.nn.CrossEntropyLoss output shape specification#79568
azhx wants to merge 3 commits intopytorch:masterfrom
azhx:update_loss_docs

Conversation

@azhx
Copy link
Copy Markdown
Contributor

@azhx azhx commented Jun 14, 2022

Fixes #79531

@azhx azhx requested review from albanD and jbschlosser as code owners June 14, 2022 21:46
@facebook-github-bot
Copy link
Copy Markdown
Contributor

Hi @azhx!

Thank you for your pull request and welcome to our community.

Action Required

In order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you.

Process

In order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA.

Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with CLA signed. The tagging process may take up to 1 hour after signing. Please give it that time before contacting us about it.

If you have received this in error or have any questions, please contact us at cla@fb.com. Thanks!

@facebook-github-bot
Copy link
Copy Markdown
Contributor

facebook-github-bot commented Jun 14, 2022

🔗 Helpful links

✅ No Failures (0 Pending)

As of commit 9ac6282 (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.

Copy link
Copy Markdown
Contributor

@jbschlosser jbschlosser 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 the update! Small formatting nit, otherwise LGTM

Comment thread torch/nn/modules/loss.py Outdated
Co-authored-by: Joel Schlosser <75754324+jbschlosser@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

@jbschlosser jbschlosser left a comment

Choose a reason for hiding this comment

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

LGTM!

@jbschlosser
Copy link
Copy Markdown
Contributor

@pytorchbot merge -a

@pytorch-bot
Copy link
Copy Markdown

pytorch-bot Bot commented Jun 14, 2022

❌ 🤖 pytorchbot command failed:

@pytorchbot: error: unrecognized arguments: -a

usage: @pytorchbot [-h] {merge,revert,rebase} ...

Try @pytorchbot help for more info.

@jbschlosser
Copy link
Copy Markdown
Contributor

@pytorchbot merge -g

@pytorchmergebot
Copy link
Copy Markdown
Collaborator

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

@pytorchmergebot
Copy link
Copy Markdown
Collaborator

Merge failed due to Refusing to merge as mandatory check(s) Facebook CLA Check failed for rule superuser
Raised by https://github.com/pytorch/pytorch/actions/runs/2498625541

@azhx
Copy link
Copy Markdown
Contributor Author

azhx commented Jun 14, 2022

Merge failed due to Refusing to merge as mandatory check(s) Facebook CLA Check failed for rule superuser Raised by https://github.com/pytorch/pytorch/actions/runs/2498625541

I submitted my CLA right after I opened the PR, not sure when that check is gonna be rerun

@jbschlosser jbschlosser added the ciflow/trunk Trigger trunk jobs on your pull request label Jun 14, 2022
@facebook-github-bot
Copy link
Copy Markdown
Contributor

Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Meta Open Source project. Thanks!

@jbschlosser jbschlosser added cla signed and removed cla signed ciflow/trunk Trigger trunk jobs on your pull request labels Jun 14, 2022
@jbschlosser
Copy link
Copy Markdown
Contributor

@pytorchbot merge -g

@pytorchmergebot
Copy link
Copy Markdown
Collaborator

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

@pytorchmergebot
Copy link
Copy Markdown
Collaborator

Merge failed due to 1 additional jobs have failed, first few of them are: trunk
Raised by https://github.com/pytorch/pytorch/actions/runs/2498658117

@albanD
Copy link
Copy Markdown
Collaborator

albanD commented Jun 15, 2022

@pytorchbot merge -f

@jbschlosser
Copy link
Copy Markdown
Contributor

@pytorchbot merge

@pytorchmergebot
Copy link
Copy Markdown
Collaborator

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

@github-actions
Copy link
Copy Markdown
Contributor

Hey @azhx.
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.

@jbschlosser jbschlosser added release notes: nn release notes category topic: docs topic category labels Jun 15, 2022
facebook-github-bot pushed a commit that referenced this pull request Jun 20, 2022
…#79568)

Summary:
Fixes #79531

Pull Request resolved: #79568
Approved by: https://github.com/jbschlosser

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

Reviewed By: malfet

Differential Revision: D37208296

Pulled By: malfet

fbshipit-source-id: 3e816c6adccf019598681bc5552cdb0bacb5413b
laurentdupin pushed a commit to laurentdupin/pytorch that referenced this pull request Apr 25, 2026
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.

torch.nn.CrossEntropyLoss output shape specification does not match behaviour

6 participants