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

Road to BatchedPytorchWithoutJax - PR1 #122

Open
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

GiulioRomualdi
Copy link
Member

@GiulioRomualdi GiulioRomualdi commented Jan 9, 2025

⚠️ This PR must be merged after #120 and #121.

This is the first PR in a long series (still a work in progress) aimed at creating a PyTorch interface that does not require going through JAX for enabling the batch operation

Important commits:

  1. 89b6a0b In this commit, I attempted to make the function that generates the rotation from RPY work with batches. To address the mismatch between CasADi and other NumPy-like arrays (PyTorch, NumPy, and JAX), I modified the CasadiLike functions so that they behave similarly to NumPy. For instance:

    • The shape property now behaves like the others.
    • The reshape function accounts for the fact that CasADi stores numbers in column-major order, while NumPy-like libraries store them in row-major order.
  2. 9ea1952 Here, I made the skew function for PyTorch work with batches. Thanks to this modification, there is no longer a need to reshape the base velocity as was done in some algorithms (see crba).


📚 Documentation preview 📚: https://adam-docs--122.org.readthedocs.build/en/122/

@GiulioRomualdi GiulioRomualdi requested a review from Giulero January 9, 2025 22:52
@GiulioRomualdi GiulioRomualdi self-assigned this Jan 9, 2025
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