repo_name
stringlengths
7
94
repo_path
stringlengths
4
237
repo_head_hexsha
stringlengths
40
40
content
stringlengths
10
680k
apis
stringlengths
2
840k
rs9899/Parsing-R-CNN
utils/data/dataset_catalog.py
a0c9ed8850abe740eedf8bfc6e1577cc0aa3fc7b
import os.path as osp # Root directory of project ROOT_DIR = osp.abspath(osp.join(osp.dirname(__file__), '..', '..')) # Path to data dir _DATA_DIR = osp.abspath(osp.join(ROOT_DIR, 'data')) # Required dataset entry keys _IM_DIR = 'image_directory' _ANN_FN = 'annotation_file' # Available datasets COMMON_DATASETS = { ...
[((7, 24, 7, 50), 'os.path.join', 'osp.join', ({(7, 33, 7, 41): 'ROOT_DIR', (7, 43, 7, 49): '"""data"""'}, {}), "(ROOT_DIR, 'data')", True, 'import os.path as osp\n'), ((4, 32, 4, 53), 'os.path.dirname', 'osp.dirname', ({(4, 44, 4, 52): '__file__'}, {}), '(__file__)', True, 'import os.path as osp\n')]
Dakewe-DS1000/LapRSNet
prepareDataSet.py
47e630acd3f0523ee5ac698566ff45e645681b23
# Prepare my dataset for Digital Pathology import os import math import cv2 import pdb rootFolder = "F:\DataBase\LymphnodePathology" trainFolder = rootFolder + "\\trainDataSet" testFolder = rootFolder + "\\testDataSet" srcTrainFilePath = trainFolder + "\\20X\\" dstTrainFilePath = trainFolder + "\\5X\\" srcTestFileP...
[((21, 27, 21, 55), 'os.listdir', 'os.listdir', ({(21, 38, 21, 54): 'srcTrainFilePath'}, {}), '(srcTrainFilePath)', False, 'import os\n'), ((22, 27, 22, 54), 'os.listdir', 'os.listdir', ({(22, 38, 22, 53): 'srcTestFilePath'}, {}), '(srcTestFilePath)', False, 'import os\n'), ((25, 24, 25, 71), 'cv2.imread', 'cv2.imread'...
zentrumnawi/solid-backend
sample_project/sample_content/serializers.py
0a6ac51608d4c713903856bb9b0cbf0068aa472c
from rest_framework import serializers from solid_backend.photograph.serializers import PhotographSerializer from solid_backend.media_object.serializers import MediaObjectSerializer from .models import SampleProfile class SampleProfileSerializer(serializers.ModelSerializer): media_objects = MediaObjectSerializer...
[((9, 20, 9, 52), 'solid_backend.media_object.serializers.MediaObjectSerializer', 'MediaObjectSerializer', (), '', False, 'from solid_backend.media_object.serializers import MediaObjectSerializer\n')]
wchsieh/utensor_cgen
tests/reshape_4/generate_pb.py
1774f0dfc0eb98b274271e7a67457dc3593b2593
# -*- coding: utf8 -*- import os from utensor_cgen.utils import save_consts, save_graph, save_idx import numpy as np import tensorflow as tf def generate(): test_dir = os.path.dirname(__file__) graph = tf.Graph() with graph.as_default(): x = tf.constant(np.random.randn(10), dtype=tf.floa...
[((9, 13, 9, 38), 'os.path.dirname', 'os.path.dirname', ({(9, 29, 9, 37): '__file__'}, {}), '(__file__)', False, 'import os\n'), ((10, 10, 10, 20), 'tensorflow.Graph', 'tf.Graph', ({}, {}), '()', True, 'import tensorflow as tf\n'), ((15, 15, 15, 53), 'tensorflow.reshape', 'tf.reshape', (), '', True, 'import tensorflow ...
modsim/junn
junn-predict/junn_predict/common/logging.py
a40423b98c6a3739dd0b2ba02d546a5db91f9215
"""Logging helpers.""" import logging import sys import colorlog import tqdm class TqdmLoggingHandler(logging.StreamHandler): """TqdmLoggingHandler, outputs log messages to the console compatible with tqdm.""" def emit(self, record): # noqa: D102 message = self.format(record) tqdm.tqdm.writ...
[((74, 4, 76, 5), 'logging.basicConfig', 'logging.basicConfig', (), '', False, 'import logging\n'), ((86, 24, 86, 51), 'logging._nameToLevel.copy', 'logging._nameToLevel.copy', ({}, {}), '()', False, 'import logging\n'), ((14, 8, 14, 32), 'tqdm.tqdm.write', 'tqdm.tqdm.write', ({(14, 24, 14, 31): 'message'}, {}), '(mess...
LesterYHZ/Automated-Bridge-Inspection-Robot-Project
subpartcode/ultrasonic_basic_code.py
c3f4e12f9b60a8a6b041bf2b6d0461a1bb39c726
#Basic Ultrasonic sensor (HC-SR04) code import RPi.GPIO as GPIO #GPIO RPI library import time # makes sure Pi waits between steps GPIO.setmode(GPIO.BCM) #sets GPIO pin numbering #GPIO.setmode(GPIO.BOARD) #Remove warnings GPIO.setwarnings(False) #Create loop variable #loop = 1 #BCM TRIG = 23 #output pin - triggers t...
[((5, 0, 5, 22), 'RPi.GPIO.setmode', 'GPIO.setmode', ({(5, 13, 5, 21): 'GPIO.BCM'}, {}), '(GPIO.BCM)', True, 'import RPi.GPIO as GPIO\n'), ((9, 0, 9, 23), 'RPi.GPIO.setwarnings', 'GPIO.setwarnings', ({(9, 17, 9, 22): '(False)'}, {}), '(False)', True, 'import RPi.GPIO as GPIO\n'), ((27, 0, 27, 25), 'RPi.GPIO.setup', 'GP...
MOURAIGOR/python
Mentorama/Modulo 3 - POO/Retangulo.py
b267f8ef277a385e3e315e88a22390512bf1e101
class Retangulo: # Atributos def __init__(self, comprimento, altura): self.setcomprimento(comprimento) self.setAltura(altura) # Métodos def setcomprimento(self, comprimento): self.comprimento = comprimento def getcomprimento(self): return self.comprimento def se...
[]
PeterFogh/digital_elevation_model_use_cases
DEMs/denmark/download_dk_dem.py
0e72cc6238ca5217a73d06dc3e8c3229024112c3
""" Fetch all files from Kortforsyningen FTP server folder. Copyright (c) 2021 Peter Fogh See also command line alternative in `download_dk_dem.sh` """ from ftplib import FTP, error_perm import os from pathlib import Path import time import operator import functools import shutil # TODO: use logging to std instead of...
[((37, 4, 37, 28), 'shutil.rmtree', 'shutil.rmtree', ({(37, 18, 37, 27): 'local_dir'}, {}), '(local_dir)', False, 'import shutil\n'), ((105, 11, 105, 71), 'functools.reduce', 'functools.reduce', ({(105, 28, 105, 41): 'operator.iand', (105, 43, 105, 64): 'map_download_FTP_tree', (105, 66, 105, 70): '(True)'}, {}), '(ope...
jiaxinjiang2919/Refinance-Calculator
6_refin_widgets.py
f4bb0c536b88692ef90f504fdb2d9bed85588b7c
# -*- coding: utf-8 -*- """ Created on Sun Mar 24 15:02:37 2019 @author: Matt Macarty """ from tkinter import * import numpy as np class LoanCalculator: def __init__(self): window = Tk() window.title("Loan Calculator") Label(window, text="Loan Amount").grid(row=1...
[((85, 14, 85, 51), 'numpy.pmt', 'np.pmt', ({(85, 21, 85, 32): 'rate / 1200', (85, 34, 85, 43): 'term * 12', (85, 45, 85, 48): '-pv', (85, 49, 85, 50): '0'}, {}), '(rate / 1200, term * 12, -pv, 0)', True, 'import numpy as np\n')]
davelarsen58/pmemtool
ndctl.py
a7acb0991cbcd683f761d4b108d018d7d2d10aeb
#!/usr/bin/python3 # # PMTOOL NDCTL Python Module # Copyright (C) David P Larsen # Released under MIT License import os import json from common import message, get_linenumber, pretty_print from common import V0, V1, V2, V3, V4, V5, D0, D1, D2, D3, D4, D5 import common as c import time DEFAULT_FSTAB_FILE = "/etc/fsta...
[((27, 7, 27, 27), 'os.getenv', 'os.getenv', ({(27, 17, 27, 26): '"""SANDBOX"""'}, {}), "('SANDBOX')", False, 'import os\n'), ((44, 10, 44, 29), 'time.perf_counter', 'time.perf_counter', ({}, {}), '()', False, 'import time\n'), ((49, 13, 49, 34), 'common.clean_up', 'c.clean_up', ({(49, 24, 49, 33): 'file_name'}, {}), '...
DronMDF/manabot
tb/sources/__init__.py
b412e8cb9b5247f05487bed4cbf4967f7b58327f
from .admin import ReviewListAdmin, SoAdminReviewIsOut, SoReviewForAdmin from .admin_commands import ( AdminCommands, AdminFilteredCommands, ReviewListByCommands, SoIgnoreReview, SoSubmitReview ) from .gerrit import ReviewOnServer, SoNewReview, SoOutReview, SoUpdateReview from .reaction import ( ReactionAlways, ...
[]
sisisin/pulumi-gcp
sdk/python/pulumi_gcp/accesscontextmanager/service_perimeter.py
af6681d70ea457843409110c1324817fe55f68ad
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** import warnings import pulumi import pulumi.runtime from typing import Any, Mapping, Optional, Sequence, Union, overload from .. import...
[((139, 5, 139, 40), 'pulumi.getter', 'pulumi.getter', (), '', False, 'import pulumi\n'), ((197, 5, 197, 48), 'pulumi.getter', 'pulumi.getter', (), '', False, 'import pulumi\n'), ((299, 5, 299, 37), 'pulumi.getter', 'pulumi.getter', (), '', False, 'import pulumi\n'), ((351, 5, 351, 40), 'pulumi.getter', 'pulumi.getter'...
ianpartridge/incubator-openwhisk-runtime-swift
core/swift3.1.1Action/swift3runner.py
5aacba1435f46b13cbb0a70874afb4b53c1a78bc
"""Python proxy to run Swift action. /* * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The ASF licenses this file to You under the Apache License, Ve...
[((26, 0, 26, 33), 'sys.path.append', 'sys.path.append', ({(26, 16, 26, 32): '"""../actionProxy"""'}, {}), "('../actionProxy')", False, 'import sys\n'), ((114, 4, 114, 10), 'actionproxy.main', 'main', ({}, {}), '()', False, 'from actionproxy import ActionRunner, main, setRunner\n'), ((40, 8, 40, 68), 'actionproxy.Actio...
vanderh0ff/ychaos
src/ychaos/utils/types.py
5148c889912b744ee73907e4dd30c9ddb851aeb3
from typing import Dict, List, TypeVar, Union JsonTypeVar = TypeVar("JsonTypeVar") JsonPrimitive = Union[str, float, int, bool, None] JsonDict = Dict[str, JsonTypeVar] JsonArray = List[JsonTypeVar] Json = Union[JsonPrimitive, JsonDict, JsonArray]
[((3, 14, 3, 36), 'typing.TypeVar', 'TypeVar', ({(3, 22, 3, 35): '"""JsonTypeVar"""'}, {}), "('JsonTypeVar')", False, 'from typing import Dict, List, TypeVar, Union\n')]
stefanitsky/yandex_market_language
yandex_market_language/models/promo.py
e17595b556fc55e183cf366227b2739c5c6178dc
import typing as t from yandex_market_language import models from yandex_market_language.models.abstract import XMLElement, XMLSubElement class Promo(models.AbstractModel): """ Docs: https://yandex.ru/support/partnermarket/elements/promo-gift.html """ MAPPING = { "start-date": "start_date", ...
[((63, 19, 63, 47), 'yandex_market_language.models.abstract.XMLElement', 'XMLElement', ({(63, 30, 63, 37): '"""promo"""', (63, 39, 63, 46): 'attribs'}, {}), "('promo', attribs)", False, 'from yandex_market_language.models.abstract import XMLElement, XMLSubElement\n'), ((75, 25, 75, 63), 'yandex_market_language.models.a...
skogsbaer/check-assignments
src/testCmd.py
cda8208c10644eecfe0bb988bee61098485aa6c4
import shell from dataclasses import dataclass from utils import * from ownLogging import * from typing import * from ansi import * import re import os import testHaskell import testPython import testJava @dataclass class TestArgs: dirs: List[str] assignments: List[str] # take all if empty interactive: boo...
[((55, 4, 55, 32), 'os.system', 'os.system', ({(55, 14, 55, 31): 'f"""{editor} \'{f}\'"""'}, {}), '(f"{editor} \'{f}\'")', False, 'import os\n'), ((68, 12, 68, 38), 'shell.basename', 'shell.basename', ({(68, 27, 68, 37): 'studentDir'}, {}), '(studentDir)', False, 'import shell\n'), ((107, 15, 107, 32), 'shell.basename'...
kipoi/kipoi-containers
kipoi_containers/singularityhelper.py
5978cf1563dcc1072170f28a0a956cc28aa3c406
from collections import Counter from datetime import datetime import os import requests from subprocess import Popen, PIPE from pathlib import Path import json from typing import Dict, Union, TYPE_CHECKING from kipoi_utils.external.torchvision.dataset_utils import download_url if TYPE_CHECKING: import zenodoclien...
[((53, 14, 53, 55), 'subprocess.Popen', 'Popen', (), '', False, 'from subprocess import Popen, PIPE\n'), ((98, 14, 98, 55), 'subprocess.Popen', 'Popen', (), '', False, 'from subprocess import Popen, PIPE\n'), ((27, 32, 27, 59), 'pathlib.Path', 'Path', ({(27, 37, 27, 58): 'singularity_file_path'}, {}), '(singularity_fil...
garenchan/policy
policy/_cache.py
fbd056c0474e62252d1fe986fe029cacde6845d8
# -*- coding: utf-8 -*- """ policy._cache ~~~~~~~~~~~~~~~ Cache for policy file. """ import os import logging LOG = logging.getLogger(__name__) # Global file cache CACHE = {} def read_file(filename: str, force_reload=False): """Read a file if it has been modified. :param filename: File name ...
[((13, 6, 13, 33), 'logging.getLogger', 'logging.getLogger', ({(13, 24, 13, 32): '__name__'}, {}), '(__name__)', False, 'import logging\n'), ((31, 12, 31, 38), 'os.path.getmtime', 'os.path.getmtime', ({(31, 29, 31, 37): 'filename'}, {}), '(filename)', False, 'import os\n')]
samn/opencensus-python
contrib/opencensus-ext-django/opencensus/ext/django/middleware.py
d8709f141b67f7f5ba011c440b8ba8fb9cbc419a
# Copyright 2017, OpenCensus Authors # # 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 w...
[((55, 6, 55, 33), 'logging.getLogger', 'logging.getLogger', ({(55, 24, 55, 32): '__name__'}, {}), '(__name__)', False, 'import logging\n'), ((77, 11, 77, 74), 'opencensus.trace.execution_context.get_opencensus_attr', 'execution_context.get_opencensus_attr', ({(77, 49, 77, 73): 'REQUEST_THREAD_LOCAL_KEY'}, {}), '(REQUE...
ICT2x01-p2-4/ICT2x01-p2-4
codeblockCar/codingPage/tests.py
6249c0a807354b33db80f367344fe14cb5512840
from typing import Reversible from django.test import TestCase, Client from challenge.models import Challenge from codingPage.models import Command, Log from django.core.exceptions import ValidationError from django.urls import reverse class CodingPageTest(TestCase): def setUp(self) -> None: self.client = ...
[((10, 22, 10, 59), 'django.test.Client', 'Client', (), '', False, 'from django.test import TestCase, Client\n'), ((11, 25, 11, 113), 'challenge.models.Challenge.objects.create', 'Challenge.objects.create', (), '', False, 'from challenge.models import Challenge\n'), ((12, 23, 12, 68), 'codingPage.models.Command.objects...
vigov5/oshougatsu2015
app/hint/models.py
38cbf325675ee2c08a6965b8689fad8308eb84eb
import os import datetime from app import app, db class Hint(db.Model): __tablename__ = 'hints' id = db.Column(db.Integer, primary_key=True) description = db.Column(db.Text) is_open = db.Column(db.Boolean) problem_id = db.Column(db.Integer, db.ForeignKey('problems.id')) def __repr__(self): ...
[((9, 9, 9, 48), 'app.db.Column', 'db.Column', (), '', False, 'from app import app, db\n'), ((10, 18, 10, 36), 'app.db.Column', 'db.Column', ({(10, 28, 10, 35): 'db.Text'}, {}), '(db.Text)', False, 'from app import app, db\n'), ((11, 14, 11, 35), 'app.db.Column', 'db.Column', ({(11, 24, 11, 34): 'db.Boolean'}, {}), '(d...
almustafa-noureddin/Portfolio-website
base/urls.py
67462c98fec65e74183ae057e8b31b5bdff1402c
from django.urls import path from . import views app_name = "base" urlpatterns = [ path('', views.IndexView.as_view(), name="home"), path('contact/', views.ContactView.as_view(), name="contact"),]
[]
cds-snc/notification-admin
app/main/views/templates.py
d4056798bf889ad29893667bbb67ead2f8e466e4
from datetime import datetime, timedelta from string import ascii_uppercase from dateutil.parser import parse from flask import abort, flash, jsonify, redirect, render_template, request, url_for from flask_babel import _ from flask_babel import lazy_gettext as _l from flask_login import current_user from markupsafe im...
[((69, 1, 69, 66), 'app.main.main.route', 'main.route', ({(69, 12, 69, 65): '"""/services/<service_id>/templates/<uuid:template_id>"""'}, {}), "('/services/<service_id>/templates/<uuid:template_id>')", False, 'from app.main import main\n'), ((70, 1, 70, 23), 'app.utils.user_has_permissions', 'user_has_permissions', ({}...
MarcelloVendruscolo/DeepLearningForImageAnalysis
linearRegression_gradientDescent/linearRegression_gradientDescent.py
0f57d63510d0f7b2729d214b3729a21a663794b5
import numpy as np from load_auto import load_auto import matplotlib.pyplot as plt import math def initialize_parameters(observation_dimension): # observation_dimension: number of features taken into consideration of the input # returns weights as a vector and offset as a scalar weights = np.zeros((observa...
[((110, 30, 110, 53), 'load_auto.load_auto', 'load_auto', ({(110, 40, 110, 52): 'PATH_DATASET'}, {}), '(PATH_DATASET)', False, 'from load_auto import load_auto\n'), ((111, 16, 111, 39), 'numpy.array', 'np.array', ({(111, 25, 111, 38): 'train_dataset'}, {}), '(train_dataset)', True, 'import numpy as np\n'), ((114, 15, 1...
mdholbrook/heart_rate_sentinel_server
unit_tests/test_hr_calculations.py
927b59ad6d2078bd6e3491014fdebbc610d25e63
import pytest from functions.hr_calculations import * @pytest.mark.parametrize("candidate, database, expected", [ ('jack', [{'patient_id': 'jump'}, {'patient_id': 'jack'}], 1), ('jungle', [{'patient_id': 'jungle'}, {'patient_id': 'jack'}], 0), ('bo', [{'patient_id': 'james'}, {'patient_id': 'boo'}, ...
[((5, 1, 9, 39), 'pytest.mark.parametrize', 'pytest.mark.parametrize', ({(5, 25, 5, 56): '"""candidate, database, expected"""', (5, 58, 9, 38): "[('jack', [{'patient_id': 'jump'}, {'patient_id': 'jack'}], 1), ('jungle',\n [{'patient_id': 'jungle'}, {'patient_id': 'jack'}], 0), ('bo', [{\n 'patient_id': 'james'}, ...
919bot/Tessa
selfdrive/boardd/tests/test_boardd_api.py
9b48ff9020e8fb6992fc78271f2720fd19e01093
import random import numpy as np import selfdrive.boardd.tests.boardd_old as boardd_old import selfdrive.boardd.boardd as boardd from common.realtime import sec_since_boot from cereal import log import unittest def generate_random_can_data_list(): can_list = [] cnt = random.randint(1, 64) for j in range(cnt):...
[((14, 8, 14, 29), 'random.randint', 'random.randint', ({(14, 23, 14, 24): '1', (14, 26, 14, 28): '64'}, {}), '(1, 64)', False, 'import random\n'), ((77, 4, 77, 19), 'unittest.main', 'unittest.main', ({}, {}), '()', False, 'import unittest\n'), ((60, 9, 60, 25), 'common.realtime.sec_since_boot', 'sec_since_boot', ({}, ...
zekna/py-types
py_types/static/parse.py
ec39da1277986f0ea44830dfb0da9d906deb13e1
import ast import inspect import sys import argparse from ..runtime.asserts import typecheck @typecheck def pretty_print_defs(defs: list) -> None: for d in defs: print("Function definition for {}".format(d["name"])) print("Arguments:") for arg in d["args"]: arg_type = "untyped...
[((35, 19, 35, 31), 'ast.parse', 'ast.parse', ({(35, 29, 35, 30): 'a'}, {}), '(a)', False, 'import ast\n')]
pmaccamp/django-tastypie-swagger
example/example/urls.py
d51ef3ea8e33791617edba8ed55a1be1f16e4ccc
from django.conf.urls import include, url from django.contrib import admin from demo.apis import api urlpatterns = [ url(r'^api/', include(api.urls)), url(r'^api/doc/', include(('tastypie_swagger.urls', 'tastypie_swagger'), namespace='demo_api_swagger'), kwargs={ "...
[((14, 4, 14, 36), 'django.conf.urls.url', 'url', ({(14, 8, 14, 18): '"""^admin/"""', (14, 20, 14, 35): 'admin.site.urls'}, {}), "('^admin/', admin.site.urls)", False, 'from django.conf.urls import include, url\n'), ((6, 18, 6, 35), 'django.conf.urls.include', 'include', ({(6, 26, 6, 34): 'api.urls'}, {}), '(api.urls)'...
savor007/scrapy_framework
scrapy_framework/midwares/download_midware.py
9f1266eb2d4bb7e181d1c5352b05298e77040980
from scrapy_framework.html.request import Request from scrapy_framework.html.response import Response import random def get_ua(): first_num=random.randint(55,69) third_num=random.randint(0,3200) forth_num=random.randint(0, 140) os_type = [ '(Windows NT 6.1; WOW64)', '(Windows NT 10.0; WOW64)...
[((8, 14, 8, 35), 'random.randint', 'random.randint', ({(8, 29, 8, 31): '55', (8, 32, 8, 34): '69'}, {}), '(55, 69)', False, 'import random\n'), ((9, 14, 9, 36), 'random.randint', 'random.randint', ({(9, 29, 9, 30): '0', (9, 31, 9, 35): '3200'}, {}), '(0, 3200)', False, 'import random\n'), ((10, 14, 10, 36), 'random.ra...
bytepl/tracardi
tracardi/process_engine/action/v1/pro/scheduler/plugin.py
e8fa4684fa6bd3d05165fe48aa925fc6c1e74923
from pydantic import BaseModel from tracardi.domain.entity import Entity from tracardi.domain.scheduler_config import SchedulerConfig from tracardi.domain.resource import ResourceCredentials from tracardi.service.storage.driver import storage from tracardi.service.plugin.runner import ActionRunner from tracardi.servic...
[((28, 25, 28, 71), 'tracardi.service.storage.driver.storage.driver.resource.load', 'storage.driver.resource.load', ({(28, 54, 28, 70): 'config.source.id'}, {}), '(config.source.id)', False, 'from tracardi.service.storage.driver import storage\n'), ((43, 19, 43, 54), 'tracardi.service.plugin.domain.result.Result', 'Res...
alvarobartt/covid-daily
tests/test_covid_daily.py
cb4506a007ac206e85409a13281028f6f82441a6
# Copyright 2020 Alvaro Bartolome, alvarobartt @ GitHub # See LICENSE for details. import pytest import covid_daily def test_overview(): params = [ { 'as_json': True }, { 'as_json': False } ] for param in params: covid_daily.overview(as_js...
[((24, 11, 28, 5), 'covid_daily.data', 'covid_daily.data', (), '', False, 'import covid_daily\n'), ((20, 8, 20, 54), 'covid_daily.overview', 'covid_daily.overview', (), '', False, 'import covid_daily\n')]
BryanWhitehurst/HPCCEA
2021/HANFS/fence-agents/fence/agents/zvm/fence_zvmip.py
54b7e7355b67ba3fdce2e28cc1b0e3b29d2bdefa
#!@PYTHON@ -tt import sys import atexit import socket import struct import logging sys.path.append("@FENCEAGENTSLIBDIR@") from fencing import * from fencing import fail, fail_usage, run_delay, EC_LOGIN_DENIED, EC_TIMED_OUT #BEGIN_VERSION_GENERATION RELEASE_VERSION="" REDHAT_COPYRIGHT="" BUILD_DATE="" #END_VERSION_GEN...
[((8, 0, 8, 38), 'sys.path.append', 'sys.path.append', ({(8, 16, 8, 37): '"""@FENCEAGENTSLIBDIR@"""'}, {}), "('@FENCEAGENTSLIBDIR@')", False, 'import sys\n'), ((35, 8, 35, 23), 'socket.socket', 'socket.socket', ({}, {}), '()', False, 'import socket\n'), ((53, 11, 53, 41), 'struct.pack', 'struct.pack', ({(53, 23, 53, 27...
feel-easy/myspider
2.5.9/test_splash/test_splash/spiders/with_splash.py
dcc65032015d7dbd8bea78f846fd3cac7638c332
# -*- coding: utf-8 -*- import scrapy from scrapy_splash import SplashRequest # 使用scrapy_splash包提供的request对象 class WithSplashSpider(scrapy.Spider): name = 'with_splash' allowed_domains = ['baidu.com'] start_urls = ['https://www.baidu.com/s?wd=13161933309'] def start_requests(self): yield Splas...
[((11, 14, 14, 51), 'scrapy_splash.SplashRequest', 'SplashRequest', (), '', False, 'from scrapy_splash import SplashRequest\n')]
iudaichi/iu_linebot
run.py
d3f5a7b0227b175963d51d62bcd5894366bde35c
from main import app import os import uvicorn if __name__ == '__main__': port = int(os.getenv("PORT")) uvicorn.run(app, host="0.0.0.0", port=port, workers=1, reload=True)
[((7, 4, 7, 71), 'uvicorn.run', 'uvicorn.run', (), '', False, 'import uvicorn\n'), ((6, 15, 6, 32), 'os.getenv', 'os.getenv', ({(6, 25, 6, 31): '"""PORT"""'}, {}), "('PORT')", False, 'import os\n')]
DwijayDS/fastestimator
fastestimator/architecture/pytorch/unet.py
9b288cb2bd870f971ec4cee09d0b3205e1316a94
# Copyright 2019 The FastEstimator Authors. All Rights Reserved. # # 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 appl...
[((34, 36, 34, 98), 'torch.nn.Conv2d', 'nn.Conv2d', (), '', True, 'import torch.nn as nn\n'), ((35, 36, 35, 57), 'torch.nn.ReLU', 'nn.ReLU', (), '', True, 'import torch.nn as nn\n'), ((36, 36, 36, 99), 'torch.nn.Conv2d', 'nn.Conv2d', (), '', True, 'import torch.nn as nn\n'), ((37, 36, 37, 57), 'torch.nn.ReLU', 'nn.ReLU...
Mandera/generalfile
generalfile/path.py
5e476a1c075fa072c7e52e62455feeb78b9bb298
import pathlib import os from generallibrary import VerInfo, TreeDiagram, Recycle, classproperty, deco_cache from generalfile.errors import InvalidCharacterError from generalfile.path_lock import Path_ContextManager from generalfile.path_operations import Path_Operations from generalfile.path_strings import Path_St...
[((24, 14, 24, 23), 'generallibrary.VerInfo', 'VerInfo', ({}, {}), '()', False, 'from generallibrary import VerInfo, TreeDiagram, Recycle, classproperty, deco_cache\n'), ((104, 5, 104, 17), 'generallibrary.deco_cache', 'deco_cache', ({}, {}), '()', False, 'from generallibrary import VerInfo, TreeDiagram, Recycle, class...
Tontolda/genui
src/genui/models/models.py
c5b7da7c5a99fc16d34878e2170145ac7c8e31c4
import os from django.db import models import uuid # Create your models here. from djcelery_model.models import TaskMixin from polymorphic.models import PolymorphicModel from genui.utils.models import NON_POLYMORPHIC_CASCADE, OverwriteStorage from genui.utils.extensions.tasks.models import TaskShortcutsMixIn, Polymo...
[((16, 11, 16, 68), 'django.db.models.CharField', 'models.CharField', (), '', False, 'from django.db import models\n'), ((23, 20, 23, 77), 'django.db.models.CharField', 'models.CharField', (), '', False, 'from django.db import models\n'), ((24, 18, 24, 64), 'django.db.models.TextField', 'models.TextField', (), '', Fals...
bihealth/sodar_core
projectroles/tests/test_views_api.py
a6c22c4f276b64ffae6de48779a82d59a60a9333
"""REST API view tests for the projectroles app""" import base64 import json import pytz from django.conf import settings from django.core import mail from django.forms.models import model_to_dict from django.test import override_settings from django.urls import reverse from django.utils import timezone from knox.mod...
[((919, 5, 919, 60), 'django.test.override_settings', 'override_settings', (), '', False, 'from django.test import override_settings\n'), ((1030, 5, 1030, 63), 'django.test.override_settings', 'override_settings', (), '', False, 'from django.test import override_settings\n'), ((1053, 5, 1053, 63), 'django.test.override...
kwasnydam/animal_disambiguation
src/model/model.py
1dba0a2f40ca952a3adab925ff9ef54238cf7c1c
"""Contains the classification model I am going to use in my problem and some utility functions. Functions build_mmdisambiguator - build the core application object with the collaborators info Classes MMDisambiguator - core class of the application """ import pickle import os import numpy as np from sklearn....
[((26, 26, 26, 72), 'os.path.join', 'os.path.join', ({(26, 39, 26, 61): 'DEFAULT_ROOT_DIRECTORY', (26, 63, 26, 71): '"""models"""'}, {}), "(DEFAULT_ROOT_DIRECTORY, 'models')", False, 'import os\n'), ((48, 21, 48, 68), 'src.data.dataset.TextLabelsVectorizer', 'dataset.TextLabelsVectorizer', ({(48, 50, 48, 67): 'data_mod...
myelintek/results
v0.5.0/nvidia/submission/code/recommendation/pytorch/load.py
11c38436a158c453e3011f8684570f7a55c03330
# Copyright (c) 2018, deepakn94. All rights reserved. # # 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 ...
[((20, 13, 21, 78), 'collections.namedtuple', 'namedtuple', ({(20, 24, 20, 36): '"""RatingData"""', (21, 24, 21, 77): "['items', 'users', 'ratings', 'min_date', 'max_date']"}, {}), "('RatingData', ['items', 'users', 'ratings', 'min_date', 'max_date'])", False, 'from collections import namedtuple\n'), ((37, 27, 37, 73),...
jptomo/pypy-lang-scheme
rpython/jit/backend/llsupport/test/test_rewrite.py
55edb2cec69d78f86793282a4566fcbc1ef9fcac
from rpython.jit.backend.llsupport.descr import get_size_descr,\ get_field_descr, get_array_descr, ArrayDescr, FieldDescr,\ SizeDescr, get_interiorfield_descr from rpython.jit.backend.llsupport.gc import GcLLDescr_boehm,\ GcLLDescr_framework from rpython.jit.backend.llsupport import jitframe from rpython...
[((26, 11, 26, 61), 'rpython.rtyper.lltypesystem.lltype.malloc', 'lltype.malloc', (), '', False, 'from rpython.rtyper.lltypesystem import lltype, rffi\n'), ((30, 12, 31, 54), 'rpython.rtyper.lltypesystem.lltype.GcStruct', 'lltype.GcStruct', ({(30, 28, 30, 31): '"""S"""', (30, 33, 30, 53): "('x', lltype.Signed)", (31, 3...
sanchaymittal/hummingbot
hummingbot/client/command/history_command.py
f8d1c19dfd0875bd12717f9c46ddbe20cc7b9a0d
from decimal import Decimal import pandas as pd from typing import ( Any, Dict, Set, Tuple, TYPE_CHECKING) from hummingbot.client.performance_analysis import PerformanceAnalysis from hummingbot.core.utils.exchange_rate_conversion import ExchangeRateConversion from hummingbot.market.market_base impo...
[((15, 6, 15, 43), 'hummingbot.core.utils.exchange_rate_conversion.ExchangeRateConversion.get_instance', 'ExchangeRateConversion.get_instance', ({}, {}), '()', False, 'from hummingbot.core.utils.exchange_rate_conversion import ExchangeRateConversion\n'), ((70, 13, 71, 87), 'pandas.DataFrame', 'pd.DataFrame', (), '', Tr...
sami2316/asm2vec-pytorch
scripts/bin2asm.py
5de1351aeda61d7467b3231e48437fd8d34a970c
import re import os import click import r2pipe import hashlib from pathlib import Path import _pickle as cPickle def sha3(data): return hashlib.sha3_256(data.encode()).hexdigest() def validEXE(filename): magics = [bytes.fromhex('7f454c46')] with open(filename, 'rb') as f: header = f.read(4) ...
[((88, 1, 88, 16), 'click.command', 'click.command', ({}, {}), '()', False, 'import click\n'), ((89, 1, 89, 85), 'click.option', 'click.option', (), '', False, 'import click\n'), ((90, 1, 90, 80), 'click.option', 'click.option', (), '', False, 'import click\n'), ((91, 1, 91, 123), 'click.option', 'click.option', (), ''...
Chyroc/homework
6/4.py
b1ee8e9629b4dbb6c46a550d710157702d57b00b
import re def remove_not_alpha_num(string): return re.sub('[^0-9a-zA-Z]+', '', string) if __name__ == '__main__': print(remove_not_alpha_num('a000 aa-b') == 'a000aab')
[((5, 11, 5, 46), 're.sub', 're.sub', ({(5, 18, 5, 33): '"""[^0-9a-zA-Z]+"""', (5, 35, 5, 37): '""""""', (5, 39, 5, 45): 'string'}, {}), "('[^0-9a-zA-Z]+', '', string)", False, 'import re\n')]
DougLazyAngus/lazyAngus
LazyAngus/Assets/Extensions/IOSDeploy/Scripts/Editor/post_process.py
485a8d5061ab740ab055abfc7fc5b86b864a5c7e
import os from sys import argv from mod_pbxproj import XcodeProject #import appcontroller path = argv[1] frameworks = argv[2].split(' ') libraries = argv[3].split(' ') cflags = argv[4].split(' ') ldflags = argv[5].split(' ') folders = argv[6].split(' ') print('Step 1: add system frameworks ') #if...
[((15, 10, 15, 76), 'mod_pbxproj.XcodeProject.Load', 'XcodeProject.Load', ({(15, 28, 15, 75): "path + '/Unity-iPhone.xcodeproj/project.pbxproj'"}, {}), "(path + '/Unity-iPhone.xcodeproj/project.pbxproj')", False, 'from mod_pbxproj import XcodeProject\n')]
TheAvidDev/pnoj-site
judge/migrations/0024_auto_20200705_0246.py
63299e873b1fb654667545222ce2b3157e78acd9
# Generated by Django 3.0.8 on 2020-07-05 02:46 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('judge', '0023_auto_20200704_2318'), ] operations = [ migrations.AlterField( model_name='submission', name='language'...
[((16, 18, 16, 269), 'django.db.models.CharField', 'models.CharField', (), '', False, 'from django.db import migrations, models\n'), ((21, 18, 21, 277), 'django.db.models.CharField', 'models.CharField', (), '', False, 'from django.db import migrations, models\n')]
stottlerhenke-seattle/openbadge-hub-py
src/badge_hub.py
d0eb1772eb1250862041cc50071252f46d4c4771
#!/usr/bin/env python from __future__ import absolute_import, division, print_function import os import re import shlex import subprocess import signal import csv import logging import json import time from datetime import datetime as dt from requests.exceptions import RequestException import glob import traceback i...
[((49, 9, 49, 42), 'logging.getLogger', 'logging.getLogger', ({(49, 27, 49, 41): '"""badge_server"""'}, {}), "('badge_server')", False, 'import logging\n'), ((53, 5, 53, 39), 'logging.FileHandler', 'logging.FileHandler', ({(53, 25, 53, 38): 'log_file_name'}, {}), '(log_file_name)', False, 'import logging\n'), ((57, 5, ...
liamgam/gdkit
python/compile.py
e9d419ff916f15dbd8ec6d7cc59b0a3d8f636a95
import compileall compileall.compile_dir(".",force=1)
[((2, 0, 2, 35), 'compileall.compile_dir', 'compileall.compile_dir', (), '', False, 'import compileall\n')]
fairhopeweb/saleor
saleor/product/migrations/0141_update_descritpion_fields.py
9ac6c22652d46ba65a5b894da5f1ba5bec48c019
# Generated by Django 3.1.5 on 2021-02-17 11:04 from django.db import migrations import saleor.core.db.fields import saleor.core.utils.editorjs def update_empty_description_field(apps, schema_editor): Category = apps.get_model("product", "Category") CategoryTranslation = apps.get_model("product", "CategoryT...
[((91, 8, 94, 9), 'django.db.migrations.RunPython', 'migrations.RunPython', ({(92, 12, 92, 42): 'update_empty_description_field', (93, 12, 93, 37): 'migrations.RunPython.noop'}, {}), '(update_empty_description_field, migrations.RunPython.noop)', False, 'from django.db import migrations\n')]
arnaubena97/SatSolver-sat_isfayer
local_search/sat_isfayer.py
db7edc83547786deb7bf6b1c5d75b406f877ca15
#!/usr/bin/env python3 import sys import random def read_file(file_name): """File reader and parser the num of variables, num of clauses and put the clauses in a list""" clauses =[] with open(file_name) as all_file: for line in all_file: if line.startswith('c'): continue #ignore comment...
[((109, 15, 109, 45), 'random.choice', 'random.choice', ({(109, 29, 109, 44): 'bests_variables'}, {}), '(bests_variables)', False, 'import random\n'), ((86, 28, 86, 63), 'random.choice', 'random.choice', ({(86, 42, 86, 62): 'list_all_unsatisfied'}, {}), '(list_all_unsatisfied)', False, 'import random\n'), ((40, 31, 40,...
Hacky-DH/pytorch
torch/_VF.py
80dc4be615854570aa39a7e36495897d8a040ecc
""" This makes the functions in torch._C._VariableFunctions available as torch._VF.<funcname> without mypy being able to find them. A subset of those functions are mapped to ATen functions in torch/jit/_builtins.py See https://github.com/pytorch/pytorch/issues/21478 for the reason for introducing torch._VF """ i...
[]
sergeivolodin/causality-disentanglement-rl
sparse_causal_model_learner_rl/annealer/threshold_projection.py
5a41b4a2e3d85fa7e9c8450215fdc6cf954df867
import gin import torch import logging from sparse_causal_model_learner_rl.metrics import find_value, find_key @gin.configurable def ProjectionThreshold(config, config_object, epoch_info, temp, adjust_every=100, metric_threshold=0.5, delta=0.5, source_metric_key=None, min_hyper=0, max_hyper=100...
[((17, 12, 17, 45), 'gin.query_parameter', 'gin.query_parameter', ({(17, 32, 17, 44): 'gin_variable'}, {}), '(gin_variable)', False, 'import gin\n'), ((18, 4, 18, 107), 'logging.info', 'logging.info', ({(18, 17, 18, 106): 'f"""Projection: metric={metric_val} threshold={metric_threshold} good={good} hyper={hyper}"""'}, ...
ucals/numpyro
numpyro/contrib/control_flow/scan.py
566a5311d660d28a630188063c03a018165a38a9
# Copyright Contributors to the Pyro project. # SPDX-License-Identifier: Apache-2.0 from collections import OrderedDict from functools import partial from jax import lax, random, tree_flatten, tree_map, tree_multimap, tree_unflatten import jax.numpy as jnp from jax.tree_util import register_pytree_node_class from nu...
[((52, 21, 52, 36), 'jax.numpy.ndim', 'jnp.ndim', ({(52, 30, 52, 35): 'value'}, {}), '(value)', True, 'import jax.numpy as jnp\n'), ((111, 13, 111, 42), 'jax.tree_map', 'tree_map', ({(111, 22, 111, 37): 'lambda x: x[-1]', (111, 39, 111, 41): 'xs'}, {}), '(lambda x: x[-1], xs)', False, 'from jax import lax, random, tree...
earth-emoji/dennea
src/catalog/migrations/0003_remove_productattributevalue_name.py
fbabd7d9ecc95898411aba238bbcca8b5e942c31
# Generated by Django 2.2.12 on 2020-06-10 01:11 from django.db import migrations class Migration(migrations.Migration): dependencies = [ ('catalog', '0002_auto_20200610_0019'), ] operations = [ migrations.RemoveField( model_name='productattributevalue', name='na...
[((13, 8, 16, 9), 'django.db.migrations.RemoveField', 'migrations.RemoveField', (), '', False, 'from django.db import migrations\n')]
divindevaiah/e2xgrader
e2xgrader/preprocessors/overwritecells.py
19eb4662e4eee5ddef673097517e4bd4fb469e62
import json from nbformat.notebooknode import NotebookNode from nbconvert.exporters.exporter import ResourcesDict from typing import Tuple from nbgrader.api import MissingEntry from nbgrader.preprocessors import OverwriteCells as NbgraderOverwriteCells from ..utils.extra_cells import is_singlechoice, is_multiplechoi...
[((32, 45, 32, 75), 'json.loads', 'json.loads', ({(32, 56, 32, 74): 'source_cell.source'}, {}), '(source_cell.source)', False, 'import json\n')]
ehtec/pdfminer.six
tools/pdf2txt.py
5b1823f25ab998e904fc5d81687732580f23e3b9
#!/usr/bin/env python3 """A command line tool for extracting text and images from PDF and output it to plain text, html, xml or tags.""" import argparse import logging import sys from typing import Any, Container, Iterable, List, Optional import pdfminer.high_level from pdfminer.layout import LAParams from pdfminer.ut...
[((13, 0, 13, 21), 'logging.basicConfig', 'logging.basicConfig', ({}, {}), '()', False, 'import logging\n'), ((70, 13, 70, 72), 'argparse.ArgumentParser', 'argparse.ArgumentParser', (), '', False, 'import argparse\n'), ((106, 16, 106, 26), 'pdfminer.layout.LAParams', 'LAParams', ({}, {}), '()', False, 'from pdfminer.la...
agungnasik57/nython
nython/nythonize.py
cf499fe20f86e2685671495bd941b411fa066813
"""Compile Nim libraries as Python Extension Modules. If you want your namespace to coexist with your pthon code, name this ponim.nim and then your import will look like `from ponim.nim import adder` and `from ponim import subtractor`. There must be a way to smooth that out in the __init__.py file somehow. Note that ...
[((40, 11, 40, 37), 'os.path.join', 'join', ({(40, 16, 40, 23): '"""build"""', (40, 25, 40, 36): '"""nim_build"""'}, {}), "('build', 'nim_build')", False, 'from os.path import join, expanduser\n'), ((43, 21, 43, 74), 'os.path.join', 'join', ({(43, 26, 43, 33): '"""build"""', (43, 35, 43, 46): '"""nim_build"""', (43, 48...
lixinso/pyro
tests/contrib/test_util.py
ca0d6417bed3882a47cb8cbb01b36f403ee903d5
from collections import OrderedDict import pytest import torch import pyro.distributions as dist from pyro.contrib.util import ( get_indices, tensor_to_dict, rmv, rvv, lexpand, rexpand, rdiag, rtril, hessian ) from tests.common import assert_equal def test_get_indices_sizes(): sizes = OrderedDict([("a", 2), ...
[((13, 12, 13, 55), 'collections.OrderedDict', 'OrderedDict', ({(13, 24, 13, 54): "[('a', 2), ('b', 2), ('c', 2)]"}, {}), "([('a', 2), ('b', 2), ('c', 2)])", False, 'from collections import OrderedDict\n'), ((22, 12, 22, 55), 'collections.OrderedDict', 'OrderedDict', ({(22, 24, 22, 54): "[('a', 2), ('b', 2), ('c', 2)]"...
HarisHijazi/mojarnik-server
emodul/apps.py
bee7266609cc0bca7cc6a4059086fc0ba7219a33
from django.apps import AppConfig class EmodulConfig(AppConfig): name = 'emodul'
[]
mIXs222/diffnet
Diffnet++/class/DataModule.py
1f580332254a5113ed7b88b9b2e0aa467344e94d
from __future__ import division from collections import defaultdict import numpy as np from time import time import random import tensorflow.compat.v1 as tf tf.disable_v2_behavior() # import tensorflow as tf class DataModule(): def __init__(self, conf, filename): self.conf = conf self.data_dict = ...
[((7, 0, 7, 24), 'tensorflow.compat.v1.disable_v2_behavior', 'tf.disable_v2_behavior', ({}, {}), '()', True, 'import tensorflow.compat.v1 as tf\n'), ((80, 20, 80, 36), 'collections.defaultdict', 'defaultdict', ({(80, 32, 80, 35): 'int'}, {}), '(int)', False, 'from collections import defaultdict\n'), ((90, 24, 90, 40), ...
iosurodri/annotated-transformer
src/models/VanillaTransformer.py
e5a7e27067d08c09f51b57bbf2824fbcd80ae4d9
from xmlrpc.server import MultiPathXMLRPCServer import torch.nn as nn import torch.nn.functional as F import copy from src.layers.layers import Encoder, EncoderLayer, Decoder, DecoderLayer, PositionwiseFeedForward from src.layers.preprocessing import Embeddings, PositionalEncoding from src.layers.attention import Mult...
[((52, 11, 52, 56), 'src.layers.attention.MultiHeadedAttention', 'MultiHeadedAttention', (), '', False, 'from src.layers.attention import MultiHeadedAttention\n'), ((53, 9, 53, 56), 'src.layers.layers.PositionwiseFeedForward', 'PositionwiseFeedForward', ({(53, 33, 53, 40): 'd_model', (53, 42, 53, 46): 'd_ff', (53, 48, ...
YileC928/finm-portfolio-2021
venv/lib/python3.8/site-packages/arch/tests/univariate/test_recursions.py
3fa1e97423fa731bce0cad3457807e1873120891
import os import timeit from typing import List import numpy as np from numpy.random import RandomState from numpy.testing import assert_allclose, assert_almost_equal import pytest from scipy.special import gamma import arch.univariate.recursions_python as recpy CYTHON_COVERAGE = os.environ.get("ARCH_CYTHON_COVERAGE...
[((34, 13, 34, 87), 'pytest.mark.filterwarnings', 'pytest.mark.filterwarnings', ({(34, 40, 34, 86): '"""ignore::arch.compat.numba.PerformanceWarning"""'}, {}), "('ignore::arch.compat.numba.PerformanceWarning')", False, 'import pytest\n'), ((13, 18, 13, 61), 'os.environ.get', 'os.environ.get', ({(13, 33, 13, 55): '"""AR...
SoldAI/hermetrics
hermetrics/damerau_levenshtein.py
5e07a4f40376779015ef2f5b964d7ac060ed6e25
from .levenshtein import Levenshtein class DamerauLevenshtein(Levenshtein): def __init__(self, name='Damerau-Levenshtein'): super().__init__(name=name) def distance(self, source, target, cost=(1, 1, 1, 1)): """Damerau-Levenshtein distance with costs for deletion, insertion, substitution a...
[]
Carlosbogo/etna
etna/analysis/outliers/hist_outliers.py
b6210f0e79ee92aa9ae8ff4fcfb267be9fb7cc94
import typing from copy import deepcopy from typing import TYPE_CHECKING from typing import List import numba import numpy as np import pandas as pd if TYPE_CHECKING: from etna.datasets import TSDataset @numba.jit(nopython=True) def optimal_sse(left: int, right: int, p: np.ndarray, pp: np.ndarray) -> float: ...
[((14, 1, 14, 25), 'numba.jit', 'numba.jit', (), '', False, 'import numba\n'), ((42, 1, 42, 25), 'numba.jit', 'numba.jit', (), '', False, 'import numba\n'), ((86, 1, 86, 25), 'numba.jit', 'numba.jit', (), '', False, 'import numba\n'), ((249, 12, 249, 33), 'numpy.empty_like', 'np.empty_like', ({(249, 26, 249, 32): 'seri...
emanueleleyland/sabd-project2
aws/securityGroup.py
387b33443b87e78635d8d6c9a03faadbc90ae9da
def createKafkaSecurityGroup(ec2, vpc): sec_group_kafka = ec2.create_security_group( GroupName='kafka', Description='kafka sec group', VpcId=vpc.id) sec_group_kafka.authorize_ingress( IpPermissions=[{'IpProtocol': 'icmp', 'FromPort': -1, 'ToPort': -1, 'IpRanges': [{'CidrIp': '0.0.0.0/0'}]}, ...
[]
petermirithu/hooby_lab
virtual/lib/python3.6/site-packages/django_pusher/context_processors.py
ffd641948bc2d2539649ec747114c78b5ad105e7
from django.conf import settings def pusher(request): return { "PUSHER_KEY": getattr(settings, "PUSHER_KEY", ""), }
[]
tiltowait/inconnu
inconnu/character/update/parse.py
6cca5fed520899d159537701b695c94222d8dc45
"""character/update/parse.py - Defines an interface for updating character traits.""" # pylint: disable=too-many-arguments import re import discord from discord_ui.components import LinkButton from . import paramupdate from ..display import display from ... import common, constants from ...log import Log from ...vch...
[((44, 11, 44, 41), 're.sub', 're.sub', ({(44, 18, 44, 22): '""":"""', (44, 24, 44, 28): '"""="""', (44, 30, 44, 40): 'parameters'}, {}), "(':', '=', parameters)", False, 'import re\n'), ((45, 11, 45, 69), 're.sub', 're.sub', ({(45, 18, 45, 41): '"""(\\\\w)\\\\s*([+-])\\\\s*(\\\\w)"""', (45, 43, 45, 62): '"""\\\\g<1>=\...
smadha/MlTrio
src/models/train_search_multi_deep.py
a7269fc4c6d77b2f71432ab9d2ab8fe4e28234d5
''' Uses flattened features in feature directory and run a SVM on it ''' from keras.layers import Dense from keras.models import Sequential import keras.regularizers as Reg from keras.optimizers import SGD, RMSprop from keras.callbacks import EarlyStopping import cPickle as pickle import numpy as np from sklearn.model...
[]
graham-kim/pygremlin-graph-visualiser
formation.py
65cb4d4fb71c8dde46ff1a36a40adcbdf233448c
import sys import os sys.path.append( os.path.dirname(__file__) ) import numpy as np import typing as tp import angles from model import Node, Link, Label from spec import ArrowDraw, NodeSpec class FormationManager: def __init__(self): self._nodes = {} self._links = [] self._labels = [] ...
[((4, 17, 4, 42), 'os.path.dirname', 'os.path.dirname', ({(4, 33, 4, 41): '__file__'}, {}), '(__file__)', False, 'import os\n'), ((45, 15, 45, 49), 'numpy.array', 'np.array', ({(45, 24, 45, 48): 'self._nodes[node_id].pos'}, {}), '(self._nodes[node_id].pos)', True, 'import numpy as np\n'), ((48, 20, 48, 54), 'numpy.arra...
MomsFriendlyRobotCompany/opencv_camera
opencv_camera/parameters/utils.py
046d779a853ef0117c0177c03a6fd81f361a9dd3
############################################## # The MIT License (MIT) # Copyright (c) 2014 Kevin Walchko # see LICENSE for full details ############################################## # -*- coding: utf-8 -* from math import atan, pi def fov(w,f): """ Returns the FOV as in degrees, given: w...
[((16, 17, 16, 28), 'math.atan', 'atan', ({(16, 22, 16, 27): '(w / 2 / f)'}, {}), '(w / 2 / f)', False, 'from math import atan, pi\n')]
SamanFekri/BookRecommendation
Code_Hybrid_SLIMBPR_CBF_RP3Beta.py
07dfa875154af39546cb263d4407339ce26d47e8
# This Python 3 environment comes with many helpful analytics libraries installed # It is defined by the kaggle/python Docker image: https://github.com/kaggle/docker-python # For example, here's several helpful packages to load import numpy as np # linear algebra import pandas as pd # data processing, CSV file I/O (e.g...
[((9, 9, 9, 46), 'pandas.read_csv', 'pd.read_csv', ({(9, 21, 9, 45): '"""./input/data_train.csv"""'}, {}), "('./input/data_train.csv')", True, 'import pandas as pd\n'), ((10, 7, 10, 56), 'pandas.read_csv', 'pd.read_csv', ({(10, 19, 10, 55): '"""./input/data_target_users_test.csv"""'}, {}), "('./input/data_target_users_...
MoyTW/7DRL2016_Rewrite
dodge/config.py
99e092dcb8797a25caa3c8a989a574efae19e4d4
import json class Config(object): def __init__(self, file_location): with open(file_location, 'r') as f: config = json.load(f) self.SCREEN_WIDTH = int(config["SCREEN_WIDTH"]) self.SCREEN_HEIGHT = int(config["SCREEN_HEIGHT"]) self.MAP_WIDTH = int(config["MAP_...
[((7, 21, 7, 33), 'json.load', 'json.load', ({(7, 31, 7, 32): 'f'}, {}), '(f)', False, 'import json\n')]
barel-mishal/InCal_lib
incal_lib/create_dataframe.py
3aa63ebccf2ed3277fac55049c88178541cbb94b
import pandas as pd import numpy as np def create_calr_example_df(n_rows, start_date): ''' ''' np.random.seed(20) array = np.random.rand(n_rows) cumulative = np.cumsum(array) d = { 'feature1_subject_1': array, 'feature1_subject_2': array, 'feature2_subject_1': cumulati...
[((9, 4, 9, 22), 'numpy.random.seed', 'np.random.seed', ({(9, 19, 9, 21): '(20)'}, {}), '(20)', True, 'import numpy as np\n'), ((10, 12, 10, 34), 'numpy.random.rand', 'np.random.rand', ({(10, 27, 10, 33): 'n_rows'}, {}), '(n_rows)', True, 'import numpy as np\n'), ((11, 17, 11, 33), 'numpy.cumsum', 'np.cumsum', ({(11, 2...
lms-07/HybridSN
HybridSN/DataLoadAndOperate.py
7580d67a5879d5b53ced75a653d4f198a8aefde2
import os import numpy as np import scipy.io as sio import tifffile from sklearn.decomposition import PCA from sklearn.model_selection import train_test_split #Load dataset def loadData(name,data_path): if name == 'IP': data = sio.loadmat(os.path.join(data_path, 'Indian_pines_corrected.mat'))['indian_pin...
[((65, 11, 65, 42), 'numpy.reshape', 'np.reshape', ({(65, 22, 65, 23): 'X', (65, 25, 65, 41): '(-1, X.shape[2])'}, {}), '(X, (-1, X.shape[2]))', True, 'import numpy as np\n'), ((66, 10, 66, 54), 'sklearn.decomposition.PCA', 'PCA', (), '', False, 'from sklearn.decomposition import PCA\n'), ((68, 11, 68, 67), 'numpy.resh...
antopen/alipay-sdk-python-all
alipay/aop/api/domain/AlipayOpenIotmbsDooropenresultSyncModel.py
8e51c54409b9452f8d46c7bb10eea7c8f7e8d30c
#!/usr/bin/env python # -*- coding: utf-8 -*- import json from alipay.aop.api.constant.ParamConstants import * class AlipayOpenIotmbsDooropenresultSyncModel(object): def __init__(self): self._dev_id = None self._door_state = None self._project_id = None @property def dev_id(self...
[]
ghost58400/marlin-binary-protocol
setup.py
fb93603866ecfce84e887c159bbbb9f9d2f01f17
import setuptools with open("README.md", "r") as fh: long_description = fh.read() setuptools.setup( name="marlin_binary_protocol", version="0.0.7", author="Charles Willis", author_email="charleswillis3@users.noreply.github.com", description="Transfer files with Marlin 2.0 firmware using Marlin...
[((15, 13, 15, 39), 'setuptools.find_packages', 'setuptools.find_packages', ({}, {}), '()', False, 'import setuptools\n')]
henryseg/Veering
taut_euler_class.py
50ebdcd5bde582726aefdd564c43e17890651282
# # taut_euler_class.py # from file_io import parse_data_file, write_data_file from taut import liberal, isosig_to_tri_angle from transverse_taut import is_transverse_taut from sage.matrix.constructor import Matrix from sage.modules.free_module_element import vector from sage.arith.misc import gcd from sage.arith.fu...
[((218, 11, 218, 41), 'transverse_taut.is_transverse_taut', 'is_transverse_taut', ({(218, 30, 218, 33): 'tri', (218, 35, 218, 40): 'angle'}, {}), '(tri, angle)', False, 'from transverse_taut import is_transverse_taut\n'), ((219, 26, 219, 93), 'transverse_taut.is_transverse_taut', 'is_transverse_taut', (), '', False, 'f...
ananyamalik/Railway-Concession-Portal
mailing/urls.py
295264ccb50bc4750bf0a749c8477384407d51ad
from django.urls import path from .views import ( student_list, student_add, student_profile,student_delete )
[]
deepbluesea/transformers
transformers/tests/tokenization_xlnet_test.py
11a2317986aad6e9a72f542e31344cfb7c94cbab
# coding=utf-8 # Copyright 2018 The Google AI Language Team Authors. # # 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 ...
[((106, 4, 106, 19), 'unittest.main', 'unittest.main', ({}, {}), '()', False, 'import unittest\n'), ((24, 44, 24, 69), 'os.path.abspath', 'os.path.abspath', ({(24, 60, 24, 68): '__file__'}, {}), '(__file__)', False, 'import os\n'), ((35, 20, 35, 67), 'transformers.tokenization_xlnet.XLNetTokenizer', 'XLNetTokenizer', (...
Rongtingting/xcltk
preprocess/utils/liftOver_vcf.py
2e86207c45a1caa7f905a89e1c121c3c203eab2d
# forked from https://github.com/single-cell-genetics/cellSNP ## A python wrap of UCSC liftOver function for vcf file ## UCSC liftOver binary and hg19 to hg38 chain file: ## https://genome.ucsc.edu/cgi-bin/hgLiftOver ## http://hgdownload.cse.ucsc.edu/admin/exe/linux.x86_64/liftOver ## http://hgdownload.soe.ucsc.edu/gol...
[((89, 4, 89, 36), 'warnings.filterwarnings', 'warnings.filterwarnings', ({(89, 28, 89, 35): '"""error"""'}, {}), "('error')", False, 'import warnings\n'), ((92, 13, 92, 27), 'optparse.OptionParser', 'OptionParser', ({}, {}), '()', False, 'from optparse import OptionParser\n'), ((19, 17, 19, 41), 'gzip.open', 'gzip.ope...
kamil559/pomodorr
pomodorr/frames/tests/test_consumers.py
232e6e98ff3481561dd1235794b3960066713210
import json import pytest from channels.db import database_sync_to_async from channels.testing import WebsocketCommunicator from pytest_lazyfixture import lazy_fixture from pomodorr.frames import statuses from pomodorr.frames.models import DateFrame from pomodorr.frames.routing import frames_application from pomodorr...
[((25, 1, 28, 1), 'pytest.mark.parametrize', 'pytest.mark.parametrize', ({(26, 4, 26, 23): '"""tested_frame_type"""', (27, 4, 27, 73): '[DateFrame.pomodoro_type, DateFrame.break_type, DateFrame.pause_type]'}, {}), "('tested_frame_type', [DateFrame.pomodoro_type,\n DateFrame.break_type, DateFrame.pause_type])", False...
FaHoLo/Fish_shop
Bot/db_aps.py
b08018223705bca169dab9f39ec5a55f62822f0b
import logging import os import redis import moltin_aps _database = None db_logger = logging.getLogger('db_logger') async def get_database_connection(): global _database if _database is None: database_password = os.getenv('DB_PASSWORD') database_host = os.getenv('DB_HOST') databas...
[((11, 12, 11, 42), 'logging.getLogger', 'logging.getLogger', ({(11, 30, 11, 41): '"""db_logger"""'}, {}), "('db_logger')", False, 'import logging\n'), ((37, 4, 37, 63), 'moltin_aps.update_customer_info', 'moltin_aps.update_customer_info', ({(37, 36, 37, 47): 'customer_id', (37, 49, 37, 62): 'customer_info'}, {}), '(cu...
shiv12095/realtimeviz
backend/server/tables/__init__.py
ee2bf10b5f9467212f9a9ce8957d80456ebd0259
from .lime_bike_feed import LimeBikeFeed from .lime_bike_trips import LimeBikeTrips from .lime_bike_trips_analyze import LimeBikeTripsAnalyze
[]
gummadirajesh/AzureMonitorForSAPSolutions
sapmon/payload/provider/sapnetweaver.py
9f8e9dbd38141b5de4782d40556c4368f6ad8d0b
# Python modules import json import logging from datetime import datetime, timedelta, timezone from time import time from typing import Any, Callable import re import requests from requests import Session from threading import Lock # SOAP Client modules from zeep import Client from zeep import helpers from zeep.transp...
[((30, 0, 30, 67), 'urllib3.disable_warnings', 'urllib3.disable_warnings', ({(30, 25, 30, 66): 'urllib3.exceptions.InsecureRequestWarning'}, {}), '(urllib3.exceptions.InsecureRequestWarning)', False, 'import urllib3\n'), ((34, 37, 34, 58), 'datetime.timedelta', 'timedelta', (), '', False, 'from datetime import datetime...
pombredanne/docker-scripts
docker_squash/version.py
ecee9f921b22cd44943197635875572185dd015d
version = "1.0.10.dev0"
[]
oceanprotocol/plecos
example_usage/example_list_errors.py
ae532df8539e5c327cca57fbc1ea1b1193916cd1
from pathlib import Path import plecos import json print(plecos.__version__) #%% path_to_json_local = Path("~/ocn/plecos/plecos/samples/sample_metadata_local.json").expanduser() path_to_json_remote = Path("~/ocn/plecos/plecos/samples/sample_metadata_remote.json").expanduser() path_to_broken_json = Path("~/ocn/plecos/pl...
[((41, 0, 41, 31), 'plecos.is_valid_dict', 'plecos.is_valid_dict', ({(41, 21, 41, 30): 'json_dict'}, {}), '(json_dict)', False, 'import plecos\n'), ((48, 9, 48, 56), 'plecos.list_errors', 'plecos.list_errors', ({(48, 28, 48, 37): 'json_dict', (48, 39, 48, 55): 'path_schema_file'}, {}), '(json_dict, path_schema_file)', ...
CLRafaelR/pangloss
pangloss/backend.py
920c509381a8d7831471fc3f22a07e58b53b8c0e
import re import panflute as pf from functools import partial from pangloss.util import smallcapify, break_plain # regular expression for label formats label_re = re.compile(r'\{#ex:(\w+)\}') gb4e_fmt_labelled = """ \\ex\\label{{ex:{label}}} \\gll {} \\\\ {} \\\\ \\trans {} """ gb4e_fmt = """ \\ex \\gll {} \\\\ {}...
[((8, 11, 8, 39), 're.compile', 're.compile', ({(8, 22, 8, 38): '"""\\\\{#ex:(\\\\w+)\\\\}"""'}, {}), "('\\\\{#ex:(\\\\w+)\\\\}')", False, 'import re\n'), ((56, 11, 56, 45), 'panflute.RawBlock', 'pf.RawBlock', (), '', True, 'import panflute as pf\n'), ((81, 11, 81, 43), 'panflute.RawBlock', 'pf.RawBlock', (), '', True,...
xavfernandez/virtualenv
tests/unit/discovery/test_py_spec.py
dd37c7d2af8a21026f4d4b7f43142e4e1e0faf86
from __future__ import absolute_import, unicode_literals import itertools import os import sys from copy import copy import pytest from virtualenv.discovery.py_spec import PythonSpec def test_bad_py_spec(): text = "python2.3.4.5" spec = PythonSpec.from_string_spec(text) assert text in repr(spec) as...
[((15, 11, 15, 44), 'virtualenv.discovery.py_spec.PythonSpec.from_string_spec', 'PythonSpec.from_string_spec', ({(15, 39, 15, 43): 'text'}, {}), '(text)', False, 'from virtualenv.discovery.py_spec import PythonSpec\n'), ((26, 11, 26, 45), 'virtualenv.discovery.py_spec.PythonSpec.from_string_spec', 'PythonSpec.from_stri...
robertcsapo/dnacenter-ansible
plugins/module_utils/definitions/trigger_image_activation.py
33f776f8c0bc7113da73191c301dd1807e6b4a43
from __future__ import (absolute_import, division, print_function) __metaclass__ = type import json module_definition = json.loads( """{ "family": "software_image_management_swim", "name": "trigger_image_activation", "operations": { "post": [ "trigger_software_image_activation" ...
[((5, 20, 75, 1), 'json.loads', 'json.loads', ({(6, 4, 74, 4): '"""{\n "family": "software_image_management_swim",\n "name": "trigger_image_activation",\n "operations": {\n "post": [\n "trigger_software_image_activation"\n ]\n },\n "parameters": {\n "trigger_software_image...
bopchik/Simple-minecraft-mod-launcher
minecraft_launcher_lib/fabric.py
52e4e8ec351b0bac7eb4fe707f21de8da14b9ac9
from .helper import download_file, get_user_agent from .install import install_minecraft_version from typing import List, Dict, Union from xml.dom import minidom import subprocess import requests import tempfile import random import os def get_all_minecraft_versions() -> List[Dict[str,Union[str,bool]]]: """ Re...
[((73, 15, 73, 42), 'xml.dom.minidom.parseString', 'minidom.parseString', ({(73, 35, 73, 41): 'r.text'}, {}), '(r.text)', False, 'from xml.dom import minidom\n'), ((94, 4, 94, 152), 'subprocess.run', 'subprocess.run', ({(94, 19, 94, 151): "['java', '-jar', installer_path, 'client', '-dir', path, '-mcversion',\n mine...
Nishkarsh-Tripathi/Sorting-algorithms-
Strand Sort.py
cda25f1a8e7fb5e25e59e69e78f000421b0e4eb0
# STRAND SORT # It is a recursive comparison based sorting technique which sorts in increasing order. # It works by repeatedly pulling sorted sub-lists out of the list to be sorted and merging them # with a result array. # Algorithm: # Create a empty strand (list) and append the first element to it popping it from th...
[]
minhhoang1023/GamestonkTerminal
gamestonk_terminal/cryptocurrency/overview/pycoingecko_model.py
195dc19b491052df080178c0cc6a9d535a91a704
"""CoinGecko model""" __docformat__ = "numpy" # pylint: disable=C0301, E1101 import logging import re from typing import Any, List import numpy as np import pandas as pd from pycoingecko import CoinGeckoAPI from gamestonk_terminal.cryptocurrency.dataframe_helpers import ( create_df_index, long_number_format...
[((22, 9, 22, 36), 'logging.getLogger', 'logging.getLogger', ({(22, 27, 22, 35): '__name__'}, {}), '(__name__)', False, 'import logging\n'), ((99, 1, 99, 26), 'gamestonk_terminal.decorators.log_start_end', 'log_start_end', (), '', False, 'from gamestonk_terminal.decorators import log_start_end\n'), ((143, 1, 143, 26), ...
sourceperl/tk-dashboard
docker/messein/board-import-app/app.py
015ececc670902b02284749ac59f354db4304e48
#!/usr/bin/env python3 from configparser import ConfigParser from datetime import datetime import urllib.parse import hashlib import io import json import logging import os import re import time from xml.dom import minidom import feedparser import requests import schedule import PIL.Image import PIL.ImageDraw import P...
[((37, 6, 37, 20), 'configparser.ConfigParser', 'ConfigParser', ({}, {}), '()', False, 'from configparser import ConfigParser\n'), ((69, 1, 69, 19), 'board_lib.catch_log_except', 'catch_log_except', ({}, {}), '()', False, 'from board_lib import CustomRedis, catch_log_except, dt_utc_to_local\n'), ((107, 1, 107, 19), 'bo...
pauldmccarthy/fsleyes-widgets
fsleyes_widgets/widgetlist.py
cb27899a0f665efe3f1c6ca1f89349507e004378
#!/usr/bin/env python # # widgetlist.py - A widget which displays a list of groupable widgets. # # Author: Paul McCarthy <pauldmccarthy@gmail.com> # """This module provides the :class:`WidgetList` class, which displays a list of widgets. """ import wx import wx.lib.newevent as wxevent import wx.lib.scrolledpanel...
[((619, 47, 619, 65), 'wx.lib.newevent.NewEvent', 'wxevent.NewEvent', ({}, {}), '()', True, 'import wx.lib.newevent as wxevent\n'), ((77, 16, 77, 66), 'wx.SystemSettings.GetColour', 'wx.SystemSettings.GetColour', ({(77, 44, 77, 65): 'wx.SYS_COLOUR_LISTBOX'}, {}), '(wx.SYS_COLOUR_LISTBOX)', False, 'import wx\n'), ((89, ...
TransactPRO/gw3-python-client
setup.py
77a9395c13f75467385227461b57ce85f4730ce5
#!/usr/bin/env python import setuptools MAINTAINER_NAME = 'Transact Pro' MAINTAINER_EMAIL = 'support@transactpro.lv' URL_GIT = 'https://github.com/TransactPRO/gw3-python-client' try: import pypandoc LONG_DESCRIPTION = pypandoc.convert('README.md', 'rst') except (IOError, ImportError, OSError, RuntimeError):...
[((12, 23, 12, 59), 'pypandoc.convert', 'pypandoc.convert', ({(12, 40, 12, 51): '"""README.md"""', (12, 53, 12, 58): '"""rst"""'}, {}), "('README.md', 'rst')", False, 'import pypandoc\n'), ((44, 13, 44, 39), 'setuptools.find_packages', 'setuptools.find_packages', ({}, {}), '()', False, 'import setuptools\n')]
mitodl/social-auth-mitxpro
social_auth_mitxpro/backends_test.py
8cae8bbe900b25f724b24f783d06de7b853a1366
"""Tests for our backend""" from urllib.parse import urljoin import pytest from social_auth_mitxpro.backends import MITxProOAuth2 # pylint: disable=redefined-outer-name @pytest.fixture def strategy(mocker): """Mock strategy""" return mocker.Mock() @pytest.fixture def backend(strategy): """MITxProOAu...
[((24, 1, 33, 1), 'pytest.mark.parametrize', 'pytest.mark.parametrize', ({(25, 4, 25, 24): '"""response, expected"""', (26, 4, 32, 5): "[({'username': 'abc123', 'email': 'user@example.com', 'name': 'Jane Doe'},\n {'username': 'abc123', 'email': 'user@example.com', 'name': 'Jane Doe'}\n ), ({'username': 'abc123'},...
velocist/TS4CheatsInfo
Scripts/simulation/careers/detective/detective_crime_scene.py
b59ea7e5f4bd01d3b3bd7603843d525a9c179867
# uncompyle6 version 3.7.4 # Python bytecode 3.7 (3394) # Decompiled from: Python 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:58:18) [MSC v.1900 64 bit (AMD64)] # Embedded file name: T:\InGame\Gameplay\Scripts\Server\careers\detective\detective_crime_scene.py # Compiled at: 2015-02-08 03:00:54 # Size of source mod 2...
[]
methylgrammarlab/proj_scwgbs
classifier/interpretation_exp.py
287196898796eb617fef273bfaf9e978a57047dc
""" Code adapted from https://github.com/ohlerlab/DeepRiPe with changes Extract information and graphs from the Integrated gradients output """ import argparse import os import sys import matplotlib.pyplot as plt import numpy as np import seaborn as sns from classifier.plotseqlogo import seqlogo_fig from commons imp...
[((17, 0, 17, 9), 'seaborn.set', 'sns.set', ({}, {}), '()', True, 'import seaborn as sns\n'), ((18, 0, 18, 26), 'seaborn.set_style', 'sns.set_style', ({(18, 14, 18, 25): '"""whitegrid"""'}, {}), "('whitegrid')", True, 'import seaborn as sns\n'), ((22, 13, 22, 38), 'argparse.ArgumentParser', 'argparse.ArgumentParser', (...
shulinye/dotfiles
scripts/pythonutils/autorepr.py
a342512c33ca102d03921cc653ee4605d0cf9617
#!/usr/bin/python3 from collections import OrderedDict from functools import partial from ordered_set import OrderedSet import inspect import itertools import types from .utils import walk_getattr __all__ = ['autoinit', 'autorepr', 'TotalCompareByKey'] def autoinit(obj=None, *args, params=None, **kwargs): """T...
[((29, 7, 29, 27), 'inspect.isclass', 'inspect.isclass', ({(29, 23, 29, 26): 'obj'}, {}), '(obj)', False, 'import inspect\n'), ((61, 7, 61, 27), 'inspect.isclass', 'inspect.isclass', ({(61, 23, 61, 26): 'obj'}, {}), '(obj)', False, 'import inspect\n'), ((20, 27, 20, 59), 'functools.partial', 'partial', (), '', False, '...
TTOFFLINE-LEAK/ttoffline
v1.0.0.test/toontown/estate/DistributedGardenPlotAI.py
bb0e91704a755d34983e94288d50288e46b68380
from direct.directnotify import DirectNotifyGlobal from toontown.estate import GardenGlobals from toontown.estate.DistributedLawnDecorAI import DistributedLawnDecorAI FLOWER_X_OFFSETS = ( None, (0, ), (-1.5, 1.5), (-3.4, 0, 3.5)) class DistributedGardenPlotAI(DistributedLawnDecorAI): notify = DirectNotifyGlobal.d...
[((8, 13, 8, 83), 'direct.directnotify.DirectNotifyGlobal.directNotify.newCategory', 'DirectNotifyGlobal.directNotify.newCategory', ({(8, 57, 8, 82): '"""DistributedGardenPlotAI"""'}, {}), "('DistributedGardenPlotAI')", False, 'from direct.directnotify import DirectNotifyGlobal\n'), ((11, 8, 11, 50), 'toontown.estate.D...