original_docstring:  Takes a Tensorflow stringified Summary object and returns only
      the scalar values to a list of tags and a list of values
      Args:
          summary_str: string of a Tensorflow Summary object
      Returns:
          tags: list of tags
          vals: list of values corresponding to the tag list
  
      
docstring: Takes a Tensorflow stringified Summary object and returns only
  the scalar values to a list of tags and a list of values
docstring_tokens: Takes a Tensorflow stringified Summary object and returns only the scalar values to a list of tags and a list of values
code: def summary_to_lists(summary_str):
      """ Takes a Tensorflow stringified Summary object and returns only
      the scalar values to a list of tags and a list of values
      Args:
          summary_str: string of a Tensorflow Summary object
      Returns:
          tags: list of tags
          vals: list of values corresponding to the tag list
  
      """
      summ = summary_pb2.Summary()
      summ.ParseFromString(summary_str)
      tags = []
      vals = []
      for s in summ.value:
          if s.HasField('simple_value'):  # and s.simple_value: # Only parse scalar_summaries
              if s.simple_value == float('Inf') or np.isnan(s.simple_value):
                  raise ValueError('Model diverged with %s = %s : Try decreasing your learning rate' %
                                   (s.tag, s.simple_value))
              tags.append(s.tag)
              vals.append(s.simple_value)
      tags, vals = average_head_keys(tags, vals)
      vals = np.asarray(vals)
      return tags, vals
code_tokens: def summary_to_lists ( summary_str ) : summ = summary_pb2 . Summary ( ) summ . ParseFromString ( summary_str ) tags = [ ] vals = [ ] for s in summ . value : if s . HasField ( 'simple_value' ) : if s . simple_value == float ( 'Inf' ) or np . isnan ( s . simple_value ) : raise ValueError ( 'Model diverged with %s = %s : Try decreasing your learning rate' % ( s . tag , s . simple_value ) ) tags . append ( s . tag ) vals . append ( s . simple_value ) tags , vals = average_head_keys ( tags , vals ) vals = np . asarray ( vals ) return tags , vals
short_docstring: Takes a Tensorflow stringified Summary object and returns only
  the scalar values to a list of tags and a list of values
short_docstring_tokens: Takes a Tensorflow stringified Summary object and returns only the scalar values to a list of tags and a list of values
comment: """ Takes a Tensorflow stringified Summary object and returns only
      the scalar values to a list of tags and a list of values
      Args:
          summary_str: string of a Tensorflow Summary object
      Returns:
          tags: list of tags
          vals: list of values corresponding to the tag list
  
      """$SEP$# and s.simple_value: # Only parse scalar_summaries