'Opens all the used output streams.
Returns:
Dictionary with "stream name" -> "stream object" key-value pairs.'

def OpenOutputStreams(self):

    urn_to_names = {self.state.output_base_urn.Add(name): name for name in self.stream_objects}
    streams = aff4.FACTORY.MultiOpen(urn_to_names.keys(), aff4_type=aff4.AFF4UnversionedImage, token=self.token)
    result = {}
    for stream in streams:
        result[urn_to_names[stream.urn]] = stream
    return result
