def readVegetation(filename):
    veg = {}
    with open(filename) as fin:
        lines = fin.readlines()
        c = 0
        while c < len(lines):
            data = lines[c].split()
            nveg = int(data[1])
            veg[int(data[0])] = np.array([float(l.split()[1])
                                          for l in lines[c + 1:c + 2 * nveg + 1:2]])
            c = c + 2 * nveg + 1
    return veg
Extract artist names from a block of text.
dataset/ETHPy150Open nasa/RHEAS/src/vic/state.py/readVegetation--crossover with--dataset/ETHPy150Open echonest/pyechonest/pyechonest/artist.py/extract