def materialize_span(words, span, func=lambda x:x):
	"""Given a sequence of objects and a span, return the subsequence that corresponds to the span.

	Args:
	    words: A sequence of objects.
	    span: A Span namedtuple
	    func: Optional function that will be applied to each element in the result subsequence.
	"""
	return map(func, words[span.begin_word_id:(span.begin_word_id+span.length)])