def memdump(samples=10, file=None):
 say = partial(print, file=file)
 if (ps() is None):
  say(u'- rss: (psutil not installed).')
  return
 (prev, after_collect) = _memdump(samples)
 if prev:
  say(u'- rss (sample):')
  for mem in prev:
   say(u'-    > {0},'.format(mem))
 say(u'- rss (end): {0}.'.format(after_collect))

def memdump ( samples = 10 , file = None ) : say = partial ( print , file = file ) if ( ps ( ) is None ) : say ( u'- rss: (psutil not installed).' ) return ( prev , after_collect ) = _memdump ( samples ) if prev : say ( u'- rss (sample):' ) for mem in prev : say ( u'-    > {0},' . format ( mem ) ) say ( u'- rss (end): {0}.' . format ( after_collect ) )
dump statistics of previous memsample requests .