mlx.data.stream_csv_reader_from_string#
- mlx.data.stream_csv_reader_from_string(content: str, sep: str = ',', quote: str = '"') mlx.data._c.Stream #
Stream samples from a csv file provided as a string.
The same can be achieved with
stream_csv_reader()
and using anio.StringIO
object as follows:from io import StringIO import mlx.data as dx # dset1 and dset2 are exactly the same. my_csv_string = "... csv content here ..." dset1 = dx.stream_csv_reader_from_string(my_csv_string) dset2 = dx.stream_csv_reader(StringIO(my_csv_string))