code
stringlengths
1
1.49M
file_id
stringlengths
42
46
node_count
int64
0
7.38k
total_lines
int64
1
20.9k
vector_dim
int64
15
15
vector_labels
stringclasses
1 value
nodes
stringlengths
2
3.75M
connections
stringlengths
2
964k
s = set([2,3,4]) t = set([3,4,5]) u = set([1,3,5]) print s s.difference_update(t) u.difference_update(t) print s print u print s == set([2]) print u == set([1]) s = set([2,3,4]) t = set([3,4,5]) t.difference_update(s, u) print t print t == set([5])
ajibawa-2023/Python-Code-Large/train/row_97255
15
22
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97255:Assign_L1_C0", "label": "s = set()", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 0.0455, 0.0455, 0, 0.66, 0.0, 553, 3, 1, 0, 0, 21, 10, 1], "semantic": {"name": "s", "arg_names": [], "import_names": [], "rhs_call_name"...
[]
y = "\n\ The \"quick\"\n\ brown fox\n\ jumps over\n\ the 'lazy' dog.\n\ " print y
ajibawa-2023/Python-Code-Large/train/row_97256
2
7
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97256:Assign_L1_C0", "label": "y =", "type": "assigned_variable", "loc": [1, 6], "level": 0, "parent": null, "vector": [14, 0, 0.5, 0.8571, 0, 0.66, 0.0, 304, 1, 0, 0, 0, 0, 3, 0], "semantic": {"name": "y", "arg_names": [], "import_names": [], "rhs_call_name": "", "anno...
[]
class O(object): pass class A(O): pass class B(O): pass class C(O): pass class D(O): pass class E(O): pass class K1(A,B,C): pass class K2(D,B,E): pass class K3(D,A): pass class Z(K1,K2,K3): pass print K1.__mro__ print K2.__mro__ print K3.__mro__ print Z.__mro__
ajibawa-2023/Python-Code-Large/train/row_97257
14
14
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97257:ClassDef_L1_C0", "label": "O", "type": "class", "loc": [1, 1], "level": 0, "parent": null, "vector": [3, 0, 0.0714, 0.0714, 0, 0.66, 0.0, 720, 0, 0, 0, 0, 186, 0, 0], "semantic": {"name": "O", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation":...
[]
c = "squirrel" time = 0 def x(): global time time += 1 if time == 1: b = "dog" else: b = "banana" print b, c def y(d): a = "cat" print a,b,d def z(): for i in range(10*time): yield i,a,b,c,d return z return y("blorp"...
ajibawa-2023/Python-Code-Large/train/row_97258
19
22
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97258:Assign_L1_C0", "label": "c =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 0.0455, 0.0455, 0, 0.66, 0.0, 411, 1, 0, 0, 0, 0, 3, 0], "semantic": {"name": "c", "arg_names": [], "import_names": [], "rhs_call_name": "", "a...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97258:FunctionDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97258:If_L6_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97258:If_L6_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_97258:Assign_L7_C8"}, {"f": "ajibawa-2023/Python-Code-Large/train/ro...
# Test the behaviour of sets l = [1,2,3,4,1,1] print l s = set(l) # Test the addition and removal of items print len(s), s s.add(100) print len(s), s s.discard(2) print len(s), s
ajibawa-2023/Python-Code-Large/train/row_97259
8
11
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97259:Assign_L2_C0", "label": "l =", "type": "assigned_variable", "loc": [2, 2], "level": 0, "parent": null, "vector": [14, 0, 0.1818, 0.0909, 0, 0.66, 0.0, 810, 0, 0, 0, 0, 0, 5, 0], "semantic": {"name": "l", "arg_names": [], "import_names": [], "rhs_call_name": "", "a...
[]
print "-----" print [] and 5 print {} and 5 print False and 5 print True and 5 print "-----" print [] or 5 print {} or 5 print False or 5 print True or 5 print "-----" print 5 and [] print 5 and {} print 5 and False print 5 and True print "-----" print 5 or [] print 5 or {} print 5 or False print 5 or True print "-----...
ajibawa-2023/Python-Code-Large/train/row_97260
25
25
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97260:Expr_L1_C0", "label": "print()", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 0.04, 0.04, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 1], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print", "an...
[]
class Wee: def __init__(self): self.called = False def __iter__(self): return self def next(self): print "in next" if not self.called: self.called = True return "dog" raise StopIteration for i in Wee(): print i
ajibawa-2023/Python-Code-Large/train/row_97261
12
14
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97261:ClassDef_L1_C0", "label": "Wee", "type": "class", "loc": [1, 11], "level": 0, "parent": null, "vector": [3, 0, 0.4286, 0.7857, 0, 0.66, 0.0, 410, 0, 3, 0, 0, 0, 0, 1], "semantic": {"name": "Wee", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotatio...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97261:ClassDef_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97261:FunctionDef_L2_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97261:FunctionDef_L2_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_97261:Assign_L3_C8"}, {"f": "ajibawa-2023/Python-Code...
from pkga.pkgb.modc import stuff as mystuff from pkga.pkgb.modc import things as mythings print mystuff, mythings
ajibawa-2023/Python-Code-Large/train/row_97263
3
4
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97263:ImportFrom_L1_C0", "label": "from pkga.pkgb.modc import mystuff", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.25, 0.25, 0, 0.66, 0.0, 812, 0, 1, 0, 0, 812, 0, 0], "semantic": {"name": "pkga.pkgb.modc", "arg_names": [], "import_n...
[]
class Stuff: def __init__(self): self.a = 0 self.b = 'b' self.c = [1,2,3] self.d = 100000000000000 def doit(self): self.a += 10 self.b += 'dog' self.c += [9,10] self.d += 10000 s = Stuff() s.doit() print s.a print s.b print s.c print s.d
ajibawa-2023/Python-Code-Large/train/row_97264
13
19
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97264:ClassDef_L1_C0", "label": "Stuff", "type": "class", "loc": [1, 11], "level": 0, "parent": null, "vector": [3, 0, 0.3158, 0.5789, 0, 0.66, 0.0, 710, 0, 2, 0, 0, 0, 0, 0], "semantic": {"name": "Stuff", "arg_names": [], "import_names": [], "rhs_call_name": "", "annot...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97264:ClassDef_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97264:FunctionDef_L2_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97264:FunctionDef_L2_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_97264:Assign_L3_C8"}, {"f": "ajibawa-2023/Python-Code...
class X: def __init__(self): print "wee" x = X() print repr(x)
ajibawa-2023/Python-Code-Large/train/row_97265
5
5
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97265:ClassDef_L1_C0", "label": "X", "type": "class", "loc": [1, 3], "level": 0, "parent": null, "vector": [3, 0, 0.4, 0.6, 0, 0.66, 0.0, 783, 0, 1, 0, 0, 0, 0, 1], "semantic": {"name": "X", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": ""}, "s...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97265:ClassDef_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97265:FunctionDef_L2_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97265:FunctionDef_L2_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_97265:Expr_L3_C8"}]
print slice(1,2)
ajibawa-2023/Python-Code-Large/train/row_97266
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97266:Expr_L1_C0", "label": "print()", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 2], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print", "anno...
[]
x="OK" print x
ajibawa-2023/Python-Code-Large/train/row_97267
2
2
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97267:Assign_L1_C0", "label": "x =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 0.5, 0.5, 0, 0.66, 0.0, 190, 1, 0, 0, 0, 0, 3, 0], "semantic": {"name": "x", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[]
def f(a,b,c=10,d=20,*e,**f): sortf = [(x,y) for x,y in f.items()] sortf.sort() print a,b,c,d,e,sortf f(1,2) f(1,2,3) f(1,2,3,5) f(1,2,d=3,c=5) f(1,2,e=['x','y','z']) f(1,2,d=3,c=5,e=['x','y','z']) f(1,2,3,5,['x','y','z']) f(1,2,3,5,['x','y','z'],z=5,y=9) f(1,2,3,5,['x','y','z'],'blorp','wee',z=5,y=9)
ajibawa-2023/Python-Code-Large/train/row_97268
13
14
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97268:FunctionDef_L1_C0", "label": "f", "type": "function", "loc": [1, 4], "level": 0, "parent": null, "vector": [2, 0, 0.1786, 0.2857, 0, 0.66, 0.0, 899, 0, 6, 0, 0, 0, 0, 3], "semantic": {"name": "f", "arg_names": ["a", "b", "c", "d", "e", "f"], "import_names": [], "r...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97268:FunctionDef_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97268:Assign_L2_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97268:FunctionDef_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97268:Expr_L3_C4"}, {"f": "ajibawa-2023/Python-Code-Lar...
print("O"+"K")
ajibawa-2023/Python-Code-Large/train/row_97269
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97269:Expr_L1_C0", "label": "print()", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 1], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print", "anno...
[]
if 0 == 1: print "X" else: print "OK"
ajibawa-2023/Python-Code-Large/train/row_97270
3
4
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97270:If_L1_C0", "label": "if", "type": "if", "loc": [1, 4], "level": 0, "parent": null, "vector": [4, 0, 0.625, 1.0, 0, 0.66, 0.0, 0, 0, 0, 0, 0, 0, 0, 2], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": ""}, "snippet": ...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97270:If_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97270:Expr_L2_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97270:If_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97270:Expr_L4_C4"}]
big = 123456789012345678901234567890L print "'%d'" % big print "'%d'" % -big print "'%5d'" % -big print "'%31d'" % -big print "'%32d'" % -big print "'%-32d'" % -big print "'%032d'" % -big print "'%-032d'" % -big print "'%034d'" % -big print "'%034d'" % big print "'%0+34d'" % big print "'%+34d'" % big print "'%34d'" % b...
ajibawa-2023/Python-Code-Large/train/row_97271
17
17
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97271:Expr_L1_C0", "label": "print()", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 0.0588, 0.0588, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 1], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print",...
[]
class X: def __init__(self): self.px = 3 def y(self): l = "xyz" if len(l) == self.px: print "OK" x = X() x.y()
ajibawa-2023/Python-Code-Large/train/row_97272
9
9
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97272:ClassDef_L1_C0", "label": "X", "type": "class", "loc": [1, 7], "level": 0, "parent": null, "vector": [3, 0, 0.4444, 0.7778, 0, 0.66, 0.0, 783, 0, 2, 0, 0, 0, 0, 2], "semantic": {"name": "X", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": "...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97272:ClassDef_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97272:FunctionDef_L2_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97272:FunctionDef_L2_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_97272:Assign_L3_C8"}, {"f": "ajibawa-2023/Python-Code...
print str(range(-8,-4,-1))[:5] print len(range(-8,-4,-1))
ajibawa-2023/Python-Code-Large/train/row_97273
2
2
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97273:Expr_L1_C0", "label": "print()", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 0.5, 0.5, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 3], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print", "anno...
[]
x = "abcdefghjijk" print x[:0] print x[0:]
ajibawa-2023/Python-Code-Large/train/row_97274
3
3
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97274:Assign_L1_C0", "label": "x =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 0.3333, 0.3333, 0, 0.66, 0.0, 190, 1, 0, 0, 0, 0, 3, 0], "semantic": {"name": "x", "arg_names": [], "import_names": [], "rhs_call_name": "", "a...
[]
if None is None: print "OK"
ajibawa-2023/Python-Code-Large/train/row_97275
2
2
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97275:If_L1_C0", "label": "if", "type": "if", "loc": [1, 2], "level": 0, "parent": null, "vector": [4, 0, 0.75, 1.0, 0, 0.66, 0.0, 0, 0, 0, 0, 0, 0, 0, 1], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": ""}, "snippet": "...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97275:If_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97275:Expr_L2_C4"}]
# multiple instances of generator at the same time def genmaker(a, b): z = a*b def gen(y): for i in range(4): yield i,a,b,y,z return gen(a*a*b*b) g1 = genmaker(3, 4) g2 = genmaker(4, 5) print g1.next() print g2.next() print g1.next() print g2.next() print g1.next() print g2.next() pr...
ajibawa-2023/Python-Code-Large/train/row_97276
16
21
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97276:FunctionDef_L4_C0", "label": "genmaker", "type": "function", "loc": [4, 9], "level": 0, "parent": null, "vector": [2, 0, 0.3095, 0.2857, 0, 0.66, 0.0, 808, 0, 2, 1, 0, 0, 0, 2], "semantic": {"name": "genmaker", "arg_names": ["a", "b"], "import_names": [], "rhs_cal...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97276:FunctionDef_L4_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97276:Assign_L5_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97276:FunctionDef_L4_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97276:FunctionDef_L6_C4"}, {"f": "ajibawa-2023/Python-C...
# free and cell vars in y c = "squirrel" def x(): b = "dog" print b, c def y(): a = "cat" print a,b def z(): return a,b,c return z return y() print x()()
ajibawa-2023/Python-Code-Large/train/row_97277
12
14
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97277:Assign_L3_C0", "label": "c =", "type": "assigned_variable", "loc": [3, 3], "level": 0, "parent": null, "vector": [14, 0, 0.2143, 0.0714, 0, 0.66, 0.0, 411, 1, 0, 0, 0, 0, 3, 0], "semantic": {"name": "c", "arg_names": [], "import_names": [], "rhs_call_name": "", "a...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97277:FunctionDef_L4_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97277:Assign_L5_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97277:FunctionDef_L4_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97277:Expr_L6_C4"}, {"f": "ajibawa-2023/Python-Code-Lar...
class A: pass class B: pass class C: pass class D(A): pass class E(A,B): pass class F(E,C): pass a,b,c,d,e,f = A(),B(),C(),D(),E(),F() print isinstance(a, A) print isinstance(a, B) print isinstance(a, C) print isinstance(a, D) print isinstance(a, E) print isinstance(a, F) print "---" print isinstance(b, A) print isin...
ajibawa-2023/Python-Code-Large/train/row_97278
49
51
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97278:ClassDef_L1_C0", "label": "A", "type": "class", "loc": [1, 1], "level": 0, "parent": null, "vector": [3, 0, 0.0196, 0.0196, 0, 0.66, 0.0, 429, 0, 0, 0, 0, 0, 0, 0], "semantic": {"name": "A", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": "...
[]
def f(a, b, c): print a, b, c args = [5, 6, 7] f(*args)
ajibawa-2023/Python-Code-Large/train/row_97279
4
5
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97279:FunctionDef_L1_C0", "label": "f", "type": "function", "loc": [1, 2], "level": 0, "parent": null, "vector": [2, 0, 0.3, 0.4, 0, 0.66, 0.0, 899, 0, 3, 0, 0, 0, 0, 1], "semantic": {"name": "f", "arg_names": ["a", "b", "c"], "import_names": [], "rhs_call_name": "", "a...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97279:FunctionDef_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97279:Expr_L2_C4"}]
print "..bbb..".replace("..", "X")
ajibawa-2023/Python-Code-Large/train/row_97280
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97280:Expr_L1_C0", "label": "print()", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 2], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print", "anno...
[]
print "a\0b".replace("\0", "c")
ajibawa-2023/Python-Code-Large/train/row_97281
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97281:Expr_L1_C0", "label": "print()", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 2], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print", "anno...
[]
def f(): for i in 1,2,3,4,5: if i % 2 == 0: continue yield i print list(f())
ajibawa-2023/Python-Code-Large/train/row_97282
5
6
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97282:FunctionDef_L1_C0", "label": "f", "type": "function", "loc": [1, 4], "level": 0, "parent": null, "vector": [2, 0, 0.4167, 0.6667, 0, 0.66, 0.0, 899, 0, 0, 0, 0, 0, 0, 0], "semantic": {"name": "f", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotati...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97282:FunctionDef_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97282:For_L2_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97282:For_L2_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_97282:If_L3_C8"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_...
# empty set creation print set()
ajibawa-2023/Python-Code-Large/train/row_97283
1
2
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97283:Expr_L2_C0", "label": "print()", "type": "expression", "loc": [2, 2], "level": 0, "parent": null, "vector": [8, 0, 1.0, 0.5, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 2], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print", "anno...
[]
print int print float print int(3.0) print float(3)
ajibawa-2023/Python-Code-Large/train/row_97284
4
4
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97284:Expr_L1_C0", "label": "print()", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 0.25, 0.25, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 1], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print", "an...
[]
print (2 < 3 < 9) print (2 < (3 < 9))
ajibawa-2023/Python-Code-Large/train/row_97285
2
2
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97285:Expr_L1_C0", "label": "print()", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 0.5, 0.5, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 1], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print", "anno...
[]
big = 0x1234567890abcdef12345L # 21 hex digits print "'%x'" % big print "'%x'" % -big print "'%5x'" % -big print "'%22x'" % -big print "'%23x'" % -big print "'%-23x'" % -big print "'%023x'" % -big print "'%-023x'" % -big print "'%025x'" % -big print "'%025x'" % big print "'%0+25x'" % big print "'%+25x'" % big print "'...
ajibawa-2023/Python-Code-Large/train/row_97286
32
35
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97286:Expr_L1_C0", "label": "print()", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 0.0286, 0.0286, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 1], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print",...
[]
print 234
ajibawa-2023/Python-Code-Large/train/row_97287
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97287:Expr_L1_C0", "label": "print()", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 1], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print", "anno...
[]
def foo(value = None): for i in [-1,0,1,2,3,4]: if i < 0: continue elif i == 0: yield 0 elif i == 1: yield 1 yield value yield 2 else: yield i print list(foo())
ajibawa-2023/Python-Code-Large/train/row_97288
11
13
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97288:FunctionDef_L1_C0", "label": "foo", "type": "function", "loc": [1, 12], "level": 0, "parent": null, "vector": [2, 0, 0.5, 0.9231, 0, 0.66, 0.0, 528, 0, 1, 0, 0, 0, 0, 0], "semantic": {"name": "foo", "arg_names": ["value"], "import_names": [], "rhs_call_name": "", ...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97288:FunctionDef_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97288:For_L2_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97288:For_L2_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_97288:If_L3_C8"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_...
print({1:"OK"}[1])
ajibawa-2023/Python-Code-Large/train/row_97289
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97289:Expr_L1_C0", "label": "print()", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 1], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print", "anno...
[]
print 2*3**2
ajibawa-2023/Python-Code-Large/train/row_97290
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97290:Expr_L1_C0", "label": "print()", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 1], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print", "anno...
[]
# Test that a clone of a list really is distinct l = [1,2,3] print l m = list(l) print m m.pop() print l print m
ajibawa-2023/Python-Code-Large/train/row_97291
7
8
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97291:Assign_L2_C0", "label": "l =", "type": "assigned_variable", "loc": [2, 2], "level": 0, "parent": null, "vector": [14, 0, 0.25, 0.125, 0, 0.66, 0.0, 810, 0, 0, 0, 0, 0, 5, 0], "semantic": {"name": "l", "arg_names": [], "import_names": [], "rhs_call_name": "", "anno...
[]
print "1234"[-3:3]
ajibawa-2023/Python-Code-Large/train/row_97292
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97292:Expr_L1_C0", "label": "print()", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 1], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print", "anno...
[]
class O(object): pass class F(O): pass class E(O): pass class D(O): pass class C(D,F): pass class B(D,E): pass class A(B,C): pass print A.__bases__ print A.__mro__
ajibawa-2023/Python-Code-Large/train/row_97293
9
10
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97293:ClassDef_L1_C0", "label": "O", "type": "class", "loc": [1, 1], "level": 0, "parent": null, "vector": [3, 0, 0.1, 0.1, 0, 0.66, 0.0, 720, 0, 0, 0, 0, 186, 0, 0], "semantic": {"name": "O", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": ""}, ...
[]
s='abcd' print s[::2]
ajibawa-2023/Python-Code-Large/train/row_97294
2
2
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97294:Assign_L1_C0", "label": "s =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 0.5, 0.5, 0, 0.66, 0.0, 553, 1, 0, 0, 0, 0, 3, 0], "semantic": {"name": "s", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[]
import sys def main(): cout = sys.stdout.write size = 4000 xr_size = range(size) xr_iter = range(50) bit = 128 byte_acc = 0 cout("P4\n%d %d\n" % (size, size)) size = float(size) for y in xr_size: fy = 2j * y / size - 1j for x in xr_size: z = 0j ...
ajibawa-2023/Python-Code-Large/train/row_97295
27
39
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97295:Import_L1_C0", "label": "sys import sys", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0256, 0.0256, 0, 0.66, 0.0, 509, 0, 1, 0, 0, 509, 0, 0], "semantic": {"name": "sys", "arg_names": [], "import_names": ["sys"], "rhs_call_name"...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97295:FunctionDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97295:Assign_L4_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97295:FunctionDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97295:Assign_L5_C4"}, {"f": "ajibawa-2023/Python-Code-L...
def make_tree(item, depth): if not depth: return item, None, None item2 = item + item depth -= 1 return item, make_tree(item2 - 1, depth), make_tree(item2, depth) def check_tree(node): item, left, right = node if not left: return item return item + check_tree(left) - check_tree(right) def ...
ajibawa-2023/Python-Code-Large/train/row_97296
23
32
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97296:FunctionDef_L1_C0", "label": "make_tree", "type": "function", "loc": [1, 5], "level": 0, "parent": null, "vector": [2, 0, 0.0938, 0.1562, 0, 0.66, 0.0, 92, 0, 2, 1, 0, 0, 0, 2], "semantic": {"name": "make_tree", "arg_names": ["item", "depth"], "import_names": [], ...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97296:FunctionDef_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97296:If_L2_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97296:If_L2_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_97296:Return_L2_C18"}, {"f": "ajibawa-2023/Python-Code-Large/train/r...
2134568 != 01231515
ajibawa-2023/Python-Code-Large/train/row_97297
0
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[]
[]
wee = """this is some stuff and
ajibawa-2023/Python-Code-Large/train/row_97298
0
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[]
[]
if 1 < 1 > 1 == 1 >= 5 <= 0x15 <= 0x12 != 1 and 5 in 1 not in 1 is 1 or 5 is not 1: pass
ajibawa-2023/Python-Code-Large/train/row_97299
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97299:If_L1_C0", "label": "if", "type": "if", "loc": [1, 1], "level": 0, "parent": null, "vector": [4, 0, 1.0, 1.0, 0, 0.66, 0.0, 0, 0, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": ""}, "snippet": "i...
[]
x = ur'abc' + Ur'ABC' + uR'ABC' + UR'ABC'
ajibawa-2023/Python-Code-Large/train/row_97300
0
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[]
[]
x = 0xfffffffffff
ajibawa-2023/Python-Code-Large/train/row_97301
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97301:Assign_L1_C0", "label": "x =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 1.0, 1.0, 0, 0.66, 0.0, 190, 1, 0, 0, 0, 0, 1, 0], "semantic": {"name": "x", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[]
x = 123141242151251616110l
ajibawa-2023/Python-Code-Large/train/row_97302
0
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[]
[]
x = 3e14159
ajibawa-2023/Python-Code-Large/train/row_97304
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97304:Assign_L1_C0", "label": "x =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 1.0, 1.0, 0, 0.66, 0.0, 190, 1, 0, 0, 0, 0, 2, 0], "semantic": {"name": "x", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[]
x = "doesn't "shrink", does it"
ajibawa-2023/Python-Code-Large/train/row_97305
0
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[]
[]
x = 314159.
ajibawa-2023/Python-Code-Large/train/row_97307
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97307:Assign_L1_C0", "label": "x =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 1.0, 1.0, 0, 0.66, 0.0, 190, 1, 0, 0, 0, 0, 2, 0], "semantic": {"name": "x", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[]
def f(): if True: if False: x =3 y = 4 return return 19
ajibawa-2023/Python-Code-Large/train/row_97308
7
7
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97308:FunctionDef_L1_C0", "label": "f", "type": "function", "loc": [1, 7], "level": 0, "parent": null, "vector": [2, 0, 0.5714, 1.0, 0, 0.66, 0.0, 899, 0, 0, 1, 0, 0, 0, 0], "semantic": {"name": "f", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation"...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97308:FunctionDef_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97308:If_L2_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97308:If_L2_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_97308:If_L3_C8"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97...
x = ''; y = ""
ajibawa-2023/Python-Code-Large/train/row_97309
2
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97309:Assign_L1_C0", "label": "x =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 1.0, 1.0, 0, 0.66, 0.0, 190, 1, 0, 0, 0, 0, 3, 0], "semantic": {"name": "x", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[]
a = r'''this is some more stuff
ajibawa-2023/Python-Code-Large/train/row_97310
0
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[]
[]
x = '"'; y = "'"
ajibawa-2023/Python-Code-Large/train/row_97311
2
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97311:Assign_L1_C0", "label": "x =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 1.0, 1.0, 0, 0.66, 0.0, 190, 1, 0, 0, 0, 0, 3, 0], "semantic": {"name": "x", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[]
0xdeadbeef != -1
ajibawa-2023/Python-Code-Large/train/row_97312
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97312:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 0, 0, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": ...
[]
x = 1 - y + 15 - 01 + 0x124 + z + a[5]
ajibawa-2023/Python-Code-Large/train/row_97313
0
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[]
[]
import sys, time x = sys.modules['time'].time()
ajibawa-2023/Python-Code-Large/train/row_97314
2
2
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97314:Import_L1_C0", "label": "sys import sys, time", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.5, 0.5, 0, 0.66, 0.0, 509, 0, 2, 0, 0, 509, 0, 0], "semantic": {"name": "sys", "arg_names": [], "import_names": ["sys", "time"], "rhs_ca...
[]
-1*1/1+1*1//1 - ---1**1
ajibawa-2023/Python-Code-Large/train/row_97315
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97315:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 0, 4, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": ...
[]
0o123 <= 0123
ajibawa-2023/Python-Code-Large/train/row_97316
0
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[]
[]
def d22(a, b, c=2, d=2, *k): pass
ajibawa-2023/Python-Code-Large/train/row_97317
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97317:FunctionDef_L1_C0", "label": "d22", "type": "function", "loc": [1, 1], "level": 0, "parent": null, "vector": [2, 0, 1.0, 1.0, 0, 0.66, 0.0, 755, 0, 5, 0, 0, 0, 0, 0], "semantic": {"name": "d22", "arg_names": ["a", "b", "c", "d", "k"], "import_names": [], "rhs_call...
[]
x = u'abc' + U'ABC'
ajibawa-2023/Python-Code-Large/train/row_97318
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97318:Assign_L1_C0", "label": "x =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 1.0, 1.0, 0, 0.66, 0.0, 190, 4, 0, 0, 0, 0, 0, 0], "semantic": {"name": "x", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[]
1 + 1
ajibawa-2023/Python-Code-Large/train/row_97319
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97319:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 0, 4, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": ...
[]
x = 3E123
ajibawa-2023/Python-Code-Large/train/row_97320
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97320:Assign_L1_C0", "label": "x =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 1.0, 1.0, 0, 0.66, 0.0, 190, 1, 0, 0, 0, 0, 2, 0], "semantic": {"name": "x", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[]
x = 1//1*1/5*12%0x12
ajibawa-2023/Python-Code-Large/train/row_97321
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97321:Assign_L1_C0", "label": "x =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 1.0, 1.0, 0, 0.66, 0.0, 190, 4, 0, 0, 0, 0, 0, 0], "semantic": {"name": "x", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[]
01234567 > ~0x15
ajibawa-2023/Python-Code-Large/train/row_97322
0
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[]
[]
@staticmethod def foo(x,y): pass
ajibawa-2023/Python-Code-Large/train/row_97323
1
2
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97323:FunctionDef_L2_C0", "label": "foo", "type": "function", "loc": [2, 2], "level": 0, "parent": null, "vector": [2, 0, 1.0, 0.5, 0, 0.66, 0.0, 528, 0, 2, 0, 0, 0, 0, 0], "semantic": {"name": "foo", "arg_names": ["x", "y"], "import_names": [], "rhs_call_name": "", "an...
[]
x = .314159
ajibawa-2023/Python-Code-Large/train/row_97324
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97324:Assign_L1_C0", "label": "x =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 1.0, 1.0, 0, 0.66, 0.0, 190, 1, 0, 0, 0, 0, 2, 0], "semantic": {"name": "x", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[]
0xdeadc0de & 012345
ajibawa-2023/Python-Code-Large/train/row_97325
0
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[]
[]
x+y = 3e-1230
ajibawa-2023/Python-Code-Large/train/row_97326
0
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[]
[]
x = 3.14159
ajibawa-2023/Python-Code-Large/train/row_97327
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97327:Assign_L1_C0", "label": "x =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 1.0, 1.0, 0, 0.66, 0.0, 190, 1, 0, 0, 0, 0, 2, 0], "semantic": {"name": "x", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[]
def d01v_(a=1, *k, **w): pass
ajibawa-2023/Python-Code-Large/train/row_97328
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97328:FunctionDef_L1_C0", "label": "d01v_", "type": "function", "loc": [1, 1], "level": 0, "parent": null, "vector": [2, 0, 1.0, 1.0, 0, 0.66, 0.0, 498, 0, 3, 0, 0, 0, 0, 0], "semantic": {"name": "d01v_", "arg_names": ["a", "k", "w"], "import_names": [], "rhs_call_name"...
[]
def k(x): x += 2 x += 5
ajibawa-2023/Python-Code-Large/train/row_97329
1
2
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97329:FunctionDef_L1_C0", "label": "k", "type": "function", "loc": [1, 2], "level": 0, "parent": null, "vector": [2, 0, 0.75, 1.0, 0, 0.66, 0.0, 954, 0, 1, 0, 0, 0, 0, 0], "semantic": {"name": "k", "arg_names": ["x"], "import_names": [], "rhs_call_name": "", "annotation...
[]
0xFF & 0x15 | 1234
ajibawa-2023/Python-Code-Large/train/row_97330
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97330:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 0, 4, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": ...
[]
0xff <= 255
ajibawa-2023/Python-Code-Large/train/row_97331
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97331:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 0, 0, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": ...
[]
y = ur"abc" + Ur"ABC" + uR"ABC" + UR"ABC"
ajibawa-2023/Python-Code-Large/train/row_97332
0
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[]
[]
(-124561-1) & 0200000000
ajibawa-2023/Python-Code-Large/train/row_97333
0
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[]
[]
x = 1 << 1 >> 5
ajibawa-2023/Python-Code-Large/train/row_97334
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97334:Assign_L1_C0", "label": "x =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 1.0, 1.0, 0, 0.66, 0.0, 190, 4, 0, 0, 0, 0, 0, 0], "semantic": {"name": "x", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[]
x = 0L
ajibawa-2023/Python-Code-Large/train/row_97335
0
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[]
[]
x = -15921590215012591L
ajibawa-2023/Python-Code-Large/train/row_97336
0
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[]
[]
x = 3.14e159
ajibawa-2023/Python-Code-Large/train/row_97337
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97337:Assign_L1_C0", "label": "x =", "type": "assigned_variable", "loc": [1, 1], "level": 0, "parent": null, "vector": [14, 0, 1.0, 1.0, 0, 0.66, 0.0, 190, 1, 0, 0, 0, 0, 2, 0], "semantic": {"name": "x", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[]
0b01 <= 255
ajibawa-2023/Python-Code-Large/train/row_97338
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97338:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 0, 0, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": ...
[]
~1 ^ 1 & 1 |1 ^ -1
ajibawa-2023/Python-Code-Large/train/row_97339
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97339:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 0, 4, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": ...
[]
import ast import sys def astppdump(node): def _format(node, indent): #print node, len(indent) if isinstance(node, ast.AST): namelen = " "*(len(node.__class__.__name__)) + " " fields = [] for a,b in ast.iter_fields(node): fieldlen = len(a)*" " ...
ajibawa-2023/Python-Code-Large/train/row_97340
22
27
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97340:Import_L1_C0", "label": "ast import ast", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.037, 0.037, 0, 0.66, 0.0, 809, 0, 1, 0, 0, 809, 0, 0], "semantic": {"name": "ast", "arg_names": [], "import_names": ["ast"], "rhs_call_name": ...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97340:FunctionDef_L4_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97340:FunctionDef_L5_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97340:FunctionDef_L5_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_97340:If_L7_C8"}, {"f": "ajibawa-2023/Python-Code-...
class X: pass
ajibawa-2023/Python-Code-Large/train/row_97342
1
3
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97342:ClassDef_L1_C0", "label": "X", "type": "class", "loc": [1, 1], "level": 0, "parent": null, "vector": [3, 0, 0.3333, 0.3333, 0, 0.66, 0.0, 783, 0, 0, 0, 0, 0, 0, 0], "semantic": {"name": "X", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": "...
[]
print 4
ajibawa-2023/Python-Code-Large/train/row_97343
1
1
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97343:Expr_L1_C0", "label": "print()", "type": "expression", "loc": [1, 1], "level": 0, "parent": null, "vector": [8, 0, 1.0, 1.0, 0, 0.66, 0.0, 535, 3, 1, 0, 0, 0, 0, 1], "semantic": {"name": "print", "arg_names": [], "import_names": [], "rhs_call_name": "print", "anno...
[]
def foobar(): print 'yes' foobar()
ajibawa-2023/Python-Code-Large/train/row_97344
3
4
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97344:FunctionDef_L1_C0", "label": "foobar", "type": "function", "loc": [1, 2], "level": 0, "parent": null, "vector": [2, 0, 0.375, 0.5, 0, 0.66, 0.0, 139, 0, 0, 0, 0, 0, 0, 1], "semantic": {"name": "foobar", "arg_names": [], "import_names": [], "rhs_call_name": "", "an...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97344:FunctionDef_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97344:Expr_L2_C4"}]
for i in range(10): print i
ajibawa-2023/Python-Code-Large/train/row_97345
2
3
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97345:For_L1_C0", "label": "for i", "type": "for", "loc": [1, 2], "level": 0, "parent": null, "vector": [6, 0, 0.5, 0.6667, 0, 0.66, 0.0, 826, 3, 0, 0, 0, 0, 0, 2], "semantic": {"name": "i", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation": ""}, "s...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97345:For_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97345:Expr_L2_C4"}]
import goog.math as gm c1 = gm.Coordinate() c2 = gm.Coordinate(1) c3 = gm.Coordinate(1, 2) print c1.toString() print c2.toString() print c3.toString() c4 = gm.Coordinate(1, 2) c5 = gm.Coordinate(3, 4) print gm.Coordinate.equals(c3, c4) print gm.Coordinate.equals(c3, c5) c6 = c4.clone() c7 = c6.clone() print gm.Coordi...
ajibawa-2023/Python-Code-Large/train/row_97346
19
22
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97346:Import_L1_C0", "label": "goog.math import gm", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0455, 0.0455, 0, 0.66, 0.0, 190, 0, 1, 0, 0, 190, 0, 0], "semantic": {"name": "goog.math", "arg_names": [], "import_names": ["gm"], "rhs_...
[]
import goog.json strd = goog.json.serialize({ 'a': 45, 'b': [ 1, 2, 3, 4, { 'c': "stuff", 'd': "things", }], 'xyzzy': False, 'blorp': True }) print strd print goog.json.unsafeParse(strd) print goog.json.serialize(goog.json.unsafeParse(strd)) == strd
ajibawa-2023/Python-Code-Large/train/row_97347
5
15
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97347:Import_L1_C0", "label": "goog.json import goog.json", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0667, 0.0667, 0, 0.66, 0.0, 575, 0, 1, 0, 0, 575, 0, 0], "semantic": {"name": "goog.json", "arg_names": [], "import_names": ["goog...
[]
import goog.math as gm K = 10000 def main(): print gm.clamp(408, 10, 100) print gm.modulo(-10, 3) print gm.lerp(0, 14, 0.25) a = 14 b = 14.0001 print gm.nearlyEquals(a, b) print gm.nearlyEquals(a, b, 0.01) print gm.standardAngle(480) print gm.toRadians(170) print gm.toDegrees(2...
ajibawa-2023/Python-Code-Large/train/row_97348
34
50
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97348:Import_L1_C0", "label": "goog.math import gm", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.02, 0.02, 0, 0.66, 0.0, 190, 0, 1, 0, 0, 190, 0, 0], "semantic": {"name": "goog.math", "arg_names": [], "import_names": ["gm"], "rhs_call...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97348:FunctionDef_L5_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97348:Expr_L6_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97348:FunctionDef_L5_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97348:Expr_L7_C4"}, {"f": "ajibawa-2023/Python-Code-Large...
import goog.json print goog.json.parse # random sample from json.org obj = goog.json.parse(""" { "glossary": { "title": "example glossary", "GlossDiv": { "title": "S", "GlossList": { "GlossEntry": { "ID": "SGML", "SortA...
ajibawa-2023/Python-Code-Large/train/row_97349
4
29
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97349:Import_L1_C0", "label": "goog.json import goog.json", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0345, 0.0345, 0, 0.66, 0.0, 575, 0, 1, 0, 0, 575, 0, 0], "semantic": {"name": "goog.json", "arg_names": [], "import_names": ["goog...
[]
import goog.math as gm v0 = gm.Vec2(10, 12) print "ctor", v0 v1 = gm.Vec2.randomUnit() print "randomunit", gm.nearlyEquals(v1.magnitude(), 1.0); v2 = gm.Vec2.random() # todo; attr access #print v2.x >= -1 and v2.x <= 1, v2.y >= -1 and v2.y <= 1 v3 = gm.Vec2.fromCoordinate(gm.Coordinate(4, 5)) print "fromcoord", v3 ...
ajibawa-2023/Python-Code-Large/train/row_97350
34
49
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97350:Import_L1_C0", "label": "goog.math import gm", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0204, 0.0204, 0, 0.66, 0.0, 190, 0, 1, 0, 0, 190, 0, 0], "semantic": {"name": "goog.math", "arg_names": [], "import_names": ["gm"], "rhs_...
[]
from goog.json import parse as jparse print jparse(''' {"x":5, "y":6, "z":[3.1, 4.7, 5.6]} ''')
ajibawa-2023/Python-Code-Large/train/row_97351
1
2
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97351:ImportFrom_L1_C0", "label": "from goog.json import jparse", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.5, 0.5, 0, 0.66, 0.0, 575, 0, 1, 0, 0, 575, 0, 0], "semantic": {"name": "goog.json", "arg_names": [], "import_names": ["jpar...
[]
#!/usr/bin/python # # Copyright (C) 2012 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law ...
ajibawa-2023/Python-Code-Large/train/row_97352
133
305
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97352:Assign_L17_C0", "label": "__author__ =", "type": "assigned_variable", "loc": [17, 17], "level": 0, "parent": null, "vector": [14, 0, 0.0557, 0.0033, 0, 0.66, 0.0, 777, 1, 0, 0, 0, 0, 3, 0], "semantic": {"name": "__author__", "arg_names": [], "import_names": [], "r...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97352:ClassDef_L45_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97352:Expr_L46_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97352:ClassDef_L45_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97352:Assign_L47_C2"}, {"f": "ajibawa-2023/Python-Code-Large...
#!/usr/bin/python # # Copyright (C) 2012 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law ...
ajibawa-2023/Python-Code-Large/train/row_97353
218
605
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97353:Assign_L17_C0", "label": "__author__ =", "type": "assigned_variable", "loc": [17, 17], "level": 0, "parent": null, "vector": [14, 0, 0.0281, 0.0017, 0, 0.66, 0.0, 777, 1, 0, 0, 0, 0, 3, 0], "semantic": {"name": "__author__", "arg_names": [], "import_names": [], "r...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97353:FunctionDef_L46_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97353:Expr_L47_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97353:FunctionDef_L46_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97353:Return_L54_C2"}, {"f": "ajibawa-2023/Python-Code...
#!/usr/bin/env python # Copyright (c) 2010, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # notice, this l...
ajibawa-2023/Python-Code-Large/train/row_97355
51
187
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97355:Expr_L32_C0", "label": "expression", "type": "expression", "loc": [32, 36], "level": 0, "parent": null, "vector": [8, 0, 0.1818, 0.0267, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "anno...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97355:ClassDef_L41_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97355:Expr_L42_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97355:ClassDef_L45_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97355:Expr_L46_C2"}, {"f": "ajibawa-2023/Python-Code-Large/t...
#!/usr/bin/python2.4 # -*- coding: utf-8 -*- # # Copyright (C) 2011 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless ...
ajibawa-2023/Python-Code-Large/train/row_97357
86
244
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97357:Import_L18_C0", "label": "base64 import base64", "type": "import", "loc": [18, 18], "level": 0, "parent": null, "vector": [1, 0, 0.0738, 0.0041, 0, 0.66, 0.0, 177, 0, 1, 0, 0, 177, 0, 0], "semantic": {"name": "base64", "arg_names": [], "import_names": ["base64"], ...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97357:ClassDef_L36_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97357:Expr_L37_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97357:ClassDef_L36_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97357:FunctionDef_L39_C2"}, {"f": "ajibawa-2023/Python-Code-...
# Copyright 2011 Google Inc. All Rights Reserved. """Multi-credential file store with lock support. This module implements a JSON credential store where multiple credentials can be stored in one file. That file supports locking both in a single process and across processes. The credential themselves are keyed off o...
ajibawa-2023/Python-Code-Large/train/row_97359
155
378
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97359:Expr_L3_C0", "label": "expression", "type": "expression", "loc": [3, 30], "level": 0, "parent": null, "vector": [8, 0, 0.0437, 0.0741, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annota...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97359:ClassDef_L52_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97359:Expr_L53_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97359:ClassDef_L57_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97359:Expr_L58_C2"}, {"f": "ajibawa-2023/Python-Code-Large/t...
# Copyright (C) 2010 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writ...
ajibawa-2023/Python-Code-Large/train/row_97360
7
32
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97360:Expr_L15_C0", "label": "expression", "type": "expression", "loc": [15, 19], "level": 0, "parent": null, "vector": [8, 0, 0.5312, 0.1562, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "anno...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97360:Try_L24_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97360:Import_L26_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97360:Try_L24_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97360:Try_L28_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_...
# Copyright (C) 2010 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writ...
ajibawa-2023/Python-Code-Large/train/row_97362
396
1,139
15
["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"]
[{"id": "ajibawa-2023/Python-Code-Large/train/row_97362:Expr_L15_C0", "label": "expression", "type": "expression", "loc": [15, 18], "level": 0, "parent": null, "vector": [8, 0, 0.0145, 0.0035, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "anno...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_97362:Try_L37_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97362:ImportFrom_L38_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_97362:Try_L37_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_97362:ImportFrom_L39_C2"}, {"f": "ajibawa-2023/Python-Code-Large...