See file parse_comments.py
parser = ParseComments()
dirs = ['/repo/github/diaspora/diaspora', '/repo/github/django/django']
for d in dirs:
comments = parser.parse_dir(d)
pprint(comments)
print 'Statictics\n'
parser.print_statistics()
Set var ParseComments.collect_statistic = True for collect statistic for file types and parse time
Wikipedia has a good reference on comments