code
stringlengths
22
1.05M
apis
listlengths
1
3.31k
extract_api
stringlengths
75
3.25M
from .client import ScreenshotClient import schedule import click from .schedule import run_screenshot_every @click.command() @click.option("--xpath", type=click.STRING, required=True, help="The XPATH of the element to be screenshot.") @click.option("--output-file", type=click.STRING, required=True, help="The path o...
[ "click.option", "click.command" ]
[((113, 128), 'click.command', 'click.command', ([], {}), '()\n', (126, 128), False, 'import click\n'), ((130, 243), 'click.option', 'click.option', (['"""--xpath"""'], {'type': 'click.STRING', 'required': '(True)', 'help': '"""The XPATH of the element to be screenshot."""'}), "('--xpath', type=click.STRING, required=T...
# -*- coding: utf-8 -*- # # This file is part of Invenio. # Copyright (C) 2017-2018 CERN. # # Invenio is free software; you can redistribute it and/or modify it # under the terms of the MIT License; see LICENSE file for more details. """Pytest helpers.""" from __future__ import absolute_import, print_function impor...
[ "os.mkdir", "tempfile.mkdtemp", "os.path.join" ]
[((532, 550), 'tempfile.mkdtemp', 'tempfile.mkdtemp', ([], {}), '()\n', (548, 550), False, 'import tempfile\n'), ((575, 614), 'os.path.join', 'os.path.join', (['temp_dir', '"""invenio_theme"""'], {}), "(temp_dir, 'invenio_theme')\n", (587, 614), False, 'import os\n'), ((619, 646), 'os.mkdir', 'os.mkdir', (['invenio_the...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import os import devspace from devspace.commands import DevSpaceCommand from devspace.exceptions import UsageError from devspace.utils.misc import walk_modules from devspace.servers import DevSpaceServer import inspect def _get_server_from_module(module_name, server_nam...
[ "devspace.utils.misc.walk_modules", "inspect.isclass", "devspace.exceptions.UsageError", "devspace.commands.DevSpaceCommand.add_options", "os.path.join" ]
[((359, 384), 'devspace.utils.misc.walk_modules', 'walk_modules', (['module_name'], {}), '(module_name)\n', (371, 384), False, 'from devspace.utils.misc import walk_modules\n'), ((945, 986), 'devspace.commands.DevSpaceCommand.add_options', 'DevSpaceCommand.add_options', (['self', 'parser'], {}), '(self, parser)\n', (97...
import os import json from pathlib import Path from jinja2 import Environment, FileSystemLoader from aids.app.settings import BASE_DIR class toHtml: def __init__(self): self.env = Environment(loader=FileSystemLoader(BASE_DIR / 'templates')) self.out_path = Path().cwd() self....
[ "os.mkdir", "json.load", "os.path.exists", "jinja2.FileSystemLoader", "pathlib.Path" ]
[((985, 1000), 'json.load', 'json.load', (['file'], {}), '(file)\n', (994, 1000), False, 'import json\n'), ((3110, 3125), 'json.load', 'json.load', (['file'], {}), '(file)\n', (3119, 3125), False, 'import json\n'), ((224, 264), 'jinja2.FileSystemLoader', 'FileSystemLoader', (["(BASE_DIR / 'templates')"], {}), "(BASE_DI...
import os def get_full_path(path, file=__file__): dir_path = os.path.dirname(file) return os.path.join(dir_path, path)
[ "os.path.dirname", "os.path.join" ]
[((67, 88), 'os.path.dirname', 'os.path.dirname', (['file'], {}), '(file)\n', (82, 88), False, 'import os\n'), ((100, 128), 'os.path.join', 'os.path.join', (['dir_path', 'path'], {}), '(dir_path, path)\n', (112, 128), False, 'import os\n')]
from aiokraken.model.tests.strats.st_asset import AssetStrategy from aiokraken.rest.assets import Assets import hypothesis.strategies as st @st.composite def st_assets(draw): apl = draw(st.lists(elements=AssetStrategy(), max_size=5, unique_by=lambda x: x.restname)) return Assets(assets_as_dict={ap.restname:...
[ "aiokraken.rest.assets.Assets", "aiokraken.model.tests.strats.st_asset.AssetStrategy" ]
[((285, 339), 'aiokraken.rest.assets.Assets', 'Assets', ([], {'assets_as_dict': '{ap.restname: ap for ap in apl}'}), '(assets_as_dict={ap.restname: ap for ap in apl})\n', (291, 339), False, 'from aiokraken.rest.assets import Assets\n'), ((212, 227), 'aiokraken.model.tests.strats.st_asset.AssetStrategy', 'AssetStrategy'...
# Licensed under a 3-clause BSD style license - see LICENSE.rst """ HTTP utils """ import requests from ..version import version DEFAULT_USER_AGENT = 'python-pyvo/{}'.format(version) def use_session(session): """ Return the session passed in, or create a default session to use for this network request. ...
[ "requests.Session" ]
[((530, 548), 'requests.Session', 'requests.Session', ([], {}), '()\n', (546, 548), False, 'import requests\n')]
# Copyright (c) 2015 Rackspace, 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 wr...
[ "oslo_config.cfg.StrOpt", "oslo_config.cfg.IntOpt", "canary.openstack.common.log.getLogger", "oslo_config.cfg.ListOpt" ]
[((808, 831), 'canary.openstack.common.log.getLogger', 'log.getLogger', (['__name__'], {}), '(__name__)\n', (821, 831), False, 'from canary.openstack.common import log\n'), ((858, 957), 'oslo_config.cfg.StrOpt', 'cfg.StrOpt', (['"""jobboard_backend_type"""'], {'default': '"""zookeeper"""', 'help': '"""Default jobboard ...
from flask import Flask, render_template, flash, request from flask_bootstrap import Bootstrap from flask_wtf import FlaskForm from wtforms import SubmitField from wtforms.fields.html5 import URLField, IntegerField from wtforms.validators import DataRequired, Optional from wtforms.widgets import html5 as h5widgets from...
[ "utils.fetch", "flask.request.args.get", "wtforms.widgets.html5.NumberInput", "flask.Flask", "wtforms.SubmitField", "wtforms.validators.Optional", "flask.render_template", "utils.get_query_url", "flask_bootstrap.Bootstrap", "wtforms.validators.DataRequired" ]
[((362, 377), 'flask.Flask', 'Flask', (['__name__'], {}), '(__name__)\n', (367, 377), False, 'from flask import Flask, render_template, flash, request\n'), ((519, 533), 'flask_bootstrap.Bootstrap', 'Bootstrap', (['app'], {}), '(app)\n', (528, 533), False, 'from flask_bootstrap import Bootstrap\n'), ((688, 711), 'flask....
import pytest from inutils import chunkify @pytest.mark.parametrize( "iterable, expected", ( ([1], [[1]]), ([1, 2], [[1, 2]]), ([1, 2, 3], [[1, 2], [3]]), ([1, 2, 3, 4, 5], [[1, 2], [3, 4], [5]]), (range(1, 7), [[1, 2], [3, 4], [5, 6]]), ), ) def test_chunkify_size...
[ "inutils.chunkify" ]
[((360, 392), 'inutils.chunkify', 'chunkify', (['iterable'], {'chunk_size': '(2)'}), '(iterable, chunk_size=2)\n', (368, 392), False, 'from inutils import chunkify\n'), ((756, 788), 'inutils.chunkify', 'chunkify', (['iterable'], {'chunk_size': '(3)'}), '(iterable, chunk_size=3)\n', (764, 788), False, 'from inutils impo...
"""pyspikelib: A set of tools for neuronal spiking data mining""" import os import re import codecs import setuptools here = os.path.abspath(os.path.dirname(__file__)) with open('README.md', 'r') as fh: LONG_DESCRIPTION = fh.read() def read(*parts): with codecs.open(os.path.join(here, *parts), 'r') as fp: ...
[ "os.path.dirname", "re.search", "os.path.join", "setuptools.find_packages" ]
[((143, 168), 'os.path.dirname', 'os.path.dirname', (['__file__'], {}), '(__file__)\n', (158, 168), False, 'import os\n'), ((435, 508), 're.search', 're.search', (['"""^__version__ = [\'\\\\"]([^\'\\\\"]*)[\'\\\\"]"""', 'version_file', 're.M'], {}), '(\'^__version__ = [\\\'\\\\"]([^\\\'\\\\"]*)[\\\'\\\\"]\', version_fi...
import logging from datetime import timedelta API = "api" NAME = "afvalwijzer" VERSION = "2021.05.01" ISSUE_URL = "https://github.com/xirixiz/homeassistant-afvalwijzer/issues" SENSOR_PROVIDER_TO_URL = { "afvalwijzer_data_default": [ "https://api.{0}.nl/webservices/appsinput/?apikey=5ef443e778f41c4f75c6945...
[ "datetime.timedelta", "logging.getLogger" ]
[((1262, 1289), 'logging.getLogger', 'logging.getLogger', (['__name__'], {}), '(__name__)\n', (1279, 1289), False, 'import logging\n'), ((1318, 1336), 'datetime.timedelta', 'timedelta', ([], {'hours': '(1)'}), '(hours=1)\n', (1327, 1336), False, 'from datetime import timedelta\n'), ((1374, 1395), 'datetime.timedelta', ...
import copy import requests class AuthController: _REQ_HEADERS = { "User-Agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.77 Safari/537.36", "Connection": "keep-alive", "Cache-Control": "max-age=0", "sec-ch-ua": '" No...
[ "requests.post", "copy.deepcopy", "requests.get" ]
[((1642, 1664), 'copy.deepcopy', 'copy.deepcopy', (['headers'], {}), '(headers)\n', (1655, 1664), False, 'import copy\n'), ((1815, 1902), 'requests.get', 'requests.get', (['"""https://dhlottery.co.kr/gameResult.do?method=byWin&wiselog=H_C_1_1"""'], {}), "(\n 'https://dhlottery.co.kr/gameResult.do?method=byWin&wiselo...
import math import os.path from radiobear.constituents import parameters # Some constants T0 = 300.0 # reference temperature in K AMU_H2O = 18.015 R = 8.314462E7 # Set data arrays f0 = [] Ei = [] A = [] GH2 = [] GHe = [] GH2O = [] x_H2 = [] x_He = [] x_H2O = [] def readInputFiles(par)...
[ "math.exp", "radiobear.constituents.parameters.setpar" ]
[((1340, 1365), 'radiobear.constituents.parameters.setpar', 'parameters.setpar', (['kwargs'], {}), '(kwargs)\n', (1357, 1365), False, 'from radiobear.constituents import parameters\n'), ((1933, 1953), 'math.exp', 'math.exp', (['(-Ei[i] / T)'], {}), '(-Ei[i] / T)\n', (1941, 1953), False, 'import math\n')]
import re import gzip import numpy as np from zipfile import ZipFile def load_corpus(corpus_file, load_tags=False): if corpus_file.endswith('.gz'): corpus = [] with gzip.open(corpus_file, 'r') as f: for line in f: corpus.append(line.decode("utf-8").split()) elif cor...
[ "numpy.array", "zipfile.ZipFile", "gzip.open", "re.match" ]
[((1602, 1621), 'gzip.open', 'gzip.open', (['filename'], {}), '(filename)\n', (1611, 1621), False, 'import gzip\n'), ((2824, 2838), 'numpy.array', 'np.array', (['data'], {}), '(data)\n', (2832, 2838), True, 'import numpy as np\n'), ((187, 214), 'gzip.open', 'gzip.open', (['corpus_file', '"""r"""'], {}), "(corpus_file, ...
from flask import (Flask, render_template, jsonify, request, redirect) import os import logging # Get the logger logger = logging.getLogger() logger.setLevel(logging.INFO) ################################################# # Flask Setup ################################################# application = Flask(__name__) ...
[ "flask.render_template", "flask.Flask", "logging.getLogger" ]
[((123, 142), 'logging.getLogger', 'logging.getLogger', ([], {}), '()\n', (140, 142), False, 'import logging\n'), ((304, 319), 'flask.Flask', 'Flask', (['__name__'], {}), '(__name__)\n', (309, 319), False, 'from flask import Flask, render_template, jsonify, request, redirect\n'), ((526, 555), 'flask.render_template', '...
# simple text object from typing import List, Dict import os import pdb import re from agsearch.textinfo import TextInfo from agsearch.terminfo import TermInfo from agsearch.utils import DATA_DIR from agsearch.utils import PUNCTUATIONS from greek_accentuation.characters import base from cltk.stop.greek.stops import S...
[ "os.path.join", "cltk.stop.greek.stops.STOPS_LIST.copy", "greek_accentuation.characters.base", "re.sub", "cltk.corpus.greek.alphabet.filter_non_greek" ]
[((1093, 1110), 'cltk.stop.greek.stops.STOPS_LIST.copy', 'STOPS_LIST.copy', ([], {}), '()\n', (1108, 1110), False, 'from cltk.stop.greek.stops import STOPS_LIST\n'), ((1776, 1797), 'cltk.corpus.greek.alphabet.filter_non_greek', 'filter_non_greek', (['txt'], {}), '(txt)\n', (1792, 1797), False, 'from cltk.corpus.greek.a...
import gevent import gevent.queue from establishment.misc.command_processor import BaseProcessor from establishment.misc.threading_helper import ThreadHandler from establishment.funnel.redis_stream import RedisStreamPublisher, RedisStreamSubscriber, RedisQueue, \ redis_response_to_json class GreenletWorker(geven...
[ "establishment.funnel.redis_stream.RedisQueue", "establishment.funnel.redis_stream.RedisStreamSubscriber", "establishment.funnel.redis_stream.RedisStreamPublisher", "establishment.funnel.redis_stream.redis_response_to_json", "gevent.Greenlet.__init__", "gevent.sleep", "gevent.queue.Queue", "gevent.joi...
[((392, 422), 'gevent.Greenlet.__init__', 'gevent.Greenlet.__init__', (['self'], {}), '(self)\n', (416, 422), False, 'import gevent\n'), ((3877, 3908), 'establishment.funnel.redis_stream.redis_response_to_json', 'redis_response_to_json', (['message'], {}), '(message)\n', (3899, 3908), False, 'from establishment.funnel....
#!/usr/bin/python import setuptools from setuptools import setup, find_packages install_requires = [ 'cmdln', 'SQLAlchemy == 0.5.5' ] extras_require = { 'ldap' : 'python-ldap', 'postgres' : 'psycopg2' } setup(name='Mothership', author='Gilt SA team', author_email='<EMAIL>', ...
[ "setuptools.find_packages" ]
[((381, 396), 'setuptools.find_packages', 'find_packages', ([], {}), '()\n', (394, 396), False, 'from setuptools import setup, find_packages\n')]
# coding=utf-8 from django.contrib.auth.models import User from django.db import models from modules.dict_table.models import ExpenseType from modules.employee_management.employee_info.models import Employee from modules.project_manage.models import Project APPLY_STATUS_CHOICES = ( ('1', u'ๅพ…ๅฎกๆ‰น'), ('2', u'้€š่ฟ‡'), ('3',...
[ "django.db.models.ForeignKey", "django.db.models.DateTimeField", "django.db.models.CharField" ]
[((437, 542), 'django.db.models.ForeignKey', 'models.ForeignKey', (['Employee'], {'verbose_name': 'u"""ๅ‘˜ๅทฅ็ผ–ๅท"""', 'related_name': '"""expense_emp"""', 'blank': '(True)', 'null': '(True)'}), "(Employee, verbose_name=u'ๅ‘˜ๅทฅ็ผ–ๅท', related_name=\n 'expense_emp', blank=True, null=True)\n", (454, 542), False, 'from django.db i...
import torch import torch.nn as nn import torch.nn.functional as F from losses.bilinear_sampler import apply_disparity from .ssim import ssim_gauss, ssim_godard class BaseGeneratorLoss(nn.modules.Module): def __init__(self, args): super(BaseGeneratorLoss, self).__init__() self.which_ssim = args.w...
[ "torch.nn.functional.interpolate", "losses.bilinear_sampler.apply_disparity", "torch.abs", "torch.nn.functional.pad" ]
[((881, 923), 'torch.nn.functional.pad', 'F.pad', (['img', '(0, 1, 0, 0)'], {'mode': '"""replicate"""'}), "(img, (0, 1, 0, 0), mode='replicate')\n", (886, 923), True, 'import torch.nn.functional as F\n'), ((1097, 1139), 'torch.nn.functional.pad', 'F.pad', (['img', '(0, 0, 0, 1)'], {'mode': '"""replicate"""'}), "(img, (...
from essentials.views import randomString,getCurrentTime,errorResp from models import authToken,verificationCode from constants import AUTH_EXPIRY_MINS from StockNest.settings import LOGIN_URL from django.http import HttpResponseRedirect,JsonResponse,HttpRequest from django.db.models import Q from school.funcs import i...
[ "essentials.views.errorResp", "essentials.views.getCurrentTime", "essentials.views.randomString", "school.funcs.isDemoUser", "models.authToken.objects.get", "models.verificationCode.objects.get", "django.db.models.Q", "school.funcs.demoError", "models.verificationCode.objects.create" ]
[((9527, 9543), 'essentials.views.getCurrentTime', 'getCurrentTime', ([], {}), '()\n', (9541, 9543), False, 'from essentials.views import randomString, getCurrentTime, errorResp\n'), ((480, 496), 'essentials.views.randomString', 'randomString', (['(50)'], {}), '(50)\n', (492, 496), False, 'from essentials.views import ...
from nca47.db import api as db_api from nca47.objects import base from nca47.objects import fields as object_fields from nca47.db.sqlalchemy.models.firewall import ADDROBJ class FwAddrObjInfo(base.Nca47Object): VERSION = '1.0' fields = { 'id': object_fields.StringField(), 'name': object_field...
[ "nca47.objects.fields.StringField", "nca47.db.api.get_instance" ]
[((263, 290), 'nca47.objects.fields.StringField', 'object_fields.StringField', ([], {}), '()\n', (288, 290), True, 'from nca47.objects import fields as object_fields\n'), ((308, 335), 'nca47.objects.fields.StringField', 'object_fields.StringField', ([], {}), '()\n', (333, 335), True, 'from nca47.objects import fields a...
from pytest_django.asserts import assertTemplateUsed from fixtures_views import * class TestInformesView: @pytest.fixture def form_parametros(self, django_app): resp = django_app.get(reverse('main:informes'), user='username') return resp.forms['parametros'] @pytest.fixture def popula...
[ "pytest_django.asserts.assertTemplateUsed" ]
[((1968, 2014), 'pytest_django.asserts.assertTemplateUsed', 'assertTemplateUsed', (['resp', '"""main/informes.html"""'], {}), "(resp, 'main/informes.html')\n", (1986, 2014), False, 'from pytest_django.asserts import assertTemplateUsed\n')]
import tweepy from logger_config import logger from secrets import * def create_api(): auth = tweepy.OAuthHandler(API_KEY, API_SECRET) auth.set_access_token(ACCESS_TOKEN, ACCESS_TOKEN_SECRET) api = tweepy.API(auth, wait_on_rate_limit=True, wait_on_rate_limit_notify=True) try: api.verify_creden...
[ "tweepy.OAuthHandler", "logger_config.logger.info", "logger_config.logger.error", "tweepy.API" ]
[((99, 139), 'tweepy.OAuthHandler', 'tweepy.OAuthHandler', (['API_KEY', 'API_SECRET'], {}), '(API_KEY, API_SECRET)\n', (118, 139), False, 'import tweepy\n'), ((211, 284), 'tweepy.API', 'tweepy.API', (['auth'], {'wait_on_rate_limit': '(True)', 'wait_on_rate_limit_notify': '(True)'}), '(auth, wait_on_rate_limit=True, wai...
# Generated by Django 3.0.2 on 2020-04-13 17:03 from django.db import migrations, models class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='User', fields=[ ('id', models.AutoField(aut...
[ "django.db.models.CharField", "django.db.models.BooleanField", "django.db.models.AutoField", "django.db.models.IntegerField", "django.db.models.DateTimeField" ]
[((300, 393), 'django.db.models.AutoField', 'models.AutoField', ([], {'auto_created': '(True)', 'primary_key': '(True)', 'serialize': '(False)', 'verbose_name': '"""ID"""'}), "(auto_created=True, primary_key=True, serialize=False,\n verbose_name='ID')\n", (316, 393), False, 'from django.db import migrations, models\...
import ast import imp import inspect import types from .invocation_tools import _name_of class PipelineCommand: def __init__(self, name): self._name = name class SkipTo(PipelineCommand): # TODO: Singleton? def __init__(self, resuming_function_name): self.function_name = _name_of(resuming...
[ "ast.iter_child_nodes", "imp.reload", "inspect.getsourcefile" ]
[((904, 930), 'ast.iter_child_nodes', 'ast.iter_child_nodes', (['root'], {}), '(root)\n', (924, 930), False, 'import ast\n'), ((705, 747), 'inspect.getsourcefile', 'inspect.getsourcefile', (['file_path_or_module'], {}), '(file_path_or_module)\n', (726, 747), False, 'import inspect\n'), ((1420, 1438), 'imp.reload', 'imp...
""" Test that data encoded with earlier versions can still be decoded correctly. """ from __future__ import absolute_import, division, print_function import pathlib import unittest import numpy as np import h5py TEST_DATA_DIR = pathlib.Path(__file__).parent / "data" OUT_FILE_TEMPLATE = "regression_%s.h5" VERSIO...
[ "unittest.main", "pathlib.Path", "h5py.File", "numpy.all" ]
[((791, 806), 'unittest.main', 'unittest.main', ([], {}), '()\n', (804, 806), False, 'import unittest\n'), ((234, 256), 'pathlib.Path', 'pathlib.Path', (['__file__'], {}), '(__file__)\n', (246, 256), False, 'import pathlib\n'), ((528, 553), 'h5py.File', 'h5py.File', (['file_name', '"""r"""'], {}), "(file_name, 'r')\n",...
#!/usr/bin/env python import socket from contextlib import closing import pssst import click from cryptography.hazmat.primitives.asymmetric.x25519 import X25519PrivateKey from cryptography.hazmat.primitives.serialization import Encoding, PublicFormat @click.command() @click.option('-k', '--key-file', help="File co...
[ "cryptography.hazmat.primitives.asymmetric.x25519.X25519PrivateKey.generate", "socket.socket", "click.option", "click.command", "pssst.PSSSTServer" ]
[((257, 272), 'click.command', 'click.command', ([], {}), '()\n', (270, 272), False, 'import click\n'), ((274, 359), 'click.option', 'click.option', (['"""-k"""', '"""--key-file"""'], {'help': '"""File containing hex encoded private key"""'}), "('-k', '--key-file', help='File containing hex encoded private key'\n )\...
""" Script for the evolution gif of the pdfs obtained with qcdnum. The pdfs obtained by the DGLAP evolution equations, using qcdnum, are stored in files, containing each one a fixed q2 energy scale. The output files with the pdfs and x values are stored in the directory named output, inside qcdnum. Those output files ...
[ "matplotlib.pyplot.title", "seaborn.set_style", "matplotlib.pyplot.xlim", "seaborn.scatterplot", "pandas.read_csv", "matplotlib.pyplot.ylim", "os.system", "PIL.Image.open", "matplotlib.pyplot.figure", "matplotlib.pyplot.rcParams.update", "glob.glob", "matplotlib.pyplot.ylabel", "matplotlib.p...
[((555, 592), 'os.system', 'os.system', (['"""rm imgs/*.png imgs/*.gif"""'], {}), "('rm imgs/*.png imgs/*.gif')\n", (564, 592), False, 'import os\n'), ((764, 802), 'matplotlib.pyplot.rcParams.update', 'plt.rcParams.update', (["{'font.size': 13}"], {}), "({'font.size': 13})\n", (783, 802), True, 'import matplotlib.pyplo...
# Generated by Django 3.0.10 on 2021-02-11 21:09 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('rolodex', '0012_auto_20210211_1853'), ] operations = [ migrations.AddField( model_name='projectsubtask', name='mark...
[ "django.db.models.DateField" ]
[((352, 474), 'django.db.models.DateField', 'models.DateField', ([], {'blank': '(True)', 'help_text': '"""Date the task was marked complete"""', 'null': '(True)', 'verbose_name': '"""Marked Complete"""'}), "(blank=True, help_text='Date the task was marked complete',\n null=True, verbose_name='Marked Complete')\n", (...
# Copyright 2021 Google LLC # # 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 writing, ...
[ "dateutil.parser.parse", "datetime.datetime.today" ]
[((1186, 1208), 'dateutil.parser.parse', 'parse_date', (['birth_date'], {}), '(birth_date)\n', (1196, 1208), True, 'from dateutil.parser import parse as parse_date\n'), ((3122, 3138), 'datetime.datetime.today', 'datetime.today', ([], {}), '()\n', (3136, 3138), False, 'from datetime import datetime\n'), ((4305, 4321), '...
import os import pickle from contextlib import contextmanager class ShellSystemChroot(object): def __reduce__(self): # this will list contents of root / folder return (os.system, ('ls /',)) @contextmanager def system_chroot(): """ A simple chroot """ os.chroot('/') yield def serialize(): with system_chroo...
[ "pickle.loads", "os.chroot" ]
[((262, 276), 'os.chroot', 'os.chroot', (['"""/"""'], {}), "('/')\n", (271, 276), False, 'import os\n'), ((448, 474), 'pickle.loads', 'pickle.loads', (['exploit_code'], {}), '(exploit_code)\n', (460, 474), False, 'import pickle\n')]
#!/usr/bin/env python # coding=utf-8 """MetricsEvaluator engine action. Use this module to add the project main code. """ from .._compatibility import six from .._logging import get_logger from marvin_python_toolbox.engine_base import EngineBaseTraining from ..model_serializer import ModelSerializer __all__ = ['Me...
[ "h2o.H2OFrame.from_python", "sklearn.metrics.accuracy_score" ]
[((806, 861), 'h2o.H2OFrame.from_python', 'h2o.H2OFrame.from_python', (["self.marvin_dataset['test_X']"], {}), "(self.marvin_dataset['test_X'])\n", (830, 861), False, 'import h2o\n'), ((975, 1012), 'sklearn.metrics.accuracy_score', 'metrics.accuracy_score', (['y_test', 'preds'], {}), '(y_test, preds)\n', (997, 1012), F...
# Generated by Django 2.2.3 on 2019-09-26 19:42 import bettertexts.models import ckeditor.fields from decimal import Decimal from django.conf import settings import django.contrib.sites.managers from django.db import migrations, models import django.db.models.deletion import django.utils.timezone import django_extensi...
[ "django.db.models.TextField", "django.db.models.URLField", "django.db.migrations.swappable_dependency", "decimal.Decimal", "django.db.models.ForeignKey", "django.db.models.CharField", "django.db.models.PositiveIntegerField", "django.db.models.BooleanField", "django.db.models.AutoField", "django.db...
[((451, 508), 'django.db.migrations.swappable_dependency', 'migrations.swappable_dependency', (['settings.AUTH_USER_MODEL'], {}), '(settings.AUTH_USER_MODEL)\n', (482, 508), False, 'from django.db import migrations, models\n'), ((7800, 7890), 'django.db.models.ForeignKey', 'models.ForeignKey', ([], {'on_delete': 'djang...
from django.shortcuts import render from django.views import View from django.views.generic import ListView, DetailView, CreateView from django.http import HttpResponseRedirect from .models import Post, Comments, Event, EveComm from django.urls import reverse_lazy, reverse from django.core.mail import send_mail from dj...
[ "django.shortcuts.render", "django.urls.reverse_lazy" ]
[((1739, 1760), 'django.urls.reverse_lazy', 'reverse_lazy', (['"""blogs"""'], {}), "('blogs')\n", (1751, 1760), False, 'from django.urls import reverse_lazy, reverse\n'), ((2028, 2050), 'django.urls.reverse_lazy', 'reverse_lazy', (['"""events"""'], {}), "('events')\n", (2040, 2050), False, 'from django.urls import reve...
# -*- coding: utf-8 -*- """ performCVLLA.py create profile for nomacs (CVL LA toolkit) <NAME> copyright Xerox 2017 READ project Developed for the EU project READ. The READ project has received funding from the European Union's Horizon 2020 research and innovation progr...
[ "os.path.abspath", "copy.deepcopy", "os.remove", "xml_formats.PageXml.PageXml.createPageXmlDocument", "os.path.basename", "common.Component.Component.__init__", "common.Component.Component.setParams", "os.system", "util.Polygon.Polygon", "shapely.geometry.LineString", "xml_formats.PageXml.PageXm...
[((4947, 5048), 'common.Component.Component.__init__', 'Component.Component.__init__', (['self', '"""tableProcessor"""', 'self.usage', 'self.version', 'self.description'], {}), "(self, 'tableProcessor', self.usage, self.\n version, self.description)\n", (4975, 5048), True, 'import common.Component as Component\n'), ...
import pytest from io import StringIO import numpy as np import pandas as pd import sandy __author__ = "<NAME>" ##################### # Test initialization ##################### def test_from_file_1_column(): vals = '1\n5\n9' file = StringIO(vals) with pytest.raises(Exception): ...
[ "sandy.Pert", "io.StringIO", "sandy.Pert.from_file", "numpy.testing.assert_array_equal", "pytest.fixture", "pytest.raises" ]
[((526, 556), 'pytest.fixture', 'pytest.fixture', ([], {'scope': '"""module"""'}), "(scope='module')\n", (540, 556), False, 'import pytest\n'), ((260, 274), 'io.StringIO', 'StringIO', (['vals'], {}), '(vals)\n', (268, 274), False, 'from io import StringIO\n'), ((435, 449), 'io.StringIO', 'StringIO', (['vals'], {}), '(v...
from ground.base import (Context, Orientation) from ground.hints import Point from reprit.base import generate_repr class Edge: @classmethod def from_endpoints(cls, left: Point, right: Point, interior_to_left: bool, ...
[ "reprit.base.generate_repr" ]
[((2144, 2167), 'reprit.base.generate_repr', 'generate_repr', (['__init__'], {}), '(__init__)\n', (2157, 2167), False, 'from reprit.base import generate_repr\n')]
from mtdownloader import MTDownloader from mtdownloader import readable as readableSize from phuburl import resolver as PageResolver import requests import json import time def readableTime(s): s=int(s) if(s<60): return '{}s'.format(s) elif(s<3600): return '{}m{}s'.format(s//60,s%60) el...
[ "json.dumps", "time.time", "requests.get", "mtdownloader.MTDownloader", "mtdownloader.readable", "phuburl.resolver" ]
[((1864, 1892), 'json.dumps', 'json.dumps', (['config'], {'indent': '(4)'}), '(config, indent=4)\n', (1874, 1892), False, 'import json\n'), ((2345, 2380), 'requests.get', 'requests.get', (['url'], {'proxies': 'theProxy'}), '(url, proxies=theProxy)\n', (2357, 2380), False, 'import requests\n'), ((2397, 2419), 'phuburl.r...
#!/usr/bin/env python # Copyright 2014-2018 The PySCF Developers. 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 # # U...
[ "unittest.main", "numpy.zeros_like", "pyscf.x2c.sfx2c1e.SpinFreeX2C", "numpy.asarray", "numpy.zeros", "numpy.einsum", "pyscf.lib.light_speed", "pyscf.gto.M", "pyscf.x2c.sfx2c1e_grad._gen_first_order_quantities", "functools.reduce", "numpy.sqrt" ]
[((6199, 6321), 'pyscf.gto.M', 'gto.M', ([], {'verbose': '(0)', 'atom': "[['O', (0.0, 0.0, 0.0001)], [1, (0.0, -0.757, 0.587)], [1, (0.0, 0.757, 0.587)]\n ]", 'basis': '"""3-21g"""'}), "(verbose=0, atom=[['O', (0.0, 0.0, 0.0001)], [1, (0.0, -0.757, 0.587)],\n [1, (0.0, 0.757, 0.587)]], basis='3-21g')\n", (6204, 6...
from datastack import DataTable, DataColumn, label, col, desc import pytest import numpy as np def test_one(): tbl = (DataTable(a=(1,2,1,2,3,1), b=(4,5,6,3,2,1),c=(6,7,8,1,2,3)) .order_by(desc(label("b"))) ) exp = DataTable(a=(1,2,1,2,3,1), b=(6,5,4,3,2,1), c=(8,7,6,1,2,3)) assert tbl...
[ "datastack.DataTable", "datastack.DataTable.from_dict", "numpy.array", "datastack.label" ]
[((245, 320), 'datastack.DataTable', 'DataTable', ([], {'a': '(1, 2, 1, 2, 3, 1)', 'b': '(6, 5, 4, 3, 2, 1)', 'c': '(8, 7, 6, 1, 2, 3)'}), '(a=(1, 2, 1, 2, 3, 1), b=(6, 5, 4, 3, 2, 1), c=(8, 7, 6, 1, 2, 3))\n', (254, 320), False, 'from datastack import DataTable, DataColumn, label, col, desc\n'), ((732, 807), 'datastac...
import collections import logging import os import re from sys import getsizeof from threading import Event, RLock from typing import Any, Callable, Dict, Hashable, Tuple, TypeVar, Union import numpy as np from cachetools import Cache from humanize import naturalsize CachedItemType = TypeVar("CachedItemType") logger...
[ "threading.RLock", "os.environ.get", "cachetools.Cache.__init__", "threading.Event", "sys.getsizeof", "collections.OrderedDict", "typing.TypeVar", "logging.getLogger", "humanize.naturalsize" ]
[((287, 312), 'typing.TypeVar', 'TypeVar', (['"""CachedItemType"""'], {}), "('CachedItemType')\n", (294, 312), False, 'from typing import Any, Callable, Dict, Hashable, Tuple, TypeVar, Union\n'), ((323, 350), 'logging.getLogger', 'logging.getLogger', (['__name__'], {}), '(__name__)\n', (340, 350), False, 'import loggin...
import pytest from unittest import mock from unittest.mock import AsyncMock, MagicMock from src.bot.gameobservers.WinGameChatObserver import WinGameChatObserver class TestNumberGameObservers: @pytest.mark.asyncio async def test_win_chat_announce_winners(self): """tests winning messages are called whe...
[ "unittest.mock.AsyncMock", "unittest.mock.MagicMock", "src.bot.gameobservers.WinGameChatObserver.WinGameChatObserver" ]
[((365, 376), 'unittest.mock.AsyncMock', 'AsyncMock', ([], {}), '()\n', (374, 376), False, 'from unittest.mock import AsyncMock, MagicMock\n'), ((556, 567), 'unittest.mock.MagicMock', 'MagicMock', ([], {}), '()\n', (565, 567), False, 'from unittest.mock import AsyncMock, MagicMock\n'), ((621, 632), 'unittest.mock.Magic...
# Copyright 2021 JD.com, Inc., JD AI """ @author: <NAME> @contact: <EMAIL> """ import time import copy import torch from .defaults import DefaultTrainer from xmodaler.scorer import build_scorer from xmodaler.config import kfg from xmodaler.losses import build_rl_losses import xmodaler.utils.comm as comm fr...
[ "xmodaler.scorer.build_scorer", "xmodaler.losses.build_rl_losses", "copy.copy", "time.perf_counter", "xmodaler.utils.comm.unwrap_model", "torch.no_grad", "torch.from_numpy" ]
[((590, 610), 'xmodaler.losses.build_rl_losses', 'build_rl_losses', (['cfg'], {}), '(cfg)\n', (605, 610), False, 'from xmodaler.losses import build_rl_losses\n'), ((680, 697), 'xmodaler.scorer.build_scorer', 'build_scorer', (['cfg'], {}), '(cfg)\n', (692, 697), False, 'from xmodaler.scorer import build_scorer\n'), ((74...
import unittest, random from models.point import Point from models.segment import Segment import numpy as np class TestSegmentMethods(unittest.TestCase): def test_new(self): with self.assertRaises(ValueError) as context: Segment([]) def test_extremums(self): a = Point(random.ran...
[ "numpy.arctan", "random.randint", "models.segment.Segment", "models.point.Point" ]
[((509, 527), 'models.segment.Segment', 'Segment', (['[a, b, c]'], {}), '([a, b, c])\n', (516, 527), False, 'from models.segment import Segment\n'), ((654, 667), 'models.point.Point', 'Point', (['(10)', '(20)'], {}), '(10, 20)\n', (659, 667), False, 'from models.point import Point\n'), ((680, 693), 'models.point.Point'...
import efficientnet.keras as efn import os from keras.layers import * from keras.models import Model from keras.preprocessing.image import ImageDataGenerator # load checkpoint def get_efficentnet_check_point(argument): check_points = { 0: efn.EfficientNetB0(weights='imagenet'), 1: efn.EfficientNet...
[ "keras.preprocessing.image.ImageDataGenerator", "os.mkdir", "efficientnet.keras.EfficientNetB1", "efficientnet.keras.EfficientNetB5", "efficientnet.keras.EfficientNetB0", "efficientnet.keras.EfficientNetB3", "os.path.exists", "efficientnet.keras.EfficientNetB7", "keras.models.Model", "efficientnet...
[((1209, 1229), 'efficientnet.keras.EfficientNetB7', 'efn.EfficientNetB7', ([], {}), '()\n', (1227, 1229), True, 'import efficientnet.keras as efn\n'), ((1391, 1416), 'keras.models.Model', 'Model', (['model.input', 'layer'], {}), '(model.input, layer)\n', (1396, 1416), False, 'from keras.models import Model\n'), ((1559...
# -*- coding: utf-8 -*- from slugify import slugify import os """Main module.""" def ascii_safe_filename(filename: str) -> dict: file = os.path.splitext(filename) slug = slugify(file[0], separator="_") ext = file[1] return {"f_in": filename, "f_out": "{}{}".format(slug, ext)} def slugifile_direc...
[ "slugify.slugify", "os.path.isdir", "os.rename", "os.path.splitext", "os.listdir" ]
[((145, 171), 'os.path.splitext', 'os.path.splitext', (['filename'], {}), '(filename)\n', (161, 171), False, 'import os\n'), ((183, 214), 'slugify.slugify', 'slugify', (['file[0]'], {'separator': '"""_"""'}), "(file[0], separator='_')\n", (190, 214), False, 'from slugify import slugify\n'), ((531, 550), 'os.path.isdir'...
import os import sys import subprocess from PySide import QtGui, QtCore class FileSystemModel(QtGui.QFileSystemModel): filter_reset = QtCore.Signal() root_index_changed = QtCore.Signal(QtCore.QModelIndex) status_changed = QtCore.Signal(int, int) STORAGE_NAME = '.filemon.dat' def __init__(self):...
[ "os.path.expanduser", "os.path.abspath", "PySide.QtCore.Slot", "os.getcwd", "PySide.QtGui.QDrag", "PySide.QtGui.QApplication.startDragDistance", "PySide.QtGui.QColor", "os.path.isfile", "subprocess.call", "PySide.QtGui.QFileSystemModel.__init__", "PySide.QtCore.Signal", "PySide.QtGui.QListView...
[((141, 156), 'PySide.QtCore.Signal', 'QtCore.Signal', ([], {}), '()\n', (154, 156), False, 'from PySide import QtGui, QtCore\n'), ((182, 215), 'PySide.QtCore.Signal', 'QtCore.Signal', (['QtCore.QModelIndex'], {}), '(QtCore.QModelIndex)\n', (195, 215), False, 'from PySide import QtGui, QtCore\n'), ((237, 260), 'PySide....
#!/usr/bin/env python3 # # MIT License # # Copyright (c) 2020 EntySec # # 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,...
[ "core.badges.badges" ]
[((1282, 1290), 'core.badges.badges', 'badges', ([], {}), '()\n', (1288, 1290), False, 'from core.badges import badges\n')]
# vim:fileencoding=UTF-8 # # Copyright ยฉ 2016, 2019 <NAME> # # Licensed under the Apache License, Version 2.0 with modifications, # (the "License"); you may not use this file except in compliance # with the License. You may obtain a copy of the License at # # https://raw.githubusercontent.com/StanLivitski/...
[ "version.requirePythonVersion" ]
[((1111, 1145), 'version.requirePythonVersion', 'version.requirePythonVersion', (['(3)', '(3)'], {}), '(3, 3)\n', (1139, 1145), False, 'import version\n')]
print('\nDevice Monitor') print('----------------') from qiskit import IBMQ from qiskit.tools.monitor import backend_overview IBMQ.enable_account('Insert API token here') # Insert your API token in to here provider = IBMQ.get_provider(hub='ibm-q') backend_overview() # Function to get all information back about each ...
[ "qiskit.IBMQ.enable_account", "qiskit.tools.monitor.backend_overview", "qiskit.IBMQ.get_provider" ]
[((128, 172), 'qiskit.IBMQ.enable_account', 'IBMQ.enable_account', (['"""Insert API token here"""'], {}), "('Insert API token here')\n", (147, 172), False, 'from qiskit import IBMQ\n'), ((219, 249), 'qiskit.IBMQ.get_provider', 'IBMQ.get_provider', ([], {'hub': '"""ibm-q"""'}), "(hub='ibm-q')\n", (236, 249), False, 'fro...
import copy class SquareAlgorithmNode(object): def __init__(self, x=0, y=0, width=0, height=0, used=False, down=None, right=None): """Node constructor. :param x: X coordinate. :param y: Y coordinate. :param width: Image width. :param height: Image height....
[ "copy.copy" ]
[((2132, 2147), 'copy.copy', 'copy.copy', (['self'], {}), '(self)\n', (2141, 2147), False, 'import copy\n'), ((2823, 2838), 'copy.copy', 'copy.copy', (['self'], {}), '(self)\n', (2832, 2838), False, 'import copy\n')]
import re import csv import codecs import json import os import environ from django.shortcuts import render, get_object_or_404 from django.http import ( HttpResponse, HttpResponseNotFound, ) from django.db.models import ( Q, F, Count, Sum ) from django.conf import settings from apps.data.model...
[ "csv.writer", "django.http.HttpResponse", "apps.article.models.Article.objects.filter", "json.dumps", "django.db.models.Q", "apps.data.helpers.stats.get_home_stats", "os.environ.get", "django.http.HttpResponseNotFound", "django.db.models.F", "apps.data.models.SimpleData.objects.filter", "apps.da...
[((1275, 1313), 'django.shortcuts.render', 'render', (['request', '"""index.html"""', 'context'], {}), "(request, 'index.html', context)\n", (1281, 1313), False, 'from django.shortcuts import render, get_object_or_404\n'), ((1356, 1395), 'django.shortcuts.render', 'render', (['request', '"""publishing-data.html"""'], {...
# -*- coding: utf-8 -*- from django.http import Http404, HttpResponseBadRequest, HttpResponseForbidden, HttpResponseNotAllowed from django.shortcuts import redirect from django.contrib import messages from bundestagger.helper.utils import is_post from bundestagger.account.auth import logged_in from bundestagger.accoun...
[ "django.shortcuts.redirect", "bundestagger.account.auth.logout", "bundestagger.account.models.User.objects.filter", "django.contrib.messages.add_message" ]
[((440, 460), 'bundestagger.account.auth.logout', 'logout_func', (['request'], {}), '(request)\n', (451, 460), True, 'from bundestagger.account.auth import logout as logout_func\n'), ((554, 568), 'django.shortcuts.redirect', 'redirect', (['next'], {}), '(next)\n', (562, 568), False, 'from django.shortcuts import redire...
"""Utility functions for neural networks.""" import numpy as np import torch def detach(states): """Truncate backpropagation (usually used in RNN).""" return [state.detach() for state in states] def hasnan(m): """Check if torch.tensor m have NaNs in it.""" return np.any(np.isnan(m.cpu().data.numpy()...
[ "torch.LongTensor" ]
[((1488, 1524), 'torch.LongTensor', 'torch.LongTensor', (['self.seqlengths[i]'], {}), '(self.seqlengths[i])\n', (1504, 1524), False, 'import torch\n')]
from image_comparison import compare_images import pytest import util_config import util_test @pytest.mark.parametrize("name", util_test.all_names()) def test_config_filled(name): config = util_config.ConfigFilled(name) image_buffer = config.save_to_buffer() compare_images(image_buffer, "config_filled.png...
[ "util_config.ConfigFilledCorner", "util_test.all_names", "util_test.quad_as_tri_names", "pytest.skip", "util_config.ConfigLines", "util_config.ConfigLinesCorner", "image_comparison.compare_images", "util_test.corner_mask_names", "util_config.ConfigFilled" ]
[((195, 225), 'util_config.ConfigFilled', 'util_config.ConfigFilled', (['name'], {}), '(name)\n', (219, 225), False, 'import util_config\n'), ((273, 328), 'image_comparison.compare_images', 'compare_images', (['image_buffer', '"""config_filled.png"""', 'name'], {}), "(image_buffer, 'config_filled.png', name)\n", (287, ...
# -*- coding: utf-8 -*- # Copyright 2018 <NAME> # Distributed under the terms of the Apache License 2.0 """ Test Aerial Objects ##################### """ import six import json import uuid import numpy as np from itertools import cycle from dronedirector.aerial import AerialObject, Drone, SinusoidalDrone class CaliRe...
[ "uuid.uuid4", "json.loads", "numpy.isclose", "numpy.arange", "itertools.cycle" ]
[((1186, 1220), 'numpy.isclose', 'np.isclose', (["msg['altitude']", '(100.0)'], {}), "(msg['altitude'], 100.0)\n", (1196, 1220), True, 'import numpy as np\n'), ((1288, 1300), 'uuid.uuid4', 'uuid.uuid4', ([], {}), '()\n', (1298, 1300), False, 'import uuid\n'), ((930, 945), 'json.loads', 'json.loads', (['msg'], {}), '(ms...
import asyncio import inspect import factory class AsyncFactory(factory.Factory): """ Copied from https://github.com/FactoryBoy/factory_boy/issues/679#issuecomment-673960170 """ class Meta: abstract = True @classmethod def _create(cls, model_class, *args, **kwargs): asyn...
[ "inspect.isawaitable" ]
[((559, 585), 'inspect.isawaitable', 'inspect.isawaitable', (['value'], {}), '(value)\n', (578, 585), False, 'import inspect\n')]
import os import cv2 import time import imutils import pyrebase import numpy as np from utils import * import sys import dlib from skimage import io #################### Initialize #################### print("Start initializing") os.environ['TF_CPP_MIN_LOG_LEVEL'] = '2' emotion_dict = {0: "Angry", 1: "Disgusted", ...
[ "os.path.basename", "numpy.argmax", "numpy.empty", "cv2.imread", "dlib.get_frontal_face_detector", "dlib.shape_predictor", "cv2.resize" ]
[((616, 648), 'dlib.get_frontal_face_detector', 'dlib.get_frontal_face_detector', ([], {}), '()\n', (646, 648), False, 'import dlib\n'), ((661, 697), 'dlib.shape_predictor', 'dlib.shape_predictor', (['predictor_path'], {}), '(predictor_path)\n', (681, 697), False, 'import dlib\n'), ((1460, 1508), 'cv2.imread', 'cv2.imr...
# laser_path_utils.py """Utility functions for working with paths for laser cutting""" import numpy as np import svgpathtools.svgpathtools as SVGPT # it's imporatant to clone and install the repo manually. The pip/pypi version is outdated from laser_svg_utils import tree_to_tempfile from laser_clipper import point_o...
[ "svgpathtools.svgpathtools.svg2paths", "numpy.angle", "svgpathtools.svgpathtools.parse_path", "laser_svg_utils.tree_to_tempfile", "laser_clipper.point_on_loops", "laser_clipper.point_inside_loop", "svgpathtools.svgpathtools.Path" ]
[((476, 506), 'svgpathtools.svgpathtools.svg2paths', 'SVGPT.svg2paths', (['temp_svg.name'], {}), '(temp_svg.name)\n', (491, 506), True, 'import svgpathtools.svgpathtools as SVGPT\n'), ((645, 667), 'laser_svg_utils.tree_to_tempfile', 'tree_to_tempfile', (['tree'], {}), '(tree)\n', (661, 667), False, 'from laser_svg_util...
import discord import os import requests,json import tweepy consumer_key=os.getenv('C_K') consumer_secret=os.getenv('C_S') access_token=os.getenv('A_T') access_token_secret=os.getenv('A_S') auth = tweepy.OAuthHandler(consumer_key, consumer_secret) auth.set_access_token(access_token, access_token_secret) api = tweepy...
[ "tweepy.API", "requests.get", "tweepy.OAuthHandler", "os.getenv", "discord.Client" ]
[((75, 91), 'os.getenv', 'os.getenv', (['"""C_K"""'], {}), "('C_K')\n", (84, 91), False, 'import os\n'), ((108, 124), 'os.getenv', 'os.getenv', (['"""C_S"""'], {}), "('C_S')\n", (117, 124), False, 'import os\n'), ((138, 154), 'os.getenv', 'os.getenv', (['"""A_T"""'], {}), "('A_T')\n", (147, 154), False, 'import os\n'),...
# Generated by Django 2.0.7 on 2019-05-08 12:22 from django.db import migrations, models import django.db.models.deletion class Migration(migrations.Migration): dependencies = [ ('app_warehouse', '0001_initial'), ] operations = [ migrations.AddField( model_name='cargoin', ...
[ "django.db.models.CharField", "django.db.models.IntegerField", "django.db.models.DateTimeField", "django.db.models.ForeignKey" ]
[((363, 434), 'django.db.models.CharField', 'models.CharField', ([], {'default': '"""default"""', 'max_length': '(20)', 'verbose_name': '"""ๅ…ฅๅบ“ๅŽŸๅ› """'}), "(default='default', max_length=20, verbose_name='ๅ…ฅๅบ“ๅŽŸๅ› ')\n", (379, 434), False, 'from django.db import migrations, models\n'), ((558, 632), 'django.db.models.IntegerFie...
#!/usr/bin/env python # -*- coding: utf-8 -*- # @Date : 2021-10-21 # @Author : iamwm from amp.broker.store import Store class Exchange: """ exchange of broker """ def __init__(self, name: str) -> None: self.name = name self.topic_manager = Store(Topic) def bind_topic(self, t...
[ "amp.broker.store.Store" ]
[((393, 408), 'amp.broker.store.Store', 'Store', (['Exchange'], {}), '(Exchange)\n', (398, 408), False, 'from amp.broker.store import Store\n'), ((280, 292), 'amp.broker.store.Store', 'Store', (['Topic'], {}), '(Topic)\n', (285, 292), False, 'from amp.broker.store import Store\n')]
# Copyright 2020 <NAME> # # 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 writi...
[ "torch.nn.Dropout", "torch.nn.Sequential", "torch.nn.Embedding", "torchvision.models.resnet50", "torch.cuda.is_available", "torch.nn.Linear", "torch.zeros", "torch.nn.LSTM", "torch.no_grad" ]
[((689, 714), 'torch.cuda.is_available', 'torch.cuda.is_available', ([], {}), '()\n', (712, 714), False, 'import torch\n'), ((883, 915), 'torchvision.models.resnet50', 'models.resnet50', ([], {'pretrained': '(True)'}), '(pretrained=True)\n', (898, 915), True, 'import torchvision.models as models\n'), ((1076, 1099), 'to...
from _pytest.mark import param import pytest import numpy as np from bayesian_mmm.sampling.stan_model_generator import StanModelGenerator from bayesian_mmm.sampling.sampler import Sampler from bayesian_mmm.sampling.stan_model_wrapper import StanModelWrapper MAX_LAG = 4 SPENDS = np.array([[10, 20], [0, 8], [1, 30], [5...
[ "bayesian_mmm.sampling.stan_model_generator.StanModelGenerator", "pytest.mark.parametrize", "numpy.array", "bayesian_mmm.sampling.sampler.Sampler" ]
[((281, 327), 'numpy.array', 'np.array', (['[[10, 20], [0, 8], [1, 30], [5, 40]]'], {}), '([[10, 20], [0, 8], [1, 30], [5, 40]])\n', (289, 327), True, 'import numpy as np\n'), ((344, 490), 'numpy.array', 'np.array', (['[[[10, 0, 0, 0], [20, 0, 0, 0]], [[0, 10, 0, 0], [8, 20, 0, 0]], [[1, 0, 10,\n 0], [30, 8, 20, 0]]...
from __future__ import unicode_literals import frappe from frappe.desk.doctype.notification_log.notification_log import enqueue_create_notification,\ get_title, get_title_html def execute(): set_title_wp_as_civil_id() set_title_mi_as_civil_id() set_title_moi_as_civil_id() set_title_fp_as_civil_id() d...
[ "frappe.get_doc", "frappe.get_all" ]
[((366, 395), 'frappe.get_all', 'frappe.get_all', (['"""Work Permit"""'], {}), "('Work Permit')\n", (380, 395), False, 'import frappe\n'), ((621, 656), 'frappe.get_all', 'frappe.get_all', (['"""Medical Insurance"""'], {}), "('Medical Insurance')\n", (635, 656), False, 'import frappe\n'), ((889, 928), 'frappe.get_all', ...
import json class Config: def __init__(self, file=None): with open(file) as cfg_file: self._cfg = json.load(cfg_file) self._scopes = [scope for scope in self._cfg['scopes']] self._scope_index = 0 self._current_scope: dict = self._scopes[0] def next_scope(self) -> b...
[ "json.load" ]
[((124, 143), 'json.load', 'json.load', (['cfg_file'], {}), '(cfg_file)\n', (133, 143), False, 'import json\n')]
import requests import pprint pp = pprint.PrettyPrinter(indent=4) # Example for making a GET requests link = 'http://localhost:5000/example-get-static' response = requests.get(link) responseDict = response.json() pp.pprint(responseDict) # access the dict print(responseDict['num-example']) # your name goes here na...
[ "pprint.PrettyPrinter", "requests.get" ]
[((36, 66), 'pprint.PrettyPrinter', 'pprint.PrettyPrinter', ([], {'indent': '(4)'}), '(indent=4)\n', (56, 66), False, 'import pprint\n'), ((166, 184), 'requests.get', 'requests.get', (['link'], {}), '(link)\n', (178, 184), False, 'import requests\n'), ((426, 445), 'requests.get', 'requests.get', (['link2'], {}), '(link...
from re import U from flask import Blueprint, render_template,request,flash,redirect,url_for from flask_login import login_required, current_user from .models import Pitch,User,Comment,Like from . import db views = Blueprint("views", __name__) @views.route("/") @views.route("/home") @login_required def home(): p...
[ "flask.flash", "flask.Blueprint", "flask.request.form.get", "flask.url_for", "flask.render_template" ]
[((216, 244), 'flask.Blueprint', 'Blueprint', (['"""views"""', '__name__'], {}), "('views', __name__)\n", (225, 244), False, 'from flask import Blueprint, render_template, request, flash, redirect, url_for\n'), ((356, 420), 'flask.render_template', 'render_template', (['"""home.html"""'], {'user': 'current_user', 'pitc...
from django.shortcuts import render, render_to_response from django import forms from django.http import HttpResponse from django.forms import ModelForm from user_manage.models import User from django.views.decorators.csrf import csrf_exempt from django.utils import timezone import requests from colock.key_generator ...
[ "colock.utils.hook", "django.shortcuts.render_to_response", "django.forms.IntegerField", "json.loads", "django.http.HttpResponse", "django.utils.timezone.now", "json.dumps", "requests.post", "django.forms.CharField", "user_manage.models.User.objects.get" ]
[((2660, 2674), 'colock.utils.hook', 'hook', (['"""verify"""'], {}), "('verify')\n", (2664, 2674), False, 'from colock.utils import hook\n'), ((570, 590), 'django.forms.IntegerField', 'forms.IntegerField', ([], {}), '()\n', (588, 590), False, 'from django import forms\n'), ((641, 661), 'django.forms.IntegerField', 'for...
""" This file contains strings which need i18n but doesn't have a place in any files. They maybe appear in DB only, so they can't be detected without being writed explicitly. """ from django.utils.translation import gettext_lazy as _ I18N_NEEDED = [ _('T00 member'), _('T01 member'), _('T02 member'), _(...
[ "django.utils.translation.gettext_lazy" ]
[((255, 270), 'django.utils.translation.gettext_lazy', '_', (['"""T00 member"""'], {}), "('T00 member')\n", (256, 270), True, 'from django.utils.translation import gettext_lazy as _\n'), ((276, 291), 'django.utils.translation.gettext_lazy', '_', (['"""T01 member"""'], {}), "('T01 member')\n", (277, 291), True, 'from dj...
#-*-coding:utf-8-*- import os import re import json import time import glob import random import argparse import numpy as np import pandas as pd from tqdm import tqdm import torch from torch.utils.data import DataLoader from transformers import AutoTokenizer, AutoModel from shiba import Shiba, CodepointTokenizer, get...
[ "argparse.ArgumentParser", "shiba.CodepointTokenizer", "utils.set_seed", "transformers.AutoModel.from_pretrained", "glob.glob", "torch.no_grad", "pandas.DataFrame", "torch.utils.data.DataLoader", "torch.load", "shiba.Shiba", "transformers.AutoTokenizer.from_pretrained", "torch.cuda.is_availabl...
[((580, 605), 'argparse.ArgumentParser', 'argparse.ArgumentParser', ([], {}), '()\n', (603, 605), False, 'import argparse\n'), ((1655, 1669), 'utils.set_seed', 'set_seed', (['SEED'], {}), '(SEED)\n', (1663, 1669), False, 'from utils import epoch_time, decode_attr_bio, operate_bio, set_seed\n'), ((1805, 1901), 'pandas.r...
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # theme and sys for linking signals import sys # other forms import managerMenu as managermenu import staffForm as staffform import stockForm as stockform import treatmentsForm as treatmentsform import appointmentForm as appointmentform import chartForm as chartform im...
[ "PyQt5.QtCore.pyqtSignal", "treatmentsForm.createTreatmentsForm", "PyQt5.QtWidgets.QSizePolicy", "PyQt5.QtWidgets.QPushButton", "customerForm.createCustomerForm", "appointmentForm.createAppointmentForm", "PyQt5.QtWidgets.QApplication", "PyQt5.QtWidgets.QToolBar", "managerMenu.createManagerMenu", "...
[((589, 604), 'PyQt5.QtCore.pyqtSignal', 'pyqtSignal', (['int'], {}), '(int)\n', (599, 604), False, 'from PyQt5.QtCore import pyqtSignal, QObject\n'), ((13442, 13474), 'PyQt5.QtWidgets.QApplication', 'QtWidgets.QApplication', (['sys.argv'], {}), '(sys.argv)\n', (13464, 13474), False, 'from PyQt5 import QtCore, QtGui, Q...
import cPickle def load_pickle(filename): pickled = open(filename, 'rb') data = cPickle.load(pickled) return data def export_pickle(filename, the_object): pickle_file = open(filename, 'w') cPickle.dump(the_object, pickle_file) pickle_file.close()
[ "cPickle.dump", "cPickle.load" ]
[((91, 112), 'cPickle.load', 'cPickle.load', (['pickled'], {}), '(pickled)\n', (103, 112), False, 'import cPickle\n'), ((214, 251), 'cPickle.dump', 'cPickle.dump', (['the_object', 'pickle_file'], {}), '(the_object, pickle_file)\n', (226, 251), False, 'import cPickle\n')]
# Licensed under an MIT open source license - see LICENSE ''' Test functions for Kurtosis ''' from unittest import TestCase import numpy as np import numpy.testing as npt from ..statistics import StatMoments, StatMomentsDistance from ._testing_data import \ dataset1, dataset2, computed_data, computed_distances...
[ "numpy.testing.assert_almost_equal", "numpy.allclose" ]
[((584, 656), 'numpy.allclose', 'np.allclose', (['self.tester.kurtosis_hist[1]', "computed_data['kurtosis_val']"], {}), "(self.tester.kurtosis_hist[1], computed_data['kurtosis_val'])\n", (595, 656), True, 'import numpy as np\n'), ((699, 771), 'numpy.allclose', 'np.allclose', (['self.tester.skewness_hist[1]', "computed_...
import datetime import requests from sdcclient._common import _SdcCommon class PolicyEventsClientV1(_SdcCommon): def __init__(self, token="", sdc_url='https://secure.sysdig.com', ssl_verify=True, custom_headers=None): super(PolicyEventsClientV1, self).__init__(token, sdc_url, ssl_verify, custom_headers)...
[ "datetime.datetime.utcnow", "datetime.datetime.utcfromtimestamp", "requests.get" ]
[((929, 1003), 'requests.get', 'requests.get', (['policy_events_url'], {'headers': 'self.hdrs', 'verify': 'self.ssl_verify'}), '(policy_events_url, headers=self.hdrs, verify=self.ssl_verify)\n', (941, 1003), False, 'import requests\n'), ((3868, 3894), 'datetime.datetime.utcnow', 'datetime.datetime.utcnow', ([], {}), '(...
import click from motor.motor_asyncio import AsyncIOMotorClient from pymongo.errors import CollectionInvalid from app import settings from scripts.utils import coro async def create_collection(db: AsyncIOMotorClient, collection_name: str): """ๅˆ›ๅปบ่กจ.""" try: await db[settings.MONGO_DB].create_collection...
[ "click.confirm", "click.echo", "motor.motor_asyncio.AsyncIOMotorClient", "click.command" ]
[((455, 478), 'click.command', 'click.command', (['"""initdb"""'], {}), "('initdb')\n", (468, 478), False, 'import click\n'), ((531, 572), 'click.confirm', 'click.confirm', (['"""ๅˆๅง‹ๅŒ–ๆ•ฐๆฎๅบ“ๅฏ่ƒฝไผšๅฏผ่‡ดๅŽŸๆ•ฐๆฎไธขๅคฑ๏ผŒ็กฎ่ฎค่ฆ็ปง็ปญๅ—๏ผŸ"""'], {}), "('ๅˆๅง‹ๅŒ–ๆ•ฐๆฎๅบ“ๅฏ่ƒฝไผšๅฏผ่‡ดๅŽŸๆ•ฐๆฎไธขๅคฑ๏ผŒ็กฎ่ฎค่ฆ็ปง็ปญๅ—๏ผŸ')\n", (544, 572), False, 'import click\n'), ((413, 451), 'click.echo', 'click...
# -*- coding: utf-8 -*- # --- # jupyter: # jupytext: # formats: ipynb,py:light # text_representation: # extension: .py # format_name: light # format_version: '1.5' # jupytext_version: 1.11.2 # kernelspec: # display_name: Python 3 # language: python # name: python3 # --- ...
[ "json.loads", "logging.basicConfig", "slogdata.show_times", "numpy.where", "pandas.read_sql", "logging.getLogger", "slogdata.mysql_socket" ]
[((723, 860), 'logging.basicConfig', 'logging.basicConfig', ([], {'level': 'logging.INFO', 'stream': 'stderr', 'format': '"""%(asctime)s %(levelname)s: %(message)s"""', 'datefmt': '"""%Y-%m-%d %H:%M:%S"""'}), "(level=logging.INFO, stream=stderr, format=\n '%(asctime)s %(levelname)s: %(message)s', datefmt='%Y-%m-%d %...
from guizero import App, Text, TextBox, Combo, PushButton, Box app = App() Text(app, text="My form") form = Box(app, width="fill", layout="grid") form.border = True Text(form, text="Title", grid=[0,0], align="right") TextBox(form, grid=[1,0]) Text(form, text="Name", grid=[0,1], align="right") TextBox(form, grid=[1...
[ "guizero.App", "guizero.TextBox", "guizero.PushButton", "guizero.Box", "guizero.Text" ]
[((70, 75), 'guizero.App', 'App', ([], {}), '()\n', (73, 75), False, 'from guizero import App, Text, TextBox, Combo, PushButton, Box\n'), ((77, 102), 'guizero.Text', 'Text', (['app'], {'text': '"""My form"""'}), "(app, text='My form')\n", (81, 102), False, 'from guizero import App, Text, TextBox, Combo, PushButton, Box...
# -*- coding: utf-8 -*- # Copyright 2017 <NAME> # See https://github.com/codingcatgirl/ttml2srt # # MIT License # # Copyright (c) 2017 <NAME> # # 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...
[ "datetime.timedelta", "re.match", "defusedxml.ElementTree.parse", "io.open" ]
[((1334, 1350), 'defusedxml.ElementTree.parse', 'ET.parse', (['infile'], {}), '(infile)\n', (1342, 1350), True, 'from defusedxml import ElementTree as ET\n'), ((2084, 2096), 'datetime.timedelta', 'timedelta', (['(0)'], {}), '(0)\n', (2093, 2096), False, 'from datetime import timedelta\n'), ((2115, 2175), 're.match', 'r...
# file: timer_decor.py import time class timer: def __init__(self, func): self.func = func self.alltime = 0 def __call__(self, *args, **kwargs): start = time.time() result = self.func(*args, **kwargs) elapsed = time.time() - start self.alltime += elapsed # ...
[ "time.time" ]
[((187, 198), 'time.time', 'time.time', ([], {}), '()\n', (196, 198), False, 'import time\n'), ((261, 272), 'time.time', 'time.time', ([], {}), '()\n', (270, 272), False, 'import time\n')]
import sys import pygame from pygame.locals import * import moyu_engine.config.data.constants as C import moyu_engine.config.system.assets_system import moyu_engine.config.system.tilemap_system import moyu_engine.config.system.move_system import moyu_engine.config.window.main_window def init(): pygame.init(...
[ "pygame.quit", "pygame.event.get", "pygame.display.set_mode", "pygame.mixer.init", "pygame.init", "pygame.display.flip", "pygame.display.update", "pygame.display.set_caption", "pygame.time.Clock", "sys.exit" ]
[((308, 321), 'pygame.init', 'pygame.init', ([], {}), '()\n', (319, 321), False, 'import pygame\n'), ((326, 345), 'pygame.mixer.init', 'pygame.mixer.init', ([], {}), '()\n', (343, 345), False, 'import pygame\n'), ((366, 425), 'pygame.display.set_mode', 'pygame.display.set_mode', (["C.window['size']", 'pygame.RESIZABLE'...
import inspect import logging import time from functools import wraps logger = logging.getLogger(__name__) def benchmark(method): """The following decorator aims at calculating the decorated function's execution time and is used to benchmark our various approaches and assist us in coming up with a compre...
[ "inspect.signature", "functools.wraps", "logging.getLogger", "time.time" ]
[((80, 107), 'logging.getLogger', 'logging.getLogger', (['__name__'], {}), '(__name__)\n', (97, 107), False, 'import logging\n'), ((374, 387), 'functools.wraps', 'wraps', (['method'], {}), '(method)\n', (379, 387), False, 'from functools import wraps\n'), ((1273, 1298), 'inspect.signature', 'inspect.signature', (['meth...
#! /usr/bin/env python3 # # Copyright 2019 Garmin Ltd. or its subsidiaries # # SPDX-License-Identifier: Apache-2.0 import os import sys import glob import re from scipy import stats import numpy THIS_DIR = os.path.dirname(os.path.realpath(__file__)) sys.path.append(os.path.join(THIS_DIR, 'poky', 'scripts', 'lib')) f...
[ "numpy.average", "os.path.basename", "numpy.std", "scipy.stats.ttest_rel", "os.path.realpath", "re.match", "os.path.join", "numpy.sqrt" ]
[((224, 250), 'os.path.realpath', 'os.path.realpath', (['__file__'], {}), '(__file__)\n', (240, 250), False, 'import os\n'), ((268, 316), 'os.path.join', 'os.path.join', (['THIS_DIR', '"""poky"""', '"""scripts"""', '"""lib"""'], {}), "(THIS_DIR, 'poky', 'scripts', 'lib')\n", (280, 316), False, 'import os\n'), ((1754, 1...
# use python3 import pandas as pd import matplotlib.pyplot as plt plt.rcParams.update({'figure.max_open_warning': 0}) from matplotlib import patches from matplotlib.pyplot import figure from datetime import timedelta, date def date_range(start_date, end_date): for n in range(int((end_date - start_date).days)):...
[ "matplotlib.pyplot.subplot", "matplotlib.pyplot.plot", "matplotlib.pyplot.clf", "matplotlib.pyplot.legend", "matplotlib.pyplot.yticks", "datetime.date", "matplotlib.pyplot.figure", "matplotlib.pyplot.rcParams.update", "matplotlib.pyplot.style.use", "matplotlib.pyplot.xticks", "datetime.timedelta...
[((68, 119), 'matplotlib.pyplot.rcParams.update', 'plt.rcParams.update', (["{'figure.max_open_warning': 0}"], {}), "({'figure.max_open_warning': 0})\n", (87, 119), True, 'import matplotlib.pyplot as plt\n'), ((1673, 1706), 'matplotlib.pyplot.figure', 'figure', ([], {'figsize': '(48, 10)', 'dpi': '(100)'}), '(figsize=(4...
""" xsede_perform_psf_test.py: get the preconditioned summed kernel for doing the PSF test. It's just the copy of xsede_perform_structure_inversion.py, but not submit the job3, and part of the job2 is contained into job1. useless flags may be possible to exist. """ import sys from os.path import join import click impo...
[ "click.option", "sh.pwd", "click.command", "sh.mkdir", "os.path.join" ]
[((1065, 1080), 'click.command', 'click.command', ([], {}), '()\n', (1078, 1080), False, 'import click\n'), ((1082, 1181), 'click.option', 'click.option', (['"""--base_directory"""'], {'required': '(True)', 'type': 'str', 'help': '"""the base inversion directory"""'}), "('--base_directory', required=True, type=str, hel...
# from __future__ import annotations from abc import ABCMeta, abstractmethod from typing import List, TypeVar, Dict from ..Peripheral_interface import Peripherical_interface class Gpu_interface(Peripherical_interface, metaclass=ABCMeta): _vendor: str _model: str @property def vendor(self) -> str: ...
[ "typing.TypeVar" ]
[((1206, 1247), 'typing.TypeVar', 'TypeVar', (['"""GpuType"""'], {'bound': '"""Gpu_interface"""'}), "('GpuType', bound='Gpu_interface')\n", (1213, 1247), False, 'from typing import List, TypeVar, Dict\n')]
# -*- coding: utf-8 -*- import base64 import hashlib import sublime, sublime_plugin import sys PYTHON = sys.version_info[0] if 3 == PYTHON: # Python 3 and ST3 from urllib import parse from . import codec_base62 from . import codec_base64 from . import codec_xml from . import codec_json fro...
[ "sublime.load_settings", "hashlib.new" ]
[((1462, 1498), 'sublime.load_settings', 'sublime.load_settings', (['SETTINGS_FILE'], {}), '(SETTINGS_FILE)\n', (1483, 1498), False, 'import sublime, sublime_plugin\n'), ((1634, 1670), 'sublime.load_settings', 'sublime.load_settings', (['SETTINGS_FILE'], {}), '(SETTINGS_FILE)\n', (1655, 1670), False, 'import sublime, s...
from interfaces.ANNIndexer import ANNIndexer import annoy # Usage : indexer = AnnoyIndexer(vector_length=100, n_trees=1000) class AnnoyIndexer(ANNIndexer): def __init__(self, content_vectors, vector_length=100, n_trees=10): print("initializing annoy wrapper") self.vector_length = vector_length self.n_tr...
[ "annoy.AnnoyIndex" ]
[((351, 382), 'annoy.AnnoyIndex', 'annoy.AnnoyIndex', (['vector_length'], {}), '(vector_length)\n', (367, 382), False, 'import annoy\n')]
import time import threading import numpy as np from common import preprocess_one_image_fn, draw_outputs, load_classes, generate_colors from yolo_utils import yolo_eval from priority_queue import PriorityQueue class YOLOv3Thread(threading.Thread): def __init__(self, runner: "Runner", deque_input, lock_input, ...
[ "common.preprocess_one_image_fn", "common.draw_outputs", "yolo_utils.yolo_eval", "priority_queue.PriorityQueue", "numpy.empty", "common.generate_colors", "common.load_classes" ]
[((651, 696), 'common.load_classes', 'load_classes', (['"""./model_data/adas_classes.txt"""'], {}), "('./model_data/adas_classes.txt')\n", (663, 696), False, 'from common import preprocess_one_image_fn, draw_outputs, load_classes, generate_colors\n'), ((719, 752), 'common.generate_colors', 'generate_colors', (['self.cl...
# WARNING: Please don't edit this file. It was generated by Python/WinRT v1.0.0-beta.4 import enum import winsdk _ns_module = winsdk._import_ns_module("Windows.Web.UI") try: import winsdk.windows.applicationmodel.datatransfer except Exception: pass try: import winsdk.windows.foundation except Exception...
[ "winsdk._import_ns_module" ]
[((129, 171), 'winsdk._import_ns_module', 'winsdk._import_ns_module', (['"""Windows.Web.UI"""'], {}), "('Windows.Web.UI')\n", (153, 171), False, 'import winsdk\n')]
import discord from discord.ext import commands import json import glob import time import os import motor.motor_asyncio as motor import logging import sys from cogs.utils.guild_features import GuildFeatures class Schezo(commands.Bot): __slots__ = 'config', 'start_time', '_cogs_loaded', 'db_client', 'db', 'logger'...
[ "discord.Activity", "json.load", "logging.FileHandler", "sys.modules.keys", "os.path.exists", "time.time", "logging.Formatter", "discord.Intents", "glob.glob", "cogs.utils.guild_features.GuildFeatures", "discord.ext.commands.is_owner", "logging.getLogger" ]
[((3002, 3021), 'discord.ext.commands.is_owner', 'commands.is_owner', ([], {}), '()\n', (3019, 3021), False, 'from discord.ext import commands\n'), ((682, 891), 'discord.Intents', 'discord.Intents', ([], {'presences': '(True)', 'members': '(True)', 'reactions': '(True)', 'messages': '(True)', 'guilds': '(True)', 'typin...
# Generated by Django 3.0.7 on 2020-07-04 10:55 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('photologue', '0012_auto_20200704_0747'), ] operations = [ migrations.AddField( model_name='photo', name='source', ...
[ "django.db.models.TextField" ]
[((336, 387), 'django.db.models.TextField', 'models.TextField', ([], {'blank': '(True)', 'verbose_name': '"""source"""'}), "(blank=True, verbose_name='source')\n", (352, 387), False, 'from django.db import migrations, models\n')]
"""Contains all automatically generated BinaryOps from CFFI. """ __all__ = [ "BinaryOp", "Accum", "current_binop", "current_accum", "binary_op", ] import sys import re import contextvars from itertools import chain from collections import defaultdict from functools import partial import numba fr...
[ "numba.types.CPointer", "tempfile.TemporaryFile", "numba.jit", "contextvars.ContextVar", "numba.cfunc", "re.compile" ]
[((390, 429), 'contextvars.ContextVar', 'contextvars.ContextVar', (['"""current_accum"""'], {}), "('current_accum')\n", (412, 429), False, 'import contextvars\n'), ((446, 485), 'contextvars.ContextVar', 'contextvars.ContextVar', (['"""current_binop"""'], {}), "('current_binop')\n", (468, 485), False, 'import contextvar...
import serial from time import sleep, localtime, strftime, time from smc100py3 import SMC100CC """ Controller class for stack of SMC100CC drivers. It makes easier to handle multiple controllers. Requires smc100py3.py module. Example: ConstructionDict = { 1 : (1, None, 0), 2 : (2, None,...
[ "smc100py3.SMC100CC", "time.time", "time.sleep" ]
[((1181, 1225), 'smc100py3.SMC100CC', 'SMC100CC', (['port', '*ConstructionDict[MasterKey]'], {}), '(port, *ConstructionDict[MasterKey])\n', (1189, 1225), False, 'from smc100py3 import SMC100CC\n'), ((1335, 1349), 'time.sleep', 'sleep', (['self.dT'], {}), '(self.dT)\n', (1340, 1349), False, 'from time import sleep, loca...
################################################################################# # ConstrainedPlanningToolbox # Copyright (C) 2019 Algorithmics group, Delft University of Technology # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as publis...
[ "model.BeliefPoint.BeliefPoint" ]
[((6870, 6893), 'model.BeliefPoint.BeliefPoint', 'BeliefPoint', (['new_belief'], {}), '(new_belief)\n', (6881, 6893), False, 'from model.BeliefPoint import BeliefPoint\n')]
import warnings warnings.filterwarnings('ignore') import tensorflow as tf from tensorflow.examples.tutorials import mnist import numpy as np import os import random from scipy import misc import time import sys #from draw import viz_data, x, A, B, read_n, T #from drawCopy1 import viz_data, x, A, B, read_n, T #from dra...
[ "tensorflow.train.Saver", "warnings.filterwarnings", "tensorflow.examples.tutorials.mnist.input_data.read_data_sets", "tensorflow.ConfigProto", "random.randrange", "numpy.array", "tensorflow.InteractiveSession" ]
[((16, 49), 'warnings.filterwarnings', 'warnings.filterwarnings', (['"""ignore"""'], {}), "('ignore')\n", (39, 49), False, 'import warnings\n'), ((486, 502), 'tensorflow.ConfigProto', 'tf.ConfigProto', ([], {}), '()\n', (500, 502), True, 'import tensorflow as tf\n'), ((554, 595), 'tensorflow.InteractiveSession', 'tf.In...
import argparse from pathlib import Path from typing import Any, Optional, Sequence, Union class FullDirPath(argparse.Action): """ argparse.Action subclass to resolve a path and make sure it's a directory """ def __call__( self, parse: argparse.ArgumentParser, namespace: argpa...
[ "argparse.ArgumentTypeError" ]
[((715, 777), 'argparse.ArgumentTypeError', 'argparse.ArgumentTypeError', (['f"""{self.dest} must be a directory"""'], {}), "(f'{self.dest} must be a directory')\n", (741, 777), False, 'import argparse\n')]
# Generated by Django 2.0.1 on 2018-03-22 20:14 from django.db import migrations, models import django.utils.timezone import model_utils.fields class Migration(migrations.Migration): initial = True dependencies = [ ] operations = [ migrations.CreateModel( name='Configuration', ...
[ "django.db.models.ImageField", "django.db.models.EmailField", "django.db.models.CharField", "django.db.models.AutoField" ]
[((364, 457), 'django.db.models.AutoField', 'models.AutoField', ([], {'auto_created': '(True)', 'primary_key': '(True)', 'serialize': '(False)', 'verbose_name': '"""ID"""'}), "(auto_created=True, primary_key=True, serialize=False,\n verbose_name='ID')\n", (380, 457), False, 'from django.db import migrations, models\...