(joint_name, param_dict)
| 140 | |
| 141 | |
| 142 | def get_param(joint_name, param_dict): |
| 143 | for pattern, value in param_dict.items(): |
| 144 | if pattern.startswith(".*"): |
| 145 | if joint_name.startswith("left") or joint_name.startswith("right"): |
| 146 | if joint_name.endswith(pattern[3:]): |
| 147 | return value |
| 148 | else: |
| 149 | if joint_name == pattern: |
| 150 | return value |
| 151 | raise ValueError(f"No value found for joint: {joint_name}") |
| 152 | |
| 153 | |
| 154 | def get_action_scale(joint_name): |