equivalent of getbuffer for BytesIO in Python 2 -
in python 3, can size of byteio object via object.getbuffer().nbytes
(where object = byteio()
), best equivalent getbuffer()
in python 2? doing exploring, found out can use len(object.getvalue())
or sys.getsizeof(object)
, don't know if python 2 accept them.
Comments
Post a Comment