<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def iterstraight(self, raw):
 """ Iterator that undoes the effect of filtering Yields each row in serialised format (as a sequence of bytes). Assumes input is straightlaced. `raw` should be an iterable that yields the raw bytes in chunks of arbitrary size. """

        # length of row, in bytes (with filter)
        rb_1 = self.row_bytes + 1
        a = bytearray()
        filt = Filter(self.bitdepth * self.planes)
        for some in raw:
            a.extend(some)
            offset = 0
            while len(a) >= rb_1 + offset:
                filter_type = a[offset]
                if filter_type not in (0, 1, 2, 3, 4):
                    raise FormatError('Invalid PNG Filter Type.'
                '  See http://www.w3.org/TR/2003/REC-PNG-20031110/#9Filters .')
                scanline = a[offset + 1:offset + rb_1]
                filt.undo_filter(filter_type, scanline)
                yield scanline
                offset += rb_1
            del a[:offset]

        if len(a) != 0:
            # :file:format We get here with a file format error:
            # when the available bytes (after decompressing) do not
            # pack into exact rows.
            raise FormatError(
              'Wrong size for decompressed IDAT chunk.')
        assert len(a) == 0