Skip to content

Commit

Permalink
get_groups now returns deepcopy to fullfill requirements of #40
Browse files Browse the repository at this point in the history
  • Loading branch information
liquidcronos committed Sep 13, 2021
1 parent 18973a8 commit fa564bc
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/trip_kinematics/Robot.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from typing import Dict, List
from casadi import SX
from copy import deepcopy

from trip_kinematics.Utility import identity_transformation
from trip_kinematics.KinematicGroup import KinematicGroup , OpenKinematicGroup
Expand Down Expand Up @@ -49,12 +50,12 @@ def __init__(self, kinematic_chain: List[KinematicGroup]) -> None:
self._virtual_group_mapping[key]=str(group)

def get_groups(self):
"""Returns a dictionary of the py:class`KinematicGroup` managed by the :py:class`Robot`-
"""Returns a dictionary of the py:class`KinematicGroup` managed by the :py:class`Robot`_
Returns:
Dict[str, KinematicGroup]: The dictionary of py:class`KinematicGroup` objects.
"""
return self._group_dict
return deepcopy(self._group_dict)

def pass_group_arg_v_to_a(self,argv_dict):
for key in argv_dict.keys():
Expand Down

0 comments on commit fa564bc

Please sign in to comment.