def loadIncidentListFromCsv(path):
    incidentList = []
    with open(path, 'r') as fp:
        reader = csv.reader(fp, delimiter=';', quotechar='"')
        bFirstLine = True
        for row in reader:
            if (bFirstLine):  # skip the first line
                bFirstLine = False
                continue
            assert(len(row) == 4)
            incidentId = int(row[0])
            message = row[1]
            # Note that there are duplicates.
            categoryIdList = map(lambda x: int(x), row[2].split(','))
            categoryTitleList = map(lambda x: x.strip(), row[3].split(','))
            assert(len(categoryIdList) == len(categoryTitleList))

            incidentList.append([incidentId, message, categoryIdList,
                                 categoryTitleList])
    return incidentList
Set `a` can safe convert to `b`
dataset/ETHPy150Open dssg/ushine-learning/dssg/util.py/loadIncidentListFromCsv--crossover with--dataset/ETHPy150Open numba/numba/numba/typeconv/typeconv.py/TypeCastingRules.safe