def _generate_overview_note(pass_count, only_warning_count, error_count, total_count):
    """ Generates and returns the HTML note that provides a summary of validation status. """

    note_html = ['<div class="progress">']
    pbars = [
        [ float(error_count), 'danger', 'had errors' ],
        [ float(only_warning_count), 'warning', 'had warnings' ],
        [ float(pass_count), 'success', 'passed' ]
    ]
    for b in pbars:
        if b[0]:
            note_html.append(
                '<div class="progress-bar progress-bar-{pbcol}" style="width: {pct}%" data-toggle="tooltip" title="{count} {sample} {txt}">{count}</div>'. \
                format(
                    pbcol = b[1],
                    count = int(b[0]),
                    pct = (b[0]/float(total_count))*100.0,
                    txt = b[2],
                    sample = 'samples' if b[0] > 1 else 'sample'
                )
            )
    note_html.append('</div>')

    return "\n".join(note_html)
Generates and returns the HTML note that provides a summary of validation status.