Skip to content

Conversation

@inexorabletash
Copy link
Contributor

@inexorabletash inexorabletash commented Mar 13, 2024

Per #388, the change #505 removed null value support in reshape()'s newShape parameter. That pull request missed updating the prose description to match.


Preview | Diff

Per #388, the change #505 removed null value support in reshape()'s
newShape parameter. That pull request missed updating the prose
description to match.
@inexorabletash inexorabletash requested a review from fdwr March 13, 2024 19:36
@inexorabletash
Copy link
Contributor Author

Trivial fix.

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.

👍 TY JB.
(@huningxin because this is so trivial, I'll merge it now)

@fdwr fdwr merged commit cee6fa6 into webmachinelearning:main Mar 13, 2024
github-actions bot added a commit that referenced this pull request Mar 13, 2024
SHA: cee6fa6
Reason: push, by fdwr

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
@fdwr
Copy link
Collaborator

fdwr commented Mar 13, 2024

p.s. I see we have two other places (GRU and BatchNormalization) that will need updating too:

const shape = [1,null,1,1]; <--------------------
return builder.relu(
  builder.add(
    builder.mul(
      builder.reshape(options.scale, shape),
      builder.div(
        builder.sub(input, builder.reshape(mean, shape)),
        builder.sqrt(builder.add(builder.reshape(variance, shape), builder.constant(options.epsilon)))
        )),
    builder.reshape(options.bias, shape))); <--------------------
    currentOutput = builder.reshape(currentOutput, [1, numDirections, null, hiddenSize]); <--------------------

(I can't get to it today, but added local todo)

@inexorabletash inexorabletash deleted the bugfix-reshape-not-nullable branch March 13, 2024 20:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants