0b92b4f5530fee68432f13075a1ddc866748f9d1,examples/showcase/firefox.py,,svg_parse,#Any#,19

Before Change


    codes = []
    last = (0, 0)
    for cmd, values in path_re.findall(path):
        points = [float(v) for v in float_re.findall(values)]
        points = np.array(points).reshape((len(points)//2, 2))
        if cmd.islower():
            points += last

After Change


        // the beginning of the string).
        points = ([*map(float, re.split(",|(?<!^)(?=[+-])", values))] if values
                  else [(0., 0.)])  // Only for "z/Z" (CLOSEPOLY).
        points = np.reshape(points, (-1, 2))
        if cmd.islower():
            points += vertices[-1][-1]
        codes.extend(commands[cmd.upper()])
        vertices.append(points)
    return np.array(codes), np.concatenate(vertices)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: matplotlib/matplotlib
Commit Name: 0b92b4f5530fee68432f13075a1ddc866748f9d1
Time: 2020-11-20
Author: anntzer.lee@gmail.com
File Name: examples/showcase/firefox.py
Class Name:
Method Name: svg_parse


Project Name: facebook/FAI-PEP
Commit Name: 9f67a534bce1063693d7716df11311e7584b6786
Time: 2018-12-11
Author: feisun@fb.com
File Name: libraries/python/classification_compare.py
Class Name: OutputCompare
Method Name: getData


Project Name: tensorflow/cleverhans
Commit Name: 33afc8d9385d3f198f0b757f95b023f02485d065
Time: 2017-01-30
Author: Reuben_Feinman@symantec.com
File Name: cleverhans/attacks_tf.py
Class Name:
Method Name: jsma_tf