human
Complete the below
def find_stacktraces_in_data(data, include_raw=False):

    ''''Finds all stracktraces in a given data blob and returns it
    together with some meta information.
    If `include_raw` is True, then also raw stacktraces are included.'
    '''
 ... Give me a the Python code you requested?
assistant
#Here is the Python code you requested.
    rv = []
    def _report_stack(stacktrace, container):
        platforms = set()
        for frame in (stacktrace.get('frames') or ()):
            platforms.add((frame.get('platform') or data.get('platform')))
        rv.append(StacktraceInfo(stacktrace=stacktrace, container=container, platforms=platforms))
    exc_container = data.get('sentry.interfaces.Exception')
    if exc_container:
        for exc in exc_container['values']:
            stacktrace = exc.get('stacktrace')
            if stacktrace:
                _report_stack(stacktrace, exc)
    stacktrace = data.get('sentry.interfaces.Stacktrace')
    if stacktrace:
        _report_stack(stacktrace, None)
    threads = data.get('threads')
    if threads:
        for thread in threads['values']:
            stacktrace = thread.get('stacktrace')
            if stacktrace:
                _report_stack(stacktrace, thread)
    if include_raw:
        for stacktrace_info in rv[:]:
            if (stacktrace_info.container is None):
                continue
            raw = stacktrace_info.container.get('raw_stacktrace')
            if raw:
                _report_stack(raw, stacktrace_info.container)
    return rv