<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def count_generated_adv_examples(self):
 """Returns total number of all generated adversarial examples."""

    result = {}
    for v in itervalues(self.data):
      s_id = v['submission_id']
      result[s_id] = result.get(s_id, 0) + len(v['images'])
    return result