Skip to content

[Bug]: Hybrid Entity-Soft Particles Generated inside Rigid Component #2288

@Annie-spaces

Description

@Annie-spaces

Bug Description

When using hybrid material, the soft particles were not only grown on the rigid body, but also appeared inside the rigid body. We wonder if this is designed on purpose, or if this is a bug

Many white particles were half inside the rigid cube
Image

After changing the transprancy of the cube, we can see there are a lot of particles inside the cube
Image

I read through the hybrid entity.py. and I think it is this part of code that let particles generated all over the body
Image
As we can see, the mesh is only equal to the outer_mesh, and the inner_mesh was not used.

Steps to Reproduce

deformdemo.zip

Attached zip file contains the program and the urdf file

Expected Behavior

We were expecting the soft particles to be generated only outside the rigid body

Screenshots/Videos

No response

Relevant log output

[Genesis] [12:33:55] [INFO] ╭───────────────────────────────────────────────╮
[Genesis] [12:33:55] [INFO] │┈┉┈┉┈┉┈┉┈┉┈┉┈┉┈┉┈┉┈ Genesis ┈┉┈┉┈┉┈┉┈┉┈┉┈┉┈┉┈┉┈│
[Genesis] [12:33:55] [INFO] ╰───────────────────────────────────────────────╯
[Genesis] [12:33:55] [WARNING] Torch GPU backend not available. Falling back to CPU device.
[Genesis] [12:34:07] [INFO] Running on [11th Gen Intel(R) Core(TM) i7-11370H @ 3.30GHz] with backend gs.vulkan. Device memory: 31.84 GB.
[Genesis] [12:34:07] [INFO] 🚀 Genesis initialized. 🔖 version: 0.3.11, 🎨 theme: dark, 🌱 seed: gs.cpu, 🐛 debug: False, 📏 precision: 32, 🔥 performance: False, 💬 verbose: INFO
[Genesis] [12:34:21] [WARNING] Using a simulation timestep smaller than 2ms is not recommended for 'use_gjk_collision=False' as it could lead to numerically unstable collision detection.
[Genesis] [12:34:22] [INFO] Scene <1a18368> created.
[Genesis] [12:34:22] [INFO] Adding <gs.RigidEntity>. idx: 0, uid: <0aa35b5>, morph: <gs.morphs.Plane>, material: <gs.materials.Rigid>.
[Genesis] [12:34:23] [INFO] Adding <gs.HybridEntity>. idx: 1, uid: <3a17e8f>, morph: <gs.morphs.URDF(file='C:\Users\lulu\PycharmProjects\GenSim\Test_Functionality\deformdemo\objects\AutoCube.urdf')>, material: <gs.materials.Hybrid>.
[Genesis] [12:34:23] [INFO] Use default coupling in hybrid. Overwrite `needs_coup` in rigid material to False
[Genesis] [12:34:23] [INFO] Adding <gs.RigidEntity>. idx: 1, uid: <0107845>, morph: <gs.morphs.URDF(file='C:\Users\lulu\PycharmProjects\GenSim\Test_Functionality\deformdemo\objects\AutoCube.urdf')>, material: <gs.materials.Rigid>.
[Genesis] [12:34:23] [INFO] Applying offset to base link's pose with user provided value in morph.
[Genesis] [12:34:23] [INFO] Adding <gs.MPMEntity>. idx: 2, uid: <12a5d19>, morph: <gs.morphs.MeshSet(file='C:\Users\lulu\PycharmProjects\GenSim\Test_Functionality\deformdemo')>, material: <gs.materials.MPM.Muscle>.
[Genesis] [12:34:23] [INFO] Sampled 10,648 particles.
[Genesis] [12:34:25] [INFO] Building scene <1a18368>...
[Genesis] [12:34:37] [INFO] Compiling simulation kernels...
C:\Users\lulu\anaconda3\envs\env-genesis\lib\site-packages\gstaichi\_test_tools\warnings_helper.py:11: UserWarning:

cannot create weak reference to 'tuple' object. Template mapper caching disabled.

[Genesis] [12:35:07] [INFO] Building visualizer...
[Genesis] [12:35:09] [INFO] Viewer created. Resolution: 1600×1200, max_FPS: 60.
[Genesis] [12:35:16] [INFO] Running at 0.32 FPS.
[Genesis] [12:35:21] [INFO] Running at 0.19 FPS.
[Genesis] [12:35:25] [INFO] Running at 0.19 FPS.
[Genesis] [12:35:31] [INFO] Running at 0.19 FPS.
[Genesis] [12:35:35] [INFO] Running at 0.19 FPS.

Environment

  • OS: Windows 11
  • GPU/CPU: CPU
  • GPU-driver version: N/A
  • CUDA / CUDA-toolkit version: N/A

Release version or Commit ID

Genesis 0.3.11

Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions