Skip to content

Update MjWarp dependency and associated changes#474

Merged
shi-eric merged 3 commits into
newton-physics:mainfrom
adenzler-nvidia:dev/adenzler/update-mjwarp
Jul 25, 2025
Merged

Update MjWarp dependency and associated changes#474
shi-eric merged 3 commits into
newton-physics:mainfrom
adenzler-nvidia:dev/adenzler/update-mjwarp

Conversation

@adenzler-nvidia

@adenzler-nvidia adenzler-nvidia commented Jul 25, 2025

Copy link
Copy Markdown
Member

njmax is now per world, so we need to change the numbers we pass there in MuJoCo solver.

Before your PR is "Ready for review"

  • All commits are signed-off to indicate that your contribution adheres to the Developer Certificate of Origin requirements
  • Necessary tests have been added and new examples are tested (see newton/tests/test_examples.py)
  • Documentation is up-to-date
  • Code passes formatting and linting checks with pre-commit run -a

Summary by CodeRabbit

  • Refactor
    • Improved internal handling of constraints in the MuJoCo solver for better model conversion consistency.
  • Chores
    • Updated the MuJoCo Warp package version used during installation.

Signed-off-by: Alain Denzler <adenzler@nvidia.com>
@coderabbitai

coderabbitai Bot commented Jul 25, 2025

Copy link
Copy Markdown
Contributor
📝 Walkthrough

Walkthrough

The update modifies how the number of equality constraints (nefc) and the maximum number of constraint Jacobian nonzeros (njmax) are set during MuJoCo model conversion. The explicit assignment to self.mj_data.nefc is removed, and the calculation of njmax is changed to use the maximum of nefc_per_env and self.mj_data.nefc, no longer multiplying by nworld. Additionally, the Git commit reference for the mujoco_warp package installation is updated in the ASV configuration.

Changes

File(s) Change Summary
newton/solvers/mujoco/solver_mujoco.py Removed explicit self.mj_data.nefc assignment; revised njmax calculation for MuJoCo Warp data.
asv.conf.json Updated Git commit hash for mujoco_warp package installation.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Note

⚡️ Unit Test Generation is now available in beta!

Learn more here, or try it out under "Finishing Touches" below.


📜 Recent review details

Configuration used: .coderabbit.yml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 162e92a and 7339e51.

📒 Files selected for processing (1)
  • asv.conf.json (1 hunks)
✅ Files skipped from review due to trivial changes (1)
  • asv.conf.json
⏰ Context from checks skipped due to timeout of 900000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Run GPU Unit Tests on AWS EC2 (Pull Request)
✨ Finishing Touches
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai generate unit tests to generate unit tests for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@shi-eric

Copy link
Copy Markdown
Member

@adenzler-nvidia Can you also update the versions in https://github.com/newton-physics/newton/blob/main/asv.conf.json ?

Signed-off-by: Alain Denzler <adenzler@nvidia.com>
Comment thread asv.conf.json Outdated
@adenzler-nvidia

Copy link
Copy Markdown
Member Author

@shi-eric updated MjWarp in the asv config. I'm actually not sure what the minimum version for mujoco is, but I suppose if it doesn't break it's fine. We don't seem to have a hardcoded min version in the MjWarp repo.

Fix install command

Signed-off-by: Eric Shi <97630937+shi-eric@users.noreply.github.com>
@shi-eric shi-eric merged commit cd09f5d into newton-physics:main Jul 25, 2025
10 checks passed
@coderabbitai coderabbitai Bot mentioned this pull request Aug 11, 2025
4 tasks
@coderabbitai coderabbitai Bot mentioned this pull request Jan 12, 2026
4 tasks
eric-heiden pushed a commit to eric-heiden/newton that referenced this pull request Jan 28, 2026
Signed-off-by: Alain Denzler <adenzler@nvidia.com>
Signed-off-by: Eric Shi <97630937+shi-eric@users.noreply.github.com>
Co-authored-by: Eric Shi <97630937+shi-eric@users.noreply.github.com>
vidurv-nvidia pushed a commit to vidurv-nvidia/newton that referenced this pull request Mar 6, 2026
# Description

Adds information and installation instructions for using Isaac Sim open
source repo.

## Type of change

- This change requires a documentation update

## Checklist

- [x] I have run the [`pre-commit` checks](https://pre-commit.com/) with
`./isaaclab.sh --format`
- [x] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [ ] I have updated the changelog and the corresponding version in the
extension's `config/extension.toml` file
- [ ] I have added my name to the `CONTRIBUTORS.md` or my name already
exists there

<!--
As you go through the checklist above, you can mark something as done by
putting an x character in it

For example,
- [x] I have done this task
- [ ] I have not done this task
-->
mmacklin pushed a commit to mmacklin/newton that referenced this pull request Apr 7, 2026
Signed-off-by: Alain Denzler <adenzler@nvidia.com>
Signed-off-by: Eric Shi <97630937+shi-eric@users.noreply.github.com>
Co-authored-by: Eric Shi <97630937+shi-eric@users.noreply.github.com>
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