Ejemplo n.º 1
0
 def __repr__(self):
     txt = "{} ({})"
     return txt.format(object.__repr__(self),
                       pretty_size_print(self.nbytes))
Ejemplo n.º 2
0
 def __repr__(self):
     """ print the object and memory usage"""
     txt = "{}\n source: {}, \n current memory footprint: {}"
     return txt.format(object.__repr__(self), self.fname,
                       pretty_size_print(self.nbytes))