malib.utils.io_wrapper package

class malib.utils.io_wrapper.BaseIOWrapper[source]

Bases: abc.ABC

Abstract base class for io wrapper.

The wrapper serves the following purposes

  • Unified local/remote files r/w

abstract read()[source]
abstract write(object)[source]

Serialize object and write/send to target uri.

class malib.utils.io_wrapper.StandardIOWrapper(in_stream=<_io.TextIOWrapper name='<stdin>' mode='r' encoding='UTF-8'>, out_stream=<_io.TextIOWrapper name='<stdout>' mode='w' encoding='UTF-8'>)[source]

Bases: malib.utils.io_wrapper.base_io_wrapper.BaseIOWrapper

read()[source]
write(object, serialzer=None)[source]

Serialize object and write/send to target uri.

Submodules