def iter_lines(self, f):
        """
        Return an iterator over the lines of an input file.

        Each iteration sets self.line and self.line_no.

        """
        for line_no, line in enumerate(iter(f), start=1):
            self.line = line
            self.line_no = line_no
            yield line
        log.info("parsed: %d lines" % line_no)
dataset/ETHPy150Open cjerdonek/open-rcv/openrcv/parsing.py/Parser.iter_lines/original