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

C++ tree with path API #19366

Merged
merged 1 commit into from
Dec 1, 2024
Merged

C++ tree with path API #19366

merged 1 commit into from
Dec 1, 2024

Conversation

copybara-service[bot]
Copy link

@copybara-service copybara-service bot commented Nov 14, 2024

C++ tree with path API

  • Make tree_util.tree_flatten_with_path and tree_map_with_path APIs to be C++-based, to speed up the pytree flattening.

  • Moves all the key classes down to C++ level, while keeping the APIs unchanged.

    • Known small caveats: they are no longer Python dataclasses, and pattern matching might make pytype unhappy.
  • Registered defaultdict and ordereddict via the keypath API now.

@copybara-service copybara-service bot force-pushed the test_694219933 branch 13 times, most recently from 5b129db to 3b2f5d6 Compare November 21, 2024 22:48
@copybara-service copybara-service bot force-pushed the test_694219933 branch 8 times, most recently from afc93cd to d3d76ca Compare December 1, 2024 04:55
* Make tree_util.tree_flatten_with_path and tree_map_with_path APIs to be C++-based, to speed up the pytree flattening.

* Moves all the key classes down to C++ level, while keeping the APIs unchanged.
  * Known small caveats: they are no longer Python dataclasses, and pattern matching might make pytype unhappy.

* Registered defaultdict and ordereddict via the keypath API now.

PiperOrigin-RevId: 701613257
@copybara-service copybara-service bot merged commit 6b8d80a into main Dec 1, 2024
1 check passed
@copybara-service copybara-service bot deleted the test_694219933 branch December 1, 2024 05:30
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