(self, random_state)
Applies variations in-place to the specified MJCF element.

    Args:
      random_state: A `numpy.random.RandomState` instance.
Applies variations in-place to the specified MJCF element.
Applies variations in - place to the specified MJCF element .
def apply_variations(self, random_state):
    """Applies variations in-place to the specified MJCF element.

    Args:
      random_state: A `numpy.random.RandomState` instance.
    """
    for element, attribute_variations in self._variations.items():
      new_values = {}
      for attribute_name, variation_info in attribute_variations.items():
        current_value = getattr(element, attribute_name)
        if variation_info.initial_value is None:
          variation_info.initial_value = copy.copy(current_value)
        new_values[attribute_name] = evaluate(
            variation_info.variation, variation_info.initial_value,
            current_value, random_state)
      element.set_attributes(**new_values)
def apply_variations ( self , random_state ) : for element , attribute_variations in self . _variations . items ( ) : new_values = { } for attribute_name , variation_info in attribute_variations . items ( ) : current_value = getattr ( element , attribute_name ) if variation_info . initial_value is None : variation_info . initial_value = copy . copy ( current_value ) new_values [ attribute_name ] = evaluate ( variation_info . variation , variation_info . initial_value , current_value , random_state ) element . set_attributes ( * * new_values )