content
stringlengths
1
1.04M
input_ids
listlengths
1
774k
ratio_char_token
float64
0.38
22.9
token_count
int64
1
774k
#! /usr/bin/env python ############################################################################## ## DendroPy Phylogenetic Computing Library. ## ## Copyright 2010-2015 Jeet Sukumaran and Mark T. Holder. ## All rights reserved. ## ## See "LICENSE.rst" for terms and conditions of usage. ## ## If you use this wo...
[ 2, 0, 1220, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 29113, 29113, 7804, 4242, 2235, 198, 2235, 220, 360, 437, 305, 20519, 1380, 2645, 6644, 5139, 38589, 10074, 13, 198, 2235, 198, 2235, 220, 15069, 3050, 12, 4626, 3852, 316, 4121...
3.587302
189
""" Copyright (c) Contributors to the Open 3D Engine Project. For complete copyright and license terms please see the LICENSE at the root of this distribution. SPDX-License-Identifier: Apache-2.0 OR MIT """ """ This script is used by the Editor HDR Color Grading component to use a stored lut asset path and pass it on...
[ 37811, 198, 15269, 357, 66, 8, 25767, 669, 284, 262, 4946, 513, 35, 7117, 4935, 13, 198, 1890, 1844, 6634, 290, 5964, 2846, 3387, 766, 262, 38559, 24290, 379, 262, 6808, 286, 428, 6082, 13, 198, 198, 4303, 36227, 12, 34156, 12, 3323...
2.998285
583
import nltk from django.conf import settings from tf_core.annotation import Annotation from tf_core.nltoolkit.helpers import TreebankWordTokenizer, NltkRegexpTokenizer, TextTilingTokenizer, \ StanfordTokenizer def tokenizer_hub(input_dict): """ Apply the *tokenizer* object on the Annotated Document Corpu...
[ 11748, 299, 2528, 74, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 198, 6738, 48700, 62, 7295, 13, 1236, 14221, 1330, 1052, 38983, 198, 6738, 48700, 62, 7295, 13, 77, 2528, 970, 15813, 13, 16794, 364, 1330, 12200, 17796, 26449, ...
2.709431
4,061
import numpy as np def isMaxMagUnity(real_part, imag_part): ''' Description: Checks if the maximum magnitude of the arguments is one Note: Consider this problem on the complex plane ... no vector magnitude larger than one Note: accuracy to account for computational error is included in the check ...
[ 11748, 299, 32152, 355, 45941, 198, 198, 4299, 318, 11518, 13436, 35955, 7, 5305, 62, 3911, 11, 3590, 62, 3911, 2599, 628, 220, 220, 220, 705, 7061, 198, 220, 220, 220, 12489, 25, 47719, 611, 262, 5415, 14735, 286, 262, 7159, 318, 5...
3.094637
317
# -*- coding: utf-8 -*- import os import datetime import socket import json import ctypes try: from urllib.parse import (quote, unquote) except ImportError: from urllib import (quote, unquote)
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 11748, 28686, 198, 11748, 4818, 8079, 198, 11748, 17802, 198, 11748, 33918, 198, 11748, 269, 19199, 198, 198, 28311, 25, 198, 220, 220, 220, 422, 2956, 297, 571, 13...
2.023438
128
from go import bytes, encoding.hex, fmt, io.ioutil, regexp from go.crypto import rand, sha256 import conv, dh, flag, sym from "github.com/strickyak/rye/contrib" import data "The global RingDict." RingDict = {} Ring = {} RingFilename = flag.String('ring', '', 'name of keyring file') RingSecret = flag.String('secret', ...
[ 6738, 467, 1330, 9881, 11, 21004, 13, 33095, 11, 46996, 11, 33245, 13, 72, 448, 346, 11, 40364, 79, 198, 6738, 467, 13, 29609, 78, 1330, 43720, 11, 427, 64, 11645, 198, 11748, 3063, 11, 34590, 11, 6056, 11, 5659, 198, 6738, 366, 1...
2.126646
1,595
from django.conf import settings REDIS_DB: int = settings.REGULATOR['REDIS_DB'] DEFAULT_CALLS: int = settings.REGULATOR.get('DEFAULT_CALLS', 10) DEFAULT_PERIOD: int = settings.REGULATOR.get('DEFAULT_PERIOD', 60)
[ 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 198, 22083, 1797, 62, 11012, 25, 493, 796, 6460, 13, 31553, 6239, 25633, 17816, 22083, 1797, 62, 11012, 20520, 198, 7206, 38865, 62, 34, 1847, 6561, 25, 493, 796, 6460, 13, 31553, 6239, ...
2.597561
82
from output.models.nist_data.atomic.unsigned_short.schema_instance.nistschema_sv_iv_atomic_unsigned_short_min_inclusive_3_xsd.nistschema_sv_iv_atomic_unsigned_short_min_inclusive_3 import NistschemaSvIvAtomicUnsignedShortMinInclusive3 __all__ = [ "NistschemaSvIvAtomicUnsignedShortMinInclusive3", ]
[ 6738, 5072, 13, 27530, 13, 77, 396, 62, 7890, 13, 47116, 13, 43375, 62, 19509, 13, 15952, 2611, 62, 39098, 13, 77, 1023, 2395, 2611, 62, 21370, 62, 452, 62, 47116, 62, 43375, 62, 19509, 62, 1084, 62, 259, 5731, 62, 18, 62, 87, 2...
2.62069
116
import os.path as osp import PIL.Image import numpy as np import tensorflow as tf from keras import backend as K import keras import sys import time from patch.constants import * from patch.image import load_image, StubImageLoader from patch.transformations import transform_vector image_loader = StubImageLoader(VALI...
[ 11748, 28686, 13, 6978, 355, 267, 2777, 198, 11748, 350, 4146, 13, 5159, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 11192, 273, 11125, 355, 48700, 198, 6738, 41927, 292, 1330, 30203, 355, 509, 198, 11748, 41927, 292, 198, 198, 1174...
2.575543
1,979
import os
[ 11748, 28686, 628 ]
3.666667
3
from __future__ import absolute_import import os import sys #### # Change per project #### from django.urls import reverse_lazy from django.utils.text import slugify PROJECT_NAME = 'unpp_api' # project root and add "apps" to the path PROJECT_ROOT = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) sys.path...
[ 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 198, 11748, 28686, 198, 11748, 25064, 628, 198, 4242, 198, 2, 9794, 583, 1628, 198, 4242, 198, 6738, 42625, 14208, 13, 6371, 82, 1330, 9575, 62, 75, 12582, 198, 6738, 42625, 14208, 13, 2...
2.181003
4,906
import random list = [3,2,1,5,6,4] k = 2 s = Solution() print(s.findKthLargest(list,k))
[ 11748, 4738, 198, 198, 4868, 796, 685, 18, 11, 17, 11, 16, 11, 20, 11, 21, 11, 19, 60, 198, 74, 796, 362, 198, 82, 796, 28186, 3419, 198, 4798, 7, 82, 13, 19796, 42, 400, 43, 853, 395, 7, 4868, 11, 74, 4008 ]
2
44
#coding=UTF-8 ''' Copyright (2021, ) Institute of Software, Chinese Academy of Sciences @author: wuyuewen@otcaix.iscas.ac.cn @author: wuheng@otcaix.iscas.ac.cn @since: 2019/09/29 ''' import os import re try: from utils import constants except: import constants class UserDefinedParser: ...
[ 2, 66, 7656, 28, 48504, 12, 23, 198, 7061, 6, 198, 15269, 357, 1238, 2481, 11, 1267, 5136, 286, 10442, 11, 3999, 8581, 286, 13473, 628, 220, 220, 220, 2488, 9800, 25, 266, 4669, 84, 413, 268, 31, 313, 6888, 844, 13, 2304, 292, 1...
1.614334
1,172
''' Author: tusikalanse Date: 2021-06-29 00:48:14 LastEditTime: 2021-06-29 00:48:14 LastEditors: tusikalanse Description: FilePath: /atcoder/mnt/e/algo/ProjectEuler/13.py ''' n = 0 for i in range(100): n += int(input()) print(str(n)[:10])
[ 7061, 6, 198, 13838, 25, 256, 385, 1134, 25786, 325, 198, 10430, 25, 33448, 12, 3312, 12, 1959, 3571, 25, 2780, 25, 1415, 198, 5956, 18378, 7575, 25, 33448, 12, 3312, 12, 1959, 3571, 25, 2780, 25, 1415, 198, 5956, 18378, 669, 25, ...
2.189189
111
# pylint: disable=duplicate-code # pylint: disable=line-too-long # pylint: disable=missing-function-docstring # pylint: disable=missing-function-docstring # pylint: disable=missing-module-docstring # pylint: disable=too-many-arguments # pylint: disable=too-many-branches # pylint: disable=too-many-instance-attributes # ...
[ 2, 279, 2645, 600, 25, 15560, 28, 646, 489, 5344, 12, 8189, 198, 2, 279, 2645, 600, 25, 15560, 28, 1370, 12, 18820, 12, 6511, 198, 2, 279, 2645, 600, 25, 15560, 28, 45688, 12, 8818, 12, 15390, 8841, 198, 2, 279, 2645, 600, 25, ...
3.332759
580
"""Plot of x position depending on spectral index estimation """ import numpy as np import matplotlib.pyplot as plt from astropy.table import Table from gammapy.spectrum.flux_point import _energy_lafferty_power_law from gammapy.spectrum.powerlaw import power_law_evaluate, power_law_integral_flux from flux_point_demo im...
[ 37811, 43328, 286, 2124, 2292, 6906, 319, 37410, 6376, 31850, 198, 37811, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 6738, 6468, 28338, 13, 11487, 1330, 8655, 198, 6738, 308, 6...
3.147826
115
import os import unittest from wtouch.touch import create_file if __name__ == '__main__': unittest.main()
[ 11748, 28686, 198, 11748, 555, 715, 395, 198, 6738, 266, 29332, 13, 29332, 1330, 2251, 62, 7753, 628, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 555, 715, 395, 13, 12417, 3419, 198 ]
2.756098
41
''' cmocean is a package to help standardize colormaps for commonly-plotted oceanographic properties. See README.md for an overview on instructions. ''' from __future__ import absolute_import # from cmocean import * from . import cm, tools, data __all__ = ['cm', 'tools', 'plots', 'd...
[ 7061, 6, 198, 66, 5908, 5829, 318, 257, 5301, 284, 1037, 3210, 1096, 951, 579, 1686, 329, 8811, 12, 489, 8426, 198, 78, 5829, 6826, 6608, 13, 198, 198, 6214, 20832, 11682, 13, 9132, 329, 281, 16700, 319, 7729, 13, 198, 7061, 6, 19...
2.518987
158
# License: MIT # Author: Robert Peharz import tensorflow as tf
[ 2, 13789, 25, 17168, 198, 2, 6434, 25, 5199, 2631, 9869, 89, 198, 198, 11748, 11192, 273, 11125, 355, 48700, 628 ]
3.095238
21
from django.http import Http404 from rest_framework.generics import ( get_object_or_404, GenericAPIView, CreateAPIView, ListAPIView, ListCreateAPIView, RetrieveAPIView, RetrieveUpdateDestroyAPIView, UpdateAPIView ) from rest_framework.response import Response from rest_framework.permiss...
[ 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 26429, 198, 198, 6738, 1334, 62, 30604, 13, 8612, 873, 1330, 357, 198, 220, 220, 220, 651, 62, 15252, 62, 273, 62, 26429, 11, 198, 220, 220, 220, 42044, 2969, 3824, 769, 11, 198, 220, ...
2.932464
1,688
# # This file made available under CC0 1.0 Universal (https://creativecommons.org/publicdomain/zero/1.0/legalcode) # # Created with the Rule Development Kit: https://github.com/awslabs/aws-config-rdk # Can be used stand-alone or with the Rule Compliance Engine: https://github.com/awslabs/aws-config-engine-for-complianc...
[ 2, 198, 2, 770, 2393, 925, 1695, 739, 12624, 15, 352, 13, 15, 14499, 357, 5450, 1378, 20123, 425, 9503, 684, 13, 2398, 14, 11377, 27830, 14, 22570, 14, 16, 13, 15, 14, 18011, 8189, 8, 198, 2, 198, 2, 15622, 351, 262, 14330, 7712...
3.15015
333
#!/usr/bin/env python2 # -*- coding: utf-8 -*- # # SPDX-License-Identifier: GPL-3.0 # ################################################## # GNU Radio Python Flow Graph # Title: Dtv Sigmf # Generated: Fri Feb 22 02:11:45 2019 # GNU Radio version: 3.7.12.0 ################################################## if __name__ ==...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 17, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 198, 2, 30628, 55, 12, 34156, 12, 33234, 7483, 25, 38644, 12, 18, 13, 15, 198, 2, 198, 29113, 14468, 2235, ...
2.753149
397
""" A smart home function that can push configuration updates to a Google Cloud IoT device to control individually a few pins """ from flask import jsonify import base64 import json from googleapiclient import discovery from googleapiclient.errors import HttpError DEVICE = 'd0123156631436CC0FE' REGISTRY = 'mini'...
[ 198, 37811, 198, 32, 4451, 1363, 2163, 326, 460, 4574, 8398, 5992, 284, 257, 3012, 10130, 38488, 3335, 198, 1462, 1630, 17033, 257, 1178, 20567, 198, 198, 37811, 198, 198, 6738, 42903, 1330, 33918, 1958, 198, 11748, 2779, 2414, 198, 117...
2.680871
1,056
import click import json from jinja2 import Environment, select_autoescape, FileSystemLoader from filters import add_filters @click.group() @cli.command() @click.argument("json_resume", type=click.File("r")) @click.argument("template_path") @click.argument("output_file", type=click.File("w")) @cli.command() @cli...
[ 11748, 3904, 198, 11748, 33918, 198, 198, 6738, 474, 259, 6592, 17, 1330, 9344, 11, 2922, 62, 2306, 3028, 36435, 11, 9220, 11964, 17401, 198, 6738, 16628, 1330, 751, 62, 10379, 1010, 628, 198, 31, 12976, 13, 8094, 3419, 628, 198, 31, ...
2.958084
167
import json import mysql.connector from mysql.connector import errorcode def read_config_parameter(path_to_file): """ read configure parameters from file :param path_to_file: path to config file :return: config: configure parameters used to connect to MySQL DB_NAME: name of database shoul...
[ 11748, 33918, 198, 11748, 48761, 13, 8443, 273, 198, 6738, 48761, 13, 8443, 273, 1330, 4049, 8189, 198, 198, 4299, 1100, 62, 11250, 62, 17143, 2357, 7, 6978, 62, 1462, 62, 7753, 2599, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 1...
2.454545
1,122
import tensorflow as tf import numpy as np
[ 11748, 11192, 273, 11125, 355, 48700, 198, 11748, 299, 32152, 355, 45941, 628 ]
3.384615
13
from django.core.urlresolvers import reverse from django.db import models from filer.fields.image import FilerImageField from .category import Category
[ 6738, 42625, 14208, 13, 7295, 13, 6371, 411, 349, 690, 1330, 9575, 198, 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 6738, 1226, 263, 13, 25747, 13, 9060, 1330, 376, 5329, 5159, 15878, 198, 198, 6738, 764, 22872, 1330, 21743, 628, 6...
3.714286
42
from typing import Tuple, Any import numpy as np import torch from torch import nn import gym from typing import List from wordrl.experience import SequenceReplay, Experience from wordrl.envs.wordle_env_v2_visualized import WORDS class ActorCriticAgent: """Actor-Critic based agent that returns an action bas...
[ 6738, 19720, 1330, 309, 29291, 11, 4377, 198, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 28034, 198, 6738, 28034, 1330, 299, 77, 198, 11748, 11550, 198, 198, 6738, 19720, 1330, 7343, 628, 198, 6738, 1573, 45895, 13, 23100, 1240, 13...
2.552783
521
import logging from time import sleep from itertools import chain from threading import Thread try: from Queue import Queue, Full except ImportError: from queue import Queue, Full try: from urllib.parse import quote except ImportError: from urllib import quote from sys import version_info PY2 = versio...
[ 11748, 18931, 198, 6738, 640, 1330, 3993, 198, 6738, 340, 861, 10141, 1330, 6333, 198, 6738, 4704, 278, 1330, 14122, 198, 28311, 25, 198, 220, 220, 220, 422, 4670, 518, 1330, 4670, 518, 11, 6462, 198, 16341, 17267, 12331, 25, 198, 220...
2.798604
1,003
""" 一个案例数据: { "msgtype": "text", "text": { "content": "告警测试exception" }, "at": { "atMobiles": [ "10086" ] } } 参考文档: https://developers.dingtalk.com/document/app/custom-robot-access """ import json import requests base_url = "https://oapi.dingtalk.com/robot/send"...
[ 37811, 198, 31660, 10310, 103, 162, 94, 230, 160, 122, 233, 46763, 108, 162, 235, 106, 25, 198, 90, 198, 220, 220, 220, 366, 19662, 4906, 1298, 366, 5239, 1600, 198, 220, 220, 220, 366, 5239, 1298, 1391, 198, 220, 220, 220, 220, 2...
1.75
184
import compileall import site import sys import shutil import zipfile from importlib import import_module from pathlib import Path from .environment import Environment from .interpreter import execute_interpreter def current_zipfile(): """A function to vend the current zipfile, if any""" if zipfile.is_zipfi...
[ 11748, 17632, 439, 198, 11748, 2524, 198, 11748, 25064, 198, 11748, 4423, 346, 198, 11748, 19974, 7753, 198, 198, 6738, 1330, 8019, 1330, 1330, 62, 21412, 198, 6738, 3108, 8019, 1330, 10644, 198, 198, 6738, 764, 38986, 1330, 9344, 198, ...
2.789306
1,571
#!/usr/bin/env python2 #Author: Stefan Toman if __name__ == '__main__': t = int(raw_input()) for _ in range(t): s = raw_input().strip() r = 0 for i in range(1, len(s)): r += subsequences(s[:i], s[i:]) r %= 1000000007 print r
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 17, 198, 198, 2, 13838, 25, 28842, 4186, 272, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 256, 796, 493, 7, 1831, 62, 15414, 28955, 198, 220, ...
1.877419
155
"""Config module to pass data accross the repository project. Warning: NEVER RELOAD THIS MODULE. If you do you, you will lose all the data that was stored by the application instance. :created: 12/12/2018 :author: Benoit GIELLY <benoit.gielly@gmail.com> """ COMMAND_CALLBACK = None
[ 37811, 16934, 8265, 284, 1208, 1366, 697, 1214, 262, 16099, 1628, 13, 198, 198, 20361, 25, 198, 220, 220, 220, 33602, 29749, 41048, 12680, 33893, 13, 198, 220, 220, 220, 1002, 345, 466, 345, 11, 345, 481, 4425, 477, 262, 1366, 326, ...
3.030612
98
import pathlib import pytest from datapublic.common_fields import CommonFields from libs.datasets import AggregationLevel from libs.datasets import combined_dataset_utils from libs.datasets import combined_datasets from libs.datasets import data_source from libs.datasets import timeseries from libs.datasets.timeserie...
[ 11748, 3108, 8019, 198, 198, 11748, 12972, 9288, 198, 6738, 4818, 499, 841, 13, 11321, 62, 25747, 1330, 8070, 15878, 82, 198, 198, 6738, 9195, 82, 13, 19608, 292, 1039, 1330, 19015, 43068, 4971, 198, 6738, 9195, 82, 13, 19608, 292, 10...
3.282895
152
# Definition for a binary tree node. # class TreeNode: # def __init__(self, val=0, left=None, right=None): # self.val = val # self.left = left # self.right = right
[ 2, 30396, 329, 257, 13934, 5509, 10139, 13, 201, 198, 2, 1398, 12200, 19667, 25, 201, 198, 2, 220, 220, 220, 220, 825, 11593, 15003, 834, 7, 944, 11, 1188, 28, 15, 11, 1364, 28, 14202, 11, 826, 28, 14202, 2599, 201, 198, 2, 220,...
2.080808
99
# Generated by Django 3.1.7 on 2021-05-22 12:21 from django.db import migrations, models
[ 2, 2980, 515, 416, 37770, 513, 13, 16, 13, 22, 319, 33448, 12, 2713, 12, 1828, 1105, 25, 2481, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 628 ]
2.84375
32
import ibm_cloud_sdk_core import ibm_watson APIKEY = "A4LMwqnkIQac81v88v14_AZLj5F__wjY83S9WOgjqAXw" APIVERSION = '2019-02-28' APIURL = 'https://gateway-wdc.watsonplatform.net/assistant/api' ASSISTANT_ID = 'f2ddf51f-1048-44ad-a4a8-3d5a5289178a' service = ibm_watson.AssistantV1( iam_apikey=APIKEY, version=APIVE...
[ 11748, 24283, 76, 62, 17721, 62, 21282, 74, 62, 7295, 198, 11748, 24283, 76, 62, 86, 13506, 198, 198, 17614, 20373, 796, 366, 32, 19, 31288, 86, 80, 77, 74, 33866, 330, 6659, 85, 3459, 85, 1415, 62, 22778, 43, 73, 20, 37, 834, 8...
2.517763
1,323
"""ASE interface for MST module implemented in MuST package available at https://github.com/mstsuite/MuST""" import numpy as np from ase.calculators.calculator import FileIOCalculator, SCFError import os import subprocess import glob from ase.units import Bohr, Rydberg from default_params import defaults from ase.dat...
[ 37811, 11159, 7071, 329, 337, 2257, 8265, 9177, 287, 8252, 2257, 5301, 1695, 379, 198, 3740, 1378, 12567, 13, 785, 14, 76, 301, 2385, 578, 14, 33239, 2257, 37811, 198, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 257, 325, 13, 9948,...
2.015959
6,642
from django.conf import settings from vonage import Client, Sms from .abstract import AbstractProvider VONAGE_API_KEY = getattr(settings, 'MULTAUTH_PROVIDER_VONAGE_API_KEY', None) VONAGE_API_SECRET = getattr(settings, 'MULTAUTH_PROVIDER_VONAGE_API_SECRET', None) vonage_from = getattr(settings, 'MULTAUTH_PROVIDER_VON...
[ 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 18042, 496, 1330, 20985, 11, 311, 907, 198, 198, 6738, 764, 397, 8709, 1330, 27741, 29495, 628, 198, 53, 1340, 11879, 62, 17614, 62, 20373, 796, 651, 35226, 7, 33692, 11, 705, 44, ...
2.635135
222
# Copyright 2019 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
[ 2, 15069, 13130, 383, 309, 22854, 37535, 46665, 13, 1439, 6923, 33876, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846,...
3.578358
268
############# Credits and version info ############# # Definition generated from Assembly XML tag def # Date generated: 2018/12/03 04:56 # # revision: 1 author: Assembly # Generated plugin from scratch. # revision: 2 author: -DeToX- # added two string ids # revision: 3 author: Lord Zedd # Updated and c...
[ 7804, 4242, 2, 29501, 290, 2196, 7508, 1303, 7804, 4242, 201, 198, 2, 30396, 7560, 422, 10006, 23735, 7621, 825, 201, 198, 2, 197, 7536, 7560, 25, 2864, 14, 1065, 14, 3070, 220, 8702, 25, 3980, 201, 198, 2, 201, 198, 2, 18440, 25,...
2.160591
2,908
import configparser import threading from rich.console import Console from rich.live import Live from rich.layout import Layout from rich.panel import Panel from rich.table import Table from rich.prompt import Prompt import raritan.rpc from raritan.rpc import pdumodel console = Console() layout = Layout() # Divide...
[ 11748, 4566, 48610, 198, 11748, 4704, 278, 198, 198, 6738, 5527, 13, 41947, 1330, 24371, 198, 6738, 5527, 13, 12583, 1330, 7547, 198, 6738, 5527, 13, 39786, 1330, 47639, 198, 6738, 5527, 13, 35330, 1330, 18810, 198, 6738, 5527, 13, 1148...
2.716931
378
from bs4 import BeautifulSoup import requests URL = "https://www.filmempfehlung.com/die-top-100.html" response = requests.get(URL) response.raise_for_status() soup = BeautifulSoup(response.text, "html.parser") movie_rankings = [int(ranking.getText()) for ranking in soup.find_all(name="span", class_="platznr round...
[ 6738, 275, 82, 19, 1330, 23762, 50, 10486, 198, 11748, 7007, 628, 198, 21886, 796, 366, 5450, 1378, 2503, 13, 10379, 11883, 79, 5036, 18519, 2150, 13, 785, 14, 11979, 12, 4852, 12, 3064, 13, 6494, 1, 198, 198, 26209, 796, 7007, 13, ...
2.726415
212
# Copyright 2014 Scalyr 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 writing, so...
[ 2, 15069, 1946, 34529, 2417, 3457, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, 198, 2, 921,...
2.46079
3,596
import matplotlib.pyplot as plt import pandas as pd import ast import itertools import utils.file_utils as fu import os import configparser import numpy as np def load_results_dataframe(path): """ Load a csv file output from running an experiment and return as a DataFrame :param path: :return: """ ...
[ 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 6468, 198, 11748, 340, 861, 10141, 198, 11748, 3384, 4487, 13, 7753, 62, 26791, 355, 14035, 198, 11748, 28686, 198, 11748, 4566, ...
2.302081
10,570
import pika connection = pika.BlockingConnection(pika.ConnectionParameters("localhost")) channel = connection.channel() channel.queue_declare(queue="hello") channel.basic_publish(exchange="", routing_key="hello", body="Hello from producer again!") connection.close()
[ 11748, 279, 9232, 198, 38659, 796, 279, 9232, 13, 3629, 8629, 32048, 7, 79, 9232, 13, 32048, 48944, 7203, 36750, 48774, 198, 17620, 796, 4637, 13, 17620, 3419, 198, 17620, 13, 36560, 62, 32446, 533, 7, 36560, 2625, 31373, 4943, 198, 1...
3.708333
72
from styx_msgs.msg import TrafficLight import cv2 import numpy as np
[ 6738, 8944, 87, 62, 907, 14542, 13, 19662, 1330, 23624, 15047, 198, 11748, 269, 85, 17, 198, 11748, 299, 32152, 355, 45941, 198 ]
3
23
#!/usr/bin/env python3 # # Advent of Code 2020 - day 9 # from pathlib import Path from itertools import combinations INPUTFILE = "input.txt" SAMPLE_INPUT = """ 35 20 15 25 47 40 62 55 65 95 102 117 150 182 127 219 299 277 309 576 """ # Utility functions # Solution def solve(lines, prefix=25): """Solve ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 198, 2, 220, 33732, 286, 6127, 12131, 532, 1110, 860, 198, 2, 198, 6738, 3108, 8019, 1330, 10644, 198, 6738, 340, 861, 10141, 1330, 17790, 628, 198, 1268, 30076, 25664, 796, 3...
2.138783
526
""" Run to update all the database json files that can be served from the website """ import json import requests import numpy as np from sklearn.feature_extraction.text import TfidfVectorizer from sklearn.feature_extraction import stop_words from sklearn import svm # ------------------------------------------------...
[ 37811, 198, 10987, 284, 4296, 477, 262, 6831, 33918, 3696, 326, 460, 307, 4983, 422, 262, 3052, 198, 37811, 198, 198, 11748, 33918, 198, 11748, 7007, 198, 11748, 299, 32152, 355, 45941, 198, 198, 6738, 1341, 35720, 13, 30053, 62, 2302, ...
2.400716
1,118
from decouple import config DB_DUMPS_DIR = "../data/db_dumps" PRODUCTS_DIR = "../data/products" REVIEWS_DIR = "../data/reviews" SPECS_DIR = "../data/specs" SQL_DIR = "sql" RATINGS_DIR = "../data/ratings" REVIEWS_PER_REQUEST = 4000 HEADER_DEFAULT = { "Accept": "application/json, text/*", "Accept-Encoding": "g...
[ 6738, 875, 43846, 1330, 4566, 198, 198, 11012, 62, 35, 5883, 3705, 62, 34720, 796, 366, 40720, 7890, 14, 9945, 62, 67, 8142, 1, 198, 4805, 28644, 50, 62, 34720, 796, 366, 40720, 7890, 14, 29498, 1, 198, 2200, 28206, 50, 62, 34720, ...
2.187879
495
import re from notion.markdown import FORMAT_PRECEDENCE, _NOTION_TO_MARKDOWN_MAPPER, delimiters
[ 11748, 302, 198, 198, 6738, 9495, 13, 4102, 2902, 1330, 7473, 41636, 62, 47, 38827, 1961, 18310, 11, 4808, 11929, 2849, 62, 10468, 62, 44, 14175, 41925, 62, 33767, 18973, 11, 46728, 270, 364, 628 ]
2.8
35
# # Copyright 2018 Stephen Cuppett # # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. # The ASF licenses this file to You under the Apache License, Version 2....
[ 2, 198, 2, 15069, 2864, 7970, 327, 7211, 3087, 198, 2, 198, 2, 49962, 284, 262, 24843, 10442, 5693, 357, 1921, 37, 8, 739, 530, 393, 517, 198, 2, 18920, 5964, 11704, 13, 220, 4091, 262, 28536, 2393, 9387, 351, 198, 2, 428, 670, ...
4.208
250
# -*- coding: utf-8 -*- import pytest # from .unittestsetup import environment as environment from ..unittestsetup import fetchTestData, fetchRawData, fetchFullResponse from ..unittestsetup import API_URL, client import requests_mock from virtual_finance_api.client import Client from virtual_finance_api.exceptions i...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 11748, 12972, 9288, 198, 198, 2, 422, 764, 403, 715, 395, 40406, 1330, 2858, 355, 2858, 198, 6738, 11485, 403, 715, 395, 40406, 1330, 21207, 14402, 6601, 11, 21207,...
2.42926
622
import pandas print(pandas.__version__)
[ 11748, 19798, 292, 198, 198, 4798, 7, 79, 392, 292, 13, 834, 9641, 834, 8, 198 ]
2.5625
16
import numpy as np import pandas as pd def load_data(cluster, opt): '''Data Loading & Processing''' if opt == "seq": df = pd.read_csv( f'../data/{cluster}/cluster_sequence.csv', parse_dates=['time'], index_col='time') elif opt == "tp": df = pd.read_csv( f'../data/{c...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 628, 198, 4299, 3440, 62, 7890, 7, 565, 5819, 11, 2172, 2599, 198, 220, 220, 220, 705, 7061, 6601, 12320, 1222, 28403, 7061, 6, 198, 220, 220, 220, 611, 2172, 6624...
2.14977
434
''' Created on Feb 1, 2016 @author: jumbrich @author: svakulenko ''' import os import logging from pyyacp import YACParser from pyyacp.profiler import profile SAMPLES_PATH = "sample_csvs/" SAMPLE_CSVS = ["bevoelkerung.csv", "bezirkszahlen.csv", "hunde_wien.csv", "hunde_wien2.csv"] if __name__ == '__main__'...
[ 7061, 6, 198, 41972, 319, 3158, 352, 11, 1584, 198, 198, 31, 9800, 25, 474, 388, 1671, 488, 198, 31, 9800, 25, 38487, 461, 377, 32720, 198, 7061, 6, 198, 11748, 28686, 198, 11748, 18931, 198, 198, 6738, 12972, 88, 330, 79, 1330, 5...
2.349315
146
# Common errors GENERAL_ERROR = "GENERAL_ERROR" PERMISSION_DENIED_ERROR = "PERMISSION_DENIED_ERROR" OBJECT_DOES_NOT_EXIST_ERROR = "OBJECT_DOES_NOT_EXIST_ERROR" DATA_VALIDATION_ERROR = "DATA_VALIDATION_ERROR" API_USAGE_ERROR = "API_USAGE_ERROR" QUERY_TOO_DEEP_ERROR = "QUERY_TOO_DEEP_ERROR" # Kukkuu specific errors MAX_...
[ 2, 8070, 8563, 198, 35353, 27130, 62, 24908, 796, 366, 35353, 27130, 62, 24908, 1, 198, 18973, 44, 40373, 62, 41819, 19767, 62, 24908, 796, 366, 18973, 44, 40373, 62, 41819, 19767, 62, 24908, 1, 198, 9864, 23680, 62, 18227, 1546, 62, ...
2.18429
662
# Crie um programa que leia o nome de uma cidade e diga se ela começa ou não com o nome "SANTO" nome = str(input('Qual o nome da cidade que você nasceu? ')).strip() print(nome[:5].upper() == 'SANTO') # Exercício Python 025: Crie um programa que leia o nome de uma pessoa e diga se ela tem "SILVA" no nome. nome = str...
[ 2, 327, 5034, 23781, 1430, 64, 8358, 443, 544, 267, 299, 462, 390, 334, 2611, 269, 312, 671, 304, 3100, 64, 384, 1288, 64, 1282, 50041, 267, 84, 299, 28749, 401, 267, 299, 462, 366, 50, 8643, 46, 1, 198, 198, 77, 462, 796, 965, ...
2.44206
233
from flask import Flask, request, render_template, abort import os app = Flask(__name__) FEATURE = os.environ.get('FEATURE') @app.route('/') if __name__ == '__main__': app.run(host='0.0.0.0', port=8080)
[ 6738, 42903, 1330, 46947, 11, 2581, 11, 8543, 62, 28243, 11, 15614, 198, 11748, 28686, 198, 198, 1324, 796, 46947, 7, 834, 3672, 834, 8, 198, 15112, 40086, 796, 28686, 13, 268, 2268, 13, 1136, 10786, 15112, 40086, 11537, 198, 198, 31,...
2.518072
83
import numpy as np from sklearn.utils import check_random_state from rlnn.examples.nm_tmaze import NonMarkovianTMaze from rlnn.model.ffnn import FeedForwardNetwork from rlnn.model.lstm import LongShortTermMemoryNetwork from rlnn.model.rl_cm import q_cm if __name__ == "__main__": main()
[ 11748, 299, 32152, 355, 45941, 198, 6738, 1341, 35720, 13, 26791, 1330, 2198, 62, 25120, 62, 5219, 198, 198, 6738, 374, 18755, 77, 13, 1069, 12629, 13, 21533, 62, 17209, 6201, 1330, 8504, 9704, 709, 666, 15972, 6201, 198, 198, 6738, 3...
2.811321
106
# Generated by Django 3.0.5 on 2020-05-09 06:47 from django.db import migrations
[ 2, 2980, 515, 416, 37770, 513, 13, 15, 13, 20, 319, 12131, 12, 2713, 12, 2931, 9130, 25, 2857, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 628 ]
2.766667
30
################################################################# # Search and replace.py # # Looks for the old_string and replace it with the new_string # ################################################################# # Import and configure all plugins import os, configpar...
[ 29113, 29113, 2, 198, 2, 11140, 290, 6330, 13, 9078, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, ...
3.05977
435
from django.conf import settings from django.db import models from six import python_2_unicode_compatible from django.utils.encoding import force_str from django.utils.functional import cached_property from django.utils.translation import ugettext_lazy as _ from fluent_contents.extensions import PluginUrlField from fl...
[ 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 6738, 2237, 1330, 21015, 62, 17, 62, 46903, 1098, 62, 38532, 198, 6738, 42625, 14208, 13, 26791, 13, 12685, 7656, 1330, 2700, 62, 2536, 198, ...
3.171717
396
A().ba B().bar C().bar
[ 198, 198, 32, 22446, 7012, 628, 198, 198, 33, 22446, 5657, 628, 198, 198, 34, 22446, 5657 ]
1.764706
17
""" replik creates an easy-to-reuse environment based on docker """ import json import os import sys from os import makedirs, remove from os.path import basename, isdir, isfile, join from shutil import copyfile, move from typing import Dict import click import replik.console as console import replik.init as init impo...
[ 37811, 198, 35666, 1134, 8075, 281, 2562, 12, 1462, 12, 260, 1904, 2858, 1912, 319, 36253, 198, 37811, 198, 11748, 33918, 198, 11748, 28686, 198, 11748, 25064, 198, 6738, 28686, 1330, 285, 4335, 17062, 11, 4781, 198, 6738, 28686, 13, 69...
2.348941
897
import random import sqlite3 from src.main.python_sqlite.user import USER if __name__ == "__main__": ########################### # connect/create database # ########################### # create database in memory # db = sqlite3.connect(':memory:') # create database into directory db = s...
[ 11748, 4738, 198, 11748, 44161, 578, 18, 198, 6738, 12351, 13, 12417, 13, 29412, 62, 25410, 578, 13, 7220, 1330, 1294, 1137, 628, 198, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 1303, 14468, 7804...
2.837724
3,075
import unittest import numpy as np from openspectra.openspectra_file import OpenSpectraFileFactory if __name__ == '__main__': """A simple utility to scan float files for out of range values, set lower and upper limits below. Generates and prints out a bad band list, bbl, that can be used in the file...
[ 11748, 555, 715, 395, 198, 198, 11748, 299, 32152, 355, 45941, 198, 198, 6738, 9808, 806, 430, 13, 44813, 806, 430, 62, 7753, 1330, 4946, 49738, 430, 8979, 22810, 628, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354...
2.93985
133
#!/usr/bin/python3 """ Python interface to Apache PDFBox. """ import hashlib import html.parser import os import pathlib import re import shutil import urllib.request import appdirs import pkg_resources import sarge from sarge import run, Capture pdfbox_archive_url = 'https://archive.apache.org/dist/pdfbox/' class...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 18, 198, 198, 37811, 198, 37906, 7071, 284, 24843, 12960, 14253, 13, 198, 37811, 198, 198, 11748, 12234, 8019, 198, 11748, 27711, 13, 48610, 198, 11748, 28686, 198, 11748, 3108, 8019, 198, 11748, 30...
1.887309
5,484
from .decode import execute_reasoning from .mac_cell import MAC_Component
[ 198, 6738, 764, 12501, 1098, 1330, 12260, 62, 41181, 278, 198, 6738, 764, 20285, 62, 3846, 1330, 20582, 62, 21950 ]
3.7
20
import logging import requests import cerberus from fireplan.schemas import ALARM_SCHEMA, STATUS_SCHEMA logger = logging.getLogger(__name__)
[ 11748, 18931, 198, 11748, 7007, 198, 11748, 26074, 39192, 198, 6738, 2046, 11578, 13, 1416, 4411, 292, 1330, 8355, 33456, 62, 50, 3398, 27630, 11, 15486, 2937, 62, 50, 3398, 27630, 198, 198, 6404, 1362, 796, 18931, 13, 1136, 11187, 1362...
3.042553
47
#!/usr/bin/env python3 """ This script runs a single query to get the server cookie for a given IP/domain pair. The result is written to the specified log file """ import argparse import json import time import dns.resolver from dns.edns import GenericOption from dns.message import make_query COOKIE_OPT = 10 CLIENT_...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 37811, 198, 1212, 4226, 4539, 257, 2060, 12405, 284, 651, 262, 4382, 19751, 329, 257, 1813, 6101, 14, 27830, 5166, 13, 198, 464, 1255, 318, 3194, 284, 262, 7368, 2604, 2393, 198, ...
2.795775
284
import rubrik_cdm rubrik = rubrik_cdm.Connect() # Retrieve summary information for the "Python SDK" SLA Domain sla_name = "Python SDK" sla_summary_information = rubrik.get('v1', '/sla_domain?name={}'.format(sla_name))
[ 11748, 6437, 12602, 62, 10210, 76, 198, 198, 25089, 12602, 796, 6437, 12602, 62, 10210, 76, 13, 13313, 3419, 198, 198, 2, 4990, 30227, 10638, 1321, 329, 262, 366, 37906, 26144, 1, 12419, 32, 20021, 198, 82, 5031, 62, 3672, 796, 366, ...
2.7625
80
from socketio import ClientNamespace as SocketIOClientNamespace from operator import itemgetter from switcheo.utils import stringify_message, sha1_hash_digest import threading
[ 6738, 17802, 952, 1330, 20985, 36690, 10223, 355, 47068, 9399, 11792, 36690, 10223, 198, 6738, 10088, 1330, 2378, 1136, 353, 198, 6738, 1509, 270, 2395, 78, 13, 26791, 1330, 4731, 1958, 62, 20500, 11, 427, 64, 16, 62, 17831, 62, 12894, ...
3.729167
48
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # Distributed under the terms of the MIT License. """ Functions for I/O of BRENDA DB. Author: Andrew Tarzia Date Created: 24 Apr 2018 """ from ercollect import rxn_syst import os from ercollect import DB_functions from ercollect import CHEBI_IO from ercollect import P...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 4307, 6169, 739, 262, 2846, 286, 262, 17168, 13789, 13, 198, 198, 37811, 198, 24629, 2733, 329, 314, 14, 46, ...
2.086643
8,587
from .base import * SECRETS_DEV = SECRETS_FULL['dev'] DEBUG = True WSGI_APPLICATION = 'config.wsgi.dev.application' # Static files (CSS, JavaScript) STATIC_URL = '/static/' STATIC_ROOT = os.path.join(ROOT_DIR, 'staticfiles') # Media Files (Images, i.e. User Uploads) MEDIA_ROOT = os.path.join(ROOT_DIR, '.media') ...
[ 6738, 764, 8692, 1330, 1635, 198, 198, 23683, 2200, 4694, 62, 39345, 796, 10729, 2200, 4694, 62, 37, 9994, 17816, 7959, 20520, 198, 198, 30531, 796, 6407, 198, 198, 19416, 18878, 62, 2969, 31484, 6234, 796, 705, 11250, 13, 18504, 12397,...
2.2443
307
tup1 = (1,2) tup2 = (3,4) tuple[1] = tuple[1] + tuple[0] # Output should error out
[ 83, 929, 16, 796, 357, 16, 11, 17, 8, 198, 83, 929, 17, 796, 357, 18, 11, 19, 8, 198, 83, 29291, 58, 16, 60, 796, 46545, 58, 16, 60, 1343, 46545, 58, 15, 60, 198, 198, 2, 25235, 815, 4049, 503 ]
1.97619
42
import argparse import gym import numpy as np import random from time import sleep from agent import Agent from memory import MemoryItem from preprocessing import preprocess import logging log = logging.getLogger(__name__) log.setLevel(logging.DEBUG) formatter = logging.Formatter('%(asctime)s - %(name)s - %(levelna...
[ 11748, 1822, 29572, 198, 198, 11748, 11550, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 4738, 198, 6738, 640, 1330, 3993, 198, 198, 6738, 5797, 1330, 15906, 198, 6738, 4088, 1330, 14059, 7449, 198, 6738, 662, 36948, 1330, 662, 14681, ...
1.98087
1,150
"""Twin Delayed Deep Deterministic Policy Gradient (TD3).""" from .policy import TD3TorchPolicy from .trainer import TD3Trainer
[ 37811, 5080, 259, 4216, 16548, 10766, 45559, 49228, 7820, 17701, 1153, 357, 21016, 18, 21387, 15931, 198, 6738, 764, 30586, 1330, 13320, 18, 15884, 354, 36727, 198, 6738, 764, 2213, 10613, 1330, 13320, 18, 2898, 10613, 198 ]
3.459459
37
# palavra= ('Aprender','Programar','linguagem','Python','curso','Gratis','Estudar','Praticar','Trabalhar', # 'Mercado','Programador','Futuro') # for p in palavra: # # print(f'\nNa palavra {p} temos',end=' ') # for letra in p: # if letra.lower() in 'aeiou': # print(letra, end=' ...
[ 2, 6340, 615, 430, 28, 19203, 32, 3866, 681, 41707, 15167, 283, 41707, 1359, 84, 363, 368, 41707, 37906, 41707, 22019, 568, 41707, 8642, 37749, 41707, 36, 19149, 283, 41707, 6836, 1512, 283, 41707, 2898, 44349, 9869, 3256, 198, 2, 220, ...
2.116279
301
""" Copyright 2021 Vitaliy Zarubin 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, softwar...
[ 37811, 198, 15269, 33448, 28476, 7745, 28193, 549, 259, 198, 198, 26656, 15385, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 5832, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, ...
3.178998
419
"""Utils for server's economy. This utils contains all needed functions to handle economy operations between users or certain commands. This file can also be imported as a module and contains the following functions: * check_account - checks is a user points account exists * add_new_account - adds new points ...
[ 37811, 18274, 4487, 329, 4382, 338, 3773, 13, 198, 198, 1212, 3384, 4487, 4909, 477, 2622, 5499, 284, 5412, 3773, 4560, 198, 23395, 2985, 393, 1728, 9729, 13, 198, 198, 1212, 2393, 460, 635, 307, 17392, 355, 257, 8265, 290, 4909, 262,...
2.54406
3,064
from flask import Flask from flask_sqlalchemy import SQLAlchemy from flask_jwt_extended import JWTManager from flask_marshmallow import Marshmallow from flask_migrate import Migrate from flask_session import Session import config as Config db = SQLAlchemy() # ORM Database ma = Marshmallow() # Marshmallow for seriali...
[ 6738, 42903, 1330, 46947, 198, 6738, 42903, 62, 25410, 282, 26599, 1330, 16363, 2348, 26599, 198, 6738, 42903, 62, 73, 46569, 62, 2302, 1631, 1330, 449, 39386, 13511, 198, 6738, 42903, 62, 76, 5406, 42725, 1330, 9786, 42725, 198, 6738, ...
3.75
108
import time import sys import win32gui import win32api import win32con import re import pyautogui import win32ui from ctypes import windll from PIL import Image from likeyoubot_configure import LYBConstant as lybconstant import random
[ 11748, 640, 198, 11748, 25064, 198, 11748, 1592, 2624, 48317, 198, 11748, 1592, 2624, 15042, 198, 11748, 1592, 2624, 1102, 198, 11748, 302, 198, 11748, 12972, 2306, 519, 9019, 198, 11748, 1592, 2624, 9019, 198, 6738, 269, 19199, 1330, 234...
3.371429
70
"""Bazel rules for nucleus_py_* targets that can depend on C++ code.""" # A provider with one field, transitive_deps. CppFilesInfo = provider(fields = ["transitive_deps"]) def get_transitive_deps(deps): """Return all the transitive dependencies of deps.""" return depset( deps, transitive = [de...
[ 37811, 33, 41319, 3173, 329, 29984, 62, 9078, 62, 9, 6670, 326, 460, 4745, 319, 327, 4880, 2438, 526, 15931, 198, 198, 2, 317, 10131, 351, 530, 2214, 11, 1007, 1800, 62, 10378, 82, 13, 198, 34, 381, 25876, 12360, 796, 10131, 7, 25...
2.22556
1,831
import astropy.io.fits as pyfits import numpy as np from pkg_resources import resource_filename from lenstronomy.Util import kernel_util from lenstronomy.Data.psf import PSF __all__ = ['instantiate_PSF_kwargs','get_PSF_model'] def instantiate_PSF_kwargs(psf_type, pixel_scale, seeing, kernel_size, which_psf_maps): ...
[ 11748, 6468, 28338, 13, 952, 13, 21013, 355, 12972, 21013, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 279, 10025, 62, 37540, 1330, 8271, 62, 34345, 198, 6738, 18896, 301, 1313, 9145, 13, 18274, 346, 1330, 9720, 62, 22602, 198, 6738,...
2.287532
786
from Crypto.Cipher.blockcipher import * from pyblowfish import Blowfish as pBlowfish
[ 6738, 36579, 13, 34, 10803, 13, 9967, 66, 10803, 1330, 1635, 198, 6738, 12972, 48619, 11084, 1330, 26588, 11084, 355, 279, 3629, 322, 11084, 628, 198 ]
3.346154
26
from gym.envs.registration import register register( id='map-bro-v0', entry_point='gym_map_bro.envs:broEnv', )
[ 6738, 11550, 13, 268, 14259, 13, 2301, 33397, 1330, 7881, 198, 198, 30238, 7, 198, 220, 220, 220, 4686, 11639, 8899, 12, 7957, 12, 85, 15, 3256, 198, 220, 220, 220, 5726, 62, 4122, 11639, 1360, 76, 62, 8899, 62, 7957, 13, 268, 142...
2.333333
51
#Copyright (c) 2021 Kason Suchow import pygame import imageManager import data
[ 2, 15269, 357, 66, 8, 33448, 509, 888, 8013, 322, 198, 198, 11748, 12972, 6057, 198, 11748, 2939, 13511, 198, 11748, 1366, 198 ]
3.478261
23
# -*- coding: utf-8 -*- # %reset -f """ @author: Hiromasa Kaneko """ # Demonstration of (binary) Genetic Algorithm-based Support Vector Regression (GASVR) import random import numpy as np from deap import base from deap import creator from deap import tools from sklearn import datasets from sklearn i...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 220, 201, 198, 2, 4064, 42503, 532, 69, 201, 198, 37811, 201, 198, 31, 9800, 25, 29379, 296, 15462, 14248, 988, 78, 201, 198, 37811, 201, 198, 2, 7814, 12401, 286, 357, 3...
2.448671
1,656
#!/usr/bin/python # -*- coding: utf-8 -*- import sys import os import re import cgi import urllib import cgitb; cgitb.enable(); sys.stderr = sys.stdout import json import operator main()
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 25064, 198, 11748, 28686, 198, 11748, 302, 198, 11748, 269, 12397, 198, 11748, 2956, 297, 571, 198, 11748, 269, 18300, ...
2.597222
72
# -*- coding: utf-8 -*- import pandas import xgboost as xgb from sklearn.model_selection import train_test_split from sklearn.metrics import classification_report from sklearn.metrics import f1_score import numpy as np import random import json if __name__ == '__main__': solo_train()
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 11748, 19798, 292, 198, 11748, 2124, 70, 39521, 355, 2124, 22296, 198, 6738, 1341, 35720, 13, 19849, 62, 49283, 1330, 4512, 62, 9288, 62, 35312, 198, 6738, 1341, 35...
3.010101
99
#!/usr/bin/env python3 import argparse import binascii import re import sys import socket import uuid import logging import os import errno import threading try: # Python 2 import. import SocketServer as socketserver import Queue as Queue except ImportError: # Python 3 import. ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 11748, 1822, 29572, 198, 11748, 9874, 292, 979, 72, 198, 11748, 302, 198, 11748, 25064, 198, 11748, 17802, 198, 11748, 334, 27112, 198, 11748, 18931, 198, 11748, 28686, 198, 117...
2.694656
1,441
# -*- coding: utf-8 -*- import time import asyncio from core.config import LIMITER_CONFIG monotonic = lambda : time.monotonic() # 获取最大并发数 # 对每个请求的时间进行限制
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 640, 198, 11748, 30351, 952, 198, 198, 6738, 4755, 13, 11250, 1330, 27564, 2043, 1137, 62, 10943, 16254, 198, 198, 2144, 313, 9229, 796, 37456, 1058, 640, 13, 214...
1.666667
99
"""Contains classes for the asdf serialization of an external file.""" import socket from copy import deepcopy from dataclasses import dataclass from hashlib import md5, sha256 from pathlib import Path from typing import Union import numpy as np import pandas as pd from weldx.asdf.types import WeldxConverter # Pyt...
[ 37811, 4264, 1299, 6097, 329, 262, 355, 7568, 11389, 1634, 286, 281, 7097, 2393, 526, 15931, 628, 198, 11748, 17802, 198, 6738, 4866, 1330, 2769, 30073, 198, 6738, 4818, 330, 28958, 1330, 4818, 330, 31172, 198, 6738, 12234, 8019, 1330, ...
2.279846
2,605
from django.test import TestCase from .models import Image,Profile,Comments import datetime as dt from django.urls import reverse from django.contrib.auth.models import User # Create your tests here. class CommentTestCases(TestCase): """ This is the class I will use to test the comments """ def setUp...
[ 6738, 42625, 14208, 13, 9288, 1330, 6208, 20448, 198, 6738, 764, 27530, 1330, 7412, 11, 37046, 11, 23903, 198, 11748, 4818, 8079, 355, 288, 83, 198, 6738, 42625, 14208, 13, 6371, 82, 1330, 9575, 198, 6738, 42625, 14208, 13, 3642, 822, ...
2.534118
425
# Generated by Django 2.0.7 on 2018-08-11 05:41 from django.db import migrations, models import django.db.models.deletion
[ 2, 2980, 515, 416, 37770, 362, 13, 15, 13, 22, 319, 2864, 12, 2919, 12, 1157, 8870, 25, 3901, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 198, 11748, 42625, 14208, 13, 9945, 13, 27530, 13, 2934, 1616, 295, ...
2.818182
44
""" Test lldb exception breakpoint command for CPP. """ import lldb from lldbsuite.test.decorators import * from lldbsuite.test.lldbtest import * from lldbsuite.test import lldbutil
[ 37811, 198, 14402, 32660, 9945, 6631, 2270, 4122, 3141, 329, 327, 10246, 13, 198, 37811, 628, 198, 198, 11748, 32660, 9945, 198, 6738, 32660, 67, 1443, 84, 578, 13, 9288, 13, 12501, 273, 2024, 1330, 1635, 198, 6738, 32660, 67, 1443, 8...
2.818182
66
from webinterface import middleware, settings, urls, views, wsgi
[ 6738, 3992, 39994, 1330, 3504, 1574, 11, 6460, 11, 2956, 7278, 11, 5009, 11, 266, 82, 12397 ]
3.764706
17
from easygopigo3 import EasyGoPiGo3 gpg = EasyGoPiGo3() gpg.stop()
[ 6738, 2562, 70, 404, 14031, 18, 1330, 16789, 5247, 38729, 5247, 18, 198, 198, 70, 6024, 796, 16789, 5247, 38729, 5247, 18, 3419, 198, 198, 70, 6024, 13, 11338, 3419, 198 ]
2.225806
31
# Generated by Django 2.2.1 on 2019-06-06 03:36 from django.db import migrations
[ 2, 2980, 515, 416, 37770, 362, 13, 17, 13, 16, 319, 13130, 12, 3312, 12, 3312, 7643, 25, 2623, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 628 ]
2.766667
30