def readNParse(sent_count):
    '''Parse the sentences in the array'''

    sent_indx = 0
    coverage_cnt = 0
    relaxed_decoding = False
    refsLst = []

    tot_time = 0.0
    inF = open(settings.opts.inFile, 'r')
    sys.stderr.write( (settings.opts.inFile) % "Reading sentences from file      : %s ...\n\n" )
    for sent in inF:
        sent = sent.strip()
        if settings.opts.force_decode: refsLst = getReferences(sent_indx)
        if settings.opts.skip_sents is not None and sent_indx < settings.opts.skip_sents:
            sent_indx += 1
            sent_count += 1
            continue

        parse_begin = time.time()
        parse_obj = Parse(sent_count, sent, relaxed_decoding, refsLst)
        sys.stderr.write( "%3d Translating  :: %s\n" % (sent_count, sent) )
        if ( parse_obj.parse() == 99 ):
            parse_obj = ''
            relaxed_decoding = True
            parse_obj = Parse(sent_count, sent, relaxed_decoding, refsLst)
            dec_status = parse_obj.parse()
            relaxed_decoding = False
        parse_time = time.time() - parse_begin

        tot_time += parse_time
        sys.stderr.write( "Translation time :: %1.3g sec\n\n" % (parse_time) )
        sent_count += 1
        sent_indx += 1
        if settings.opts.force_decode: coverage_cnt += dec_status
        parse_obj = ''

        """
        print 'Collecting ...'
        n = gc.collect()
        print 'Unreachable objects:', n
        print 'Remaining Garbage : '
        pprint.pprint(gc.garbage)
        print
        """

    inF.close()
    sys.stderr.write( "Time taken for decoding the set      : %1.3g sec\n\n" % (tot_time) )
    if settings.opts.force_decode:
        sys.stderr.write( "Number of sentences covered      : %d\n" % (coverage_cnt) )
        sys.stderr.write( "%% of sentences covered           : %g\n" % (float(coverage_cnt) * 100/ float(sent_indx)) )
dataset/ETHPy150Open sfu-natlang/Kriya/src/Kriya-Decoder/decoder.py/readNParse/swapped operands of `%`