content
stringlengths
1
1.04M
input_ids
listlengths
1
774k
ratio_char_token
float64
0.38
22.9
token_count
int64
1
774k
# Generated by the protocol buffer compiler. DO NOT EDIT! from google.protobuf import descriptor from google.protobuf import message from google.protobuf import reflection from google.protobuf import descriptor_pb2 # @@protoc_insertion_point(imports) DESCRIPTOR = descriptor.FileDescriptor( name='plaso/proto/plas...
[ 2, 2980, 515, 416, 262, 8435, 11876, 17050, 13, 220, 8410, 5626, 48483, 0, 198, 198, 6738, 23645, 13, 11235, 672, 3046, 1330, 43087, 198, 6738, 23645, 13, 11235, 672, 3046, 1330, 3275, 198, 6738, 23645, 13, 11235, 672, 3046, 1330, 145...
2.306651
19,051
from django.db import models
[ 6738, 42625, 14208, 13, 9945, 1330, 4981, 628 ]
3.75
8
import psycopg import elasticsearch import psycopg.extras from datetime import datetime from elasticsearch import helpers, Elasticsearch start = datetime.now() postgres_client = psycopg.connect("postgres://username:password@127.0.0.1") elasticsearch_client = Elasticsearch("http://username:password@127.0.0.1:9200") c...
[ 11748, 17331, 22163, 70, 198, 11748, 27468, 12947, 198, 11748, 17331, 22163, 70, 13, 2302, 8847, 198, 6738, 4818, 8079, 1330, 4818, 8079, 198, 6738, 27468, 12947, 1330, 49385, 11, 48567, 12947, 198, 198, 9688, 796, 4818, 8079, 13, 2197, ...
2.796512
344
import pandas as pd import os import logging from pathlib import Path import sys # # Configure the path #FILE_PATH = Path(__file__).resolve().parent FILE_PATH = '/home/emi/unipd/Sartori_CBSD/project/cbsdproject' DATA_PATH = FILE_PATH + '/data' DATA_FILE = DATA_PATH + '/tweets_cleaned.csv' UTILS_PATH = FILE_PATH + '/u...
[ 11748, 19798, 292, 355, 279, 67, 198, 11748, 28686, 198, 11748, 18931, 198, 6738, 3108, 8019, 1330, 10644, 198, 11748, 25064, 198, 2, 198, 2, 17056, 495, 262, 3108, 198, 2, 25664, 62, 34219, 796, 10644, 7, 834, 7753, 834, 737, 411, ...
2.421687
498
from datetime import datetime, timedelta from django.db import models from django.utils.timezone import utc from django.contrib.auth.models import AbstractUser from django.conf import settings
[ 6738, 4818, 8079, 1330, 4818, 8079, 11, 28805, 12514, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 6738, 42625, 14208, 13, 26791, 13, 2435, 11340, 1330, 3384, 66, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 13, 27530,...
3.648148
54
#!/usr/bin/env python3 import os import sys import logging import csv import argparse from signal import signal, SIGPIPE, SIG_DFL logger = logging.getLogger() signal(SIGPIPE, SIG_DFL) FILTER_MAP = { 'ufo-states': unidentified_states, 'no-title': no_title, 'no-group': no_group, 'multi-cat': multi...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 11748, 28686, 198, 11748, 25064, 198, 11748, 18931, 198, 11748, 269, 21370, 198, 11748, 1822, 29572, 198, 6738, 6737, 1330, 6737, 11, 33993, 47, 4061, 36, 11, 33993, 62, 35, 3...
2.302752
436
#-*- coding: utf-8 -*- ''' evaluate AHDE ''' import csv from AHDE_Model import * from AHDE_process_data import * from AHDE_evaluation import * import os import time import argparse from random import shuffle from params import Params if __name__ == '__main__': p = argparse.ArgumentParser() p....
[ 2, 12, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 7061, 6, 198, 49786, 28159, 7206, 198, 7061, 6, 198, 11748, 269, 21370, 198, 6738, 28159, 7206, 62, 17633, 1330, 1635, 198, 6738, 28159, 7206, 62, 14681, 62, 7890, ...
2.189215
1,057
# -*- coding: utf-8 -*- from app import * from functools import wraps from datetime import datetime # Decorators # ---------------------------------------------------------------------------------------------------------------------- # TODO: Müssen Decorators in jedem .py - File vorkommen - oder kann man die nicht zen...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 598, 1330, 1635, 198, 6738, 1257, 310, 10141, 1330, 27521, 198, 6738, 4818, 8079, 1330, 4818, 8079, 198, 198, 2, 4280, 273, 2024, 198, 2, 16529, 3880, 19351, 438, ...
2.774242
660
from .basic_led_strip_proxy import BasicLedStripProxy
[ 6738, 764, 35487, 62, 992, 62, 36311, 62, 36436, 1330, 14392, 42416, 1273, 5528, 44148, 198 ]
3.375
16
import image_sectioner import video_capture import video_feed_test import pyueye_main import video_capture_with_IDS if __name__=="__main__": main()
[ 11748, 2939, 62, 5458, 263, 201, 198, 11748, 2008, 62, 27144, 495, 201, 198, 11748, 2008, 62, 12363, 62, 9288, 201, 198, 11748, 12972, 518, 5948, 62, 12417, 201, 198, 11748, 2008, 62, 27144, 495, 62, 4480, 62, 14255, 201, 198, 201, ...
2.65
60
import unittest
[ 11748, 555, 715, 395, 628 ]
3.4
5
from cuschess.logic import * import pygame import time LIGHTPINK = "#FFC0CB" PINK = "#FF69B4" RED = "#FF0000" WHITE = "#FFFFFF" BLACK = "#000000"
[ 198, 198, 6738, 269, 385, 2395, 824, 13, 6404, 291, 1330, 1635, 198, 11748, 12972, 6057, 198, 11748, 640, 198, 198, 43, 9947, 47, 17248, 796, 25113, 37, 4851, 15, 23199, 1, 198, 47, 17248, 796, 25113, 5777, 3388, 33, 19, 1, 198, 2...
2.307692
65
import argparse import os import numpy as np import autosklearn import autosklearn.data import autosklearn.data.data_manager import autosklearn.models.evaluator from ParamSklearn.classification import ParamSklearnClassifier parser = argparse.ArgumentParser() parser.add_argument('input') parser.add_argument('output'...
[ 11748, 1822, 29572, 198, 11748, 28686, 198, 198, 11748, 299, 32152, 355, 45941, 198, 198, 11748, 44619, 74, 35720, 198, 11748, 44619, 74, 35720, 13, 7890, 198, 11748, 44619, 74, 35720, 13, 7890, 13, 7890, 62, 37153, 198, 11748, 44619, 7...
2.147119
6,403
print('登陆中...') a = 0 b = 1 c = 2 d = 3
[ 4798, 10786, 163, 247, 119, 165, 247, 228, 40792, 986, 11537, 198, 64, 796, 657, 198, 65, 796, 352, 198, 66, 796, 362, 198, 67, 796, 513, 198 ]
1.428571
28
import os import torch from torch.utils.tensorboard.writer import SummaryWriter from detection.src.loaders.data_manager import DetectionSetDataManager from detection.src.yolo_maml import YOLOMAML from utils import configs from utils.io_utils import set_and_print_random_seed from detection.src.yolov3.model import Dar...
[ 11748, 28686, 628, 198, 11748, 28034, 198, 6738, 28034, 13, 26791, 13, 83, 22854, 3526, 13, 16002, 1330, 21293, 34379, 198, 198, 6738, 13326, 13, 10677, 13, 2220, 364, 13, 7890, 62, 37153, 1330, 46254, 7248, 6601, 13511, 198, 6738, 1332...
2.29392
3,865
from contextlib import contextmanager import pytest from typing_extensions import Annotated, Protocol, runtime_checkable from antidote._internal.utils import enforce_subclass_if_possible, enforce_type_if_possible @contextmanager does_raise = pytest.raises(TypeError, match="(?i).*(isinstance|subclass|implement).*"...
[ 6738, 4732, 8019, 1330, 4732, 37153, 198, 198, 11748, 12972, 9288, 198, 6738, 19720, 62, 2302, 5736, 1330, 1052, 1662, 515, 11, 20497, 11, 19124, 62, 9122, 540, 198, 198, 6738, 50131, 13557, 32538, 13, 26791, 1330, 4605, 62, 7266, 4871,...
2.400888
676
import numpy as np import time from abc import abstractmethod
[ 11748, 299, 32152, 355, 45941, 198, 11748, 640, 198, 198, 6738, 450, 66, 1330, 12531, 24396, 198 ]
3.705882
17
# -*- coding: utf-8 -*- # Define your item pipelines here # # Don't forget to add your pipeline to the ITEM_PIPELINES setting # See: https://doc.scrapy.org/en/latest/topics/item-pipeline.html import os import sys import django from scrapy import signals BASE_DIR = os.path.dirname(os.path.dirname(__file__)) sys.path....
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 2, 2896, 500, 534, 2378, 31108, 994, 198, 2, 198, 2, 2094, 470, 6044, 284, 751, 534, 11523, 284, 262, 7283, 3620, 62, 47, 4061, 3698, 1268, 1546, 4634, 198, 2, ...
2.601093
183
from app import app from flask import jsonify,render_template,json, request from services import LinksServices @app.route("/links",methods=['GET']) @app.route("/link/getTopLinks",methods=['GET']) @app.route("/link/getTotalLinks",methods=['GET']) @app.route("/link/getMentionHistory",methods=['GET'])
[ 6738, 598, 1330, 598, 198, 6738, 42903, 1330, 33918, 1958, 11, 13287, 62, 28243, 11, 17752, 11, 2581, 198, 6738, 2594, 1330, 21691, 31007, 198, 198, 31, 1324, 13, 38629, 7203, 14, 28751, 1600, 24396, 82, 28, 17816, 18851, 6, 12962, 19...
2.885714
105
from utils_rouge import rouge_eval, rouge_log rouge_ref_dir = './output/reference' rouge_dec_dir = './output/decoded' print("Decoder has finished reading dataset for single_pass.") print("Now starting ROUGE eval...") results_dict = rouge_eval(rouge_ref_dir, rouge_dec_dir) rouge_log(results_dict, './output')
[ 6738, 3384, 4487, 62, 472, 469, 1330, 13805, 469, 62, 18206, 11, 13805, 469, 62, 6404, 628, 198, 472, 469, 62, 5420, 62, 15908, 796, 705, 19571, 22915, 14, 35790, 6, 198, 472, 469, 62, 12501, 62, 15908, 796, 705, 19571, 22915, 14, ...
2.827273
110
from cached_property import cached_property from sqlalchemy import text from sqlalchemy import orm from sqlalchemy.orm import selectinload from sqlalchemy.sql.expression import func from sqlalchemy.orm import deferred from sqlalchemy.orm import foreign, remote from collections import defaultdict from time import sleep ...
[ 6738, 39986, 62, 26745, 1330, 39986, 62, 26745, 198, 6738, 44161, 282, 26599, 1330, 2420, 198, 6738, 44161, 282, 26599, 1330, 393, 76, 198, 6738, 44161, 282, 26599, 13, 579, 1330, 2922, 259, 2220, 198, 6738, 44161, 282, 26599, 13, 25410...
2.95843
1,299
NAME='ldap' CFLAGS = [] LDFLAGS = [] LIBS = ['-lldap'] GCC_LIST = ['ldap']
[ 198, 20608, 11639, 335, 499, 6, 198, 34, 38948, 50, 796, 17635, 198, 11163, 38948, 50, 796, 17635, 198, 31271, 4462, 796, 685, 29001, 297, 67, 499, 20520, 198, 198, 38, 4093, 62, 45849, 796, 37250, 335, 499, 20520, 198 ]
1.925
40
import argparse import wcxf import sys import logging import os import yaml import pylha
[ 11748, 1822, 29572, 198, 11748, 266, 66, 26152, 198, 11748, 25064, 198, 11748, 18931, 198, 11748, 28686, 198, 11748, 331, 43695, 198, 11748, 279, 2645, 3099, 628, 628, 628, 628, 628 ]
3.16129
31
# -*- coding: UTF-8 -*- from django.http import HttpResponseRedirect from datetime import datetime from django.core.urlresolvers import reverse from django.core.paginator import Paginator from meregistro.shortcuts import my_render from apps.seguridad.decorators import login_required, credential_required from apps.segu...
[ 2, 532, 9, 12, 19617, 25, 41002, 12, 23, 532, 9, 12, 198, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 7738, 1060, 198, 6738, 4818, 8079, 1330, 4818, 8079, 198, 6738, 42625, 14208, 13, 7295, 13, 6371, 411, 349, 690, ...
2.66062
1,323
""" Load a model Derek van Tilborg, Eindhoven University of Technology, March 2022 """ from MoleculeACE.benchmark.utils.const import Algorithms from .model import Model def load_model(data, algorithm: Algorithms, model_file: str): """ Train a machine learning model Args: data: MoleculeACE.benchmark....
[ 37811, 198, 8912, 257, 2746, 198, 35, 18238, 5719, 40422, 23297, 11, 412, 521, 8873, 574, 2059, 286, 8987, 11, 2805, 33160, 198, 37811, 198, 198, 6738, 25726, 23172, 11598, 13, 26968, 4102, 13, 26791, 13, 9979, 1330, 978, 7727, 907, 1...
3.096234
239
import pickle import pathlib as pl from typing import List # XMC imports from xmc.tools import dynamicImport, splitOneListIntoTwo from xmc.methodDefs_xmcAlgorithm import checkInitialisation # Import ExaQUte API from exaqute import get_value_from_remote class XMCAlgorithm: """ This top-level class handles t...
[ 11748, 2298, 293, 198, 11748, 3108, 8019, 355, 458, 198, 198, 6738, 19720, 1330, 7343, 198, 198, 2, 1395, 9655, 17944, 198, 6738, 2124, 23209, 13, 31391, 1330, 8925, 20939, 11, 6626, 3198, 8053, 5317, 78, 7571, 198, 6738, 2124, 23209, ...
2.403819
6,389
#!/usr/bin/python ## Massimiliano Patacchiola, Plymouth University 2016 import numpy as np import os import time from scipy import spatial #Informant reputation is evaluated considering: agent_action, agent_confidence, informant_action #If the confidence of the agent is high and the action suggested is different fr...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 198, 2235, 5674, 26641, 10115, 3208, 330, 354, 30292, 11, 42125, 2059, 1584, 198, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 28686, 220, 198, 11748, 640, 198, 6738, 629, 541, 88, 1330, 2...
3.013628
3,889
import seaborn as sns def deorganize(data, x=None, y=None, hue=None, size=None, style=None, **kwargs): """Make some chaos The idea is that we want to use as many plotting dimensions (e.g. marker color, marker shape, etc.) as possible when we plot our data. So given a multidimensional dataset,...
[ 11748, 384, 397, 1211, 355, 3013, 82, 201, 198, 201, 198, 201, 198, 4299, 390, 9971, 1096, 7, 7890, 11, 2124, 28, 14202, 11, 331, 28, 14202, 11, 37409, 28, 14202, 11, 2546, 28, 14202, 11, 3918, 28, 14202, 11, 12429, 46265, 22046, ...
2.185836
1,991
from flask import Blueprint, make_response, request, send_file from flask import current_app as app from flask_cors import CORS from queue import Empty from kombu import Queue import json import sys from . import tasks, celery from .project import Project widget_bp = Blueprint('widget_bp', __name__) CORS(widget_bp)...
[ 6738, 42903, 1330, 39932, 11, 787, 62, 26209, 11, 2581, 11, 3758, 62, 7753, 198, 6738, 42903, 1330, 1459, 62, 1324, 355, 598, 198, 6738, 42903, 62, 66, 669, 1330, 327, 20673, 198, 198, 6738, 16834, 1330, 33523, 198, 6738, 479, 2381, ...
2.712338
1,540
import logging import sys import gym logger = logging.getLogger(__name__) root_logger = logging.getLogger() requests_logger = logging.getLogger('requests') # Set up the default handler formatter = logging.Formatter('[%(asctime)s] %(message)s') handler = logging.StreamHandler(sys.stderr) handler.setFormatter(formatt...
[ 11748, 18931, 198, 11748, 25064, 198, 198, 11748, 11550, 198, 198, 6404, 1362, 796, 18931, 13, 1136, 11187, 1362, 7, 834, 3672, 834, 8, 198, 198, 15763, 62, 6404, 1362, 796, 18931, 13, 1136, 11187, 1362, 3419, 198, 8897, 3558, 62, 640...
3.125828
302
from django.db import models import re # Create your models here.
[ 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 11748, 302, 198, 198, 2, 13610, 534, 4981, 994, 13, 198, 220, 220, 220, 220, 198, 220, 220, 220, 220 ]
2.714286
28
""" rotational bond/torsion info for specific reaction classes """ from automol.par import ReactionClass import automol.zmat from automol.reac._util import hydrogen_abstraction_atom_keys from automol.reac._util import substitution_atom_keys # Bimolecular reactions # 1. Hydrogen abstractions def hydrogen_abstraction_l...
[ 37811, 5724, 864, 6314, 14, 83, 669, 295, 7508, 329, 2176, 6317, 6097, 198, 37811, 198, 6738, 3557, 349, 13, 1845, 1330, 39912, 9487, 198, 11748, 3557, 349, 13, 89, 6759, 198, 6738, 3557, 349, 13, 260, 330, 13557, 22602, 1330, 17669, ...
2.60123
1,788
import logging from typing import Dict from makeMKV.model.enum.item_attribute_id import ItemAttributeId from makeMKV.model.enum.item_info import ItemInfo from makeMKV.model.enum.stream_type import StreamType from makeMKV.model.stream import Stream, VideoStream, SubtitleStream, AudioStream logger = logging.getLogger(_...
[ 11748, 18931, 198, 6738, 19720, 1330, 360, 713, 198, 198, 6738, 787, 33907, 53, 13, 19849, 13, 44709, 13, 9186, 62, 42348, 62, 312, 1330, 9097, 33682, 7390, 198, 6738, 787, 33907, 53, 13, 19849, 13, 44709, 13, 9186, 62, 10951, 1330, ...
3.402062
97
import os import time import numpy as np import tensorflow as tf from operator import mul from functools import reduce from pathlib import Path from datetime import datetime from tqdm import tqdm from PIL import Image from . import data_utils from .. import settings tf.compat.v1.enable_eager_execution() @tf.functi...
[ 11748, 28686, 198, 11748, 640, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 11192, 273, 11125, 355, 48700, 198, 6738, 10088, 1330, 35971, 198, 6738, 1257, 310, 10141, 1330, 4646, 198, 6738, 3108, 8019, 1330, 10644, 198, 6738, 4818, 807...
2.353705
2,078
import numpy as np import pandas as pd import os import re from os.path import join from os import path, makedirs, rename from tqdm import tqdm #save_data_to_folders("../input")
[ 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 28686, 198, 11748, 302, 198, 6738, 28686, 13, 6978, 1330, 4654, 198, 6738, 28686, 1330, 3108, 11, 285, 4335, 17062, 11, 36265, 198, 6738, 256, 80, 36020, ...
2.919355
62
#! /usr/bin/env python # Thomas Nagy, 2011 (ita) """ Create _moc.cpp files The builds are 30-40% faster when .moc files are included, you should NOT use this tool. If you really really want it: def configure(conf): conf.load('compiler_cxx qt4') conf.load('slow_qt4') See playground/slow_qt/wscript for a complete e...
[ 2, 0, 1220, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 5658, 15196, 88, 11, 2813, 357, 5350, 8, 198, 198, 37811, 198, 16447, 4808, 76, 420, 13, 20322, 3696, 198, 198, 464, 12188, 389, 1542, 12, 1821, 4, 5443, 618, 764, 76, 420, ...
2.754286
175
from .descriptor import EasyRepr __all__ = ["easyrepr"] def easyrepr(wrapped=None, **kwargs): """Decorator for an automatic `__repr__` method. :param wrapped: the function to wrap See `.descriptor.EasyRepr` for a full description of the accepted keyword parameters. This decorator wraps a func...
[ 6738, 764, 20147, 1968, 273, 1330, 16789, 6207, 81, 628, 198, 834, 439, 834, 796, 14631, 38171, 260, 1050, 8973, 628, 198, 4299, 2562, 260, 1050, 7, 29988, 1496, 28, 14202, 11, 12429, 46265, 22046, 2599, 198, 220, 220, 220, 37227, 107...
2.61036
444
# Generated by Django 2.1 on 2019-05-07 15:15 from django.db import migrations, models
[ 2, 2980, 515, 416, 37770, 362, 13, 16, 319, 13130, 12, 2713, 12, 2998, 1315, 25, 1314, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 628 ]
2.966667
30
"""Verify the functionality of isilon_hadoop_tools.cli.""" from __future__ import absolute_import from __future__ import unicode_literals try: from unittest.mock import Mock # Python 3 except ImportError: from mock import Mock # Python 2 import pytest from isilon_hadoop_tools import IsilonHadoopToolError...
[ 37811, 13414, 1958, 262, 11244, 286, 318, 33576, 62, 71, 4533, 404, 62, 31391, 13, 44506, 526, 15931, 628, 198, 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, 198, ...
2.712468
393
from unittest import TestCase from CTCI.Ch2_Linked_Lists.common.SinglyLinkedList import Empty from CTCI.Ch2_Linked_Lists.exercises.CTCI_Ch2_Ex1 import RemoveDupsSinglyLinkedList
[ 6738, 555, 715, 395, 1330, 6208, 20448, 198, 6738, 327, 4825, 40, 13, 1925, 17, 62, 11280, 276, 62, 43, 1023, 13, 11321, 13, 50, 4420, 11280, 276, 8053, 1330, 33523, 198, 6738, 327, 4825, 40, 13, 1925, 17, 62, 11280, 276, 62, 43, ...
2.632353
68
from cloudmesh.pi.board.monitor import Monitor
[ 6738, 6279, 76, 5069, 13, 14415, 13, 3526, 13, 41143, 1330, 18289, 628 ]
3.692308
13
"""Leetcode 647. Palindromic Substrings Medium URL: https://leetcode.com/problems/palindromic-substrings/ Given a string, your task is to count how many palindromic substrings in this string. The substrings with different start indexes or end indexes are counted as different substrings even they consist of same char...
[ 37811, 3123, 316, 8189, 718, 2857, 13, 3175, 521, 398, 291, 3834, 37336, 198, 31205, 198, 198, 21886, 25, 3740, 1378, 293, 316, 8189, 13, 785, 14, 1676, 22143, 14, 18596, 521, 398, 291, 12, 7266, 37336, 14, 198, 198, 15056, 257, 473...
3
190
import os import numpy as np from keras.preprocessing.image import load_img if __name__ == '__main__': img = load_img('../dataset/validation/0000000.jpg', target_size=(1280, 720)) img.show()
[ 11748, 28686, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 41927, 292, 13, 3866, 36948, 13, 9060, 1330, 3440, 62, 9600, 628, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 33705, 796, 3440, 6...
2.753425
73
import pyglet import Block import BlockArray import random #magic numbers blockSize = 24 pointSize = 6 halfBorder = 1.0 height = 24 width = 36 #ugly global variables for visual effects hoverGroup = [] #initialize the most important data structure blocks = BlockArray.BlockArray(width, height) #initialize the graph...
[ 11748, 12972, 70, 1616, 198, 11748, 9726, 198, 11748, 9726, 19182, 198, 11748, 4738, 628, 198, 198, 2, 32707, 3146, 198, 9967, 10699, 796, 1987, 198, 4122, 10699, 796, 718, 198, 13959, 34189, 796, 352, 13, 15, 198, 17015, 796, 1987, 1...
2.519481
847
# Generated by Django 3.2.5 on 2021-07-13 06:42 import cloudinary.models from django.db import migrations
[ 2, 2980, 515, 416, 37770, 513, 13, 17, 13, 20, 319, 33448, 12, 2998, 12, 1485, 9130, 25, 3682, 198, 198, 11748, 6279, 3219, 13, 27530, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 628 ]
3
36
import unittest import json import os from dacbench.benchmarks import OneLLBenchmark from dacbench.envs import OneLLEnv # TestOneLLBenchmark().test_get_env() # TestOneLLBenchmark().test_scenarios() # TestOneLLBenchmark().test_read_instances() # TestOneLLBenchmark().test_save_conf()
[ 11748, 555, 715, 395, 198, 11748, 33918, 198, 11748, 28686, 198, 198, 6738, 288, 330, 26968, 13, 26968, 14306, 1330, 1881, 3069, 44199, 4102, 198, 6738, 288, 330, 26968, 13, 268, 14259, 1330, 1881, 43, 2538, 48005, 628, 198, 198, 2, 6...
2.958763
97
from json import load, dump from pathlib import Path from shutil import rmtree from unittest.mock import Mock from pytest import fixture from pc_spec.data import save_store, load_store @fixture @fixture @fixture @fixture @fixture @fixture @fixture @fixture @fixture @fixture @fixture @fixture ...
[ 6738, 33918, 1330, 3440, 11, 10285, 198, 6738, 3108, 8019, 1330, 10644, 198, 6738, 4423, 346, 1330, 374, 16762, 631, 198, 6738, 555, 715, 395, 13, 76, 735, 1330, 44123, 198, 198, 6738, 12972, 9288, 1330, 29220, 198, 198, 6738, 40653, ...
2.771186
118
from marshmallow import Schema, fields, validate from schema.rating_movie import RatingMovieSchema from schema.role import RoleSchema
[ 6738, 22397, 42725, 1330, 10011, 2611, 11, 7032, 11, 26571, 198, 198, 6738, 32815, 13, 8821, 62, 41364, 1330, 12028, 25097, 27054, 2611, 198, 6738, 32815, 13, 18090, 1330, 20934, 27054, 2611, 628 ]
4.121212
33
"""Test Blend modes.""" import unittest from coloraide import Color from . import util # Colors that produce pretty distinct results REDISH = '#fc3d99' BLUISH = '#07c7ed' YELLOWISH = '#f5d311' class TestBlendModes(util.ColorAsserts, unittest.TestCase): """Test blend modes.""" def test_alpha(self): "...
[ 37811, 14402, 41198, 12881, 526, 15931, 198, 11748, 555, 715, 395, 198, 6738, 3124, 64, 485, 1330, 5315, 198, 6738, 764, 1330, 7736, 198, 198, 2, 29792, 326, 4439, 2495, 7310, 2482, 198, 22083, 18422, 796, 705, 2, 16072, 18, 67, 2079,...
2.394801
4,886
import time import pandas as pd from brainflow.board_shim import ( BoardIds, BoardShim, BrainFlowInputParams, BrainFlowError, ) from timeflux.core.node import Node class BrainFlow(Node): """Driver for BrainFlow. This plugin provides a unified interface for all boards supported by BrainFlow. ...
[ 11748, 640, 198, 11748, 19798, 292, 355, 279, 67, 198, 6738, 3632, 11125, 13, 3526, 62, 1477, 320, 1330, 357, 198, 220, 220, 220, 5926, 7390, 82, 11, 198, 220, 220, 220, 5926, 2484, 320, 11, 198, 220, 220, 220, 14842, 37535, 20560, ...
2.565737
502
import numpy as np import pandas as pd import plotly.express as px import plotly.graph_objects as go import plotly.io as pio from IMLearn.learners.regressors.polynomial_fitting import PolynomialFitting from IMLearn.utils import utils pio.templates.default = "simple_white" def load_data(filename: str) -> pd.DataFram...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 7110, 306, 13, 42712, 355, 279, 87, 198, 11748, 7110, 306, 13, 34960, 62, 48205, 355, 467, 198, 11748, 7110, 306, 13, 952, 355, 279, 952, 198, 198, 673...
2.766798
506
from more_itertools import one from .._utils import names_and_abbrevs from ..unit import CURRENT, Dimension, LENGTH, MASS, TEMPERATURE, TIME, Unit base_unit_map = { (names, abbrevs): Unit(dim, name=one(abbrevs)) for (names, abbrevs), dim in { names_and_abbrevs(item): {val: 1} if isinstance(val, Dimen...
[ 6738, 517, 62, 270, 861, 10141, 1330, 530, 198, 198, 6738, 11485, 62, 26791, 1330, 3891, 62, 392, 62, 397, 4679, 14259, 198, 6738, 11485, 20850, 1330, 327, 39237, 11, 34024, 11, 406, 49494, 11, 337, 10705, 11, 309, 3620, 18973, 40086,...
2.303419
234
# Copyright 2019 - Nokia Corporation # # 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...
[ 2, 220, 15069, 13130, 532, 26182, 10501, 198, 2, 198, 2, 220, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 345, 743, 198, 2, 220, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, ...
3.720207
193
#!/usr/bin/env python # -*- coding: utf-8 -*- import unittest import time from redis_rate_limit import RateLimit, RateLimiter, TooManyRequests if __name__ == '__main__': unittest.main()
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 555, 715, 395, 198, 11748, 640, 198, 6738, 2266, 271, 62, 4873, 62, 32374, 1330, 14806, 39184, 11, 14806, 19352,...
2.608108
74
import os from conans import ConanFile, CMake, AutoToolsBuildEnvironment, tools from conans.util import files
[ 11748, 28686, 198, 6738, 369, 504, 1330, 31634, 8979, 11, 327, 12050, 11, 11160, 33637, 15580, 31441, 11, 4899, 198, 6738, 369, 504, 13, 22602, 1330, 3696, 628 ]
3.964286
28
import itertools as it import networkx as nx import numpy as np from wepy.analysis.parents import DISCONTINUITY_VALUE, \ parent_panel, net_parent_table,\ ancestors, sliding_window
[ 11748, 340, 861, 10141, 355, 340, 198, 198, 11748, 3127, 87, 355, 299, 87, 198, 11748, 299, 32152, 355, 45941, 198, 198, 6738, 356, 9078, 13, 20930, 13, 23743, 1330, 13954, 37815, 1268, 52, 9050, 62, 39488, 11, 3467, 198, 220, 220, ...
2.016129
124
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import sys import time import string import itertools from elasticsearch import Elasticsearch, helpers INDEX = 'passwd' INDEX_PREFIX = 'pwd_' DOC_TYPE = 'account' INDEX_CFG = { "settings": { "index": { #"number_of_shards": 8, "refresh...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 11748, 25064, 198, 11748, 640, 198, 11748, 4731, 198, 11748, 340, 861, 10141, 198, 6738, 27468, 12947, 1330, 4...
1.46049
2,936
import seaborn as sns import matplotlib.pyplot as plt def plot_boxplot_best_framework_designs(data, plot_file_name=False, latex_font=True): """ Parameters ---------- data: Data for plot plot_file_name: Optional name for plot latex_font: Whether latex font should be used Returns -----...
[ 11748, 384, 397, 1211, 355, 3013, 82, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 628, 198, 4299, 7110, 62, 3524, 29487, 62, 13466, 62, 30604, 62, 26124, 82, 7, 7890, 11, 7110, 62, 7753, 62, 3672, 28, 25101, 11, ...
2.413276
467
# Generated by Django 2.2.7 on 2019-12-13 03:23 from django.db import migrations, models
[ 2, 2980, 515, 416, 37770, 362, 13, 17, 13, 22, 319, 13130, 12, 1065, 12, 1485, 7643, 25, 1954, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 628 ]
2.84375
32
# classic implementation of Singleton Design pattern # main method if __name__ == "__main__": # create object of Singleton Class obj = Singleton() print(obj) # pick the instance of the class obj = Singleton.getInstance() print(obj)
[ 2, 6833, 7822, 286, 5573, 10565, 8495, 3912, 198, 198, 2, 1388, 2446, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 628, 197, 2, 2251, 2134, 286, 5573, 10565, 5016, 198, 197, 26801, 796, 5573, 10565, 3419, 198, 197, ...
3.347222
72
#! /usr/bin/env python from xml.dom import minidom from ctypes import c_longlong from mathml import cut_nomeaning_text, parse_file
[ 2, 0, 1220, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 6738, 35555, 13, 3438, 1330, 949, 312, 296, 198, 6738, 269, 19199, 1330, 269, 62, 6511, 6511, 198, 6738, 10688, 4029, 1330, 2005, 62, 77, 462, 7574, 62, 5239, 11, 21136, 62, ...
2.933333
45
import re import csv import StringIO import datetime from billy.scrape.bills import BillScraper, Bill from billy.scrape.votes import Vote import lxml.html import scrapelib
[ 11748, 302, 198, 11748, 269, 21370, 198, 11748, 10903, 9399, 198, 11748, 4818, 8079, 198, 198, 6738, 2855, 88, 13, 1416, 13484, 13, 65, 2171, 1330, 3941, 3351, 38545, 11, 3941, 198, 6738, 2855, 88, 13, 1416, 13484, 13, 29307, 1330, 19...
3.122807
57
# 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...
[ 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 345, 743, 198, 2, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, 921, 743, 7330, 198, 2, 257, 4866, 286, 262, 13789, 379, 198, 2,...
2.798937
2,258
from django.contrib import admin try: from django.conf.urls import patterns, include except ImportError: # DROP_WITH_DJANGO13 pragma: no cover from django.conf.urls.defaults import patterns, include # DROP_WITH_DJANGO16 admin.autodiscover() urlpatterns = patterns('', (r'^admin/', include(admin.site.url...
[ 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 198, 28311, 25, 198, 220, 220, 220, 422, 42625, 14208, 13, 10414, 13, 6371, 82, 1330, 7572, 11, 2291, 198, 16341, 17267, 12331, 25, 220, 1303, 10560, 3185, 62, 54, 10554, 62, 35028,...
2.889474
190
#!/usr/bin/env python #-*- encoding: utf8 -*- import warnings warnings.filterwarnings('ignore', category=RuntimeWarning) from nltk.corpus import stopwords from nltk.tokenize import word_tokenize from nltk.stem.lancaster import LancasterStemmer from nltk import classify, pos_tag, word_tokenize from keras.preprocessin...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 12, 9, 12, 21004, 25, 3384, 69, 23, 532, 9, 12, 198, 198, 11748, 14601, 198, 40539, 654, 13, 24455, 40539, 654, 10786, 46430, 3256, 6536, 28, 41006, 20361, 8, 198, 198, 6738, 29...
2.681818
638
import logging, os logging.basicConfig(level=os.environ.get("LOGLEVEL","INFO")) log = logging.getLogger(__name__) import base64, json, pickle, sys from ._version import __version__ from .choice import Choice,TextInput,PointBuy,AssignAbstractGear from .dietype import DieType from .sheetmaker import SheetMaker from .fun...
[ 11748, 18931, 11, 28686, 198, 6404, 2667, 13, 35487, 16934, 7, 5715, 28, 418, 13, 268, 2268, 13, 1136, 7203, 25294, 2538, 18697, 2430, 10778, 48774, 198, 6404, 796, 18931, 13, 1136, 11187, 1362, 7, 834, 3672, 834, 8, 198, 198, 11748, ...
2.688969
2,511
from pydantic import BaseModel, Field from pydantic.networks import EmailStr
[ 6738, 279, 5173, 5109, 1330, 7308, 17633, 11, 7663, 198, 6738, 279, 5173, 5109, 13, 3262, 5225, 1330, 9570, 13290, 628 ]
3.714286
21
#!/usr/bin/python3 # python import http.client import httplib2 import os import random import sys import time import webbrowser import threading import pprint # google from googleapiclient.discovery import build from googleapiclient.errors import HttpError from googleapiclient.http import MediaFileUpload from oauth2c...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 18, 198, 198, 2, 21015, 198, 11748, 2638, 13, 16366, 198, 11748, 1841, 489, 571, 17, 198, 11748, 28686, 198, 11748, 4738, 198, 11748, 25064, 198, 11748, 640, 198, 11748, 3992, 40259, 198, 11748, 4...
3.442748
131
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ # There's no good way in cosmos to create a tag # based on output or to conditionally run a process # This is a wrapper to run the umi utilities. # # Run a program (SeqPrep) for a directory in batches # This is a helper script for Martin Aryee's # scripts to de...
[ 2, 220, 27156, 27156, 27156, 15116, 198, 2, 1318, 338, 645, 922, 835, 287, 39385, 284, 2251, 257, 7621, 198, 2, 1912, 319, 5072, 393, 284, 4006, 453, 1057, 257, 1429, 198, 2, 770, 318, 257, 29908, 284, 1057, 262, 334, 11632, 20081, ...
2.829993
1,347
import os from time import sleep sleep(0.5) targets=os.listdir('./') targets.remove(file_name()) # remove __init__.py if('__init__.py' in targets): targets.remove('__init__.py') # remove everything that isn't a python file for i in list(targets): if('.py' != i[-3:]): targets.remove(i) with open('./__init__.py...
[ 11748, 28686, 198, 6738, 640, 1330, 3993, 198, 198, 42832, 7, 15, 13, 20, 8, 198, 198, 83, 853, 1039, 28, 418, 13, 4868, 15908, 7, 4458, 14, 11537, 198, 198, 83, 853, 1039, 13, 28956, 7, 7753, 62, 3672, 28955, 198, 198, 2, 4781,...
2.261324
287
"""Docstring.""" from typing import Optional, Union from .sub import subfoo # NOQA class Baz: """Baz test class.""" bute = 1 class Foo: """Foo test class.""" attr: str = 'test' type_attr = Baz def meth(self) -> Baz: """Test method.""" def selfref(self) -> "Foo": """...
[ 37811, 23579, 8841, 526, 15931, 198, 6738, 19720, 1330, 32233, 11, 4479, 198, 198, 6738, 764, 7266, 1330, 850, 21943, 220, 1303, 8005, 48, 32, 628, 198, 4871, 47099, 25, 198, 220, 220, 220, 37227, 33, 1031, 1332, 1398, 526, 15931, 628...
2.74
300
import secrets import random import string
[ 11748, 13141, 198, 11748, 4738, 198, 11748, 4731, 628 ]
4.888889
9
# This Python file uses the following encoding: utf-8 import hashlib from typing import List from aiogram.types import InlineQuery, \ InputTextMessageContent, InlineQueryResultArticle from core import dp, bot, lazy_get_text, cb as bank_api, crypto_price, Button @dp.inline_handler() async def inline_echo(inline_...
[ 2, 770, 11361, 2393, 3544, 262, 1708, 21004, 25, 3384, 69, 12, 23, 198, 11748, 12234, 8019, 198, 6738, 19720, 1330, 7343, 198, 198, 6738, 257, 72, 21857, 13, 19199, 1330, 554, 1370, 20746, 11, 3467, 198, 220, 220, 220, 23412, 8206, ...
2.036177
1,465
# coding: utf-8 """ Spinnaker API No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen) # noqa: E501 OpenAPI spec version: 1.0.0 Generated by: https://github.com/swagger-api/swagger-codegen.git """ from __future__ import absolute_import import ...
[ 2, 19617, 25, 3384, 69, 12, 23, 198, 198, 37811, 198, 220, 220, 220, 1338, 3732, 3110, 7824, 628, 220, 220, 220, 1400, 6764, 2810, 357, 27568, 416, 2451, 7928, 6127, 5235, 3740, 1378, 12567, 13, 785, 14, 2032, 7928, 12, 15042, 14, ...
2.507088
917
from abc import ABCMeta, abstractproperty, abstractmethod import numpy as np import pandas as pd from sklearn.preprocessing import LabelEncoder, MinMaxScaler from sklearn.model_selection import train_test_split from ..dataset.utils import _get_nunique class BaseParadigm(metaclass=ABCMeta): """ Base Paradigm...
[ 6738, 450, 66, 1330, 9738, 48526, 11, 12531, 26745, 11, 12531, 24396, 198, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 198, 6738, 1341, 35720, 13, 3866, 36948, 1330, 36052, 27195, 12342, 11, 1855, 11518, 33...
2.334463
2,066
from flask_assistant import logger from flask import json, Response, make_response from xml.etree import ElementTree class _Response(object): """docstring for _Response""" class event(_Response): """Triggers an event to invoke it's respective intent. When an event is triggered, speech, displayText a...
[ 6738, 42903, 62, 562, 10167, 1330, 49706, 198, 6738, 42903, 1330, 33918, 11, 18261, 11, 787, 62, 26209, 198, 6738, 35555, 13, 316, 631, 1330, 11703, 27660, 628, 198, 4871, 4808, 31077, 7, 15252, 2599, 198, 220, 220, 220, 37227, 15390, ...
3.63
100
""" Application: HealthNet File: /patientRegistration/forms.py Authors: - Nathan Stevens - Phillip Bedward - Daniel Herzig - George Herde - Samuel Launt Description: - This file contains all forms for Patient Registration. """ from django import forms fro...
[ 37811, 198, 220, 220, 220, 15678, 25, 3893, 7934, 198, 220, 220, 220, 9220, 25, 1220, 26029, 47133, 14, 23914, 13, 9078, 198, 220, 220, 220, 46665, 25, 198, 220, 220, 220, 220, 220, 220, 220, 532, 18106, 20019, 198, 220, 220, 220, ...
2.160626
2,621
import math
[ 11748, 10688, 628, 628, 628, 198 ]
3
6
#!/usr/bin/env python3 import json import argparse from typing import List, NamedTuple if __name__ == '__main__': args = parse_args() with open(args.input, 'r') as fi, open(args.output, 'w') as fo: for line in fi: fo.write(extract_tags(line.strip())) fo.write('\n')
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 11748, 33918, 198, 11748, 1822, 29572, 198, 6738, 19720, 1330, 7343, 11, 34441, 51, 29291, 628, 628, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 2...
2.258993
139
import torch import torch.nn as nn import torch.nn.functional as F # for test if __name__ == "__main__": net = Siamese() print(net) print(list(net.parameters()))
[ 11748, 28034, 198, 11748, 28034, 13, 20471, 355, 299, 77, 198, 11748, 28034, 13, 20471, 13, 45124, 355, 376, 628, 198, 198, 2, 329, 1332, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 2010, 796, 1...
2.565217
69
# -*- coding: utf-8 -*- import os from pysilcam.config import load_config, PySilcamSettings, load_camera_config
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 28686, 198, 6738, 279, 893, 346, 20991, 13, 11250, 1330, 3440, 62, 11250, 11, 9485, 15086, 20991, 26232, 11, 3440, 62, 25695, 62, 11250, 628, 628 ]
2.804878
41
import sys in_str = sys.stdin.read().replace('/', '//') res = eval(in_str) print(res)
[ 11748, 25064, 198, 198, 259, 62, 2536, 796, 25064, 13, 19282, 259, 13, 961, 22446, 33491, 10786, 14, 3256, 705, 1003, 11537, 198, 411, 796, 5418, 7, 259, 62, 2536, 8, 198, 4798, 7, 411, 8, 198 ]
2.351351
37
from zeep import Client, exceptions as zeep_exceptions from payit import ( Gateway, Transaction, Redirection, GatewayNetworkError, TransactionError, TransactionAlreadyPaidError, ) class ParsianGateway(Gateway): """ Parsian Bank Gateway (PECCO) Home: https://pec.ir Documentati...
[ 6738, 41271, 538, 1330, 20985, 11, 13269, 355, 41271, 538, 62, 1069, 11755, 198, 198, 6738, 1414, 270, 1330, 357, 198, 220, 220, 220, 29916, 11, 198, 220, 220, 220, 45389, 11, 198, 220, 220, 220, 2297, 4154, 11, 198, 220, 220, 220, ...
2.250122
2,051
# -*- coding: utf-8 -*- from .rte_dataset import RTEAutoInferenceDataset, RTEAutoInferenceReverseDataset, RTEAutoInferenceSignalDataset, \ RTET5InferenceDataset, RTET5InferenceReverseDataset, RTET5InferenceSignalDataset from .mnli_dataset import MNLIAutoInferenceDataset, MNLIAutoInferenceReverseDataset, MNLIAutoInf...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 764, 81, 660, 62, 19608, 292, 316, 1330, 371, 9328, 27722, 818, 4288, 27354, 292, 316, 11, 371, 9328, 27722, 818, 4288, 49, 964, 325, 27354, 292, 316, 11, 371, ...
2.473035
649
# Copyright (c) 2019 Altinity LTD # # This product is licensed to you under the # Apache License, Version 2.0 (the "License"). # You may not use this product except in compliance with the License. # # This product may include a number of subcomponents with # separate copyright notices and license terms. Your use of the...
[ 2, 15069, 357, 66, 8, 13130, 12344, 6269, 42513, 198, 2, 198, 2, 770, 1720, 318, 11971, 284, 345, 739, 262, 198, 2, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 11074, 198, 2, 921, 743, 407, 779, 428, 1720, 2845, ...
2.829966
594
import numpy as np from numpy.matlib import repmat from numpy import zeros, eye, ones, matrix from numpy import cos, sin, arccos, sqrt, pi, arctan2 from panda3d.core import * from direct.gui.DirectGui import * from utils.ArgsPack import ArgsPack class KinematicModel: """This is the base class for all robot dynamic...
[ 11748, 299, 32152, 355, 45941, 198, 6738, 299, 32152, 13, 6759, 8019, 1330, 1128, 6759, 198, 6738, 299, 32152, 1330, 1976, 27498, 11, 4151, 11, 3392, 11, 17593, 198, 6738, 299, 32152, 1330, 8615, 11, 7813, 11, 610, 535, 418, 11, 19862...
2.037696
7,189
""" A collection of utility methods :Authors: Sana dev team :Version: 1.1 """ import os, sys, traceback import time import logging import cjson from django.conf import settings LOGGING_ENABLED = 'LOGGING_ENABLE' LOGGING_START = 'LOGGING_START_TIME' def trace(f): """Decorator to add traces to a method. """...
[ 37811, 317, 4947, 286, 10361, 5050, 198, 198, 25, 30515, 669, 25, 44500, 1614, 1074, 198, 25, 14815, 25, 352, 13, 16, 198, 37811, 198, 198, 11748, 28686, 11, 25064, 11, 12854, 1891, 198, 11748, 640, 198, 11748, 18931, 198, 11748, 269,...
2.610766
483
from app.models.user import User from app.models.role import Role from app.core.security import get_password_hash
[ 6738, 598, 13, 27530, 13, 7220, 1330, 11787, 198, 6738, 598, 13, 27530, 13, 18090, 1330, 20934, 198, 6738, 598, 13, 7295, 13, 12961, 1330, 651, 62, 28712, 62, 17831, 628, 628, 628, 628, 628, 628, 628, 628, 198 ]
3.333333
39
# vim: tabstop=4 shiftwidth=4 softtabstop=4 # Copyright 2017 Lenovo # # 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 ...
[ 2, 43907, 25, 7400, 11338, 28, 19, 6482, 10394, 28, 19, 2705, 8658, 11338, 28, 19, 198, 198, 2, 15069, 2177, 40269, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, ...
2.757432
1,480
# !/usr/bin/env python # -*- coding: UTF-8 -*- from flask import Flask app=Flask(__name__) # app.config.from_pyfile('config.ini') # app.config.from_envvar('FLASKCONFIG') @app.route('/') if __name__ == '__main__': print(app.url_map) app.run(host="0.0.0.0", port=5000, debug = True)
[ 2, 5145, 14, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 41002, 12, 23, 532, 9, 12, 198, 198, 6738, 42903, 1330, 46947, 198, 1324, 28, 7414, 2093, 7, 834, 3672, 834, 8, 198, 2, 598, 13, 11250, 13, 6738, 6...
2.246154
130
# -*- coding: utf-8 -*- import csv def convert_empty_to_none(val): '''Converts empty or "None" strings to None Types Arguments: val: The field to be converted Returns: The passed value if the value is not an empty string or 'None', ``None`` otherwise. ''' return val if va...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 11748, 269, 21370, 198, 198, 4299, 10385, 62, 28920, 62, 1462, 62, 23108, 7, 2100, 2599, 198, 220, 220, 220, 705, 7061, 3103, 24040, 6565, 393, 366, 14202, 1, 130...
2.275023
1,109
import argparse
[ 198, 11748, 1822, 29572, 628 ]
3.6
5
from distutils.core import setup from distutils.extension import Extension from Cython.Build import cythonize from numpy import get_include as numpy_include import os import platform cython_extra_compile_args = ['-O3', '-g', '-I' + numpy_include(), '-ffast-math'] is_mac = platform.system() == 'Darwin' if is_mac: ...
[ 6738, 1233, 26791, 13, 7295, 1330, 9058, 198, 6738, 1233, 26791, 13, 2302, 3004, 1330, 27995, 198, 6738, 327, 7535, 13, 15580, 1330, 3075, 400, 261, 1096, 198, 6738, 299, 32152, 1330, 651, 62, 17256, 355, 299, 32152, 62, 17256, 198, 1...
2.29717
424
import os import logging import discord from discord.ext import slash client = slash.SlashBot( # Pass help_command=None if the bot only uses slash commands command_prefix='/', description='', help_command=None, debug_guild=int(os.environ.get('DISCORD_DEBUG_GUILD', 0)) or None ) @client.slash_cmd() async d...
[ 11748, 28686, 198, 11748, 18931, 198, 11748, 36446, 198, 6738, 36446, 13, 2302, 1330, 24632, 198, 198, 16366, 796, 24632, 13, 11122, 1077, 20630, 7, 198, 220, 220, 220, 1303, 6251, 1037, 62, 21812, 28, 14202, 611, 262, 10214, 691, 3544,...
2.643939
792
from __future__ import absolute_import # flake8: noqa # import apis into api package from ...sell_marketing.api.ad_api import AdApi from ...sell_marketing.api.ad_report_api import AdReportApi from ...sell_marketing.api.ad_report_metadata_api import AdReportMetadataApi from ...sell_marketing.api.ad_report_task_api imp...
[ 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 198, 198, 2, 781, 539, 23, 25, 645, 20402, 198, 198, 2, 1330, 2471, 271, 656, 40391, 5301, 198, 6738, 2644, 7255, 62, 10728, 278, 13, 15042, 13, 324, 62, 15042, 1330, 1215, 32, 14415, ...
3.243697
238
# _*_ coding: utf-8 _*_ """cmdb URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/1.9/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: url(r'^$', views.home, n...
[ 2, 4808, 9, 62, 19617, 25, 3384, 69, 12, 23, 4808, 9, 62, 198, 37811, 28758, 65, 10289, 28373, 198, 198, 464, 4600, 6371, 33279, 82, 63, 1351, 11926, 32336, 284, 5009, 13, 1114, 517, 1321, 3387, 766, 25, 198, 220, 220, 220, 3740, ...
1.791155
1,221
from typing import List, Union from pytest import raises # type: ignore from graphql.error import GraphQLError, format_error from graphql.language import Node, Source
[ 6738, 19720, 1330, 7343, 11, 4479, 198, 198, 6738, 12972, 9288, 1330, 12073, 220, 1303, 2099, 25, 8856, 198, 198, 6738, 4823, 13976, 13, 18224, 1330, 29681, 48, 2538, 81, 1472, 11, 5794, 62, 18224, 198, 6738, 4823, 13976, 13, 16129, 1...
3.717391
46
import setuptools with open('README.md', 'r') as fh: long_description = fh.read() setuptools.setup( name='ufcpy', version='2.0.1', author='youngtrep', author_email='youngtrep.business@gmail.com', description='A fast and easy way to access the UFC roster', long_description=long_description,...
[ 11748, 900, 37623, 10141, 198, 198, 4480, 1280, 10786, 15675, 11682, 13, 9132, 3256, 705, 81, 11537, 355, 277, 71, 25, 198, 220, 220, 220, 890, 62, 11213, 796, 277, 71, 13, 961, 3419, 198, 198, 2617, 37623, 10141, 13, 40406, 7, 198,...
2.545662
438
import pytest from fondat.string import Template pytestmark = pytest.mark.asyncio
[ 11748, 12972, 9288, 198, 198, 6738, 16245, 265, 13, 8841, 1330, 37350, 628, 198, 9078, 9288, 4102, 796, 12972, 9288, 13, 4102, 13, 292, 13361, 952, 628, 628, 628, 628 ]
3.066667
30
"""Network Architectures""" from typing import Callable, List import torch from torch import nn from torch.nn import functional as F class SmallNetwork(nn.Module): """ Network used in the experiments on MNIST and Fashion MNIST. """ class BigNetwork(nn.Module): """ Network used in the experiment...
[ 37811, 26245, 17340, 942, 37811, 198, 198, 6738, 19720, 1330, 4889, 540, 11, 7343, 198, 11748, 28034, 198, 6738, 28034, 1330, 299, 77, 198, 6738, 28034, 13, 20471, 1330, 10345, 355, 376, 628, 198, 4871, 10452, 26245, 7, 20471, 13, 26796...
3.162963
135