(self, other)
return True
Helper function to check whether another element has the same children.

    See docstring for `is_same_as` for explanation about the treatment of
    children ordering.

    Args:
      other: An `mjcf.Element`

    Returns:
      A boolean
Helper function to check whether another element has the same children.
Helper function to check whether another element has the same children .
def _has_same_children_as(self, other):
    """Helper function to check whether another element has the same children.

    See docstring for `is_same_as` for explanation about the treatment of
    children ordering.

    Args:
      other: An `mjcf.Element`

    Returns:
      A boolean
    """
    for child_name, child_spec in self._spec.children.items():
      child = self.get_children(child_name)
      other_child = getattr(other, child_name)
      if not child_spec.repeated:
        if ((child is None and other_child is not None) or
            (child is not None and not child.is_same_as(other_child))):
          return False
      else:
        if len(child) != len(other_child):
          return False
        else:
          for grandchild, other_grandchild in zip(child, other_child):
            if not grandchild.is_same_as(other_grandchild):
              return False
    return True
def _has_same_children_as ( self , other ) : for child_name , child_spec in self . _spec . children . items ( ) : child = self . get_children ( child_name ) other_child = getattr ( other , child_name ) if not child_spec . repeated : if ( ( child is None and other_child is not None ) or ( child is not None and not child . is_same_as ( other_child ) ) ) : return False else : if len ( child ) != len ( other_child ) : return False else : for grandchild , other_grandchild in zip ( child , other_child ) : if not grandchild . is_same_as ( other_grandchild ) : return False return True