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
# Copyright (c) The PyAMF Project. # See LICENSE.txt for details. """ Useful helpers for adapters. @since: 0.4 """ import __builtin__ if not hasattr(__builtin__, 'set'): from sets import Set as set def to_list(obj, encoder): """ Converts an arbitrary object C{obj} to a C{list}. """ return list...
ajibawa-2023/Python-Code-Large/train/row_87045
19
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_87045:Expr_L4_C0", "label": "expression", "type": "expression", "loc": [4, 8], "level": 0, "parent": null, "vector": [8, 0, 0.12, 0.1, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation":...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87045:If_L12_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87045:ImportFrom_L13_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87045:FunctionDef_L16_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87045:Expr_L17_C4"}, {"f": "ajibawa-2023/Python-Code-Larg...
# Copyright (c) The PyAMF Project. # See LICENSE.txt for details. """ C{django.utils.translation} adapter module. @see: U{Django Project<http://www.djangoproject.com>} @since: 0.4.2 """ from django.utils.translation import ugettext_lazy import pyamf def convert_lazy(l, encoder=None): if l.__class__._delegate_...
ajibawa-2023/Python-Code-Large/train/row_87046
9
26
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_87046:Expr_L4_C0", "label": "expression", "type": "expression", "loc": [4, 9], "level": 0, "parent": null, "vector": [8, 0, 0.25, 0.2308, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotatio...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87046:FunctionDef_L16_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87046:If_L17_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87046:If_L17_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87046:Return_L18_C8"}, {"f": "ajibawa-2023/Python-Code-Large/trai...
# Copyright (c) The PyAMF Project. # See LICENSE.txt for details. """ U{array<http://docs.python.org/library/array.html>} adapter module. Will convert all array.array instances to a python list before encoding. All type information is lost (but degrades nicely). @since: 0.5 """ import array import pyamf from pyamf...
ajibawa-2023/Python-Code-Large/train/row_87047
6
20
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_87047:Expr_L4_C0", "label": "expression", "type": "expression", "loc": [4, 11], "level": 0, "parent": null, "vector": [8, 0, 0.375, 0.4, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87047:If_L19_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87047:Expr_L20_C4"}]
# Copyright (c) The PyAMF Project. # See LICENSE.txt for details. """ Django query adapter module. Sets up basic type mapping and class mappings for a Django models. @see: U{Django Project<http://www.djangoproject.com>} @since: 0.1b """ from django.db.models import query import pyamf from pyamf.adapters import uti...
ajibawa-2023/Python-Code-Large/train/row_87048
5
20
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_87048:Expr_L4_C0", "label": "expression", "type": "expression", "loc": [4, 12], "level": 0, "parent": null, "vector": [8, 0, 0.4, 0.45, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation"...
[]
# Copyright (c) The PyAMF Project. # See LICENSE.txt for details. """ The adapter package provides additional functionality for other Python packages. This includes registering classes, setting up type maps etc. @since: 0.1.0 """ import os.path import glob from pyamf.util import imports adapters_registered = Fals...
ajibawa-2023/Python-Code-Large/train/row_87049
36
91
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_87049:Expr_L4_C0", "label": "expression", "type": "expression", "loc": [4, 9], "level": 0, "parent": null, "vector": [8, 0, 0.0714, 0.0659, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87049:ClassDef_L20_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87049:Expr_L21_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87049:ClassDef_L20_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87049:FunctionDef_L24_C4"}, {"f": "ajibawa-2023/Python-Code-...
# Copyright (c) The PyAMF Project. # See LICENSE.txt for details. """ C{django.db.models.fields} adapter module. @see: U{Django Project<http://www.djangoproject.com>} @since: 0.4 """ from django.db.models import fields import pyamf def convert_NOT_PROVIDED(x, encoder): """ @rtype: L{Undefined<pyamf.Undefi...
ajibawa-2023/Python-Code-Large/train/row_87051
7
23
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_87051:Expr_L4_C0", "label": "expression", "type": "expression", "loc": [4, 9], "level": 0, "parent": null, "vector": [8, 0, 0.2826, 0.2609, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87051:FunctionDef_L16_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87051:Expr_L17_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87051:FunctionDef_L16_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87051:Return_L20_C4"}]
# Copyright (c) The PyAMF Project. # See LICENSE.txt for details. """ Provides XML support. @since: 0.6 """ #: list of supported third party packages that support the C{etree} #: interface. At least enough for our needs anyway. ETREE_MODULES = [ 'lxml.etree', 'xml.etree.cElementTree', 'cElementTree', ...
ajibawa-2023/Python-Code-Large/train/row_87052
62
165
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_87052:Expr_L4_C0", "label": "expression", "type": "expression", "loc": [4, 8], "level": 0, "parent": null, "vector": [8, 0, 0.0364, 0.0303, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87052:FunctionDef_L30_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87052:Expr_L31_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87052:FunctionDef_L30_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87052:Assign_L37_C4"}, {"f": "ajibawa-2023/Python-Code...
# Copyright (c) The PyAMF Project. # See LICENSE.txt for details. """ U{PyAMF<http://pyamf.org>} provides Action Message Format (U{AMF <http://en.wikipedia.org/wiki/Action_Message_Format>}) support for Python that is compatible with the Adobe U{Flash Player <http://en.wikipedia.org/wiki/Flash_Player>}. @since: Octobe...
ajibawa-2023/Python-Code-Large/train/row_87053
313
848
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_87053:Expr_L4_C0", "label": "expression", "type": "expression", "loc": [4, 12], "level": 0, "parent": null, "vector": [8, 0, 0.0094, 0.0106, 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_87053:ClassDef_L75_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87053:Expr_L76_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87053:ClassDef_L75_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87053:FunctionDef_L79_C4"}, {"f": "ajibawa-2023/Python-Code-...
# -*- coding: utf-8 -*- # # Copyright (c) The PyAMF Project. # See LICENSE.txt for details. """ Provides the pure Python versions of L{BufferedByteStream}. Do not reference directly, use L{pyamf.util.BufferedByteStream} instead. @since: 0.6 """ import struct try: from cStringIO import StringIO except ImportErr...
ajibawa-2023/Python-Code-Large/train/row_87054
295
700
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_87054:Expr_L6_C0", "label": "expression", "type": "expression", "loc": [6, 12], "level": 0, "parent": null, "vector": [8, 0, 0.0129, 0.01, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotati...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87054:Try_L16_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87054:ImportFrom_L17_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87054:Try_L16_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87054:ImportFrom_L19_C4"}, {"f": "ajibawa-2023/Python-Code-Large...
# Copyright (c) The PyAMF Project. # See LICENSE.txt for details. """ AMF Utilities. @since: 0.1.0 """ import calendar import datetime import inspect import pyamf from pyamf import python try: from cpyamf.util import BufferedByteStream except ImportError: from pyamf.util.pure import BufferedByteStream #:...
ajibawa-2023/Python-Code-Large/train/row_87055
87
197
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_87055:Expr_L4_C0", "label": "expression", "type": "expression", "loc": [4, 8], "level": 0, "parent": null, "vector": [8, 0, 0.0305, 0.0254, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87055:Try_L17_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87055:ImportFrom_L18_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87055:Try_L17_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87055:ImportFrom_L20_C4"}, {"f": "ajibawa-2023/Python-Code-Large...
# Copyright (c) The PyAMF Project. # See LICENSE.txt for details. """ Tools for doing dynamic imports. @since: 0.3 """ import sys __all__ = ['when_imported'] def when_imported(name, *hooks): """ Call C{hook(module)} when module named C{name} is first imported. C{name} must be a fully qualified (i.e. ...
ajibawa-2023/Python-Code-Large/train/row_87056
52
137
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_87056:Expr_L4_C0", "label": "expression", "type": "expression", "loc": [4, 8], "level": 0, "parent": null, "vector": [8, 0, 0.0438, 0.0365, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87056:FunctionDef_L16_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87056:Expr_L17_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87056:FunctionDef_L16_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87056:Expr_L30_C4"}, {"f": "ajibawa-2023/Python-Code-L...
# Copyright (c) The PyAMF Project. # See LICENSE.txt for details. """ Provides basic functionality for all pyamf.amf?.[De|E]ncoder classes. """ import types import datetime import pyamf from pyamf import util, python, xml __all__ = [ 'IndexedCollection', 'Context', 'Decoder', 'Encoder' ] try: u...
ajibawa-2023/Python-Code-Large/train/row_87057
239
521
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_87057:Expr_L4_C0", "label": "expression", "type": "expression", "loc": [4, 6], "level": 0, "parent": null, "vector": [8, 0, 0.0096, 0.0058, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87057:Try_L21_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87057:Expr_L22_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87057:Try_L21_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87057:Assign_L25_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row...
#!/usr/bin/env python # vim: noexpandtab import commands import os import re import sys from path import path USAGE=""" Usage: copy_gnulinux_libs.py /path/to/some/binary Copies all the necessary .so files for 'binary' to '/path/to/some'. This is useful to gather all files necessary for a nightly tarball. """ # Thi...
ajibawa-2023/Python-Code-Large/train/row_87059
41
107
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_87059:Import_L3_C0", "label": "commands import commands", "type": "import", "loc": [3, 3], "level": 0, "parent": null, "vector": [1, 0, 0.028, 0.0093, 0, 0.66, 0.0, 760, 0, 1, 0, 0, 760, 0, 0], "semantic": {"name": "commands", "arg_names": [], "import_names": ["commands...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87059:FunctionDef_L44_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87059:Expr_L45_C1"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87059:FunctionDef_L44_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87059:Assign_L51_C1"}, {"f": "ajibawa-2023/Python-Code...
#!/usr/bin/env python # -*- coding: utf-8 -*- # # WengoPhone, a voice over Internet phone # Copyright (C) 2004-2007 Wengo # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of t...
ajibawa-2023/Python-Code-Large/train/row_87060
25
68
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_87060:Import_L26_C0", "label": "binary_utilities import binary_utilities, os, platform\u2026", "type": "import", "loc": [26, 26], "level": 0, "parent": null, "vector": [1, 0, 0.3824, 0.0147, 0, 0.66, 0.0, 369, 0, 5, 0, 0, 369, 0, 0], "semantic": {"name": "binary_utiliti...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87060:FunctionDef_L34_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87060:Expr_L35_C1"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87060:FunctionDef_L34_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87060:Assign_L40_C1"}, {"f": "ajibawa-2023/Python-Code...
#!/usr/bin/env python # -*- coding: utf-8 -*- # # WengoPhone, a voice over Internet phone # Copyright (C) 2004-2007 Wengo # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of t...
ajibawa-2023/Python-Code-Large/train/row_87061
25
68
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_87061:Import_L26_C0", "label": "binary_utilities import binary_utilities, os, platform\u2026", "type": "import", "loc": [26, 26], "level": 0, "parent": null, "vector": [1, 0, 0.3824, 0.0147, 0, 0.66, 0.0, 369, 0, 5, 0, 0, 369, 0, 0], "semantic": {"name": "binary_utiliti...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87061:FunctionDef_L34_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87061:Expr_L35_C1"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87061:FunctionDef_L34_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87061:Assign_L40_C1"}, {"f": "ajibawa-2023/Python-Code...
#!/usr/bin/env python # -*- coding: utf-8 -*- # # WengoPhone, a voice over Internet phone # Copyright (C) 2004-2007 Wengo # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of t...
ajibawa-2023/Python-Code-Large/train/row_87063
44
96
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_87063:Import_L28_C0", "label": "binary_utilities import binary_utilities, os, re\u2026", "type": "import", "loc": [28, 28], "level": 0, "parent": null, "vector": [1, 0, 0.2917, 0.0104, 0, 0.66, 0.0, 369, 0, 4, 0, 0, 369, 0, 0], "semantic": {"name": "binary_utilities", "...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87063:FunctionDef_L40_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87063:Expr_L41_C1"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87063:FunctionDef_L40_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87063:Assign_L45_C1"}, {"f": "ajibawa-2023/Python-Code...
#!/usr/bin/env python # vim: noexpandtab import commands import os import re import sys from path import path USAGE=""" Usage: copy_gnulinux_libs.py /path/to/some/binary Copies all the necessary .so files for 'binary' to '/path/to/some'. This is useful to gather all files necessary for a nightly tarball. """ # Thi...
ajibawa-2023/Python-Code-Large/train/row_87064
41
107
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_87064:Import_L3_C0", "label": "commands import commands", "type": "import", "loc": [3, 3], "level": 0, "parent": null, "vector": [1, 0, 0.028, 0.0093, 0, 0.66, 0.0, 760, 0, 1, 0, 0, 760, 0, 0], "semantic": {"name": "commands", "arg_names": [], "import_names": ["commands...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87064:FunctionDef_L44_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87064:Expr_L45_C1"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87064:FunctionDef_L44_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87064:Assign_L51_C1"}, {"f": "ajibawa-2023/Python-Code...
#!/usr/bin/env python # -*- coding: utf-8 -*- # # WengoPhone, a voice over Internet phone # Copyright (C) 2004-2007 Wengo # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of t...
ajibawa-2023/Python-Code-Large/train/row_87068
44
96
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_87068:Import_L28_C0", "label": "binary_utilities import binary_utilities, os, re\u2026", "type": "import", "loc": [28, 28], "level": 0, "parent": null, "vector": [1, 0, 0.2917, 0.0104, 0, 0.66, 0.0, 369, 0, 4, 0, 0, 369, 0, 0], "semantic": {"name": "binary_utilities", "...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87068:FunctionDef_L40_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87068:Expr_L41_C1"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87068:FunctionDef_L40_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87068:Assign_L45_C1"}, {"f": "ajibawa-2023/Python-Code...
# Copyright 2009-2014 Lee Harr # # This file is part of pybotwar. # http://pybotwar.googlecode.com/ # # Pybotwar is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at yo...
ajibawa-2023/Python-Code-Large/train/row_87069
247
440
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_87069:Import_L20_C0", "label": "os import os", "type": "import", "loc": [20, 20], "level": 0, "parent": null, "vector": [1, 0, 0.0455, 0.0023, 0, 0.66, 0.0, 688, 0, 1, 0, 0, 688, 0, 0], "semantic": {"name": "os", "arg_names": [], "import_names": ["os"], "rhs_call_name":...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87069:FunctionDef_L103_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87069:Expr_L104_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87069:FunctionDef_L103_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87069:Expr_L105_C4"}, {"f": "ajibawa-2023/Python-Co...
# Copyright (c) 2009 John Schember # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distri...
ajibawa-2023/Python-Code-Large/train/row_87070
63
126
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_87070:ImportFrom_L22_C0", "label": "from PyQt4.Qt import QFrame, QWidget, QTextEdit\u2026", "type": "import", "loc": [22, 22], "level": 0, "parent": null, "vector": [1, 0, 0.1746, 0.0079, 0, 0.66, 0.0, 570, 0, 5, 0, 0, 570, 0, 0], "semantic": {"name": "PyQt4.Qt", "arg_n...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87070:ClassDef_L25_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87070:FunctionDef_L26_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87070:FunctionDef_L26_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87070:Expr_L27_C8"}, {"f": "ajibawa-2023/Python-Co...
from robot import Robot class TheRobot(Robot): '''Strategy: Drive around the edge of the arena, Shoot whatever gets in the way. ''' def respond(self): self.ping() self.turret_forward() self.ping_react() def turret_forward(self): 'keep the turret pointed...
ajibawa-2023/Python-Code-Large/train/row_87071
27
44
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_87071:ImportFrom_L1_C0", "label": "from robot import Robot", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0227, 0.0227, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "robot", "arg_names": [], "import_names": ["Robot"]...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87071:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87071:Expr_L4_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87071:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87071:FunctionDef_L9_C4"}, {"f": "ajibawa-2023/Python-Code-Larg...
from robot import Robot class TheRobot(Robot): '''Strategy: Drive around real fast, Don't run in to anything, Shoot stuff that gets in the way. ''' def initialize(self): self._spinning = False def respond(self): if self._spinning: self.spin() ...
ajibawa-2023/Python-Code-Large/train/row_87072
41
68
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_87072:ImportFrom_L1_C0", "label": "from robot import Robot", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0147, 0.0147, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "robot", "arg_names": [], "import_names": ["Robot"]...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87072:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87072:Expr_L4_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87072:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87072:FunctionDef_L10_C4"}, {"f": "ajibawa-2023/Python-Code-Lar...
import random from robot import Robot class TheRobot(Robot): '''Strategy: Drive around in sort of a circle, Shoot randomly. ''' def initialize(self): self._state = 'FORWARD' self._fwdfor_ticks = None self._rightfor_ticks = None self._unstick_freq = 12 ...
ajibawa-2023/Python-Code-Large/train/row_87073
75
116
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_87073:Import_L1_C0", "label": "random import random", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0086, 0.0086, 0, 0.66, 0.0, 715, 0, 1, 0, 0, 715, 0, 0], "semantic": {"name": "random", "arg_names": [], "import_names": ["random"], "rh...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87073:ClassDef_L5_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87073:Expr_L6_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87073:ClassDef_L5_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87073:FunctionDef_L11_C4"}, {"f": "ajibawa-2023/Python-Code-Lar...
from robot import Robot class TheRobot(Robot): '''Strategy: Circle around the center, Home in on any found robot and shoot it. ''' def initialize(self): self._foundrobotangle = None def respond(self): self.turret_forward() self.ping() kind, angle, d...
ajibawa-2023/Python-Code-Large/train/row_87074
67
94
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_87074:ImportFrom_L1_C0", "label": "from robot import Robot", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0106, 0.0106, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "robot", "arg_names": [], "import_names": ["Robot"]...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87074:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87074:Expr_L4_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87074:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87074:FunctionDef_L9_C4"}, {"f": "ajibawa-2023/Python-Code-Larg...
from robot import Robot from math import copysign class TheRobot(Robot): '''Strategy: Stay near the middle of the field, Move if being attacked. ''' def initialize(self): self.health = 100 self._flee = 15 self._goto = 0 self._moveto_choices = [7, 7, -7,...
ajibawa-2023/Python-Code-Large/train/row_87075
55
91
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_87075:ImportFrom_L1_C0", "label": "from robot import Robot", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.011, 0.011, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "robot", "arg_names": [], "import_names": ["Robot"], ...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87075:ClassDef_L5_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87075:Expr_L6_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87075:ClassDef_L5_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87075:FunctionDef_L11_C4"}, {"f": "ajibawa-2023/Python-Code-Lar...
from robot import Robot class TheRobot(Robot): '''Strategy: Get in to a corner, Look around and shoot stuff, Try to remember where stuff was, so you can shoot it real good. ''' def initialize(self): # Try to get in to a corner self.forseconds(5, self.istep, self...
ajibawa-2023/Python-Code-Large/train/row_87076
63
119
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_87076:ImportFrom_L1_C0", "label": "from robot import Robot", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0084, 0.0084, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "robot", "arg_names": [], "import_names": ["Robot"]...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87076:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87076:Expr_L4_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87076:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87076:FunctionDef_L10_C4"}, {"f": "ajibawa-2023/Python-Code-Lar...
# This example was used in verifying the problem outlined # in issue #5 in the bug tracker. from robot import Robot class TheRobot(Robot): def respond(self): self.turret(0) self.pingcheck() def pingcheck(self): g = self.sensors['GYRO'] if -2 <= g <= 2: self.ping() ...
ajibawa-2023/Python-Code-Large/train/row_87077
15
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_87077:ImportFrom_L4_C0", "label": "from robot import Robot", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.1905, 0.0476, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "robot", "arg_names": [], "import_names": ["Robot"]...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87077:ClassDef_L6_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87077:FunctionDef_L7_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87077:FunctionDef_L7_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87077:Expr_L8_C8"}, {"f": "ajibawa-2023/Python-Code-L...
from robot import Robot class TheRobot(Robot): '''Strategy: Look around and shoot stuff, Move if attacked. ''' def initialize(self): self.health = 100 self._movefor = 0 self._moveforce = 0 self._turnto = 0 def respond(self): self.turnto() ...
ajibawa-2023/Python-Code-Large/train/row_87078
40
70
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_87078:ImportFrom_L1_C0", "label": "from robot import Robot", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0143, 0.0143, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "robot", "arg_names": [], "import_names": ["Robot"]...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87078:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87078:Expr_L4_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87078:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87078:FunctionDef_L9_C4"}, {"f": "ajibawa-2023/Python-Code-Larg...
import random from math import pi from robot import Robot class TheRobot(Robot): '''Strategy: Drive around blindly in several different patterns, Shoot stuff. This robot shows an unusual style of coding using "generators" which makes programs that require sequential steps somewhat ...
ajibawa-2023/Python-Code-Large/train/row_87079
75
109
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_87079:Import_L1_C0", "label": "random import random", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0092, 0.0092, 0, 0.66, 0.0, 715, 0, 1, 0, 0, 715, 0, 0], "semantic": {"name": "random", "arg_names": [], "import_names": ["random"], "rh...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87079:ClassDef_L6_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87079:Expr_L7_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87079:ClassDef_L6_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87079:FunctionDef_L18_C4"}, {"f": "ajibawa-2023/Python-Code-Lar...
from robot import Robot class TheRobot(Robot): def initialize(self): # Will be called once, immediately after robot is created # Must finish in less than 1 second pass def respond(self): # Will be called 60 times per second # Must finish in less than 0.015 seconds ...
ajibawa-2023/Python-Code-Large/train/row_87080
4
18
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_87080:ImportFrom_L1_C0", "label": "from robot import Robot", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0556, 0.0556, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "robot", "arg_names": [], "import_names": ["Robot"]...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87080:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87080:FunctionDef_L4_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87080:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87080:FunctionDef_L11_C4"}]
# Copyright 2010-2014 Lee Harr # # This file is part of pybotwar. # http://pybotwar.googlecode.com/ # # Pybotwar is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at yo...
ajibawa-2023/Python-Code-Large/train/row_87081
22
48
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_87081:Import_L20_C0", "label": "os import os", "type": "import", "loc": [20, 20], "level": 0, "parent": null, "vector": [1, 0, 0.4167, 0.0208, 0, 0.66, 0.0, 688, 0, 1, 0, 0, 688, 0, 0], "semantic": {"name": "os", "arg_names": [], "import_names": ["os"], "rhs_call_name":...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87081:ClassDef_L30_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87081:FunctionDef_L31_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87081:FunctionDef_L31_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87081:Expr_L32_C8"}, {"f": "ajibawa-2023/Python-Co...
# Copyright 2009-2014 Lee Harr # # This file is part of pybotwar. # http://pybotwar.googlecode.com/ # # Pybotwar is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at yo...
ajibawa-2023/Python-Code-Large/train/row_87082
30
81
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_87082:ClassDef_L20_C0", "label": "Fake", "type": "class", "loc": [20, 34], "level": 0, "parent": null, "vector": [3, 0, 0.3333, 0.1852, 0, 0.66, 0.0, 120, 0, 5, 0, 0, 186, 0, 0], "semantic": {"name": "Fake", "arg_names": [], "import_names": [], "rhs_call_name": "", "ann...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87082:ClassDef_L20_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87082:FunctionDef_L21_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87082:ClassDef_L20_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87082:FunctionDef_L24_C4"}, {"f": "ajibawa-2023/Pytho...
# Copyright 2009-2014 Lee Harr # # This file is part of pybotwar. # http://pybotwar.googlecode.com/ # # Pybotwar is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at yo...
ajibawa-2023/Python-Code-Large/train/row_87083
192
253
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_87083:Import_L20_C0", "label": "os import os", "type": "import", "loc": [20, 20], "level": 0, "parent": null, "vector": [1, 0, 0.0791, 0.004, 0, 0.66, 0.0, 688, 0, 1, 0, 0, 688, 0, 0], "semantic": {"name": "os", "arg_names": [], "import_names": ["os"], "rhs_call_name": ...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87083:ClassDef_L32_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87083:FunctionDef_L33_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87083:FunctionDef_L33_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87083:Assign_L34_C8"}, {"f": "ajibawa-2023/Python-...
# Copyright 2009-2014 Lee Harr # # This file is part of pybotwar. # http://pybotwar.googlecode.com/ # # Pybotwar is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at yo...
ajibawa-2023/Python-Code-Large/train/row_87087
227
341
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_87087:Import_L20_C0", "label": "subprocess import subprocess", "type": "import", "loc": [20, 20], "level": 0, "parent": null, "vector": [1, 0, 0.0587, 0.0029, 0, 0.66, 0.0, 394, 0, 1, 0, 0, 394, 0, 0], "semantic": {"name": "subprocess", "arg_names": [], "import_names": ...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87087:ClassDef_L40_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87087:FunctionDef_L41_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87087:FunctionDef_L41_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87087:Assign_L42_C8"}, {"f": "ajibawa-2023/Python-...
#!/usr/bin/env python """ highlightedtextedit.py A PyQt custom widget example for Qt Designer. Copyright (C) 2006 David Boddie <david@boddie.org.uk> Copyright (C) 2005-2006 Trolltech ASA. All rights reserved. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General ...
ajibawa-2023/Python-Code-Large/train/row_87088
104
201
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_87088:Expr_L3_C0", "label": "expression", "type": "expression", "loc": [3, 24], "level": 0, "parent": null, "vector": [8, 0, 0.0672, 0.1095, 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_87088:ClassDef_L29_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87088:Expr_L31_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87088:ClassDef_L29_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87088:FunctionDef_L37_C4"}, {"f": "ajibawa-2023/Python-Code-...
# Copyright 2009-2014 Lee Harr # # This file is part of pybotwar. # http://pybotwar.googlecode.com/ # # Pybotwar is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at yo...
ajibawa-2023/Python-Code-Large/train/row_87089
12
36
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_87089:FunctionDef_L20_C0", "label": "select_view_module", "type": "function", "loc": [20, 32], "level": 0, "parent": null, "vector": [2, 0, 0.7222, 0.3611, 0, 0.66, 0.0, 808, 0, 1, 0, 0, 0, 0, 0], "semantic": {"name": "select_view_module", "arg_names": ["name"], "import...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87089:FunctionDef_L20_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87089:If_L22_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87089:If_L22_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87089:Import_L23_C8"}, {"f": "ajibawa-2023/Python-Code-Large/trai...
# Copyright 2009-2014 Lee Harr # # This file is part of pybotwar. # http://pybotwar.googlecode.com/ # # Pybotwar is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at yo...
ajibawa-2023/Python-Code-Large/train/row_87090
47
107
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_87090:Import_L20_C0", "label": "os import os", "type": "import", "loc": [20, 20], "level": 0, "parent": null, "vector": [1, 0, 0.1869, 0.0093, 0, 0.66, 0.0, 688, 0, 1, 0, 0, 688, 0, 0], "semantic": {"name": "os", "arg_names": [], "import_names": ["os"], "rhs_call_name":...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87090:FunctionDef_L23_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87090:Expr_L24_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87090:FunctionDef_L23_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87090:Assign_L26_C4"}, {"f": "ajibawa-2023/Python-Code...
# Settings use_qt_settings = True # Robot subprocess subproc_python = '/usr/bin/python' subproc_main = 'control.py' init_timeout = 1.0 tick_timeout = 0.015 # Robot selection base_dir = 'robots' # user robot files generally stored here more_robot_dirs = ['examples'] # In order, in case of dup name ...
ajibawa-2023/Python-Code-Large/train/row_87092
49
92
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_87092:Assign_L2_C0", "label": "use_qt_settings =", "type": "assigned_variable", "loc": [2, 2], "level": 0, "parent": null, "vector": [14, 0, 0.0217, 0.0109, 0, 0.66, 0.0, 758, 1, 0, 0, 0, 0, 4, 0], "semantic": {"name": "use_qt_settings", "arg_names": [], "import_names":...
[]
# Copyright 2009-2014 Lee Harr # # This file is part of pybotwar. # http://pybotwar.googlecode.com/ # # Pybotwar is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at yo...
ajibawa-2023/Python-Code-Large/train/row_87093
109
232
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_87093:Import_L20_C0", "label": "os import os", "type": "import", "loc": [20, 20], "level": 0, "parent": null, "vector": [1, 0, 0.0862, 0.0043, 0, 0.66, 0.0, 688, 0, 1, 0, 0, 688, 0, 0], "semantic": {"name": "os", "arg_names": [], "import_names": ["os"], "rhs_call_name":...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87093:ClassDef_L29_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87093:FunctionDef_L30_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87093:FunctionDef_L30_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87093:Assign_L31_C8"}, {"f": "ajibawa-2023/Python-...
# Copyright 2009-2014 Lee Harr # # This file is part of pybotwar. # http://pybotwar.googlecode.com/ # # Pybotwar is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at yo...
ajibawa-2023/Python-Code-Large/train/row_87095
702
975
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_87095:Import_L20_C0", "label": "os import os", "type": "import", "loc": [20, 20], "level": 0, "parent": null, "vector": [1, 0, 0.0205, 0.001, 0, 0.66, 0.0, 688, 0, 1, 0, 0, 688, 0, 0], "semantic": {"name": "os", "arg_names": [], "import_names": ["os"], "rhs_call_name": ...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87095:ClassDef_L45_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87095:FunctionDef_L46_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87095:FunctionDef_L46_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87095:Assign_L47_C8"}, {"f": "ajibawa-2023/Python-...
# Copyright 2009-2014 Lee Harr # # This file is part of pybotwar. # http://pybotwar.googlecode.com/ # # Pybotwar is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at yo...
ajibawa-2023/Python-Code-Large/train/row_87096
128
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_87096:Import_L20_C0", "label": "pygame import pygame", "type": "import", "loc": [20, 20], "level": 0, "parent": null, "vector": [1, 0, 0.107, 0.0053, 0, 0.66, 0.0, 87, 0, 1, 0, 0, 87, 0, 0], "semantic": {"name": "pygame", "arg_names": [], "import_names": ["pygame"], "rh...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87096:FunctionDef_L36_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87096:Try_L37_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87096:Try_L37_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87096:Assign_L38_C8"}, {"f": "ajibawa-2023/Python-Code-Large/tr...
from distutils.core import setup description = """ a simple email-to-a-friend application that generates an email form, handles its submission, persists the submission data to a database, and sends a templated email. Both anonymous and registered users can send email. """ long_description = description + """ This a...
ajibawa-2023/Python-Code-Large/train/row_87097
5
47
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_87097:ImportFrom_L1_C0", "label": "from distutils.core import setup", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0213, 0.0213, 0, 0.66, 0.0, 152, 0, 1, 0, 0, 152, 0, 0], "semantic": {"name": "distutils.core", "arg_names": [], "import...
[]
import re from django import forms try: from django.core.validators import email_re except ImportError: # django 1.1 from django.forms.fields import email_re from emailthis.models import EmailEvent class MultiEmailField(forms.CharField): def clean(self, value): if not value: rai...
ajibawa-2023/Python-Code-Large/train/row_87098
21
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_87098:Import_L1_C0", "label": "re import re", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0204, 0.0204, 0, 0.66, 0.0, 540, 0, 1, 0, 0, 540, 0, 0], "semantic": {"name": "re", "arg_names": [], "import_names": ["re"], "rhs_call_name": ""...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87098:Try_L4_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87098:ImportFrom_L5_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87098:Try_L4_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87098:ImportFrom_L8_C4"}, {"f": "ajibawa-2023/Python-Code-Large/tra...
import datetime from django.db import models from django.conf import settings from django.contrib.contenttypes import generic from django.contrib.contenttypes.models import ContentType AUTH_USER_MODEL = getattr(settings, 'AUTH_USER_MODEL', 'auth.User') class EmailEvent(models.Model): content_type = models.Forei...
ajibawa-2023/Python-Code-Large/train/row_87099
19
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_87099:Import_L1_C0", "label": "datetime import datetime", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0345, 0.0345, 0, 0.66, 0.0, 426, 0, 1, 0, 0, 426, 0, 0], "semantic": {"name": "datetime", "arg_names": [], "import_names": ["datetim...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87099:ClassDef_L11_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87099:Assign_L12_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87099:ClassDef_L11_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87099:Assign_L13_C4"}, {"f": "ajibawa-2023/Python-Code-Lar...
from django.conf.urls.defaults import patterns, url urlpatterns = patterns( 'emailthis.views', url(r'^(\d+)/(\d+)/$', 'get_email_form', name="emailthis_form"), url(r'^submit/(\d+)/(\d+)/$', 'process_email_form', name="emailthis_submit"), )
ajibawa-2023/Python-Code-Large/train/row_87100
2
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_87100:ImportFrom_L1_C0", "label": "from django.conf.urls.defaults import patterns, url", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0909, 0.0909, 0, 0.66, 0.0, 341, 0, 2, 0, 0, 341, 0, 0], "semantic": {"name": "django.conf.urls.defau...
[]
import httplib try: # prefer externally maintained version import simplejson except ImportError: # use bundled version from django.utils import simplejson from django.conf import settings from django.http import HttpResponse def render_to_json(data, status=httplib.OK): return HttpResponse(simple...
ajibawa-2023/Python-Code-Large/train/row_87101
23
40
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_87101:Import_L1_C0", "label": "httplib import httplib", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.025, 0.025, 0, 0.66, 0.0, 2, 0, 1, 0, 0, 2, 0, 0], "semantic": {"name": "httplib", "arg_names": [], "import_names": ["httplib"], "rhs_...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87101:Try_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87101:Import_L5_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87101:Try_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87101:ImportFrom_L8_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/r...
import httplib import logging import re import smtplib import socket from django.conf import settings from django.contrib.contenttypes.models import ContentType from django.contrib.sites.models import Site from django.core.exceptions import ObjectDoesNotExist from django.core.mail import EmailMessage from django.http ...
ajibawa-2023/Python-Code-Large/train/row_87102
79
133
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_87102:Import_L1_C0", "label": "httplib import httplib", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0075, 0.0075, 0, 0.66, 0.0, 2, 0, 1, 0, 0, 2, 0, 0], "semantic": {"name": "httplib", "arg_names": [], "import_names": ["httplib"], "rh...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87102:FunctionDef_L21_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87102:Expr_L22_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87102:FunctionDef_L21_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87102:Try_L26_C4"}, {"f": "ajibawa-2023/Python-Code-La...
""" A Django implementation of email-to-a-friend that works with unregistered or registered users. """ import datetime from django.core.exceptions import ObjectDoesNotExist from django.contrib.contenttypes.models import ContentType import django.db from emailthis.models import EmailEvent def _safe_get_object(ctyp...
ajibawa-2023/Python-Code-Large/train/row_87103
19
41
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_87103:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 6], "level": 0, "parent": null, "vector": [8, 0, 0.0854, 0.1463, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87103:FunctionDef_L16_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87103:Try_L17_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87103:Try_L17_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87103:Return_L18_C8"}, {"f": "ajibawa-2023/Python-Code-Large/tr...
''' Module which prompts the user for translations and saves them. TODO: implement @author: Rodrigo Damazio ''' class Translator(object): ''' classdocs ''' def __init__(self, language): ''' Constructor ''' self._language = language def Translate(self, string_names): print string_names
ajibawa-2023/Python-Code-Large/train/row_87104
8
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_87104:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 7], "level": 0, "parent": null, "vector": [8, 0, 0.1905, 0.3333, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87104:ClassDef_L9_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87104:Expr_L10_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87104:ClassDef_L9_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87104:FunctionDef_L14_C2"}, {"f": "ajibawa-2023/Python-Code-La...
''' Module which brings history information about files from Mercurial. @author: Rodrigo Damazio ''' import re import subprocess REVISION_REGEX = re.compile(r'(?P<hash>[0-9a-f]{12}):.*') def _GetOutputLines(args): ''' Runs an external process and returns its output as a list of lines. @param args: the argume...
ajibawa-2023/Python-Code-Large/train/row_87105
38
94
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_87105:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 5], "level": 0, "parent": null, "vector": [8, 0, 0.0319, 0.0532, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87105:FunctionDef_L12_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87105:Expr_L13_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87105:FunctionDef_L12_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87105:Assign_L18_C2"}, {"f": "ajibawa-2023/Python-Code...
''' Module which parses a string XML file. @author: Rodrigo Damazio ''' from xml.parsers.expat import ParserCreate import re #import xml.etree.ElementTree as ET class StringsParser(object): ''' Parser for string XML files. This object is not thread-safe and should be used for parsing a single file at a time...
ajibawa-2023/Python-Code-Large/train/row_87106
54
115
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_87106:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 5], "level": 0, "parent": null, "vector": [8, 0, 0.0261, 0.0435, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87106:ClassDef_L11_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87106:Expr_L12_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87106:ClassDef_L11_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87106:FunctionDef_L19_C2"}, {"f": "ajibawa-2023/Python-Code-...
#!/usr/bin/python ''' Entry point for My Tracks i18n tool. @author: Rodrigo Damazio ''' import mytracks.files import mytracks.translate import mytracks.validate import sys def Usage(): print 'Usage: %s <command> [<language> ...]\n' % sys.argv[0] print 'Commands are:' print ' cleanup' print ' translate' p...
ajibawa-2023/Python-Code-Large/train/row_87107
58
96
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_87107:Expr_L2_C0", "label": "expression", "type": "expression", "loc": [2, 6], "level": 0, "parent": null, "vector": [8, 0, 0.0417, 0.0521, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87107:FunctionDef_L13_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87107:Expr_L14_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87107:FunctionDef_L13_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87107:Expr_L15_C2"}, {"f": "ajibawa-2023/Python-Code-L...
''' Module which compares languague files to the master file and detects issues. @author: Rodrigo Damazio ''' import os from mytracks.parser import StringsParser import mytracks.history class Validator(object): def __init__(self, languages): ''' Builds a strings file validator. Params: @para...
ajibawa-2023/Python-Code-Large/train/row_87108
65
115
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_87108:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 6], "level": 0, "parent": null, "vector": [8, 0, 0.0304, 0.0522, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87108:ClassDef_L12_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87108:FunctionDef_L14_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87108:FunctionDef_L14_C2", "t": "ajibawa-2023/Python-Code-Large/train/row_87108:Expr_L15_C4"}, {"f": "ajibawa-2023/Python-Co...
''' Module for dealing with resource files (but not their contents). @author: Rodrigo Damazio ''' import os.path from glob import glob import re MYTRACKS_RES_DIR = 'MyTracks/res' ANDROID_MASTER_VALUES = 'values' ANDROID_VALUES_MASK = 'values-*' def GetMyTracksDir(): ''' Returns the directory in which the MyTrac...
ajibawa-2023/Python-Code-Large/train/row_87109
25
45
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_87109:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 5], "level": 0, "parent": null, "vector": [8, 0, 0.0667, 0.1111, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87109:FunctionDef_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87109:Expr_L16_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87109:FunctionDef_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87109:Assign_L19_C2"}, {"f": "ajibawa-2023/Python-Code...
''' Created on 21-03-2011 @author: maciek ''' from IndexGenerator import IndexGenerator from optparse import OptionParser import os import tempfile import shutil import logging logging.basicConfig(level = logging.DEBUG) parser = OptionParser() parser.add_option('-n', '--app-name', action='store', dest='appName', hel...
ajibawa-2023/Python-Code-Large/train/row_87110
69
88
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_87110:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 5], "level": 0, "parent": null, "vector": [8, 0, 0.0341, 0.0568, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87110:If_L26_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87110:Expr_L27_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87110:If_L26_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87110:If_L28_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87110...
''' Created on 21-03-2011 @author: maciek ''' def formatString(format, **kwargs): ''' ''' if not format: return '' for arg in kwargs.keys(): format = format.replace("{" + arg + "}", "##" + arg + "##") format = format.replace ("{", "{{") format = format.replace("}", "}}") for...
ajibawa-2023/Python-Code-Large/train/row_87111
15
23
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_87111:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 5], "level": 0, "parent": null, "vector": [8, 0, 0.1304, 0.2174, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87111:FunctionDef_L8_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87111:Expr_L9_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87111:FunctionDef_L8_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87111:If_L11_C4"}, {"f": "ajibawa-2023/Python-Code-Large/...
''' Created on 21-03-2011 @author: maciek ''' from formater import formatString import os class IndexGenerator(object): ''' Generates Index.html for iOS app OTA distribution ''' basePath = os.path.dirname(__file__) templateFile = os.path.join(basePath,"templates/index.tmpl") releaseUrls = "" ...
ajibawa-2023/Python-Code-Large/train/row_87112
31
57
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_87112:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 5], "level": 0, "parent": null, "vector": [8, 0, 0.0526, 0.0877, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87112:ClassDef_L10_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87112:Expr_L11_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87112:ClassDef_L10_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87112:Assign_L14_C4"}, {"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_87113
189
572
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_87113:Assign_L17_C0", "label": "__author__ =", "type": "assigned_variable", "loc": [17, 17], "level": 0, "parent": null, "vector": [14, 0, 0.0297, 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_87113:FunctionDef_L46_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87113:Expr_L47_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87113:FunctionDef_L46_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87113:Return_L54_C2"}, {"f": "ajibawa-2023/Python-Code...
#!/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_87114
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_87114: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_87114:ClassDef_L45_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87114:Expr_L46_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87114:ClassDef_L45_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87114:Assign_L47_C2"}, {"f": "ajibawa-2023/Python-Code-Large...
# This is the version of this source code. manual_verstr = "1.5" auto_build_num = "211" verstr = manual_verstr + "." + auto_build_num try: from pyutil.version_class import Version as pyutil_Version __version__ = pyutil_Version(verstr) except (ImportError, ValueError): # Maybe there is no pyutil insta...
ajibawa-2023/Python-Code-Large/train/row_87116
8
18
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_87116:Assign_L3_C0", "label": "manual_verstr =", "type": "assigned_variable", "loc": [3, 3], "level": 0, "parent": null, "vector": [14, 0, 0.1667, 0.0556, 0, 0.66, 0.0, 189, 1, 0, 0, 0, 0, 3, 0], "semantic": {"name": "manual_verstr", "arg_names": [], "import_names": [],...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87116:Try_L12_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87116:ImportFrom_L13_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87116:Try_L12_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87116:Assign_L14_C4"}, {"f": "ajibawa-2023/Python-Code-Large/tra...
""" The MIT License Copyright (c) 2007-2010 Leah Culver, Joe Stump, Mark Paschal, Vic Fryzel Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the ...
ajibawa-2023/Python-Code-Large/train/row_87117
9
40
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_87117:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 23], "level": 0, "parent": null, "vector": [8, 0, 0.3, 0.575, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87117:ClassDef_L29_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87117:Expr_L30_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87117:ClassDef_L29_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87117:FunctionDef_L32_C4"}, {"f": "ajibawa-2023/Python-Code-...
""" The MIT License Copyright (c) 2007-2010 Leah Culver, Joe Stump, Mark Paschal, Vic Fryzel Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the ...
ajibawa-2023/Python-Code-Large/train/row_87118
10
41
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_87118:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 23], "level": 0, "parent": null, "vector": [8, 0, 0.2927, 0.561, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87118:ClassDef_L30_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87118:Expr_L31_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87118:ClassDef_L30_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87118:FunctionDef_L33_C4"}, {"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_87120
155
366
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_87120:Expr_L3_C0", "label": "expression", "type": "expression", "loc": [3, 30], "level": 0, "parent": null, "vector": [8, 0, 0.0451, 0.0765, 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_87120:Try_L40_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87120:Import_L41_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87120:Try_L40_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87120:Try_L43_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_87121
348
953
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_87121:Expr_L15_C0", "label": "expression", "type": "expression", "loc": [15, 18], "level": 0, "parent": null, "vector": [8, 0, 0.0173, 0.0042, 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_87121:Try_L36_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87121:ImportFrom_L37_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87121:Try_L36_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87121:ImportFrom_L38_C2"}, {"f": "ajibawa-2023/Python-Code-Large...
# 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_87122
38
92
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_87122:Expr_L15_C0", "label": "expression", "type": "expression", "loc": [15, 19], "level": 0, "parent": null, "vector": [8, 0, 0.1848, 0.0543, 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_87122:Try_L26_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87122:Import_L27_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87122:Try_L26_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87122:Try_L29_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_87123
55
114
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_87123:Expr_L15_C0", "label": "expression", "type": "expression", "loc": [15, 19], "level": 0, "parent": null, "vector": [8, 0, 0.1491, 0.0439, 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_87123:ClassDef_L30_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87123:Assign_L32_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87123:ClassDef_L30_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87123:FunctionDef_L34_C2"}, {"f": "ajibawa-2023/Python-Cod...
# 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_87124
214
544
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_87124:Expr_L15_C0", "label": "expression", "type": "expression", "loc": [15, 18], "level": 0, "parent": null, "vector": [8, 0, 0.0303, 0.0074, 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_87124:Try_L28_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87124:Import_L29_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87124:Try_L28_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87124:Try_L31_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_...
#!/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_87125
90
253
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_87125:Import_L18_C0", "label": "base64 import base64", "type": "import", "loc": [18, 18], "level": 0, "parent": null, "vector": [1, 0, 0.0711, 0.004, 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_87125:Try_L25_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87125:Import_L26_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87125:Try_L25_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87125:Try_L28_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_...
# 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 required by applicable law or agreed to in writ...
ajibawa-2023/Python-Code-Large/train/row_87126
37
113
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_87126:Expr_L15_C0", "label": "expression", "type": "expression", "loc": [15, 19], "level": 0, "parent": null, "vector": [8, 0, 0.1504, 0.0442, 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_87126:Try_L24_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87126:Import_L25_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87126:Try_L24_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87126:Try_L27_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_...
import Cookie import datetime import time import email.utils import calendar import base64 import hashlib import hmac import re import logging # Ripped from the Tornado Framework's web.py # http://github.com/facebook/tornado/commit/39ac6d169a36a54bb1f6b9bf1fdebb5c9da96e09 # # Tornado is licensed under the Apache Licen...
ajibawa-2023/Python-Code-Large/train/row_87127
115
168
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_87127:Import_L1_C0", "label": "Cookie import Cookie", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.006, 0.006, 0, 0.66, 0.0, 32, 0, 1, 0, 0, 32, 0, 0], "semantic": {"name": "Cookie", "arg_names": [], "import_names": ["Cookie"], "rhs_ca...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87127:ClassDef_L23_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87127:FunctionDef_L26_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87127:FunctionDef_L26_C2", "t": "ajibawa-2023/Python-Code-Large/train/row_87127:If_L27_C4"}, {"f": "ajibawa-2023/Python-Code...
# Copyright (C) 2007 Joe Gregorio # # Licensed under the MIT License """MIME-Type Parser This module provides basic functions for handling mime-types. It can handle matching mime-types against a list of media-ranges. See section 14.1 of the HTTP specification [RFC 2616] for a complete explanation. http://www.w3.o...
ajibawa-2023/Python-Code-Large/train/row_87128
57
172
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_87128:Expr_L5_C0", "label": "expression", "type": "expression", "loc": [5, 23], "level": 0, "parent": null, "vector": [8, 0, 0.0814, 0.1105, 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_87128:FunctionDef_L32_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87128:Expr_L33_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87128:FunctionDef_L32_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87128:Assign_L42_C4"}, {"f": "ajibawa-2023/Python-Code...
# 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_87129
374
940
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_87129:Expr_L15_C0", "label": "expression", "type": "expression", "loc": [15, 20], "level": 0, "parent": null, "vector": [8, 0, 0.0186, 0.0064, 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_87129:ClassDef_L51_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87129:Expr_L52_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87129:ClassDef_L51_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87129:FunctionDef_L54_C2"}, {"f": "ajibawa-2023/Python-Code-...
# 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_87130
201
483
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_87130:Expr_L15_C0", "label": "expression", "type": "expression", "loc": [15, 18], "level": 0, "parent": null, "vector": [8, 0, 0.0342, 0.0083, 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_87130:Try_L31_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87130:ImportFrom_L32_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87130:Try_L31_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87130:ImportFrom_L34_C2"}, {"f": "ajibawa-2023/Python-Code-Large...
#!/usr/bin/python2.4 # # 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 l...
ajibawa-2023/Python-Code-Large/train/row_87131
145
366
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_87131:Expr_L17_C0", "label": "expression", "type": "expression", "loc": [17, 23], "level": 0, "parent": null, "vector": [8, 0, 0.0546, 0.0191, 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_87131:ClassDef_L45_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87131:Expr_L46_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87131:ClassDef_L45_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87131:FunctionDef_L53_C2"}, {"f": "ajibawa-2023/Python-Code-...
# 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_87133
28
63
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_87133:Expr_L15_C0", "label": "expression", "type": "expression", "loc": [15, 18], "level": 0, "parent": null, "vector": [8, 0, 0.2619, 0.0635, 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_87133:ClassDef_L28_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87133:Expr_L29_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87133:ClassDef_L28_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87133:FunctionDef_L31_C2"}, {"f": "ajibawa-2023/Python-Code-...
# 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_87134
29
56
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_87134:Import_L15_C0", "label": "apiclient import apiclient", "type": "import", "loc": [15, 15], "level": 0, "parent": null, "vector": [1, 0, 0.2679, 0.0179, 0, 0.66, 0.0, 629, 0, 1, 0, 0, 629, 0, 0], "semantic": {"name": "apiclient", "arg_names": [], "import_names": ["a...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87134:ClassDef_L22_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87134:Assign_L24_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87134:ClassDef_L22_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87134:FunctionDef_L26_C2"}, {"f": "ajibawa-2023/Python-Cod...
# 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_87135
55
135
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_87135:Expr_L15_C0", "label": "expression", "type": "expression", "loc": [15, 19], "level": 0, "parent": null, "vector": [8, 0, 0.1259, 0.037, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annot...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87135:ClassDef_L30_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87135:Expr_L31_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87135:ClassDef_L30_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87135:Assign_L36_C2"}, {"f": "ajibawa-2023/Python-Code-Large...
#!/usr/bin/python2.4 # # 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 l...
ajibawa-2023/Python-Code-Large/train/row_87137
49
114
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_87137:Expr_L17_C0", "label": "expression", "type": "expression", "loc": [17, 21], "level": 0, "parent": null, "vector": [8, 0, 0.1667, 0.0439, 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_87137:ClassDef_L29_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87137:Expr_L30_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87137:ClassDef_L34_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87137:Expr_L35_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_87138
114
303
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_87138:Expr_L15_C0", "label": "expression", "type": "expression", "loc": [15, 58], "level": 0, "parent": null, "vector": [8, 0, 0.1205, 0.1452, 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_87138:ClassDef_L68_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87138:Expr_L69_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87138:ClassDef_L68_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87138:FunctionDef_L71_C2"}, {"f": "ajibawa-2023/Python-Code-...
# 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_87139
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_87139: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_87139:Try_L24_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87139:Import_L25_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87139:Try_L24_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87139:Try_L27_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_...
# Early, and incomplete implementation of -04. # import re import urllib RESERVED = ":/?#[]@!$&'()*+,;=" OPERATOR = "+./;?|!@" EXPLODE = "*+" MODIFIER = ":^" TEMPLATE = re.compile(r"{(?P<operator>[\+\./;\?|!@])?(?P<varlist>[^}]+)}", re.UNICODE) VAR = re.compile(r"^(?P<varname>[^=\+\*:\^]+)((?P<explode>[\+\*])|(?P<part...
ajibawa-2023/Python-Code-Large/train/row_87140
112
147
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_87140:Import_L3_C0", "label": "re import re", "type": "import", "loc": [3, 3], "level": 0, "parent": null, "vector": [1, 0, 0.0204, 0.0068, 0, 0.66, 0.0, 540, 0, 1, 0, 0, 540, 0, 0], "semantic": {"name": "re", "arg_names": [], "import_names": ["re"], "rhs_call_name": ""...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87140:FunctionDef_L13_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87140:If_L14_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87140:If_L14_C2", "t": "ajibawa-2023/Python-Code-Large/train/row_87140:If_L15_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/ro...
#!/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_87141
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_87141: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_87141:ClassDef_L41_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87141:Expr_L42_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87141:ClassDef_L45_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87141:Expr_L46_C2"}, {"f": "ajibawa-2023/Python-Code-Large/t...
"""SocksiPy - Python SOCKS module. Version 1.00 Copyright 2006 Dan-Haim. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this ...
ajibawa-2023/Python-Code-Large/train/row_87142
213
438
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_87142:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 31], "level": 0, "parent": null, "vector": [8, 0, 0.0365, 0.0708, 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_87142:FunctionDef_L96_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87142:Expr_L97_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87142:FunctionDef_L96_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87142:Assign_L102_C4"}, {"f": "ajibawa-2023/Python-Cod...
""" iri2uri Converts an IRI to a URI. """ __author__ = "Joe Gregorio (joe@bitworking.org)" __copyright__ = "Copyright 2006, Joe Gregorio" __contributors__ = [] __version__ = "1.0.0" __license__ = "MIT" __history__ = """ """ import urlparse # Convert an IRI to a URI following the rules in RFC 3987 # # The characte...
ajibawa-2023/Python-Code-Large/train/row_87143
43
110
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_87143:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 6], "level": 0, "parent": null, "vector": [8, 0, 0.0318, 0.0545, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87143:FunctionDef_L53_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87143:Assign_L54_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87143:FunctionDef_L53_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87143:Assign_L55_C4"}, {"f": "ajibawa-2023/Python-Co...
from StoredObject import * class Message(StoredObject): TEXT = 0 PHOTO = 1 GRAPHITY = 2 VIDEO = 3 AUDIO = 4 def __init__(self, id, time, text, mfrom, mto, isReaded, # Parameters defined at wall's messages retrieval message_type = 0, message_name = None, ...
ajibawa-2023/Python-Code-Large/train/row_87146
36
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_87146:ImportFrom_L1_C0", "label": "from StoredObject import *", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0204, 0.0204, 0, 0.66, 0.0, 754, 0, 1, 0, 0, 754, 0, 0], "semantic": {"name": "StoredObject", "arg_names": [], "import_names":...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87146:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87146:Assign_L4_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87146:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87146:Assign_L5_C4"}, {"f": "ajibawa-2023/Python-Code-Large/t...
import Captcha from Errors import UserAPIError import httplib import re ID="1" USERAPI_HOST="login.userapi.com" class Session: def __init__(self, filename = None, remixpass = None, sid = None): if filename: self.load_session(filename) self.renew_session() else: ...
ajibawa-2023/Python-Code-Large/train/row_87147
66
114
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_87147:Import_L1_C0", "label": "Captcha import Captcha", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0088, 0.0088, 0, 0.66, 0.0, 42, 0, 1, 0, 0, 42, 0, 0], "semantic": {"name": "Captcha", "arg_names": [], "import_names": ["Captcha"], "...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87147:ClassDef_L10_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87147:FunctionDef_L11_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87147:FunctionDef_L11_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87147:If_L12_C8"}, {"f": "ajibawa-2023/Python-Code...
from StoredObject import * class Privacy: def __init__(self, may_look_profile, may_look_wall, may_leave_messages): self.may_look_profile = may_look_profile self.may_look_wall = may_look_wall self.may_leave_messages = may_leave_messages class Position: def __init__(self, id_count...
ajibawa-2023/Python-Code-Large/train/row_87148
80
109
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_87148:ImportFrom_L1_C0", "label": "from StoredObject import *", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0092, 0.0092, 0, 0.66, 0.0, 754, 0, 1, 0, 0, 754, 0, 0], "semantic": {"name": "StoredObject", "arg_names": [], "import_names":...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87148:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87148:FunctionDef_L4_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87148:FunctionDef_L4_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87148:Assign_L5_C8"}, {"f": "ajibawa-2023/Python-Code...
from StoredObject import * class Photo(StoredObject): def __init__ (self, id, pic, small_pic): self.id = id self.pic = pic self.small_pic = small_pic class PhotosUploadInfo: def __init__(self, aid, upload_url = None, upload_hash = None, upload_rhash = None): se...
ajibawa-2023/Python-Code-Large/train/row_87149
18
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_87149:ImportFrom_L1_C0", "label": "from StoredObject import *", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0455, 0.0455, 0, 0.66, 0.0, 754, 0, 1, 0, 0, 754, 0, 0], "semantic": {"name": "StoredObject", "arg_names": [], "import_names":...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87149:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87149:FunctionDef_L4_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87149:FunctionDef_L4_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87149:Assign_L5_C8"}, {"f": "ajibawa-2023/Python-Code...
class StoredObject: def __eq__(self, other): return int(self.id) == int(other.id) def __ne__(self, other): return int(self.id) != int(other.id) def __hash__(self): return int(self.id)
ajibawa-2023/Python-Code-Large/train/row_87150
7
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_87150:ClassDef_L1_C0", "label": "StoredObject", "type": "class", "loc": [1, 9], "level": 0, "parent": null, "vector": [3, 0, 0.5556, 1.0, 0, 0.66, 0.0, 754, 0, 3, 0, 0, 0, 0, 5], "semantic": {"name": "StoredObject", "arg_names": [], "import_names": [], "rhs_call_name": ...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87150:ClassDef_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87150:FunctionDef_L2_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87150:FunctionDef_L2_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87150:Return_L3_C8"}, {"f": "ajibawa-2023/Python-Code...
import webbrowser class Captcha: def __init__(self): self.csid =4 # Chosed randomly! print "Look at browser and enter the captcha to console" webbrowser.open("http://userapi.com/data?act=captcha&csid=" + str(self.csid)) self.text = raw_input("VKontakte captcha: ") ...
ajibawa-2023/Python-Code-Large/train/row_87151
7
12
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_87151:Import_L1_C0", "label": "webbrowser import webbrowser", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0833, 0.0833, 0, 0.66, 0.0, 461, 0, 1, 0, 0, 461, 0, 0], "semantic": {"name": "webbrowser", "arg_names": [], "import_names": ["w...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87151:ClassDef_L3_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87151:FunctionDef_L4_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87151:FunctionDef_L4_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87151:Assign_L5_C8"}, {"f": "ajibawa-2023/Python-Code...
class UserAPIError: def __init__(this, code, action, text): this.code = code this.action = action this.text = text class JSONProblemError(Exception): def __init__(self, json_data, supplement): self.json_data = json_data self.supplement = supplement
ajibawa-2023/Python-Code-Large/train/row_87152
9
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_87152:ClassDef_L1_C0", "label": "UserAPIError", "type": "class", "loc": [1, 5], "level": 0, "parent": null, "vector": [3, 0, 0.2727, 0.4545, 0, 0.66, 0.0, 167, 0, 1, 0, 0, 0, 0, 0], "semantic": {"name": "UserAPIError", "arg_names": [], "import_names": [], "rhs_call_name...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87152:ClassDef_L1_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87152:FunctionDef_L2_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87152:FunctionDef_L2_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_87152:Assign_L3_C8"}, {"f": "ajibawa-2023/Python-Code...
from UserAPI import Token from UserAPI import UserAPITypes from UserAPI import RetCodes from UserAPI import UserAPI from Session import Session from Errors import UserAPIError, JSONProblemError
ajibawa-2023/Python-Code-Large/train/row_87153
6
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_87153:ImportFrom_L1_C0", "label": "from UserAPI import Token", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.125, 0.125, 0, 0.66, 0.0, 3, 0, 1, 0, 0, 3, 0, 0], "semantic": {"name": "UserAPI", "arg_names": [], "import_names": ["Token"], ...
[]
from Parser import * from Errors import * import Session import httplib import re import json class Token: Standard = None Login = 0 Action = 1 class RetCodes: NoError = 0 Error = 1 class UserAPITypes: Standard = None Outbox = "outbox" ...
ajibawa-2023/Python-Code-Large/train/row_87154
151
222
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_87154:ImportFrom_L1_C0", "label": "from Parser import *", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0045, 0.0045, 0, 0.66, 0.0, 717, 0, 1, 0, 0, 717, 0, 0], "semantic": {"name": "Parser", "arg_names": [], "import_names": ["*"], "rhs...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87154:ClassDef_L10_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87154:Assign_L11_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87154:ClassDef_L10_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87154:Assign_L12_C4"}, {"f": "ajibawa-2023/Python-Code-Lar...
import json import datetime from Message import * from Person import * from Photo import * MSG_PERSON = 0 FRI_PERSON = 1 PRO_PERSON = 2 def listify(data, size): result = [None for i in range(0, size)] if isinstance(data, list): for i in range(0, len(data)): result[i] = data[i] elif...
ajibawa-2023/Python-Code-Large/train/row_87155
114
198
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_87155:Import_L1_C0", "label": "json import json", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0051, 0.0051, 0, 0.66, 0.0, 463, 0, 1, 0, 0, 463, 0, 0], "semantic": {"name": "json", "arg_names": [], "import_names": ["json"], "rhs_call_n...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87155:FunctionDef_L12_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87155:Assign_L13_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87155:FunctionDef_L12_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87155:If_L14_C4"}, {"f": "ajibawa-2023/Python-Code-L...
# -*- coding: utf-8 -*- from userapi import * USER = "test.vkontakte@mail.ru" PASS = "yi8zXpHIs" DID="41657126" def test_profile(id = None): profile = test.v_profile(id) print "Profile of user " + profile.name + " <" + str(profile.id) + "> " print "Mother: " + str(profile.mother) print "Status: " ...
ajibawa-2023/Python-Code-Large/train/row_87156
77
111
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_87156:ImportFrom_L3_C0", "label": "from userapi import *", "type": "import", "loc": [3, 3], "level": 0, "parent": null, "vector": [1, 0, 0.027, 0.009, 0, 0.66, 0.0, 981, 0, 1, 0, 0, 981, 0, 0], "semantic": {"name": "userapi", "arg_names": [], "import_names": ["*"], "rhs...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87156:FunctionDef_L9_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87156:Assign_L10_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87156:FunctionDef_L9_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87156:Expr_L11_C4"}, {"f": "ajibawa-2023/Python-Code-L...
#!/usr/bin/python2.4 # # Copyright 2007 The Python-Twitter Developers # # 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...
ajibawa-2023/Python-Code-Large/train/row_87157
53
90
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_87157:Import_L18_C0", "label": "os import os", "type": "import", "loc": [18, 18], "level": 0, "parent": null, "vector": [1, 0, 0.2, 0.0111, 0, 0.66, 0.0, 688, 0, 1, 0, 0, 688, 0, 0], "semantic": {"name": "os", "arg_names": [], "import_names": ["os"], "rhs_call_name": ""...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87157:Try_L22_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87157:ImportFrom_L23_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87157:Try_L22_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87157:ImportFrom_L25_C2"}, {"f": "ajibawa-2023/Python-Code-Large...
#!/usr/bin/python2.4 '''Post a message to twitter''' __author__ = 'dewitt@google.com' import ConfigParser import getopt import os import sys import twitter USAGE = '''Usage: tweet [options] message This script posts a message to Twitter. Options: -h --help : print this help --consumer-key : the twit...
ajibawa-2023/Python-Code-Large/train/row_87160
82
141
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_87160:Expr_L3_C0", "label": "expression", "type": "expression", "loc": [3, 3], "level": 0, "parent": null, "vector": [8, 0, 0.0213, 0.0071, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87160:FunctionDef_L49_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87160:Expr_L50_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87160:FunctionDef_L49_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87160:Expr_L51_C2"}, {"f": "ajibawa-2023/Python-Code-L...
#!/usr/bin/python2.4 # # Copyright 2007 The Python-Twitter Developers # # 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...
ajibawa-2023/Python-Code-Large/train/row_87161
16
71
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_87161:Expr_L17_C0", "label": "expression", "type": "expression", "loc": [17, 20], "level": 0, "parent": null, "vector": [8, 0, 0.2606, 0.0563, 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_87161:ClassDef_L36_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87161:Expr_L37_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87161:ClassDef_L36_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87161:FunctionDef_L38_C4"}, {"f": "ajibawa-2023/Python-Code-...
#!/usr/bin/python2.4 # # Copyright 2007 The Python-Twitter Developers # # 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...
ajibawa-2023/Python-Code-Large/train/row_87162
19
73
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_87162:Expr_L17_C0", "label": "expression", "type": "expression", "loc": [17, 17], "level": 0, "parent": null, "vector": [8, 0, 0.2329, 0.0137, 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_87162:FunctionDef_L52_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87162:Return_L53_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87162:FunctionDef_L55_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87162:Return_L56_C2"}, {"f": "ajibawa-2023/Python-Co...
"""JSON token scanner """ import re try: from simplejson._speedups import make_scanner as c_make_scanner except ImportError: c_make_scanner = None __all__ = ['make_scanner'] NUMBER_RE = re.compile( r'(-?(?:0|[1-9]\d*))(\.\d+)?([eE][-+]?\d+)?', (re.VERBOSE | re.MULTILINE | re.DOTALL)) def py_make_scan...
ajibawa-2023/Python-Code-Large/train/row_87164
48
65
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_87164:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 2], "level": 0, "parent": null, "vector": [8, 0, 0.0231, 0.0308, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat...
[{"f": "ajibawa-2023/Python-Code-Large/train/row_87164:Try_L4_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87164:ImportFrom_L5_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_87164:Try_L4_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_87164:Assign_L7_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/r...