(rl_tuner, action_note, stat_dict)
return stat_dict
Updates stat dict if an excessively repeated note was played.

  Args:
    rl_tuner: An RLTuner object.
    action_note: An integer representing the chosen action.
    stat_dict: A dictionary containing fields for statistics about
      compositions.
  Returns:
    A dictionary of composition statistics with 'num_repeated_notes' field
    updated.
Updates stat dict if an excessively repeated note was played.
Updates stat dict if an excessively repeated note was played .
def add_repeating_note_stat(rl_tuner, action_note, stat_dict):
  """Updates stat dict if an excessively repeated note was played.

  Args:
    rl_tuner: An RLTuner object.
    action_note: An integer representing the chosen action.
    stat_dict: A dictionary containing fields for statistics about
      compositions.
  Returns:
    A dictionary of composition statistics with 'num_repeated_notes' field
    updated.
  """
  if rl_tuner.detect_repeating_notes(action_note):
    stat_dict['num_repeated_notes'] += 1
  return stat_dict
def add_repeating_note_stat ( rl_tuner , action_note , stat_dict ) : if rl_tuner . detect_repeating_notes ( action_note ) : stat_dict [ 'num_repeated_notes' ] += 1 return stat_dict