<commit_before>from _NetworKit import Graph, GraphEvent, DGSStreamParser, GraphUpdater


def graphFromStream(stream):
	G = Graph()
	gu = GraphUpdater(G)
	gu.update(stream)
	return G<commit_msg>docstring for dynamic.graphFromStream<commit_after>from _NetworKit import Graph, GraphEvent, DGSStreamParser, GraphUpdater


def graphFromStream(stream):
	""" Convenience function for creating a new graph from a stream of graph events

	Parameters
	----------
	stream : list of GraphEvent
		event stream
	"""
	G = Graph()
	gu = GraphUpdater(G)
	gu.update(stream)
	return G
{'fraction_non_alphanumeric': 0.09557522123893805, 'fraction_numerical': 0.0, 'mean_word_length': 5.0212765957446805, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2810818', 'n_tokens_mistral': 179, 'n_tokens_neox': 178, 'n_words': 53}