code
stringlengths
20
1.04M
apis
list
extract_api
stringlengths
75
9.94M
# This file is part of the GBI project. # Copyright (C) 2012 Omniscale GmbH & Co. KG <http://omniscale.com> # # 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/licens...
[ "threading.Thread.__init__", "os.path.exists", "geobox.lib.config.path", "time.sleep" ]
[((911, 940), 'os.path.exists', 'os.path.exists', (['user_log_file'], {}), '(user_log_file)\n', (925, 940), False, 'import os\n'), ((1283, 1314), 'threading.Thread.__init__', 'threading.Thread.__init__', (['self'], {}), '(self)\n', (1308, 1314), False, 'import threading\n'), ((1088, 1124), 'geobox.lib.config.path', 'pa...
from datetime import datetime, timezone from fastapi.testclient import TestClient from sqlalchemy.orm import Session import mlrun.api.schemas from mlrun.api.utils.singletons.db import get_db from mlrun.api.utils.singletons.k8s import get_k8s from mlrun.runtimes import RuntimeKinds, get_runtime_handler from mlrun.runt...
[ "mlrun.api.utils.singletons.k8s.get_k8s", "mlrun.api.utils.singletons.db.get_db", "mlrun.runtimes.get_runtime_handler", "datetime.datetime.now" ]
[((549, 588), 'mlrun.runtimes.get_runtime_handler', 'get_runtime_handler', (['RuntimeKinds.spark'], {}), '(RuntimeKinds.spark)\n', (568, 588), False, 'from mlrun.runtimes import RuntimeKinds, get_runtime_handler\n'), ((4969, 4977), 'mlrun.api.utils.singletons.db.get_db', 'get_db', ([], {}), '()\n', (4975, 4977), False,...
import datetime from pathlib import Path import os from typing import NamedTuple from poi import __version__, Sheet, Col, Row, Cell, Table from poi.nodes import Image def test_version(): assert __version__ == "0.2.8" def assert_match_snapshot(sheet: Sheet, snapshot): actual = sheet.write_to_bytes_io().rea...
[ "poi.Table", "os.path.dirname", "poi.nodes.Image", "poi.Cell", "datetime.datetime.now" ]
[((1915, 2172), 'poi.Table', 'Table', ([], {'data': 'data', 'columns': 'columns', 'col_width': '(20)', 'row_height': '(lambda : 100)', 'cell_style': "{'bg_color: yellow; text_wrap: true;': lambda record, col: col.attr ==\n 'name' and record.name == 'name 1'}", 'date_format': '"""yyyy-mm-dd"""', 'align': '"""center""...
# # Copyright (c) 2010 <NAME>. All rights reserved. # """Tests for SpellingBuilder """ import pytest import codecs import io import os import textwrap from sphinx.application import Sphinx @pytest.fixture def sphinx_project(tmpdir): srcdir = tmpdir.mkdir('src') outdir = tmpdir.mkdir('out') add_file(sr...
[ "textwrap.dedent", "io.StringIO", "codecs.open", "sphinx.application.Sphinx", "os.path.join" ]
[((619, 632), 'io.StringIO', 'io.StringIO', ([], {}), '()\n', (630, 632), False, 'import io\n'), ((646, 659), 'io.StringIO', 'io.StringIO', ([], {}), '()\n', (657, 659), False, 'import io\n'), ((670, 771), 'sphinx.application.Sphinx', 'Sphinx', (['srcdir', 'srcdir', 'outdir', 'outdir', '"""spelling"""'], {'status': 'st...
import numpy as np import tensorflow as tf import pandas as pd import matplotlib.pyplot as plt import config tfrecords_filename = config.data_tmp_folder + config.data_tfrecord_filename record_iterator = tf.python_io.tf_record_iterator(path=tfrecords_filename) for string_record in record_iterator: # Parse the next...
[ "tensorflow.train.Example", "matplotlib.pyplot.show", "numpy.fromstring", "tensorflow.python_io.tf_record_iterator" ]
[((204, 260), 'tensorflow.python_io.tf_record_iterator', 'tf.python_io.tf_record_iterator', ([], {'path': 'tfrecords_filename'}), '(path=tfrecords_filename)\n', (235, 260), True, 'import tensorflow as tf\n'), ((343, 361), 'tensorflow.train.Example', 'tf.train.Example', ([], {}), '()\n', (359, 361), True, 'import tensor...
import json from CSRandom import CSRandomLite as CSRandom with open('RandomBundles.json', 'r') as f: randomBundleData = json.load(f) seasonalIds = { "Hazelnut": 408, "Snow Yam": 416, "Crocus": 418, "Holly": 283, "Eggplant": 272, "Pumpkin": 276, "Summer Spangle": 593, ...
[ "json.load", "CSRandom.CSRandomLite" ]
[((129, 141), 'json.load', 'json.load', (['f'], {}), '(f)\n', (138, 141), False, 'import json\n'), ((1774, 1792), 'CSRandom.CSRandomLite', 'CSRandom', (['(seed * 9)'], {}), '(seed * 9)\n', (1782, 1792), True, 'from CSRandom import CSRandomLite as CSRandom\n')]
# Unless explicitly stated otherwise all files in this repository are licensed under the Apache-2.0 License. # This product includes software developed at Datadog (https://www.datadoghq.com/). # Copyright 2019-Present Datadog, Inc. import re # noqa: F401 import sys # noqa: F401 from datadog_api_client.v2.api_clien...
[ "datadog_api_client.v2.api_client.ApiClient", "datadog_api_client.v2.api_client.Endpoint" ]
[((1095, 2183), 'datadog_api_client.v2.api_client.Endpoint', '_Endpoint', ([], {'settings': "{'response_type': (ProcessSummariesResponse,), 'auth': ['AuthZ',\n 'apiKeyAuth', 'appKeyAuth'], 'endpoint_path': '/api/v2/processes',\n 'operation_id': 'list_processes', 'http_method': 'GET', 'servers': None}", 'params_ma...
import pygame import numpy as np def new_board(matrix): def m(mat, index): m_index = mat.copy() if index == 1: return m_index[::-1, ::-1].T elif index == 2: m_index += 4 ** dim return m_index elif index == 3: m_index += 2 * 4 ** dim ...
[ "pygame.draw.line", "pygame.event.get", "pygame.display.set_mode", "pygame.init", "pygame.display.update", "numpy.array", "numpy.concatenate" ]
[((1052, 1078), 'numpy.array', 'np.array', (['[[2, 3], [1, 4]]'], {}), '([[2, 3], [1, 4]])\n', (1060, 1078), True, 'import numpy as np\n'), ((1080, 1093), 'pygame.init', 'pygame.init', ([], {}), '()\n', (1091, 1093), False, 'import pygame\n'), ((1103, 1157), 'pygame.display.set_mode', 'pygame.display.set_mode', (['(SCR...
import configparser import logging import logging.config import google.cloud.logging import json from flask import Flask from flask_sqlalchemy import SQLAlchemy import re def to_snake(word): return re.sub('([A-Z]\w+$)', '_\\1', word).lower() def to_camel(word): components = word.s...
[ "io.StringIO", "flask_migrate.migrate", "flask_migrate.upgrade", "sys.stdout.flush", "contextlib.redirect_stdout", "re.sub", "logging.config.fileConfig", "logging.getLogger" ]
[((1123, 1171), 'logging.config.fileConfig', 'logging.config.fileConfig', (['"""config/logging.conf"""'], {}), "('config/logging.conf')\n", (1148, 1171), False, 'import logging\n'), ((1203, 1228), 'logging.getLogger', 'logging.getLogger', (['"""root"""'], {}), "('root')\n", (1220, 1228), False, 'import logging\n'), ((1...
# coding=utf-8 import os import sys import signal from lxml import etree import numpy as np #filter parametres min_surface=150.00 #Å^2 (Square Ångström) min_glycine_ratio = 0.3 sym_op="x,y,z" file_intro="Results for each class.\nOnly protein-ligand interfaces with a surface greater than "+str(min_surface)+"...
[ "os.remove", "os.path.dirname", "numpy.loadtxt", "lxml.etree.parse", "sys.exit" ]
[((5294, 5350), 'numpy.loadtxt', 'np.loadtxt', (['path_input'], {'delimiter': '""","""', 'dtype': 'np.unicode_'}), "(path_input, delimiter=',', dtype=np.unicode_)\n", (5304, 5350), True, 'import numpy as np\n'), ((4963, 4992), 'os.path.dirname', 'os.path.dirname', (['path_results'], {}), '(path_results)\n', (4978, 4992...
import os, shutil import webbrowser DOCSRC, DOCS = "docsrc", "docs" def external_run(os_cmd): print(f"\n--- Running: {os_cmd}") errcode = os.system(os_cmd) if errcode > 0: exit() print(f"--- Complete: {os_cmd}") def copy_dir(dir_src, dir_des, delete_src=False): """Overwrite/create the dir...
[ "shutil.rmtree", "os.path.isdir", "os.path.exists", "os.system", "shutil.copytree", "os.path.join" ]
[((148, 165), 'os.system', 'os.system', (['os_cmd'], {}), '(os_cmd)\n', (157, 165), False, 'import os, shutil\n'), ((353, 375), 'os.path.isdir', 'os.path.isdir', (['dir_des'], {}), '(dir_des)\n', (366, 375), False, 'import os, shutil\n'), ((412, 445), 'shutil.copytree', 'shutil.copytree', (['dir_src', 'dir_des'], {}), ...
#!/usr/bin/env python # Centralised code to set model and experiment names. # This is just an initial stab at it. More functionality is planned: # https://github.com/OceansAus/ACCESS-OM2-1-025-010deg-report/issues/6 # load this with # import sys, os # sys.path.append(os.path.join(os.getcwd(), '..')) # so we...
[ "numpy.flip", "argparse.ArgumentParser", "pandas.to_datetime", "numpy.ma.concatenate", "collections.OrderedDict", "pandas.DateOffset", "os.path.join", "numpy.concatenate" ]
[((1393, 1951), 'collections.OrderedDict', 'OrderedDict', (["[('1deg', {'model': 'access-om2', 'expt': '1deg_jra55v13_iaf_spinup1_B1',\n 'desc': 'ACCESS-OM2', 'n_files': -12, 'time_units':\n 'days since 1718-01-01', 'offset': '2880M'}), ('025deg', {'model':\n 'access-om2-025', 'expt': '025deg_jra55v13_iaf_gmre...
import json import os import logging import boto3 import base64 import sys from urllib.parse import parse_qs from dynamodb_functions import putToDynamo from slack_bolt import App from slack_bolt.adapter.aws_lambda import SlackRequestHandler # SETUP LOGGING OPTIONS logging.basicConfig(stream=sys.stdout) log = logging...
[ "logging.basicConfig", "slack_bolt.adapter.aws_lambda.SlackRequestHandler.clear_all_log_handlers", "boto3.client", "dynamodb_functions.putToDynamo", "slack_bolt.adapter.aws_lambda.SlackRequestHandler", "logging.getLogger", "slack_bolt.App" ]
[((268, 306), 'logging.basicConfig', 'logging.basicConfig', ([], {'stream': 'sys.stdout'}), '(stream=sys.stdout)\n', (287, 306), False, 'import logging\n'), ((313, 354), 'logging.getLogger', 'logging.getLogger', (['"""slack-automation-bot"""'], {}), "('slack-automation-bot')\n", (330, 354), False, 'import logging\n'), ...
# coding: utf-8 import dataclasses import abc import serpyco import typing from urllib.parse import urlencode from guilang.description import Description from rolling.model.event import WebSocketEvent from rolling.rolling_types import ActionType from rolling.server.controller.url import CHARACTER_ACTION from rolling....
[ "rolling.server.controller.url.WITH_CHARACTER_ACTION.format", "urllib.parse.urlencode", "rolling.server.controller.url.WITH_RESOURCE_ACTION.format", "rolling.server.controller.url.CHARACTER_ACTION.format" ]
[((1230, 1361), 'rolling.server.controller.url.CHARACTER_ACTION.format', 'CHARACTER_ACTION.format', ([], {'character_id': 'character_id', 'action_type': 'action_type.value', 'action_description_id': 'action_description_id'}), '(character_id=character_id, action_type=action_type.\n value, action_description_id=action...
# 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, software # distributed under t...
[ "tests.ui_tests.app.helpers.locator.Locator", "tests.ui_tests.app.helpers.locator.TemplateLocator" ]
[((771, 864), 'tests.ui_tests.app.helpers.locator.Locator', 'Locator', (['By.XPATH', '"""//*[contains(@class, \'mat-progress-bar-background\')]"""', '"""Loading info"""'], {}), '(By.XPATH, "//*[contains(@class, \'mat-progress-bar-background\')]",\n \'Loading info\')\n', (778, 864), False, 'from tests.ui_tests.app.he...
# -*- coding: utf-8 -*- # @Time : 2018/11/22 17:01 # @Author : MengnanChen # @FileName: feeder.py # @Software: PyCharm import numpy as np from sklearn.utils import shuffle import tensorflow as tf from . import text from . import hparams as hp class Feeder: def __init__(self, data_paths, labels, sess): ...
[ "numpy.asarray", "tensorflow.device", "tensorflow.data.Dataset.from_tensor_slices", "tensorflow.placeholder", "sklearn.utils.shuffle", "numpy.concatenate" ]
[((1688, 1705), 'numpy.asarray', 'np.asarray', (['datas'], {}), '(datas)\n', (1698, 1705), True, 'import numpy as np\n'), ((1726, 1749), 'numpy.asarray', 'np.asarray', (['seq_lengths'], {}), '(seq_lengths)\n', (1736, 1749), True, 'import numpy as np\n'), ((1772, 1797), 'numpy.asarray', 'np.asarray', (['ground_truths'],...
# -*- coding:utf-8 -*- """ @author:SiriYang @file:main.py @time:2020/4/15 18:48 """ import sys import sip from PyQt5.QtWidgets import QApplication from MainWindow import MainWindow def main(): app = QApplication(sys.argv) mw = MainWindow() mw.show() sys.exit(app.exec_()) if __name__ == '__main__': ...
[ "PyQt5.QtWidgets.QApplication", "MainWindow.MainWindow" ]
[((207, 229), 'PyQt5.QtWidgets.QApplication', 'QApplication', (['sys.argv'], {}), '(sys.argv)\n', (219, 229), False, 'from PyQt5.QtWidgets import QApplication\n'), ((239, 251), 'MainWindow.MainWindow', 'MainWindow', ([], {}), '()\n', (249, 251), False, 'from MainWindow import MainWindow\n')]
import pytest import torch from cplxmodule.nn.masked import LinearMasked def test_emptymask(): lin = LinearMasked(11, 13) with pytest.raises(RuntimeError, match=r"has no sparsity mask"): lin.weight_masked with pytest.raises(RuntimeError, match=r"has no sparsity mask"): lin(torch.ones(1,...
[ "torch.ones", "torch.randint", "torch.broadcast_tensors", "cplxmodule.nn.masked.LinearMasked", "pytest.raises", "torch.nn.Linear", "torch.allclose", "torch.tensor" ]
[((108, 128), 'cplxmodule.nn.masked.LinearMasked', 'LinearMasked', (['(11)', '(13)'], {}), '(11, 13)\n', (120, 128), False, 'from cplxmodule.nn.masked import LinearMasked\n'), ((388, 408), 'cplxmodule.nn.masked.LinearMasked', 'LinearMasked', (['*shape'], {}), '(*shape)\n', (400, 408), False, 'from cplxmodule.nn.masked ...
from http.server import HTTPServer as BaseHTTPServer, SimpleHTTPRequestHandler import os, sys, getopt, logging, threading, json, socket import glob2, pickle import numpy as np from PIL import Image from extractor import ImageFeatureExtractor from datetime import datetime from flask import Flask, request, render_templat...
[ "getopt.getopt", "http.server.HTTPServer.__init__", "glob2.glob", "json.dumps", "numpy.argsort", "numpy.linalg.norm", "os.path.join", "os.path.dirname", "flask.render_template", "datetime.datetime.now", "extractor.ImageFeatureExtractor", "threading.Thread", "os.path.basename", "os.system",...
[((1857, 1886), 'logging.getLogger', 'logging.getLogger', (['"""werkzeug"""'], {}), "('werkzeug')\n", (1874, 1886), False, 'import os, sys, getopt, logging, threading, json, socket\n'), ((1362, 1393), 'getopt.getopt', 'getopt.getopt', (['sys.argv', '"""p:d:"""'], {}), "(sys.argv, 'p:d:')\n", (1375, 1393), False, 'impor...
### # Copyright 2017 <NAME>, Inc. 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 or...
[ "sys.stdout.write", "redfish.ris.rmc_helper.IdTokenError", "rdmc_helper.InvalidCommandLineErrorOPTS", "rdmc_helper.NoContentsFoundForOperationError", "rdmc_helper.IncompatibleiLOVersionError", "re.match", "rdmc_helper.InvalidCommandLineError" ]
[((6621, 6720), 'rdmc_helper.IncompatibleiLOVersionError', 'IncompatibleiLOVersionError', (['"""Directory settings are only available on iLO 5 1.40 or greater."""'], {}), "(\n 'Directory settings are only available on iLO 5 1.40 or greater.')\n", (6648, 6720), False, 'from rdmc_helper import ReturnCodes, InvalidComm...
import matplotlib.pyplot as plt import numpy as np import pandas as pd import seaborn as sns from pretty_confusion_matrix import pp_matrix, pp_matrix_from_data # np.set_printoptions(precision=5, suppress= True) #NOTE https://github.com/DTrimarchi10/confusion_matrix.git path_csv = r'evaluation.csv' table = pd.read_cs...
[ "pandas.read_csv", "pretty_confusion_matrix.pp_matrix_from_data" ]
[((310, 331), 'pandas.read_csv', 'pd.read_csv', (['path_csv'], {}), '(path_csv)\n', (321, 331), True, 'import pandas as pd\n'), ((943, 1021), 'pretty_confusion_matrix.pp_matrix_from_data', 'pp_matrix_from_data', ([], {'y_test': 'gt', 'predictions': 'pred', 'columns': 'classes', 'cmap': '"""RdBu"""'}), "(y_test=gt, pred...
#!/usr/bin/env python import json import unittest import pyangbind.lib.pybindJSON as pbJ from pyangbind.lib.yangtypes import safe_name from tests.base import PyangBindTestCase class PresenceTests(PyangBindTestCase): yang_files = ["presence.yang"] pyang_flags = ["--use-extmethods", "--presence"] def set...
[ "unittest.main", "json.loads", "pyangbind.lib.yangtypes.safe_name", "pyangbind.lib.pybindJSON.loads_ietf", "pyangbind.lib.pybindJSON.dumps", "pyangbind.lib.pybindJSON.loads" ]
[((4108, 4123), 'unittest.main', 'unittest.main', ([], {}), '()\n', (4121, 4123), False, 'import unittest\n'), ((3671, 3715), 'pyangbind.lib.pybindJSON.loads', 'pbJ.loads', (['inputJ', 'self.bindings', '"""presence"""'], {}), "(inputJ, self.bindings, 'presence')\n", (3680, 3715), True, 'import pyangbind.lib.pybindJSON ...
from sqlalchemy import Column, String, Integer, Boolean, DateTime from sqlalchemy.schema import ForeignKey from sqlalchemy.ext.declarative import declarative_base from backend import db_session Base = declarative_base() Base.query = db_session.query_property() class Session(Base): __tablename__ = 'sessions' ...
[ "sqlalchemy.String", "sqlalchemy.ext.declarative.declarative_base", "backend.db_session.query_property", "sqlalchemy.Column" ]
[((203, 221), 'sqlalchemy.ext.declarative.declarative_base', 'declarative_base', ([], {}), '()\n', (219, 221), False, 'from sqlalchemy.ext.declarative import declarative_base\n'), ((235, 262), 'backend.db_session.query_property', 'db_session.query_property', ([], {}), '()\n', (260, 262), False, 'from backend import db_...
# # Copyright 2018 Analytics Zoo 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...
[ "bigdl.util.common.callBigDlFunc", "bigdl.util.common.JavaValue.jvm_class_constructor" ]
[((2309, 2366), 'bigdl.util.common.callBigDlFunc', 'callBigDlFunc', (['self.bigdl_type', '"""getLabelMap"""', 'self.value'], {}), "(self.bigdl_type, 'getLabelMap', self.value)\n", (2322, 2366), False, 'from bigdl.util.common import callBigDlFunc\n'), ((2504, 2541), 'bigdl.util.common.JavaValue.jvm_class_constructor', '...
import mhrn import sixdegrees import networkx as nx import numpy as np import time import scipy.sparse as sprs import progressbar B = 10 L = 5 k = 6 xi = 0.3 N_meas = 10 k_nx, k_c = 0.0, 0.0 t_nx, t_c = 0.0, 0.0 seed = 1 print("measuring only creation") bar = progressbar.ProgressBar() for meas in bar(range(N_mea...
[ "networkx.to_scipy_sparse_matrix", "numpy.ones_like", "mhrn.fast_mhr_graph", "time.time", "scipy.sparse.csr_matrix", "numpy.array", "sixdegrees.modular_hierarchical_network_coord_lists", "networkx.connected_component_subgraphs", "progressbar.ProgressBar", "sixdegrees.modular_hierarchical_network" ...
[((267, 292), 'progressbar.ProgressBar', 'progressbar.ProgressBar', ([], {}), '()\n', (290, 292), False, 'import progressbar\n'), ((897, 922), 'progressbar.ProgressBar', 'progressbar.ProgressBar', ([], {}), '()\n', (920, 922), False, 'import progressbar\n'), ((349, 360), 'time.time', 'time.time', ([], {}), '()\n', (358...
# -*- coding: utf-8 -*- """ Created on Sat May 1 21:13:27 2021 @author: <NAME> Date: 5.1.21 guid_generator.py description: creating functions to create guids by parameter """ # import libraries # Import the random library and set the seed import random random.seed() # guid_hex_generate() # returns a string ...
[ "random.seed", "random.choice" ]
[((260, 273), 'random.seed', 'random.seed', ([], {}), '()\n', (271, 273), False, 'import random\n'), ((603, 627), 'random.choice', 'random.choice', (['HEX_CHARS'], {}), '(HEX_CHARS)\n', (616, 627), False, 'import random\n')]
from discord.ext import commands, tasks from .utils import db, checks from collections import Counter, defaultdict import discord import asyncio import asyncpg import datetime import logging import yarl import re import io log = logging.getLogger(__name__) BLOB_GUILD_ID = 272885620769161216 EMOJI_REGEX = re.compile...
[ "discord.Embed", "discord.ext.commands.PartialEmojiConverter", "logging.getLogger", "collections.defaultdict", "asyncio.wait_for", "discord.ext.commands.command", "discord.File", "discord.ext.commands.Cog.listener", "discord.ext.commands.group", "discord.ext.commands.guild_only", "io.BytesIO", ...
[((232, 259), 'logging.getLogger', 'logging.getLogger', (['__name__'], {}), '(__name__)\n', (249, 259), False, 'import logging\n'), ((310, 347), 're.compile', 're.compile', (['"""<a?:.+?:([0-9]{15,21})>"""'], {}), "('<a?:.+?:([0-9]{15,21})>')\n", (320, 347), False, 'import re\n'), ((368, 402), 're.compile', 're.compile...
""" LLVM IR modules. Functions for working with modules and parameters in them. """ from diffkemp.simpll.library import SimpLLModule from diffkemp.simpll._simpll.lib import shutdownSimpLL import os import re import shutil from subprocess import check_call, CalledProcessError # Set of standard functions that are suppo...
[ "diffkemp.simpll._simpll.lib.shutdownSimpLL", "os.path.relpath", "shutil.copyfile", "diffkemp.simpll.library.SimpLLModule", "subprocess.check_call", "re.compile" ]
[((2135, 2151), 'diffkemp.simpll._simpll.lib.shutdownSimpLL', 'shutdownSimpLL', ([], {}), '()\n', (2149, 2151), False, 'from diffkemp.simpll._simpll.lib import shutdownSimpLL\n'), ((7030, 7103), 're.compile', 're.compile', (['"""filename:\\\\s*\\\\"([^\\\\"]*)\\\\", directory:\\\\s*\\\\"([^\\\\"]*)\\\\\\""""'], {}), '(...
# -------------------------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for license information. # -----------------------------------------------------------------...
[ "knack.log.get_logger" ]
[((477, 497), 'knack.log.get_logger', 'get_logger', (['__name__'], {}), '(__name__)\n', (487, 497), False, 'from knack.log import get_logger\n')]
import logging import os import sys import click logger = logging.getLogger(__name__) ## # Common click "options" for some subcommands ## _click_option_project_dir = click.option( '--project-dir', default=lambda: os.getcwd(), help='Project director' ) _click_option_board_manager_script = click.option( '...
[ "vznncv.mbed.greentea._mbed_cli.run_mbed_cli_command", "mbed_os_tools.test.mbed_test_api.log_mbed_devices_in_table", "vznncv.mbed.greentea._test_builder.build_main", "logging.basicConfig", "os.getcwd", "vznncv.mbed.greentea._test_runner.flash_artifact", "os.environ.items", "click.option", "vznncv.mb...
[((60, 87), 'logging.getLogger', 'logging.getLogger', (['__name__'], {}), '(__name__)\n', (77, 87), False, 'import logging\n'), ((301, 412), 'click.option', 'click.option', (['"""-s"""', '"""--board-manager-script"""'], {'help': '"""Custom script that detect targets and upload firmware"""'}), "('-s', '--board-manager-s...
import networkx as nx class BaseTestAttributeMixing(object): def setUp(self): G=nx.Graph() G.add_nodes_from([0,1],fish='one') G.add_nodes_from([2,3],fish='two') G.add_nodes_from([4],fish='red') G.add_nodes_from([5],fish='blue') G.add_edges_from([(0,1)...
[ "networkx.MultiGraph", "networkx.DiGraph", "networkx.path_graph", "networkx.Graph" ]
[((103, 113), 'networkx.Graph', 'nx.Graph', ([], {}), '()\n', (111, 113), True, 'import networkx as nx\n'), ((372, 384), 'networkx.DiGraph', 'nx.DiGraph', ([], {}), '()\n', (382, 384), True, 'import networkx as nx\n'), ((643, 658), 'networkx.MultiGraph', 'nx.MultiGraph', ([], {}), '()\n', (656, 658), True, 'import netw...
if __name__ == "__main__": from Clases.Insercion_dicotonomica import Dicotonomia_1, Dicotonomia_2 print ("Ejercicio 1:") print ("Apartado 1") tabla = [4,2,6,3,8,7,5,9,1,0] print (tabla) #Definimos nuestra unica instancia de clase resultado = Dicotonomia_1(tabla) print ("La tabla ordenad...
[ "Clases.Insercion_dicotonomica.Dicotonomia_1", "Clases.Insercion_dicotonomica.Dicotonomia_2", "Clases.Ordenacion_topologica.Lista", "Clases.Explorar.Segmento" ]
[((271, 291), 'Clases.Insercion_dicotonomica.Dicotonomia_1', 'Dicotonomia_1', (['tabla'], {}), '(tabla)\n', (284, 291), False, 'from Clases.Insercion_dicotonomica import Dicotonomia_1, Dicotonomia_2\n'), ((418, 438), 'Clases.Insercion_dicotonomica.Dicotonomia_2', 'Dicotonomia_2', (['tabla'], {}), '(tabla)\n', (431, 438...
from dataclasses import dataclass, field import turing.generated.models from typing import List, Dict, Union from turing.generated.model_utils import OpenApiModel from turing.router.config.resource_request import ResourceRequest from turing.router.config.common.env_var import EnvVar @dataclass class EnsemblerNopConfi...
[ "dataclasses.field" ]
[((393, 422), 'dataclasses.field', 'field', ([], {'init': '(False)', 'repr': '(False)'}), '(init=False, repr=False)\n', (398, 422), False, 'from dataclasses import dataclass, field\n'), ((938, 967), 'dataclasses.field', 'field', ([], {'init': '(False)', 'repr': '(False)'}), '(init=False, repr=False)\n', (943, 967), Fal...
from binascii import hexlify, unhexlify import hashlib import math SIGHASH_ALL = 1 SIGHASH_NONE = 2 SIGHASH_SINGLE = 3 BASE58_ALPHABET = b'123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz' def hash160(s): return hashlib.ripemd160(hashlib.sha256(s).digest()).digest() def double_sha256(s): return ha...
[ "binascii.hexlify", "hashlib.sha256", "binascii.unhexlify" ]
[((2843, 2855), 'binascii.unhexlify', 'unhexlify', (['h'], {}), '(h)\n', (2852, 2855), False, 'from binascii import hexlify, unhexlify\n'), ((2887, 2901), 'binascii.hexlify', 'hexlify', (['b_rev'], {}), '(b_rev)\n', (2894, 2901), False, 'from binascii import hexlify, unhexlify\n'), ((247, 264), 'hashlib.sha256', 'hashl...
import copy import os import pytest from rllib.agent import MPCAgent from rllib.algorithms.mpc import CEMShooting, MPPIShooting, RandomShooting from rllib.dataset.experience_replay import ExperienceReplay from rllib.environment import GymEnvironment from rllib.model.environment_model import EnvironmentModel from rlli...
[ "copy.deepcopy", "rllib.agent.MPCAgent", "rllib.dataset.experience_replay.ExperienceReplay", "pytest.fixture", "rllib.environment.GymEnvironment", "rllib.model.environment_model.EnvironmentModel", "rllib.util.training.agent_training.evaluate_agent", "rllib.algorithms.mpc.CEMShooting", "rllib.algorit...
[((443, 476), 'rllib.environment.GymEnvironment', 'GymEnvironment', (['ENVIRONMENT', 'SEED'], {}), '(ENVIRONMENT, SEED)\n', (457, 476), False, 'from rllib.environment import GymEnvironment\n'), ((489, 507), 'copy.deepcopy', 'copy.deepcopy', (['env'], {}), '(env)\n', (502, 507), False, 'import copy\n'), ((544, 594), 'rl...
# This is a modification of a small part of docx.py originally by <NAME> # which is licensed under the [MIT license](http://www.opensource.org/licenses/mit-license.php) # See 'license/docx.py_LICENSE' for the license of the code in this module ''' Open and modify Microsoft Word 2007 docx files (called 'OpenXML' and 'O...
[ "zipfile.ZipFile", "xml.etree.ElementTree.fromstring" ]
[((2519, 2540), 'zipfile.ZipFile', 'zipfile.ZipFile', (['file'], {}), '(file)\n', (2534, 2540), False, 'import zipfile\n'), ((2605, 2633), 'xml.etree.ElementTree.fromstring', 'etree.fromstring', (['xmlcontent'], {}), '(xmlcontent)\n', (2621, 2633), True, 'import xml.etree.ElementTree as etree\n')]
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Wed Dec 28 14:00:03 2016 @author: virati #inspired/based on code from: http://matplotlib.org/examples/widgets/slider_demo.html """ import numpy as np import matplotlib.pyplot as plt from matplotlib.widgets import Slider, Button, RadioButtons from sklearn i...
[ "numpy.absolute", "numpy.abs", "matplotlib.pyplot.axes", "matplotlib.widgets.Slider", "matplotlib.pyplot.quiver", "matplotlib.pyplot.figure", "numpy.arange", "numpy.linalg.norm", "numpy.meshgrid", "matplotlib.widgets.RadioButtons", "scipy.integrate.odeint", "matplotlib.pyplot.draw", "numpy.l...
[((556, 568), 'matplotlib.pyplot.figure', 'plt.figure', ([], {}), '()\n', (566, 568), True, 'import matplotlib.pyplot as plt\n'), ((576, 627), 'matplotlib.pyplot.axes', 'plt.axes', (['[0.05, 0.25, 0.9, 0.2]'], {'facecolor': '"""white"""'}), "([0.05, 0.25, 0.9, 0.2], facecolor='white')\n", (584, 627), True, 'import matp...
import func2pipe as fp from functools import reduce @fp.pipeit() def replace(line, original, replacement): result = str(line).replace(original, replacement) return result @fp.pipeit() def intocolumns(line, separator): result = str(line).split(separator) return result @fp.pipeit() def in...
[ "functools.reduce", "func2pipe.pipeit" ]
[((57, 68), 'func2pipe.pipeit', 'fp.pipeit', ([], {}), '()\n', (66, 68), True, 'import func2pipe as fp\n'), ((190, 201), 'func2pipe.pipeit', 'fp.pipeit', ([], {}), '()\n', (199, 201), True, 'import func2pipe as fp\n'), ((301, 312), 'func2pipe.pipeit', 'fp.pipeit', ([], {}), '()\n', (310, 312), True, 'import func2pipe a...
import pandas as pd import numpy as np import json from .util import unwrap_zb_error try: import _pickle as pickle except: import pickle from ast import literal_eval def parse_object(s): return json.loads(s) class PutPages(): def __init__(self, client, keys, data): self.client = client ...
[ "pandas.DataFrame", "pandas.concat", "json.loads", "pickle.loads" ]
[((209, 222), 'json.loads', 'json.loads', (['s'], {}), '(s)\n', (219, 222), False, 'import json\n'), ((6456, 6492), 'pandas.DataFrame', 'pd.DataFrame', (['df_data'], {'index': 'indices'}), '(df_data, index=indices)\n', (6468, 6492), True, 'import pandas as pd\n'), ((9960, 9974), 'pandas.concat', 'pd.concat', (['dfs'], ...
import wx class UnPackDialog(wx.Dialog): def __init__(self, *args, **kw): super(UnPackDialog, self).__init__(*args, **kw) self.InitUI() self.SetSize((500, 200)) self.dir = '' def InitUI(self): self.rootpanel = wx.Panel(self) vbox = wx.BoxSizer(wx.VERT...
[ "wx.ComboBox", "wx.BoxSizer", "wx.Panel", "wx.StaticText", "wx.Button", "wx.Gauge", "wx.DirDialog" ]
[((270, 284), 'wx.Panel', 'wx.Panel', (['self'], {}), '(self)\n', (278, 284), False, 'import wx\n'), ((301, 325), 'wx.BoxSizer', 'wx.BoxSizer', (['wx.VERTICAL'], {}), '(wx.VERTICAL)\n', (312, 325), False, 'import wx\n'), ((343, 369), 'wx.BoxSizer', 'wx.BoxSizer', (['wx.HORIZONTAL'], {}), '(wx.HORIZONTAL)\n', (354, 369)...
from collections import OrderedDict from distutils.version import StrictVersion import logging import h5py import numpy as np from dsgrid import __version__ as VERSION from dsgrid.dataformat.datafile import Datafile from dsgrid.dataformat.enumeration import (SectorEnumeration, GeographyEnumeration, EndUseEnumerat...
[ "h5py.File", "dsgrid.dataformat.sectordataset.Datamap.create", "distutils.version.StrictVersion", "dsgrid.dataformat.enumeration.SingleFuelEndUseEnumeration", "dsgrid.dataformat.enumeration.SectorEnumeration.load", "dsgrid.dataformat.enumeration.TimeEnumeration.load", "numpy.any", "numpy.array", "ds...
[((486, 513), 'logging.getLogger', 'logging.getLogger', (['__name__'], {}), '(__name__)\n', (503, 513), False, 'import logging\n'), ((5230, 5243), 'collections.OrderedDict', 'OrderedDict', ([], {}), '()\n', (5241, 5243), False, 'from collections import OrderedDict\n'), ((5578, 5699), 'dsgrid.dataformat.enumeration.Sing...
# Copyright 2013 by Rackspace Hosting, 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 t...
[ "falcon.util.get_bound_method" ]
[((1476, 1527), 'falcon.util.get_bound_method', 'util.get_bound_method', (['component', '"""process_request"""'], {}), "(component, 'process_request')\n", (1497, 1527), False, 'from falcon import util\n'), ((1603, 1655), 'falcon.util.get_bound_method', 'util.get_bound_method', (['component', '"""process_response"""'], ...
HELPER_SETTINGS = { "INSTALLED_APPS": [ "tests.utils.app_1", "tests.utils.app_2", "djangocms_versioning", "djangocms_version_locking", # the following 4 apps are related "aldryn_forms", "filer", "easy_thumbnails", "captcha", "djangocm...
[ "djangocms_helper.runner.cms" ]
[((920, 954), 'djangocms_helper.runner.cms', 'runner.cms', (['"""djangocms_moderation"""'], {}), "('djangocms_moderation')\n", (930, 954), False, 'from djangocms_helper import runner\n')]
import argparse import sys import vcfpy import re import csv from collections import OrderedDict import logging def resolve_consequence(consequence_string): if '&' in consequence_string: consequences = {consequence.lower() for consequence in consequence_string.split('&')} elif '.' in consequence_string...
[ "argparse.ArgumentParser", "logging.basicConfig", "vcfpy.Writer.from_path", "vcfpy.Reader.from_path", "collections.OrderedDict", "re.compile" ]
[((1414, 1452), 'vcfpy.Reader.from_path', 'vcfpy.Reader.from_path', (['args.input_vcf'], {}), '(args.input_vcf)\n', (1436, 1452), False, 'import vcfpy\n'), ((2232, 2279), 'vcfpy.Writer.from_path', 'vcfpy.Writer.from_path', (['output_file', 'new_header'], {}), '(output_file, new_header)\n', (2254, 2279), False, 'import ...
import time import requests import pymongo import pandas as pd from splinter import Browser from bs4 import BeautifulSoup from selenium import webdriver def init_browser(): # @NOTE: Replace the path with your actual path to the chromedriver executable_path = {"executable_path": "chromedriver"} return Brow...
[ "bs4.BeautifulSoup", "splinter.Browser", "pandas.read_html", "time.sleep" ]
[((316, 368), 'splinter.Browser', 'Browser', (['"""chrome"""'], {'headless': '(False)'}), "('chrome', **executable_path, headless=False)\n", (323, 368), False, 'from splinter import Browser\n'), ((627, 640), 'time.sleep', 'time.sleep', (['(1)'], {}), '(1)\n', (637, 640), False, 'import time\n'), ((723, 757), 'bs4.Beaut...
from rest_framework import routers from .views import DeviceRegistrationViewSet router = routers.SimpleRouter() router.register(r'device-registration', DeviceRegistrationViewSet, basename='device') urlpatterns = router.urls
[ "rest_framework.routers.SimpleRouter" ]
[((91, 113), 'rest_framework.routers.SimpleRouter', 'routers.SimpleRouter', ([], {}), '()\n', (111, 113), False, 'from rest_framework import routers\n')]
#!/usr/bin/env python """The JIP command line package contains utilities and the modules that expose command line functions for the JIP command. The module hosts a set of utility functions that can be used to simplify the process of interacting with the JIP API from within a command line tool. Functions in this module...
[ "jip.vendor.texttable.Texttable", "sys.stdin.isatty", "jip.vendor.docopt.docopt", "os.getcwd", "datetime.timedelta", "os.path.relpath", "sys.exit" ]
[((3927, 3984), 'jip.vendor.docopt.docopt', 'docopt', (['docstring'], {'argv': 'argv', 'options_first': 'options_first'}), '(docstring, argv=argv, options_first=options_first)\n', (3933, 3984), False, 'from jip.vendor.docopt import docopt\n'), ((14079, 14090), 'os.getcwd', 'os.getcwd', ([], {}), '()\n', (14088, 14090),...
import numpy as np import scipy.stats from numba import njit def naive_all_stats(data): # initialise output data structures covariances, variances, std, mean, correlations, skewness, kurtosis = initialise_outputs(data.values) n_periods = data.shape[0] # naive rescan of each window using Pandas and ...
[ "numpy.full", "numpy.fill_diagonal", "numpy.ndindex", "numpy.full_like", "numpy.ones_like", "numpy.divide", "numpy.empty", "numpy.power", "numpy.zeros", "pytest.main", "numpy.diag", "numpy.all", "numpy.sqrt" ]
[((1435, 1466), 'numpy.empty', 'np.empty', (['(n_periods, n_assets)'], {}), '((n_periods, n_assets))\n', (1443, 1466), True, 'import numpy as np\n'), ((1524, 1565), 'numpy.empty', 'np.empty', (['(n_periods, n_assets, n_assets)'], {}), '((n_periods, n_assets, n_assets))\n', (1532, 1565), True, 'import numpy as np\n'), (...
import requests import json from .models import Profile def postUser(cep, email, name, username, password): url = 'http://mobile-aceite.tcu.gov.br:80/appCivicoRS/rest/pessoas/' cep = str(cep) """if len(cep) is not 8: raise ValueError('CEP deve conter 8 dígitos\n')""" email = str(email) nam...
[ "json.loads", "requests.get", "json.dumps" ]
[((1138, 1172), 'requests.get', 'requests.get', (['url'], {'headers': 'headers'}), '(url, headers=headers)\n', (1150, 1172), False, 'import requests\n'), ((1185, 1209), 'json.loads', 'json.loads', (['request.text'], {}), '(request.text)\n', (1195, 1209), False, 'import json\n'), ((794, 810), 'json.dumps', 'json.dumps',...
from django.contrib import admin from .models import (Convention, Society, ) from .forms import SocietyForm @admin.register(Convention) class ConventionAdmin(admin.ModelAdmin): list_display = ('title', 'get_location', ) autocomplete_fields = ['location', ] @admin.register(Society) class SocietyAdmin(admin.Mod...
[ "django.contrib.admin.register" ]
[((110, 136), 'django.contrib.admin.register', 'admin.register', (['Convention'], {}), '(Convention)\n', (124, 136), False, 'from django.contrib import admin\n'), ((268, 291), 'django.contrib.admin.register', 'admin.register', (['Society'], {}), '(Society)\n', (282, 291), False, 'from django.contrib import admin\n')]
import logging from marrow.mailer import Message, Mailer logging.basicConfig(level=logging.INFO) mail = Mailer({'manager.use': 'immediate', 'transport.use': 'maildir', 'transport.directory': 'data/maildir'}) mail.start() message = Message([('<NAME>', '<EMAIL>')], [('<NAME>', '<EMAIL>')], "This is a test message.", pl...
[ "marrow.mailer.Mailer", "marrow.mailer.Message", "logging.basicConfig" ]
[((57, 96), 'logging.basicConfig', 'logging.basicConfig', ([], {'level': 'logging.INFO'}), '(level=logging.INFO)\n', (76, 96), False, 'import logging\n'), ((105, 212), 'marrow.mailer.Mailer', 'Mailer', (["{'manager.use': 'immediate', 'transport.use': 'maildir',\n 'transport.directory': 'data/maildir'}"], {}), "({'ma...
#!/usr/bin/env python # -*- coding: utf-8 -*- """Spectral induced polarisation (SIP) spectrum class and modules.""" import sys import codecs from math import log10, exp, pi import numpy as np import matplotlib.pyplot as plt import pygimli as pg from .importexport import readTXTSpectrum, readFuchs3File, readRadicSIPF...
[ "pygimli.RTransLog", "numpy.arctan2", "numpy.abs", "numpy.argmax", "numpy.angle", "numpy.argsort", "numpy.sin", "numpy.mean", "pygimli.RInversion", "numpy.unique", "codecs.open", "pygimli.info", "math.log10", "numpy.log10", "matplotlib.pyplot.subplots", "matplotlib.pyplot.show", "num...
[((4328, 4345), 'numpy.unique', 'np.unique', (['self.f'], {}), '(self.f)\n', (4337, 4345), True, 'import numpy as np\n'), ((5303, 5321), 'numpy.argsort', 'np.argsort', (['self.f'], {}), '(self.f)\n', (5313, 5321), True, 'import numpy as np\n'), ((5703, 5722), 'numpy.any', 'np.any', (['self.phiOrg'], {}), '(self.phiOrg)...
from Classes.Logic.LogicCommandManager import LogicCommandManager from Classes.Messaging import Messaging from Classes.Packets.PiranhaMessage import PiranhaMessage class EndClientTurnMessage(PiranhaMessage): def __init__(self, messageData): super().__init__(messageData) self.messageVersion = 0 ...
[ "Classes.Logic.LogicCommandManager.LogicCommandManager.getCommandsName", "Classes.Logic.LogicCommandManager.LogicCommandManager.createCommand", "Classes.Logic.LogicCommandManager.LogicCommandManager.commandExist" ]
[((758, 819), 'Classes.Logic.LogicCommandManager.LogicCommandManager.commandExist', 'LogicCommandManager.commandExist', (["fields['Commands'][i]['ID']"], {}), "(fields['Commands'][i]['ID'])\n", (790, 819), False, 'from Classes.Logic.LogicCommandManager import LogicCommandManager\n'), ((847, 909), 'Classes.Logic.LogicCo...
# Standard libraries import os import time import warnings import datetime from abc import ABC, abstractmethod # Third party libraries import glob import torch import numpy as np import matplotlib.pyplot as plt import torchvision.transforms.functional as FT from torch import nn from torch import optim from torch.utils...
[ "sklearn.externals.joblib.dump", "os.remove", "torchvision.transforms.functional.to_tensor", "torch.cat", "torch.cuda.device_count", "glob.glob", "torch.no_grad", "torch.utils.data.DataLoader", "torch.load", "datetime.datetime.now", "matplotlib.pyplot.show", "matplotlib.pyplot.ylabel", "matp...
[((709, 749), 'warnings.filterwarnings', 'warnings.filterwarnings', ([], {'action': '"""ignore"""'}), "(action='ignore')\n", (732, 749), False, 'import warnings\n'), ((4576, 4599), 'datetime.datetime.now', 'datetime.datetime.now', ([], {}), '()\n', (4597, 4599), False, 'import datetime\n'), ((12683, 12694), 'time.time'...
if __name__ == '__main__': import sys import os pkg_dir = os.path.split(os.path.abspath(__file__))[0] parent_dir, pkg_name = os.path.split(pkg_dir) is_pygame_pkg = (pkg_name == 'tests' and os.path.split(parent_dir)[1] == 'pygame') if not is_pygame_pkg: sys.path.inser...
[ "os.remove", "os.path.abspath", "pygame.display.set_mode", "test.test_utils.unittest.main", "pygame.image.save", "sys.path.insert", "test.test_utils.get_tmp_dir", "pygame.display.flip", "os.path.exists", "os.rmdir", "pygame.display.quit", "os.path.split", "os.path.join", "pygame.display.in...
[((141, 163), 'os.path.split', 'os.path.split', (['pkg_dir'], {}), '(pkg_dir)\n', (154, 163), False, 'import os\n'), ((1650, 1665), 'test.test_utils.unittest.main', 'unittest.main', ([], {}), '()\n', (1663, 1665), False, 'from test.test_utils import unittest\n'), ((306, 336), 'sys.path.insert', 'sys.path.insert', (['(0...
#-*- coding: utf-8 -*- import numpy as np import matplotlib.pyplot as plt import math from sklearn.decomposition import PCA # Compute a sequence's reward def reward(tsp_sequence): tour = np.concatenate((tsp_sequence, np.expand_dims(tsp_sequence[0],0))) # sequence to tour (end=start) inter_city_dista...
[ "matplotlib.pyplot.title", "numpy.sum", "numpy.random.seed", "matplotlib.pyplot.figure", "numpy.unique", "numpy.copy", "matplotlib.pyplot.imshow", "numpy.transpose", "matplotlib.pyplot.colorbar", "numpy.random.shuffle", "matplotlib.pyplot.show", "matplotlib.pyplot.ylim", "numpy.square", "m...
[((413, 441), 'numpy.sum', 'np.sum', (['inter_city_distances'], {}), '(inter_city_distances)\n', (419, 441), True, 'import numpy as np\n'), ((551, 572), 'numpy.copy', 'np.copy', (['tsp_sequence'], {}), '(tsp_sequence)\n', (558, 572), True, 'import numpy as np\n'), ((604, 642), 'numpy.flip', 'np.flip', (['tsp_sequence[i...
""" Core utilities for handling GEOS-Chem data """ from __future__ import absolute_import from __future__ import division from __future__ import print_function import os import json import shutil import matplotlib.colors as mcolors import numpy as np import xarray as xr import xbpch # JSON files to read lumped_spc ...
[ "matplotlib.colors.Normalize", "numpy.empty", "os.path.dirname", "xarray.open_dataset", "os.path.exists", "numpy.datetime_as_string", "numpy.isnan", "xarray.Dataset", "xarray.merge", "xarray.set_options", "matplotlib.colors.LogNorm", "xarray.DataArray", "os.path.splitext", "os.path.join" ]
[((2409, 2435), 'os.path.splitext', 'os.path.splitext', (['filename'], {}), '(filename)\n', (2425, 2435), False, 'import os\n'), ((5920, 5945), 'os.path.splitext', 'os.path.splitext', (['test_fn'], {}), '(test_fn)\n', (5936, 5945), False, 'import os\n'), ((15453, 15478), 'xarray.open_dataset', 'xr.open_dataset', (['dat...
# -*- coding: utf-8 -*- import pandas as pd from pandas import DataFrame import numpy as np import matplotlib.pyplot as plt import seaborn as sns test_set = pd.read_csv('raw/TestSet.csv') train_set = pd.read_csv('raw/TrainingSet.csv') test_subset = pd.read_csv('raw/TestSubset.csv') train_subset = pd.read_csv('raw/Tr...
[ "numpy.zeros_like", "seaborn.heatmap", "matplotlib.pyplot.show", "pandas.read_csv", "matplotlib.pyplot.yticks", "numpy.triu_indices_from", "numpy.hstack", "matplotlib.pyplot.figure", "seaborn.pairplot", "seaborn.diverging_palette" ]
[((160, 190), 'pandas.read_csv', 'pd.read_csv', (['"""raw/TestSet.csv"""'], {}), "('raw/TestSet.csv')\n", (171, 190), True, 'import pandas as pd\n'), ((203, 237), 'pandas.read_csv', 'pd.read_csv', (['"""raw/TrainingSet.csv"""'], {}), "('raw/TrainingSet.csv')\n", (214, 237), True, 'import pandas as pd\n'), ((252, 285), ...
""" Rewrite: ./spec/ui_specs/wizard_spec.rb """ from urllib.parse import urlparse import pytest from testsuite.ui.navigation import Navigator from testsuite.utils import blame from testsuite.ui.views.admin.wizard import WizardIntroView, \ WizardBackendApiView, WizardRequestView, WizardEditApiView, \ WizardResp...
[ "testsuite.ui.views.admin.wizard.WizardEditApiView", "testsuite.utils.blame", "pytest.fixture", "testsuite.ui.navigation.Navigator", "urllib.parse.urlparse" ]
[((349, 379), 'pytest.fixture', 'pytest.fixture', ([], {'scope': '"""module"""'}), "(scope='module')\n", (363, 379), False, 'import pytest\n'), ((618, 648), 'testsuite.ui.navigation.Navigator', 'Navigator', (['browser', 'base_views'], {}), '(browser, base_views)\n', (627, 648), False, 'from testsuite.ui.navigation impo...
import importlib.util import os import sys import setuptools from pkg_resources import parse_requirements def read(filename: str) -> str: with open(filename, encoding='utf-8') as file: return file.read() def get_module(name: str): spec = importlib.util.spec_from_file_location(name, os.path.join(nam...
[ "os.path.join", "setuptools.find_packages" ]
[((304, 337), 'os.path.join', 'os.path.join', (['name', '"""__init__.py"""'], {}), "(name, '__init__.py')\n", (316, 337), False, 'import os\n'), ((1332, 1387), 'setuptools.find_packages', 'setuptools.find_packages', ([], {'exclude': "['examples', 'tests']"}), "(exclude=['examples', 'tests'])\n", (1356, 1387), False, 'i...
import os import rethinkdb as r from rethinkdb.errors import RqlRuntimeError, RqlDriverError class Db: RDB_HOST = 'localhost' RDB_PORT = 28015 PROJECT_DB = 'Aurora' PROJECT_TABLE = 'Inventory' connection = r.connect(RDB_HOST, RDB_PORT) # Function is for cross-checking database and table exists def Setup(self...
[ "rethinkdb.db", "rethinkdb.connect", "rethinkdb.db_create" ]
[((214, 243), 'rethinkdb.connect', 'r.connect', (['RDB_HOST', 'RDB_PORT'], {}), '(RDB_HOST, RDB_PORT)\n', (223, 243), True, 'import rethinkdb as r\n'), ((333, 361), 'rethinkdb.db_create', 'r.db_create', (['self.PROJECT_DB'], {}), '(self.PROJECT_DB)\n', (344, 361), True, 'import rethinkdb as r\n'), ((509, 530), 'rethink...
# Play Hangman import os import random import pickle import sys def start(): os.system('cls') print(''' +---+ O | /|\ | / \ | === H _ N G M _ N ''') print('Would you like to play Hangman?\n') def ask(): choice = '' while choice.lower() != 'n': choice...
[ "pickle.dump", "random.choice", "os.system", "pickle.load", "sys.exit" ]
[((84, 100), 'os.system', 'os.system', (['"""cls"""'], {}), "('cls')\n", (93, 100), False, 'import os\n'), ((890, 906), 'os.system', 'os.system', (['"""cls"""'], {}), "('cls')\n", (899, 906), False, 'import os\n'), ((925, 941), 'os.system', 'os.system', (['"""cls"""'], {}), "('cls')\n", (934, 941), False, 'import os\n'...
import cv2 as cv import mss import numpy as np import collections class vision: def Screen_Shot(self, left=0, top=0, width=600, height=668): stc = mss.mss() scr = stc.grab({ 'left': left, 'top': top, 'width': width, 'height': height }) ...
[ "cv2.cvtColor", "cv2.waitKey", "mss.mss", "numpy.array", "cv2.rectangle", "collections.Counter", "cv2.imshow" ]
[((161, 170), 'mss.mss', 'mss.mss', ([], {}), '()\n', (168, 170), False, 'import mss\n'), ((329, 342), 'numpy.array', 'np.array', (['scr'], {}), '(scr)\n', (337, 342), True, 'import numpy as np\n'), ((357, 376), 'cv2.cvtColor', 'cv.cvtColor', (['img', '(0)'], {}), '(img, 0)\n', (368, 376), True, 'import cv2 as cv\n'), ...
import unittest from ansiblelint import RulesCollection, Runner from ansiblelints.rules.EmptyPassword0 import EmptyPassword0 class TestEmptyPassword(unittest.TestCase): collection = RulesCollection() def setUp(self): self.collection.register(EmptyPassword0()) def test_file(self): success ...
[ "ansiblelints.rules.EmptyPassword0.EmptyPassword0", "ansiblelint.RulesCollection", "ansiblelint.Runner" ]
[((187, 204), 'ansiblelint.RulesCollection', 'RulesCollection', ([], {}), '()\n', (202, 204), False, 'from ansiblelint import RulesCollection, Runner\n'), ((393, 437), 'ansiblelint.Runner', 'Runner', (['self.collection', 'success', '[]', '[]', '[]'], {}), '(self.collection, success, [], [], [])\n', (399, 437), False, '...
from typing import Union, Optional import numpy as np from hdrpy.image import get_luminance from hdrpy.stats import gmean from hdrpy.tmo import ColorProcessing, LuminanceProcessing, Compose, ReplaceLuminance from hdrpy.tmo.linear import ExposureCompensation, multiply_scalar from hdrpy.tmo.operator import replace_lumi...
[ "hdrpy.tmo.operator.replace_luminance", "numpy.sum", "numpy.log", "hdrpy.image.get_luminance", "hdrpy.tmo.linear.multiply_scalar", "numpy.exp", "hdrpy.stats.gmean", "doctest.testmod" ]
[((4640, 4657), 'doctest.testmod', 'doctest.testmod', ([], {}), '()\n', (4655, 4657), False, 'import doctest\n'), ((2236, 2256), 'hdrpy.image.get_luminance', 'get_luminance', (['image'], {}), '(image)\n', (2249, 2256), False, 'from hdrpy.image import get_luminance\n'), ((2373, 2411), 'hdrpy.tmo.linear.multiply_scalar',...
import os MSGLEN = os.getenv('SERVER_URL', 10) def socketMessage(s, msg): totalsent = 0 while totalsent < MSGLEN: sent = s.send(msg[totalsent:]) if sent == 0: raise RuntimeError("socket connection broken") totalsent = totalsent + sent def socketCatchMessaje(s): chunks = [] index = 0 ...
[ "os.getenv" ]
[((19, 46), 'os.getenv', 'os.getenv', (['"""SERVER_URL"""', '(10)'], {}), "('SERVER_URL', 10)\n", (28, 46), False, 'import os\n')]
import sys # import libraries from sqlalchemy import create_engine import pandas as pd import re import numpy as np # nltk import nltk nltk.download('stopwords') nltk.download('wordnet') # download for lemmatization nltk.download('punkt') from nltk.corpus import stopwords from nltk.stem.porter import PorterStemmer fro...
[ "pandas.DataFrame", "sklearn.model_selection.GridSearchCV", "sklearn.feature_extraction.text.CountVectorizer", "sklearn.ensemble.RandomForestClassifier", "nltk.stem.wordnet.WordNetLemmatizer", "sklearn.model_selection.train_test_split", "sklearn.metrics.classification_report", "pandas.read_sql_table",...
[((136, 162), 'nltk.download', 'nltk.download', (['"""stopwords"""'], {}), "('stopwords')\n", (149, 162), False, 'import nltk\n'), ((163, 187), 'nltk.download', 'nltk.download', (['"""wordnet"""'], {}), "('wordnet')\n", (176, 187), False, 'import nltk\n'), ((217, 239), 'nltk.download', 'nltk.download', (['"""punkt"""']...
import pandas as pd import numpy as np import os import itertools def dados_teses(): diretorio = "/media/hdvm02/bd/007/002/007/002" teses_anos = sorted(os.listdir(diretorio)) lista_dfs = [] for tese_ano in teses_anos: csv = os.path.join(diretorio,tese_ano) teses = pd.read_csv(csv, se...
[ "os.listdir", "pandas.read_csv", "itertools.zip_longest", "os.path.join", "pandas.concat" ]
[((961, 1011), 'pandas.read_csv', 'pd.read_csv', (['f"""{diretorio}/01_dados_1987_2012.csv"""'], {}), "(f'{diretorio}/01_dados_1987_2012.csv')\n", (972, 1011), True, 'import pandas as pd\n'), ((1789, 1858), 'itertools.zip_longest', 'itertools.zip_longest', (['anos_1987_2012', 'anos_2013_2016', 'anos_2017_2021'], {}), '...
from cement import Controller, ex from esperclient import EnterpriseUpdateV1 from esperclient.rest import ApiException from esper.controllers.enums import OutputFormat from esper.ext.api_client import APIClient from esper.ext.db_wrapper import DBWrapper from esper.ext.utils import validate_creds_exists, parse_error_me...
[ "esper.ext.db_wrapper.DBWrapper", "esperclient.EnterpriseUpdateV1", "esper.ext.utils.parse_error_message", "cement.ex", "esper.ext.utils.validate_creds_exists" ]
[((2467, 2619), 'cement.ex', 'ex', ([], {'help': '"""Show enterprise details"""', 'arguments': "[(['-j', '--json'], {'help': 'Render result in Json format', 'action':\n 'store_true', 'dest': 'json'})]"}), "(help='Show enterprise details', arguments=[(['-j', '--json'], {'help':\n 'Render result in Json format', 'a...
""" Shared pytest fixtures for unit tests. """ import numpy as np import pytest from scipy.integrate import odeint from pysindy.feature_library import CustomLibrary @pytest.fixture def data_1d(): t = np.linspace(0, 5, 100) x = 2 * t.reshape(-1, 1) return x, t @pytest.fixture def data_1d_bad_shape(): ...
[ "scipy.integrate.odeint", "pysindy.feature_library.CustomLibrary", "numpy.zeros", "numpy.ones", "numpy.linspace" ]
[((207, 229), 'numpy.linspace', 'np.linspace', (['(0)', '(5)', '(100)'], {}), '(0, 5, 100)\n', (218, 229), True, 'import numpy as np\n'), ((326, 348), 'numpy.linspace', 'np.linspace', (['(0)', '(5)', '(100)'], {}), '(0, 5, 100)\n', (337, 348), True, 'import numpy as np\n'), ((585, 607), 'numpy.linspace', 'np.linspace',...
import unittest import uuid as _uu class TestUtils(unittest.TestCase): def test_pack_unpack(self): from smalluuid.utils import unpack_uuid, pack_uuid # for x in range(0, 10000): # uuid = _uu.uuid4() # self.assertEqual(uuid, unpack_uuid(pack_uuid(uuid))) def test_pack...
[ "smalluuid.utils.unpack_uuid", "uuid.UUID", "smalluuid.utils.pack_uuid" ]
[((390, 416), 'uuid.UUID', '_uu.UUID', ([], {'int': '(0)', 'version': '(4)'}), '(int=0, version=4)\n', (398, 416), True, 'import uuid as _uu\n'), ((442, 457), 'smalluuid.utils.pack_uuid', 'pack_uuid', (['uuid'], {}), '(uuid)\n', (451, 457), False, 'from smalluuid.utils import pack_uuid\n'), ((569, 584), 'smalluuid.util...
# Enter your code here. Read input from STDIN. Print output to STDOUT import math a=int(input()) b=int(input()) m=int(input()) print(round(math.pow(a,b))) print(int(math.pow(a,b)%m))#we can use both round() and int()
[ "math.pow" ]
[((144, 158), 'math.pow', 'math.pow', (['a', 'b'], {}), '(a, b)\n', (152, 158), False, 'import math\n'), ((171, 185), 'math.pow', 'math.pow', (['a', 'b'], {}), '(a, b)\n', (179, 185), False, 'import math\n')]
import hashlib import readline # noqa import json import os from pathlib import Path from chiasim.validation.consensus import ( conditions_dict_for_solution, hash_key_pairs_for_conditions_dict, ) from utilities.BLSHDKey import BLSPrivateHDKey, fingerprint_for_pk from .pst import PartiallySignedTransaction ...
[ "json.dump", "chiasim.validation.consensus.conditions_dict_for_solution", "chiasim.validation.consensus.hash_key_pairs_for_conditions_dict", "pathlib.Path", "utilities.BLSHDKey.BLSPrivateHDKey.from_seed", "utilities.BLSHDKey.BLSPrivateHDKey.from_bytes", "utilities.BLSHDKey.fingerprint_for_pk", "os.ura...
[((554, 585), 'utilities.BLSHDKey.BLSPrivateHDKey.from_seed', 'BLSPrivateHDKey.from_seed', (['seed'], {}), '(seed)\n', (579, 585), False, 'from utilities.BLSHDKey import BLSPrivateHDKey, fingerprint_for_pk\n'), ((874, 906), 'utilities.BLSHDKey.BLSPrivateHDKey.from_bytes', 'BLSPrivateHDKey.from_bytes', (['blob'], {}), '...
"""Wykop API base praser module.""" from collections import namedtuple from wykop.api.exceptions import WykopAPIError Error = namedtuple('Error', ['code', 'message']) class BaseParser(object): def __init__(self, exception_resolver): self.exception_resolver = exception_resolver def _resolve_excepti...
[ "collections.namedtuple" ]
[((128, 168), 'collections.namedtuple', 'namedtuple', (['"""Error"""', "['code', 'message']"], {}), "('Error', ['code', 'message'])\n", (138, 168), False, 'from collections import namedtuple\n')]
import json from brownie import ERC20MOBI, VestingEscrow, VestingEscrowFactory, VestingEscrowSimple, accounts, network from . import deployment_config as config network.gas_limit(8000000) ZERO_ADDRESS = "0x0000000000000000000000000000000000000000" YEAR = 86400 * 365 def live(): """ Vest tokens in a live e...
[ "brownie.accounts.load", "brownie.network.gas_limit", "json.load", "brownie.VestingEscrowSimple.deploy", "brownie.VestingEscrow.deploy", "brownie.VestingEscrowFactory.deploy", "brownie.ERC20MOBI.at", "brownie.ERC20MOBI.deploy" ]
[((164, 190), 'brownie.network.gas_limit', 'network.gas_limit', (['(8000000)'], {}), '(8000000)\n', (181, 190), False, 'from brownie import ERC20MOBI, VestingEscrow, VestingEscrowFactory, VestingEscrowSimple, accounts, network\n'), ((654, 684), 'brownie.accounts.load', 'accounts.load', (['"""kyle_personal"""'], {}), "(...
import smtplib from email.mime.text import MIMEText from datetime import datetime from src.adapter.notification.presenter.ClusterReport import ClusterReport from src.decorator.logging import exception from src.domain.usecase.channel.Notifier import Notifier class MailSender(Notifier): def __init__(self, server,...
[ "email.mime.text.MIMEText", "src.adapter.notification.presenter.ClusterReport.ClusterReport", "smtplib.SMTP", "datetime.datetime.now" ]
[((378, 393), 'src.adapter.notification.presenter.ClusterReport.ClusterReport', 'ClusterReport', ([], {}), '()\n', (391, 393), False, 'from src.adapter.notification.presenter.ClusterReport import ClusterReport\n'), ((418, 438), 'smtplib.SMTP', 'smtplib.SMTP', (['server'], {}), '(server)\n', (430, 438), False, 'import s...
#!/usr/bin/env python3 import requests, sys, base64, os import argparse, time # AMSI Bypass stager generator based on: # https://rastamouse.me/2018/10/amsiscanbuffer-bypass-part-2/ # bypass code from: https://github.com/rasta-mouse/AmsiScanBufferBypass # tested on python3 # file name for AMSI Bypass PowerShell scrip...
[ "argparse.ArgumentParser", "time.sleep", "os.path.isfile", "requests.get", "sys.exit" ]
[((2310, 2467), 'argparse.ArgumentParser', 'argparse.ArgumentParser', ([], {'description': '"""AMSI_BYPASSR: generate files for AMSI bypass per https://rastamouse.me/2018/10/amsiscanbuffer-bypass-part-2/"""'}), "(description=\n 'AMSI_BYPASSR: generate files for AMSI bypass per https://rastamouse.me/2018/10/amsiscanb...
import skfda from skfda.representation.basis import Monomial, Tensor, VectorValued import unittest import numpy as np def ndm(*args): return [x[(None,) * i + (slice(None),) + (None,) * (len(args) - i - 1)] for i, x in enumerate(args)] class InnerProductTest(unittest.TestCase): def test_several_...
[ "unittest.main", "skfda.FDataGrid", "skfda.representation.basis.Monomial", "skfda.misc.inner_product", "numpy.linspace" ]
[((1896, 1911), 'unittest.main', 'unittest.main', ([], {}), '()\n', (1909, 1911), False, 'import unittest\n'), ((404, 426), 'numpy.linspace', 'np.linspace', (['(0)', '(1)', '(100)'], {}), '(0, 1, 100)\n', (415, 426), True, 'import numpy as np\n'), ((562, 632), 'skfda.FDataGrid', 'skfda.FDataGrid', (['data_matrix[np.new...
'https://blog.csdn.net/qq_36758914/article/details/105886811#3plot_boxes_on_image_53' import cv2 import numpy as np import tensorflow as tf from PIL import Image import matplotlib.pyplot as plt from utils import compute_iou, plot_boxes_on_image, wandhG, extract_boxes, compute_regression, decode_output pos_thresh = 0....
[ "numpy.uint8", "numpy.copy", "numpy.argmax", "utils.compute_regression", "utils.extract_boxes", "numpy.zeros", "numpy.expand_dims", "numpy.any", "cv2.imread", "numpy.array", "PIL.Image.fromarray", "utils.decode_output", "utils.plot_boxes_on_image", "utils.compute_iou", "numpy.all" ]
[((563, 588), 'utils.extract_boxes', 'extract_boxes', (['label_path'], {}), '(label_path)\n', (576, 588), False, 'from utils import compute_iou, plot_boxes_on_image, wandhG, extract_boxes, compute_regression, decode_output\n'), ((632, 654), 'cv2.imread', 'cv2.imread', (['image_path'], {}), '(image_path)\n', (642, 654),...
from defusedxml.minidom import parseString # More info: # - https://stackoverflow.com/a/37032111 def emoji_name_to_filename(*names: str, extension: str = "svg") -> str: # Based on: # - https://inflection.readthedocs.io/en/latest/_modules/inflection.html name = "_".join(names) name = name.replace(" ",...
[ "defusedxml.minidom.parseString" ]
[((468, 489), 'defusedxml.minidom.parseString', 'parseString', (['svg_code'], {}), '(svg_code)\n', (479, 489), False, 'from defusedxml.minidom import parseString\n')]
from time import sleep def lookup_ticker(symbol): print(f"lookup for ticker {symbol}") sleep(1) return symbol
[ "time.sleep" ]
[((97, 105), 'time.sleep', 'sleep', (['(1)'], {}), '(1)\n', (102, 105), False, 'from time import sleep\n')]
import json import cv2 import numpy as np from scipy.fftpack import dct, idct from enum import Enum import uuid import pickle from shutil import copyfile from image_utils import ( img_normalize, img_denormalize, generate_paths, getDiffImgs, soften, img_soften, do_compress, encoding, ...
[ "scipy.fftpack.dct", "numpy.shape", "os.path.isfile", "image_utils.get_summary", "image_utils.img_soften", "numpy.max", "cv2.split", "scipy.fftpack.idct", "image_utils.img_normalize", "json.dump", "cv2.dct", "numpy.min", "cv2.idct", "cv2.merge", "image_utils.getDiffImgs", "image_utils....
[((2299, 2322), 'image_utils.img_denormalize', 'img_denormalize', (['imgSrc'], {}), '(imgSrc)\n', (2314, 2322), False, 'from image_utils import img_normalize, img_denormalize, generate_paths, getDiffImgs, soften, img_soften, do_compress, encoding, get_summary\n'), ((2336, 2359), 'image_utils.img_denormalize', 'img_deno...
import argparse, math, random import lib.config as config import lib.constants as constants import lib.metadata as metadata import lib.utils as utils def main(args): # load and validate training videos videos = utils.load_json(config.TRAIN_METADATA_PATH) if args.format == constants.FORMAT_VIDEOS: train_vi...
[ "argparse.ArgumentParser", "math.ceil", "lib.metadata.get_valid_videos", "random.shuffle", "lib.metadata.class_keys_to_video_id_keys", "lib.utils.save_json", "lib.metadata.get_valid_sound", "lib.metadata.get_valid_frames", "lib.utils.load_json" ]
[((219, 262), 'lib.utils.load_json', 'utils.load_json', (['config.TRAIN_METADATA_PATH'], {}), '(config.TRAIN_METADATA_PATH)\n', (234, 262), True, 'import lib.utils as utils\n'), ((734, 775), 'lib.utils.load_json', 'utils.load_json', (['config.VAL_METADATA_PATH'], {}), '(config.VAL_METADATA_PATH)\n', (749, 775), True, '...
import functions def get_weekday_test(): #basic functionality assert functions.get_weekday('2018','4','23') == ['2018-04-22', '2018-04-23', '2018-04-24', '2018-04-25', '2018-04-26', '2018-04-27', '2018-04-28'] assert functions.get_weekday('3000','4','23') == ['3000-04-20', '3000-04-21', '3000-04-2...
[ "functions.next", "functions.prev", "functions.get_weekday", "functions.check_data" ]
[((86, 126), 'functions.get_weekday', 'functions.get_weekday', (['"""2018"""', '"""4"""', '"""23"""'], {}), "('2018', '4', '23')\n", (107, 126), False, 'import functions\n'), ((239, 279), 'functions.get_weekday', 'functions.get_weekday', (['"""3000"""', '"""4"""', '"""23"""'], {}), "('3000', '4', '23')\n", (260, 279), ...
from __future__ import absolute_import import torch from torch import nn from torch.nn import functional as F import torchvision __all__ = ['SqueezeNet'] class ConvBlock(nn.Module): """Basic convolutional block: convolution + batch normalization + relu. Args (following http://pytorch.org/docs/master/nn....
[ "torch.nn.Conv2d", "torch.nn.functional.dropout", "torch.cat", "torch.nn.BatchNorm2d", "torch.nn.functional.max_pool2d" ]
[((665, 711), 'torch.nn.Conv2d', 'nn.Conv2d', (['in_c', 'out_c', 'k'], {'stride': 's', 'padding': 'p'}), '(in_c, out_c, k, stride=s, padding=p)\n', (674, 711), False, 'from torch import nn\n'), ((730, 751), 'torch.nn.BatchNorm2d', 'nn.BatchNorm2d', (['out_c'], {}), '(out_c)\n', (744, 751), False, 'from torch import nn\...
##################################################################################################################################################################### # xView2 ...
[ "keras.preprocessing.image.ImageDataGenerator", "argparse.ArgumentParser", "pandas.read_csv", "tensorflow.maximum", "tensorflow.math.subtract", "tensorflow.reshape", "numpy.isclose", "tensorflow.argmin", "tensorflow.gather", "tensorflow.cast", "datetime.datetime.now", "tensorflow.equal", "js...
[((3357, 3414), 'keras.preprocessing.image.ImageDataGenerator', 'keras.preprocessing.image.ImageDataGenerator', ([], {'rescale': '(1.4)'}), '(rescale=1.4)\n', (3401, 3414), False, 'import keras\n'), ((4332, 4486), 'keras.preprocessing.image.ImageDataGenerator', 'keras.preprocessing.image.ImageDataGenerator', ([], {'hor...
import py import sys, os, subprocess from rpython.translator.platform import host from rpython.translator import cdir from rpython.tool.udir import udir class ExternalCompilationInfo(object): _ATTRIBUTES = ['pre_include_bits', 'includes', 'include_dirs', 'post_include_bits', 'libraries', 'lib...
[ "subprocess.Popen", "rpython.tool.udir.udir.join", "rpython.translator.platform.host.compile", "py.process.cmdexec", "py.path.local.sysfind", "os.path.join" ]
[((6444, 6480), 'py.path.local.sysfind', 'py.path.local.sysfind', (['execonfigtool'], {}), '(execonfigtool)\n', (6465, 6480), False, 'import py\n'), ((7423, 7466), 'py.process.cmdexec', 'py.process.cmdexec', (["('%s --cflags' % command)"], {}), "('%s --cflags' % command)\n", (7441, 7466), False, 'import py\n'), ((7529,...
from apps.bot.classes.Command import Command from apps.bot.classes.consts.Consts import Platform from apps.bot.utils.utils import get_tg_formatted_url class Git(Command): name = "гит" names = ["гитхаб"] name_tg = 'github' help_text = "ссылка на гитхаб" def start(self): url = 'https://git...
[ "apps.bot.utils.utils.get_tg_formatted_url" ]
[((414, 449), 'apps.bot.utils.utils.get_tg_formatted_url', 'get_tg_formatted_url', (['"""Гитхаб"""', 'url'], {}), "('Гитхаб', url)\n", (434, 449), False, 'from apps.bot.utils.utils import get_tg_formatted_url\n')]
# tutorial.py """ ## To install TumorDecon with pip, use: pip install git+https://github.com/kristyhoran/singscore pip install TumorDecon """ import TumorDecon as td """ To perform digital cytometry on a mixture data, given cell signatures and the deconvolution method of your choice, run: td.tumor_deconvolve(mixtu...
[ "TumorDecon.tumor_deconvolve", "TumorDecon.download_from_cbio", "TumorDecon.hierarchical_clustering", "TumorDecon.find_up_down_genes_from_sig", "TumorDecon.read_geneset", "TumorDecon.combine_celltypes", "TumorDecon.cell_frequency_boxplot", "TumorDecon.get_td_Home", "TumorDecon.read_sig_file", "Tum...
[((2067, 2201), 'TumorDecon.download_from_cbio', 'td.download_from_cbio', ([], {'url': '"""http://download.cbioportal.org/coadread_tcga_pan_can_atlas_2018.tar.gz"""', 'fetch_missing_hugo': '(False)'}), "(url=\n 'http://download.cbioportal.org/coadread_tcga_pan_can_atlas_2018.tar.gz',\n fetch_missing_hugo=False)\n...
# Copyright 2020 NullConvergence # # 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...
[ "py2neo.NodeMatcher", "os.path.abspath", "graphrepo.miners.commit.CommitMiner", "py2neo.RelationshipMatcher", "datetime.datetime.strptime", "os.path.join" ]
[((1211, 1242), 'py2neo.NodeMatcher', 'NodeMatcher', (['test_driller.graph'], {}), '(test_driller.graph)\n', (1222, 1242), False, 'from py2neo import NodeMatcher, RelationshipMatcher\n'), ((1263, 1302), 'py2neo.RelationshipMatcher', 'RelationshipMatcher', (['test_driller.graph'], {}), '(test_driller.graph)\n', (1282, 1...
# -*- coding:utf-8 -*- __author__ = 'boredbird' import os import numpy as np import woe.feature_process as fp import woe.GridSearch as gs if __name__ == '__main__': config_path = os.getcwd()+'\\config.csv' data_path = os.getcwd()+'\\UCI_Credit_Card.csv' feature_detail_path = os.getcwd()+'\\features_detail....
[ "os.getcwd", "numpy.logspace", "woe.GridSearch.grid_search_lr_c_main", "woe.feature_process.process_woe_trans", "woe.feature_process.process_train_woe" ]
[((419, 549), 'woe.feature_process.process_train_woe', 'fp.process_train_woe', ([], {'infile_path': 'data_path', 'outfile_path': 'feature_detail_path', 'rst_path': 'rst_pkl_path', 'config_path': 'config_path'}), '(infile_path=data_path, outfile_path=\n feature_detail_path, rst_path=rst_pkl_path, config_path=config_p...
# Copyright (C) 2014, Hitachi, Ltd. # # 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...
[ "mock.patch.object", "cinder.volume.drivers.hitachi.hbsd_snm2.HBSDSNM2", "cinder.volume.drivers.hitachi.hbsd_iscsi.HBSDISCSIDriver", "mock.Mock", "cinder.volume.drivers.hitachi.hbsd_common.HBSDCommon" ]
[((11786, 11901), 'mock.patch.object', 'mock.patch.object', (['utils', '"""brick_get_connector_properties"""'], {'return_value': "{'ip': '0.0.0.0', 'initiator': 'iqn'}"}), "(utils, 'brick_get_connector_properties', return_value={\n 'ip': '0.0.0.0', 'initiator': 'iqn'})\n", (11803, 11901), False, 'import mock\n'), ((...
# -*- coding: utf-8 -*- from collections import Iterable from datetime import datetime from frontera.utils.url import parse_domain_from_url_fast from frontera import DistributedBackend from frontera.core.components import Metadata, Queue, States from frontera.contrib.backends.partitioners import Crc32NamePartitioner fr...
[ "frontera.utils.misc.load_object", "functools.partial", "frontera.utils.misc.get_crc32", "frontera.utils.url.parse_domain_from_url_fast", "time.time", "time.sleep", "msgpack.unpackb", "datetime.datetime.utcnow", "redis.ConnectionPool", "frontera.contrib.backends.partitioners.Crc32NamePartitioner",...
[((1592, 1625), 'redis.StrictRedis', 'StrictRedis', ([], {'connection_pool': 'pool'}), '(connection_pool=pool)\n', (1603, 1625), False, 'from redis import ConnectionPool, StrictRedis\n'), ((1649, 1698), 'logging.getLogger', 'logging.getLogger', (['"""redis_backend.RedisOperation"""'], {}), "('redis_backend.RedisOperati...
# -*- coding: utf-8 -*- # Copyright 2020 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...
[ "proto.MapField", "proto.module", "proto.Field" ]
[((746, 831), 'proto.module', 'proto.module', ([], {'package': '"""google.appengine.v1"""', 'manifest': "{'Service', 'TrafficSplit'}"}), "(package='google.appengine.v1', manifest={'Service',\n 'TrafficSplit'})\n", (758, 831), False, 'import proto\n'), ((2052, 2087), 'proto.Field', 'proto.Field', (['proto.STRING'], {...
# import ptvsd # ptvsd.enable_attach(address = ('0.0.0.0', 5678)) # ptvsd.wait_for_attach() import os import torch import torch.autograd as autograd import torch.nn as nn import torch.nn.functional as F import torch.optim as optim import torch.utils.data as Data from torch.optim.lr_scheduler import ReduceLROnPlateau f...
[ "sklearn.metrics.confusion_matrix", "pickle.dump", "numpy.random.seed", "argparse.ArgumentParser", "numpy.sum", "numpy.argmax", "pandas.read_csv", "random.shuffle", "time.ctime", "numpy.ones", "sklearn.metrics.f1_score", "os.path.isfile", "pickle.load", "torch.no_grad", "os.path.join", ...
[((1930, 1955), 'seaborn.set', 'sns.set', ([], {'color_codes': '(True)'}), '(color_codes=True)\n', (1937, 1955), True, 'import seaborn as sns\n'), ((28802, 28827), 'argparse.ArgumentParser', 'argparse.ArgumentParser', ([], {}), '()\n', (28825, 28827), False, 'import argparse\n'), ((12114, 12137), 'numpy.array', 'np.arr...
#!/usr/bin/env python # -*- coding: utf-8 -*- # @Time : 2019/4/17 9:52 # @File : startup.py # @Role : 启动脚本 import fire from tornado.options import define from websdk.program import MainProgram from settings import settings as app_settings from biz.applications import Application as CmdbApp from biz.crontab_...
[ "biz.crontab_app.Application", "tornado.options.define", "fire.Fire", "biz.applications.Application" ]
[((355, 424), 'tornado.options.define', 'define', (['"""service"""'], {'default': '"""api"""', 'help': '"""start service flag"""', 'type': 'str'}), "('service', default='api', help='start service flag', type=str)\n", (361, 424), False, 'from tornado.options import define\n'), ((852, 872), 'fire.Fire', 'fire.Fire', (['M...
import numpy as np from numpy.testing import assert_array_equal from landlab import RasterModelGrid def test_number_of_corners(): """Test number of corners on a raster.""" grid = RasterModelGrid((4, 5)) assert grid.number_of_corners == 12 def test_add_ones_at_corners(): """Test add a field to corne...
[ "numpy.testing.assert_array_equal", "landlab.RasterModelGrid", "numpy.arange" ]
[((190, 213), 'landlab.RasterModelGrid', 'RasterModelGrid', (['(4, 5)'], {}), '((4, 5))\n', (205, 213), False, 'from landlab import RasterModelGrid\n'), ((338, 361), 'landlab.RasterModelGrid', 'RasterModelGrid', (['(4, 5)'], {}), '((4, 5))\n', (353, 361), False, 'from landlab import RasterModelGrid\n'), ((403, 508), 'n...
#!/usr/bin/env python3 import sys ################################################ # # # MACHINE-DEPENDENT CONFIGURATION INFORMATION # # # ################################################ # this is probably reasonable on a sys...
[ "sys.exit" ]
[((3966, 3976), 'sys.exit', 'sys.exit', ([], {}), '()\n', (3974, 3976), False, 'import sys\n'), ((266020, 266030), 'sys.exit', 'sys.exit', ([], {}), '()\n', (266028, 266030), False, 'import sys\n'), ((253071, 253081), 'sys.exit', 'sys.exit', ([], {}), '()\n', (253079, 253081), False, 'import sys\n'), ((260732, 260742),...
import runBackend import sqlite3 as sql if __name__ == '__main__': with sql.connect(runBackend.dbName) as conn: cur = conn.cursor() # Create Table cur.execute('''CREATE TABLE videos (Id TEXT UNIQUE ,Title TEXT ,WebpageUrl TEXT UNIQUE ,LikeCount INTEGER ,UploadDate...
[ "runBackend.updateDB", "sqlite3.connect" ]
[((508, 529), 'runBackend.updateDB', 'runBackend.updateDB', ([], {}), '()\n', (527, 529), False, 'import runBackend\n'), ((74, 104), 'sqlite3.connect', 'sql.connect', (['runBackend.dbName'], {}), '(runBackend.dbName)\n', (85, 104), True, 'import sqlite3 as sql\n')]
from fastapi import FastAPI app = FastAPI() @app.get(path='/') def Home(): return {"Twitter Api":"Ready"}
[ "fastapi.FastAPI" ]
[((35, 44), 'fastapi.FastAPI', 'FastAPI', ([], {}), '()\n', (42, 44), False, 'from fastapi import FastAPI\n')]