(cls, file_path, scale, args=None)
| 84 | |
| 85 | @classmethod |
| 86 | def from_file(cls, file_path, scale, args=None): |
| 87 | object_file = file_path |
| 88 | object_scale = default_object_scale |
| 89 | obj2usd_use_existing_usd = default_obj2usd_use_existing_usd |
| 90 | obj2usd_collision_approximation = default_obj2usd_collision_approximation |
| 91 | obj2usd_friction = default_obj2usd_friction |
| 92 | if args is not None: |
| 93 | # object_file = args.object_file |
| 94 | object_scale = args.object_scale |
| 95 | obj2usd_use_existing_usd = args.obj2usd_use_existing_usd |
| 96 | obj2usd_collision_approximation = args.obj2usd_collision_approximation |
| 97 | obj2usd_friction = args.obj2usd_friction |
| 98 | # Apply the scale uniformly to all object types |
| 99 | object_scale *= scale |
| 100 | return cls(object_file=object_file, object_scale=object_scale, |
| 101 | obj2usd_use_existing_usd=obj2usd_use_existing_usd, |
| 102 | obj2usd_collision_approximation=obj2usd_collision_approximation, |
| 103 | obj2usd_friction=obj2usd_friction) |
| 104 | |
| 105 | @classmethod |
| 106 | def from_isaac_grasp_dict(cls, grasp_dict, grasp_file_args=None): |
no outgoing calls
no test coverage detected