Skip to content

Shapes not documented properly in MarginRankingLoss Β #42884

@mariosasko

Description

@mariosasko

πŸ“š Documentation

This issue refers to #42864, but the original issue was closed by the author while I was writing my response to it.

These are the docs at the moment:
loss1

Based on the source the correct input/target shape is:

  • Input 1: (N, βˆ—) where βˆ— means, any number of additional dimensions
  • Input 2: (N, βˆ—) same shape as Input 1, or it has to be broadcastable to that shape
  • Target: (N, βˆ—), same shape as Input 1 or Input 2, or it has to be broadcastable to that shape

So I think this part in the docs should be fixed and an example of how to use the loss would be helpful.

cc @jlin27 @albanD @mruberry

Metadata

Metadata

Assignees

No one assigned

    Labels

    module: docsRelated to our documentation, both in docs/ and docblocksmodule: nnRelated to torch.nntriagedThis issue has been looked at a team member, and triaged and prioritized into an appropriate module

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions