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 error message when using custom_vmap with reverse-mode AD, and add docstrings. #25253

Closed
wants to merge 0 commits into from

Conversation

copybara-service[bot]
Copy link

Add error message when using custom_vmap with reverse-mode AD, and add docstrings.

The custom_vmap API is discussed in #9073, and it remains somewhat experimental and incomplete, but it is sufficiently widely used that it seemed worth adding it to the docs.

One specific pain point with custom_vmap is that it doesn't support reverse-mode autodiff, so I also added a better error message for this case. Before this change, using grad with a custom_vmap function would fail with an assert deep within the JAX internals. This now fails with a NotImplementedError that describes the problem.

@copybara-service copybara-service bot force-pushed the test_702731889 branch 6 times, most recently from 8c97e9c to deb4930 Compare December 9, 2024 19:00
@copybara-service copybara-service bot closed this Dec 9, 2024
@copybara-service copybara-service bot deleted the test_702731889 branch December 9, 2024 19:17
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.

1 participant