Skip to content

Comments

Clarify reduction with empty axes and scalar input#741

Merged
fdwr merged 12 commits intowebmachinelearning:mainfrom
inexorabletash:reduction-reword
Jul 30, 2024
Merged

Clarify reduction with empty axes and scalar input#741
fdwr merged 12 commits intowebmachinelearning:mainfrom
inexorabletash:reduction-reword

Conversation

@inexorabletash
Copy link
Contributor

@inexorabletash inexorabletash commented Jul 24, 2024

Improve the description of the reduction ops:

  • Give in-line definition for L1/L2.
  • Make "input values" slightly clearer.
  • Explicitly note that if the input is a scalar, so is the output.
  • State how the reduction function is applied for empty axes.
  • Standardize on "reduction operation" not "reduce operation".
  • Don't style list of reduction ops as non-normative note.

Fixes #740


Preview | Diff

Improve the description of the reduction ops:

- Give in-line definition for L1/L2.
- Make "input values" slightly clearer.
- Explicitly note that if the input is a scalar, so is the output.
- State how the reduction function is applied for empty axes.
- Standardize on "reduction operation" not "reduce operation".

Fixes #740
@inexorabletash
Copy link
Contributor Author

@philloooo - does this make the behavior clearer?

The "reduction types" list was styled as a non-normative note. The
element-wise ops (add, equal, abs, etc.) don't do this. Be consistent
here.
@inexorabletash inexorabletash changed the title Editorial: Clarify reduction with empty axes and scalar input Clarify reduction with empty axes and scalar input Jul 24, 2024
Copy link
Contributor

@huningxin huningxin left a comment

Choose a reason for hiding this comment

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

LGTM!

@huningxin huningxin requested a review from fdwr July 27, 2024 09:08
Copy link
Collaborator

@fdwr fdwr left a comment

Choose a reason for hiding this comment

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

Clarification is goodness 👍. Some wording thoughts.

Copy link
Collaborator

@fdwr fdwr left a comment

Choose a reason for hiding this comment

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

👍

@fdwr fdwr merged commit 4697a0d into webmachinelearning:main Jul 30, 2024
github-actions bot added a commit that referenced this pull request Jul 30, 2024
SHA: 4697a0d
Reason: push, by fdwr

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@inexorabletash inexorabletash deleted the reduction-reword branch July 30, 2024 19:06
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.

Question on reduction with empty axes and scalar input

3 participants