mani-skill-nightly 2025.5.12.817__py3-none-any.whl → 2025.5.12.2356__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -260,6 +260,9 @@ class Articulation(BaseStruct[physx.PhysxArticulation]):
260
260
 
261
261
  @cached_property
262
262
  def _data_index(self):
263
+ """
264
+ Returns a tensor of the indices of the articulation in the GPU simulation for the physx_cuda backend.
265
+ """
263
266
  return torch.tensor(
264
267
  [px_articulation.gpu_index for px_articulation in self._objs],
265
268
  device=self.device,
@@ -268,6 +271,9 @@ class Articulation(BaseStruct[physx.PhysxArticulation]):
268
271
 
269
272
  @cached_property
270
273
  def fixed_root_link(self):
274
+ """
275
+ Returns a boolean tensor of whether the root link is fixed for each parallel articulation
276
+ """
271
277
  return torch.tensor(
272
278
  [x.links[0].entity.components[0].joint.type == "fixed" for x in self._objs],
273
279
  device=self.device,
@@ -567,6 +573,31 @@ class Articulation(BaseStruct[physx.PhysxArticulation]):
567
573
  def get_joints(self):
568
574
  return self.joints
569
575
 
576
+ def get_link_incoming_joint_forces(self):
577
+ """
578
+ Returns the incoming joint forces, referred to as spatial forces, for each link, with shape (N, M, 6), where N is the number of environments and M is the number of links.
579
+
580
+ Spatial forces are complex to describe and we recommend you see the physx documentation for how they are computed: https://nvidia-omniverse.github.io/PhysX/physx/5.6.0/docs/Articulations.html#link-incoming-joint-force
581
+
582
+ The mth spatial force refers to the mth link, and to find a particular link you can find the Link object first then use it's index attribute.
583
+
584
+ link = articulation.links_map[link_name]
585
+ link_index = link.index
586
+ link_incoming_joint_force = articulation.get_link_incoming_joint_forces()[:, link_index]
587
+
588
+ """
589
+ if self.scene.gpu_sim_enabled:
590
+ self.px.gpu_fetch_articulation_link_incoming_joint_forces()
591
+ # TODO (stao): we should lazy call the GPU data fetching functions in the future if necessarily. Since most users don't use this at the moment
592
+ # we just fetch it live here instead of with all the other fetch functions
593
+ return self.px.cuda_articulation_link_incoming_joint_forces.torch()[
594
+ self._data_index, :
595
+ ]
596
+ else:
597
+ return torch.from_numpy(
598
+ self._objs[0].get_link_incoming_joint_forces()[None, :]
599
+ )
600
+
570
601
  def get_links(self):
571
602
  return self.links
572
603
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: mani-skill-nightly
3
- Version: 2025.5.12.817
3
+ Version: 2025.5.12.2356
4
4
  Summary: ManiSkill3: A Unified Benchmark for Generalizable Manipulation Skills
5
5
  Home-page: https://github.com/haosulab/ManiSkill
6
6
  Author: ManiSkill contributors
@@ -785,7 +785,7 @@ mani_skill/utils/scene_builder/table/assets/table.glb,sha256=yw69itZDjBFg8JXZAr9
785
785
  mani_skill/utils/structs/README.md,sha256=qnYKimp_ZkgNcduURrYQxVTimNmq_usDMKoQ8VtMdCs,286
786
786
  mani_skill/utils/structs/__init__.py,sha256=BItR3Xe0z6xCrMHAEaH0AAAVyeonsQ3q-DJUyRUibAA,524
787
787
  mani_skill/utils/structs/actor.py,sha256=L0p6vkr8rGtJmF22xAq8Q7nhXKnDD5dahzODSAko0bg,17394
788
- mani_skill/utils/structs/articulation.py,sha256=c7e_Rfkhskg_Rqz1bkesqHCTzNubObLGZQS0BkkFZF0,34691
788
+ mani_skill/utils/structs/articulation.py,sha256=7SPlcgISUHu3xQCMEeTiJFJ_UsDmCS0rORw6qpgt0Yc,36376
789
789
  mani_skill/utils/structs/articulation_joint.py,sha256=TY6joQ0RpnVlHbQHdtx_QQYqTWgFHLiZ642SSWZUuTw,11736
790
790
  mani_skill/utils/structs/base.py,sha256=meGQK5Y4KtHKLnp9VeOZS2gtwg9tE55whuEeqOguBaI,19465
791
791
  mani_skill/utils/structs/decorators.py,sha256=Lv6wQ989dOnreo2tB-qopDnkeBp_jsn1pmfUR-OY8VQ,535
@@ -811,8 +811,8 @@ mani_skill/vector/wrappers/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJ
811
811
  mani_skill/vector/wrappers/gymnasium.py,sha256=v1MDPIrVACBKCulrpdXBK2jDZQI7LKYFZgGgaCC5avY,7408
812
812
  mani_skill/vector/wrappers/sb3.py,sha256=SlXdiEPqcNHYMhJCzA29kBU6zK7DKTe1nc0L6Z3QQtY,4722
813
813
  mani_skill/viewer/__init__.py,sha256=srvDBsk4LQU75K2VIttrhiQ68p_ro7PSDqQRls2PY5c,1722
814
- mani_skill_nightly-2025.5.12.817.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
815
- mani_skill_nightly-2025.5.12.817.dist-info/METADATA,sha256=Ri_9DcVy3GaSibuoRca-rGWAv3xB03SgjOCNKLYWXFw,9410
816
- mani_skill_nightly-2025.5.12.817.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
817
- mani_skill_nightly-2025.5.12.817.dist-info/top_level.txt,sha256=bkBgOVl_MZMoQx2aRFsSFEYlZLxjWlip5vtJ39FB3jA,11
818
- mani_skill_nightly-2025.5.12.817.dist-info/RECORD,,
814
+ mani_skill_nightly-2025.5.12.2356.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
815
+ mani_skill_nightly-2025.5.12.2356.dist-info/METADATA,sha256=oD439V9av9PdzX5Vmy6mr8SvDtRgAtdv4khH_mbvz8U,9411
816
+ mani_skill_nightly-2025.5.12.2356.dist-info/WHEEL,sha256=tZoeGjtWxWRfdplE7E3d45VPlLNQnvbKiYnx7gwAy8A,92
817
+ mani_skill_nightly-2025.5.12.2356.dist-info/top_level.txt,sha256=bkBgOVl_MZMoQx2aRFsSFEYlZLxjWlip5vtJ39FB3jA,11
818
+ mani_skill_nightly-2025.5.12.2356.dist-info/RECORD,,