Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add sliceUpdate util #7876

Merged
merged 4 commits into from
Jul 28, 2023
Merged

Conversation

pforderique
Copy link
Contributor

The Keras implementation of the CachedMultiHeadAttention layer uses a non TF op, slice_update, to modify tensors in the call method.

This PR adds this as a util function while we discuss adding this op to TFJS.

tfjs-layers/src/layers/nlp/utils.ts Show resolved Hide resolved
tfjs-layers/src/layers/nlp/utils.ts Outdated Show resolved Hide resolved
tfjs-layers/src/layers/nlp/utils.ts Outdated Show resolved Hide resolved
tfjs-layers/src/layers/nlp/utils.ts Outdated Show resolved Hide resolved
@mattsoulanille
Copy link
Member

@Linchenn This one is ready for you to take a look. Thanks!

Copy link
Collaborator

@Linchenn Linchenn left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@mattsoulanille mattsoulanille enabled auto-merge (squash) July 28, 2023 00:22
@mattsoulanille mattsoulanille merged commit 4e7d5f6 into tensorflow:master Jul 28, 2023
2 checks passed
@pforderique pforderique deleted the slice-update branch July 28, 2023 00:39
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.

None yet

3 participants