content
stringlengths
1
1.05M
input_ids
listlengths
1
883k
ratio_char_token
float64
1
22.9
token_count
int64
1
883k
import os import numpy as np import pandas as pd import torch as th from mstarhe.core.nn.models import PrettyFeedForward from MstarHe2R.components.dataloader import Mstar2RDataLoader __IMG_SIZE__ = 128 * 128 def _example(): Net = MSTARNet Net.device = None from components.graphs.graph2 import TestL4M...
[ 11748, 28686, 198, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 28034, 355, 294, 198, 198, 6738, 285, 7364, 258, 13, 7295, 13, 20471, 13, 27530, 1330, 20090, 18332, 39746, 198, 6738, 337, 7364, ...
2.346505
329
from abc import ABC, abstractmethod '''Comments In the original solution only functions were used to implement the event system (observer pattern). In this implementation I wanted to write classes (to be as nearest as possible to the pattern (?)). It is surely better to use python first-citizen functions to create t...
[ 6738, 450, 66, 1330, 9738, 11, 12531, 24396, 198, 198, 7061, 6, 23903, 198, 818, 262, 2656, 4610, 691, 5499, 547, 973, 284, 198, 320, 26908, 262, 1785, 1080, 357, 672, 15388, 3912, 737, 198, 198, 818, 428, 7822, 314, 2227, 284, 3551...
4.261682
107
#! /usr/bin/env python import time import os import argparse import json import cv2 import sys sys.path += [os.path.abspath('keras-yolo3-master')] from utils.utils import get_yolo_boxes, makedirs from utils.bbox import draw_boxes from tensorflow.keras.models import load_model from tqdm import tqdm import numpy as np ...
[ 2, 0, 1220, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 11748, 640, 198, 11748, 28686, 198, 11748, 1822, 29572, 198, 11748, 33918, 198, 11748, 269, 85, 17, 198, 11748, 25064, 198, 17597, 13, 6978, 15853, 685, 418, 13, 6978, 13, 397, ...
2.996337
273
import tensorflow.keras.constraints as constraints from tensorflow.keras.layers import GlobalAveragePooling2D from tensorflow.keras.layers import BatchNormalization from tensorflow.keras.layers import Conv2DTranspose from tensorflow.keras.layers import LeakyReLU from tensorflow.keras.layers import ReLU from tensorflow....
[ 11748, 11192, 273, 11125, 13, 6122, 292, 13, 1102, 2536, 6003, 355, 17778, 198, 6738, 11192, 273, 11125, 13, 6122, 292, 13, 75, 6962, 1330, 8060, 26287, 27201, 278, 17, 35, 198, 6738, 11192, 273, 11125, 13, 6122, 292, 13, 75, 6962, ...
3.321429
224
# coding=utf-8 from operator import xor import os import scrypt import time from libs.rediswrapper import UserHelper try: xrange except NameError: xrange = range
[ 2, 19617, 28, 40477, 12, 23, 198, 6738, 10088, 1330, 2124, 273, 198, 11748, 28686, 198, 11748, 629, 6012, 198, 11748, 640, 198, 6738, 9195, 82, 13, 445, 271, 48553, 1330, 11787, 47429, 628, 198, 28311, 25, 198, 220, 220, 220, 2124, ...
3.017544
57
import json from collections import defaultdict import fastavro import pandas as pd from django.contrib import messages from django.http import HttpResponseRedirect from django.urls import reverse from datasets.models import Connection from users.models import User def get_supported_file_types(): """Return a li...
[ 11748, 33918, 198, 6738, 17268, 1330, 4277, 11600, 198, 198, 11748, 3049, 615, 305, 198, 11748, 19798, 292, 355, 279, 67, 198, 6738, 42625, 14208, 13, 3642, 822, 1330, 6218, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 77...
2.77507
1,067
#! /usr/bin/python
[ 2, 0, 1220, 14629, 14, 8800, 14, 29412, 198 ]
2.111111
9
import sys import Sofa import Tools
[ 11748, 25064, 198, 11748, 1406, 13331, 198, 11748, 20003, 628, 628, 220, 220, 220, 220, 220, 220, 220, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 198 ]
1.736842
38
import time import os import pandas as pd import numpy as np import matplotlib.pyplot as plt from sklearn.manifold import TSNE from sklearn.tree import DecisionTreeClassifier from sklearn.metrics import f1_score import stellargraph as sg from stellargraph.mapper import CorruptedGenerator, HinSAGENodeGenerator from st...
[ 11748, 640, 198, 11748, 28686, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 198, 6738, 1341, 35720, 13, 805, 361, 727, 1330, 26136, 12161, ...
3.325123
203
from flask import Flask , render_template, request import google_news app = Flask(__name__) outFile = '' if __name__ == "__main__": app.run()
[ 6738, 42903, 1330, 46947, 837, 8543, 62, 28243, 11, 2581, 198, 11748, 23645, 62, 10827, 198, 1324, 796, 46947, 7, 834, 3672, 834, 8, 198, 198, 448, 8979, 796, 10148, 198, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, ...
2.921569
51
# Copyright 2020 DeepMind Technologies Limited. # # 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 # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed...
[ 2, 15069, 12131, 10766, 28478, 21852, 15302, 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,...
3.278846
312
# Generated by Django 2.2.3 on 2019-07-12 12:51 from django.db import migrations, models import django.db.models.deletion
[ 2, 2980, 515, 416, 37770, 362, 13, 17, 13, 18, 319, 13130, 12, 2998, 12, 1065, 1105, 25, 4349, 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
""" The given file contains the class to refer to the Site entity """ from quartic_sdk.core.entities.base import Base import quartic_sdk.utilities.constants as Constants
[ 37811, 198, 464, 1813, 2393, 4909, 262, 1398, 284, 3522, 284, 262, 14413, 9312, 198, 37811, 198, 6738, 28176, 291, 62, 21282, 74, 13, 7295, 13, 298, 871, 13, 8692, 1330, 7308, 198, 11748, 28176, 291, 62, 21282, 74, 13, 315, 2410, 13...
3.489796
49
# Generated by Django 2.0.5 on 2019-05-24 15:11 from django.db import migrations, models
[ 2, 2980, 515, 416, 37770, 362, 13, 15, 13, 20, 319, 13130, 12, 2713, 12, 1731, 1315, 25, 1157, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 628 ]
2.84375
32
from django.views import View from comment.models import BlockedUser, BlockedUserHistory, Comment from comment.mixins import CanBlockUsersMixin from comment.responses import UTF8JsonResponse, DABResponseData from comment.messages import BlockUserError
[ 6738, 42625, 14208, 13, 33571, 1330, 3582, 198, 198, 6738, 2912, 13, 27530, 1330, 1086, 3543, 12982, 11, 1086, 3543, 12982, 18122, 11, 18957, 198, 6738, 2912, 13, 19816, 1040, 1330, 1680, 12235, 14490, 35608, 259, 198, 6738, 2912, 13, 1...
3.923077
65
# -*- coding: utf-8 -*- # Copyright (c) 2015 Brad Newbold (wudan07 [at] gmail.com) # See LICENSE for details. # glyph.py # """wIcon library: glyph provides GlyphObject """ ##from handy import * ##from common import * ### represents a character in a glyphString def glyphstr_length(gls): """ Returns length of gly...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 15069, 357, 66, 8, 1853, 8114, 968, 36575, 357, 86, 463, 272, 2998, 685, 265, 60, 308, 4529, 13, 785, 8, 198, 2, 4091, 38559, 24290, 329, 3307, 13, 198, 2, 2587...
2.534884
774
import json from paho.mqtt.client import Client from subscriber import Subscriber from datetime import datetime
[ 11748, 33918, 198, 198, 6738, 279, 17108, 13, 76, 80, 926, 13, 16366, 1330, 20985, 198, 6738, 32944, 1330, 3834, 1416, 24735, 198, 6738, 4818, 8079, 1330, 4818, 8079, 628 ]
3.8
30
# Generated by Django 2.2.17 on 2020-12-28 08:13 from django.db import migrations, models
[ 2, 2980, 515, 416, 37770, 362, 13, 17, 13, 1558, 319, 12131, 12, 1065, 12, 2078, 8487, 25, 1485, 201, 198, 201, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 201, 198, 201, 198 ]
2.594595
37
from webium import BasePage, Finds, Find from selenium.webdriver.common.by import By
[ 6738, 3992, 1505, 1330, 7308, 9876, 11, 9938, 82, 11, 9938, 198, 6738, 384, 11925, 1505, 13, 12384, 26230, 13, 11321, 13, 1525, 1330, 2750, 628 ]
3.307692
26
from __future__ import print_function import argparse import sys import os import shutil import zipfile import urllib parser = argparse.ArgumentParser() ## Required parameters parser.add_argument("--bert_model_name", default = None, type = str, required = Tr...
[ 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 198, 11748, 1822, 29572, 198, 11748, 25064, 198, 11748, 28686, 198, 11748, 4423, 346, 198, 11748, 19974, 7753, 198, 11748, 2956, 297, 571, 198, 198, 48610, 796, 1822, 29572, 13, 28100, 1713, ...
2.188467
1,422
# -*- coding: utf-8 -*- # Generated by Django 1.11 on 2018-02-21 15:15 from __future__ import unicode_literals from django.db import migrations, models
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 2980, 515, 416, 37770, 352, 13, 1157, 319, 2864, 12, 2999, 12, 2481, 1315, 25, 1314, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, 198, 6738...
2.8
55
# Copyright (c) 2020 PaddlePaddle 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 appli...
[ 2, 15069, 357, 66, 8, 12131, 350, 37382, 47, 37382, 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...
3.754386
171
#!/usr/bin/env python import logging import sys import CloudFlare import os import re from os import path from certbot.plugins import dns_common __author__ = "Endrigo Antonini" __copyright__ = "Copyright 2020, Endrigo Antonini" __license__ = "Apache License 2.0" __version__ = "1.0" __maintainer__ = "Endrigo Antonini...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 11748, 18931, 198, 198, 11748, 25064, 198, 11748, 10130, 7414, 533, 198, 11748, 28686, 198, 11748, 302, 198, 198, 6738, 28686, 1330, 3108, 198, 6738, 5051, 13645, 13, 37390, 1330, 288, 5...
2.861538
325
from datetime import datetime from marshmallow import Schema, EXCLUDE import marshmallow.fields as ms_fields
[ 6738, 4818, 8079, 1330, 4818, 8079, 198, 198, 6738, 22397, 42725, 1330, 10011, 2611, 11, 7788, 5097, 52, 7206, 198, 11748, 22397, 42725, 13, 25747, 355, 13845, 62, 25747, 628, 628, 198 ]
3.5625
32
# Till now only Python 3.10 can run match statement x = 1 y = 2 point = (x, y) check_point(point)
[ 2, 17888, 783, 691, 11361, 513, 13, 940, 460, 1057, 2872, 2643, 198, 198, 87, 796, 352, 198, 88, 796, 362, 198, 4122, 796, 357, 87, 11, 331, 8, 198, 9122, 62, 4122, 7, 4122, 8, 198 ]
2.675676
37
# python3 # -*- coding: utf-8 -*- # @Author : lina # @Time : 2018/4/22 21:17 """ code function: define all parameters. """ matched_file_name = "../data/gcn_res.txt" wordvec_path = '../data/word2vec.model' incremental_path = "../data/incremental_res.txt"
[ 2, 21015, 18, 201, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 201, 198, 2, 2488, 13838, 220, 1058, 300, 1437, 201, 198, 2, 2488, 7575, 220, 220, 220, 1058, 2864, 14, 19, 14, 1828, 2310, 25, 1558, 201, 198, ...
2.285714
119
from django.shortcuts import render from django.http import HttpResponseRedirect from django.core.urlresolvers import reverse def root(request): """ Newsletter > Root """ return render(request, 'newsletter/newsletter_root.jade')
[ 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 7738, 1060, 198, 6738, 42625, 14208, 13, 7295, 13, 6371, 411, 349, 690, 1330, 9575, 628, 198, 4299, 6808, 7, 25927, 2599, 198,...
3.153846
78
# Copyright (c) 2019 PaddlePaddle 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 applic...
[ 2, 15069, 357, 66, 8, 13130, 220, 350, 37382, 47, 37382, 46665, 13, 1439, 6923, 33876, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 1, 198, 2, 345, 743, 407, 779, 428, 2393, 2...
3.628763
299
"""Middle High German phonology tools """ from typing import List from cltk.phonology.gmh.transcription import Transcriber from cltk.phonology.syllabify import Syllabifier __author__ = ["Clment Besnier <clem@clementbesnier.fr>"]
[ 37811, 34621, 3334, 2679, 32896, 1435, 4899, 198, 37811, 198, 6738, 19720, 1330, 7343, 198, 198, 6738, 537, 30488, 13, 746, 261, 1435, 13, 39870, 71, 13, 7645, 6820, 1330, 3602, 66, 24735, 198, 6738, 537, 30488, 13, 746, 261, 1435, 13...
2.987179
78
import json from html import unescape from bs4 import BeautifulSoup from baiduspider.core._spider import BaseSpider from baiduspider.errors import ParseError
[ 11748, 33918, 198, 6738, 27711, 1330, 555, 41915, 198, 198, 6738, 275, 82, 19, 1330, 23762, 50, 10486, 198, 198, 6738, 275, 1698, 17723, 1304, 13, 7295, 13557, 2777, 1304, 1330, 7308, 41294, 198, 6738, 275, 1698, 17723, 1304, 13, 48277,...
3.5
46
import socket from requests.adapters import HTTPAdapter from requests.compat import urlparse, unquote try: from requests.packages.urllib3.connection import HTTPConnection from requests.packages.urllib3.connectionpool import HTTPConnectionPool except ImportError: from urllib3.connection import HTTPConnectio...
[ 11748, 17802, 198, 198, 6738, 7007, 13, 324, 12126, 1330, 14626, 47307, 198, 6738, 7007, 13, 5589, 265, 1330, 19016, 29572, 11, 555, 22708, 198, 28311, 25, 198, 220, 220, 220, 422, 7007, 13, 43789, 13, 333, 297, 571, 18, 13, 38659, ...
3.561644
146
from django.test import TestCase from jarvis.resume.utils.extractor import get_text from jarvis.resume.utils.parser_helper import get_urls, get_url_response, url_categories, get_github_username, get_stackoverflow_userid, get_stackoverflow_username, get_name, get_id_from_linkedin_url, get_email from unidecode import uni...
[ 6738, 42625, 14208, 13, 9288, 1330, 6208, 20448, 198, 6738, 17379, 4703, 13, 411, 2454, 13, 26791, 13, 2302, 40450, 1330, 651, 62, 5239, 198, 6738, 17379, 4703, 13, 411, 2454, 13, 26791, 13, 48610, 62, 2978, 525, 1330, 651, 62, 6371, ...
2.227496
611
from __future__ import print_function from __future__ import division from sklearn.utils import check_random_state from sklearn import preprocessing as prep from utils.data import load_data, show_data_splits, shape_data from utils.evaluation import evaluate from utils.profiles import select_model, show_design, train,...
[ 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 198, 6738, 11593, 37443, 834, 1330, 7297, 198, 198, 6738, 1341, 35720, 13, 26791, 1330, 2198, 62, 25120, 62, 5219, 198, 6738, 1341, 35720, 1330, 662, 36948, 355, 3143, 198, 198, 6738, 3384,...
2.449527
3,279
from django.contrib import admin from django.db import models from easy_select2.widgets import Select2Multiple from news.models import Entry admin.site.register(Entry, EntryAdmin)
[ 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 6738, 2562, 62, 19738, 17, 13, 28029, 11407, 1330, 9683, 17, 31217, 198, 6738, 1705, 13, 27530, 1330, 21617, 628, 198, 28482, 13, 15654,...
3.64
50
import analyzer_client as analyzer from tkinter import * from tkinter import filedialog from tkinter import messagebox from tkinter import ttk import json import os from pathlib import Path IP_ADDRESS = "localhost" PORT = "8061" ENGINE_CURR_OPTIONS = {} ANALYZE_CURR_OPTIONS = {'language':'en', 'ent...
[ 11748, 4284, 9107, 62, 16366, 355, 4284, 9107, 201, 198, 201, 198, 6738, 256, 74, 3849, 1330, 1635, 201, 198, 6738, 256, 74, 3849, 1330, 5717, 498, 519, 201, 198, 6738, 256, 74, 3849, 1330, 3275, 3524, 201, 198, 6738, 256, 74, 3849,...
2.576471
255
# mods 1 import random print(random.randint(1,10))
[ 2, 13743, 352, 198, 11748, 4738, 198, 197, 198, 4798, 7, 25120, 13, 25192, 600, 7, 16, 11, 940, 4008, 198 ]
2.52381
21
from typing import Callable import kge from kge.core import events from kge.core.eventlib import EventMixin from kge.core.events import Event Component = BaseComponent
[ 6738, 19720, 1330, 4889, 540, 201, 198, 201, 198, 11748, 479, 469, 201, 198, 6738, 479, 469, 13, 7295, 1330, 2995, 201, 198, 6738, 479, 469, 13, 7295, 13, 15596, 8019, 1330, 8558, 35608, 259, 201, 198, 6738, 479, 469, 13, 7295, 13, ...
3.033333
60
from pathlib import Path import numpy as np import pickle as pk from itertools import chain, product from collections import OrderedDict from structure import Struct MONKEYS = ['M', 'N'] REGIONS = ['OFC', 'ACC'] TASKVARS = ['value', 'type'] SUBSPACES = [True, False] EVT_WINS = OrderedDict((('cues ON', (-500, 1500)), ...
[ 6738, 3108, 8019, 1330, 10644, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 2298, 293, 355, 279, 74, 198, 6738, 340, 861, 10141, 1330, 6333, 11, 1720, 198, 6738, 17268, 1330, 14230, 1068, 35, 713, 198, 198, 6738, 4645, 1330, 32112, ...
2.334254
4,709
import setuptools with open('README.rst', 'r') as f: readme = f.read() with open('version', 'r') as f: version = f.read() if __name__ == '__main__': setuptools.setup( name='ohmlr', version=version, description='One-hot multinomial logisitc regression', long_description=re...
[ 11748, 900, 37623, 10141, 198, 198, 4480, 1280, 10786, 15675, 11682, 13, 81, 301, 3256, 705, 81, 11537, 355, 277, 25, 198, 220, 220, 220, 1100, 1326, 796, 277, 13, 961, 3419, 198, 198, 4480, 1280, 10786, 9641, 3256, 705, 81, 11537, ...
2.240283
283
from commands2 import CommandBase, ParallelCommandGroup from subsystems.climbers.leftclimbersubsystem import LeftClimber from subsystems.climbers.rightclimbersubsystem import RightClimber
[ 6738, 9729, 17, 1330, 9455, 14881, 11, 42945, 21575, 13247, 198, 6738, 39335, 82, 13, 565, 320, 1213, 13, 9464, 565, 320, 1213, 549, 10057, 1330, 9578, 34, 2475, 527, 198, 6738, 39335, 82, 13, 565, 320, 1213, 13, 3506, 565, 320, 121...
3.673077
52
import os from flask import Flask import practicer_flask.auth import practicer_flask.exercises import practicer_flask.dashboard import practicer_flask.topic import practicer_flask.model_viewer app = create_app() if __name__ == "__main__": app.run(debug=os.environ.get("DEV", False))
[ 11748, 28686, 198, 198, 6738, 42903, 1330, 46947, 198, 198, 11748, 1970, 16647, 62, 2704, 2093, 13, 18439, 198, 11748, 1970, 16647, 62, 2704, 2093, 13, 1069, 2798, 2696, 198, 11748, 1970, 16647, 62, 2704, 2093, 13, 42460, 3526, 198, 117...
2.84466
103
from models.models import Topic, TopicInTopic import json
[ 6738, 4981, 13, 27530, 1330, 47373, 11, 47373, 818, 33221, 198, 11748, 33918, 628 ]
4.214286
14
# SPDX-FileCopyrightText: 2021 Genome Research Ltd. # # SPDX-License-Identifier: MIT from .base import Base, db
[ 2, 30628, 55, 12, 8979, 15269, 8206, 25, 33448, 5215, 462, 4992, 12052, 13, 198, 2, 198, 2, 30628, 55, 12, 34156, 12, 33234, 7483, 25, 17168, 198, 198, 6738, 764, 8692, 1330, 7308, 11, 20613, 628 ]
3.081081
37
#!/usr/bin/env python3 # # Copyright (c) 2016-present, Facebook, Inc. # All rights reserved. # # This source code is licensed under the BSD-style license found in the # LICENSE file in the root directory of this source tree. An additional grant # of patent rights can be found in the PATENTS file in the same directory. ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 198, 2, 15069, 357, 66, 8, 1584, 12, 25579, 11, 3203, 11, 3457, 13, 198, 2, 1439, 2489, 10395, 13, 198, 2, 198, 2, 770, 2723, 2438, 318, 11971, 739, 262, 347, 10305, 12, ...
3.388889
144
import numpy as np import os # Data manipulate
[ 11748, 299, 32152, 355, 45941, 220, 198, 11748, 28686, 220, 198, 198, 2, 6060, 18510, 628 ]
3.1875
16
# Generated by Django 3.0.10 on 2021-02-15 15:09 from django.db import migrations, models import django.db.models.deletion import uuid
[ 2, 2980, 515, 416, 37770, 513, 13, 15, 13, 940, 319, 33448, 12, 2999, 12, 1314, 1315, 25, 2931, 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.854167
48
""" File-Name: [app]/serializers.py File-Desc: Rest API serializers for las_util App-Name: las_util Project-Name: Las-Util-Django Copyright: Copyright (c) 2019, DC Slagel License-Identifier: BSD-3-Clause """ from rest_framework import serializers from las_util.models import SectionInfo # TODO: replace view.api_upload ...
[ 37811, 198, 8979, 12, 5376, 25, 685, 1324, 60, 14, 46911, 11341, 13, 9078, 198, 8979, 12, 24564, 25, 8324, 7824, 11389, 11341, 329, 39990, 62, 22602, 198, 4677, 12, 5376, 25, 39990, 62, 22602, 198, 16775, 12, 5376, 25, 10123, 12, 18...
2.905028
179
#!/usr/bin/env python # Display a runtext with double-buffering. from samplebase import SampleBase from rgbmatrix import graphics import time import requests import transitfeed import datetime import arrow import schedule today = datetime.date.today() starttime = time.time() schedule = transitfeed.Schedule() url = "ht...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 16531, 257, 1057, 5239, 351, 4274, 12, 36873, 1586, 13, 198, 6738, 6291, 8692, 1330, 27565, 14881, 198, 6738, 46140, 6759, 8609, 1330, 9382, 198, 11748, 640, 198, 11748, 7007, 198, ...
2.951542
227
from django.apps import AppConfig
[ 6738, 42625, 14208, 13, 18211, 1330, 2034, 16934, 628 ]
3.888889
9
from random import sample from tile import Tile from utils import neighbours
[ 6738, 4738, 1330, 6291, 198, 6738, 17763, 1330, 47870, 198, 6738, 3384, 4487, 1330, 23788, 628 ]
4.875
16
import smart_imports smart_imports.all()
[ 198, 11748, 4451, 62, 320, 3742, 198, 198, 27004, 62, 320, 3742, 13, 439, 3419, 628, 198 ]
2.647059
17
import numpy as np import math p = np.poly1d([ +0.1429511242e-53, +0.1561712123e-44, -0.2259472298e-35, -0.2669710222e-26, +0.9784247973e-18, +0.1655572013e-8, +0.3991098106e+0, ]) for i in range(1000): k = float(i) / 100 print(sigmoid(k), p(k))
[ 11748, 299, 32152, 355, 45941, 198, 11748, 10688, 198, 198, 79, 796, 45941, 13, 35428, 16, 67, 26933, 198, 10, 15, 13, 1415, 1959, 4349, 1065, 3682, 68, 12, 4310, 11, 198, 10, 15, 13, 21599, 1558, 1065, 10163, 68, 12, 2598, 11, 19...
1.8
140
import psycopg2 import psycopg2.extras import discord from models.BotMention import BotMention from models.UpdatedMessage import UpdatedMessage from forever.Steam import Steam_API, Dota_Match, Dota_Match_Player from forever.Utilities import run_in_executor, log from forever.Warframe import CetusMessage, FissureM...
[ 11748, 17331, 22163, 70, 17, 201, 198, 11748, 17331, 22163, 70, 17, 13, 2302, 8847, 201, 198, 11748, 36446, 201, 198, 6738, 4981, 13, 20630, 44, 1463, 1330, 18579, 44, 1463, 201, 198, 6738, 4981, 13, 17354, 12837, 1330, 19433, 12837, ...
3.583333
156
import keras from keras.layers import Dense, Activation, Conv2D, MaxPool2D, Reshape model = Sequential() model.add(Reshape((3, 32, 32), input_shape=(3*32*32,) )) model.add(Conv2D(filters=32, kernel_size=(3,3), padding='same', activation="relu", data_format='channels_first')) model.add(MaxPool2D()) model.add(Conv2D(filt...
[ 11748, 41927, 292, 198, 6738, 41927, 292, 13, 75, 6962, 1330, 360, 1072, 11, 13144, 341, 11, 34872, 17, 35, 11, 5436, 27201, 17, 35, 11, 1874, 71, 1758, 198, 19849, 796, 24604, 1843, 3419, 198, 19849, 13, 2860, 7, 4965, 71, 1758, ...
2.483384
331
# Dicionarios pessoas = {'nome': 'Igor', 'sexo': 'M', 'idade': 20} print(f'O {pessoas["nome"]} tem {pessoas["idade"]} anos.') print(pessoas.keys()) #chaves do dicionario print(pessoas.values())#valores das chaves print(pessoas.items())#mostra os itens do dicionario print() for k in pessoas.keys(): print(k) for v in...
[ 2, 360, 47430, 13010, 198, 79, 408, 78, 292, 796, 1391, 6, 77, 462, 10354, 705, 40, 7053, 3256, 705, 8044, 78, 10354, 705, 44, 3256, 705, 312, 671, 10354, 1160, 92, 198, 4798, 7, 69, 6, 46, 1391, 79, 408, 78, 292, 14692, 77, 4...
2.124521
522
""" polyanalyst6api.api ~~~~~~~~~~~~~~~~~~~ This module contains functionality for access to PolyAnalyst API. """ import configparser import contextlib import pathlib import warnings from typing import Any, Dict, List, Tuple, Union, Optional from urllib.parse import urljoin, urlparse import requests import urllib3 f...
[ 37811, 198, 35428, 272, 21470, 21, 15042, 13, 15042, 198, 27156, 4907, 93, 198, 198, 1212, 8265, 4909, 11244, 329, 1895, 284, 12280, 2025, 21470, 7824, 13, 198, 37811, 198, 11748, 4566, 48610, 198, 11748, 4732, 8019, 198, 11748, 3108, 8...
2.732265
437
from django.contrib import admin from django.http import HttpResponse from django.utils.translation import ugettext as _ from froide.publicbody.models import (PublicBody, FoiLaw, PublicBodyTopic, Jurisdiction) admin.site.register(PublicBody, PublicBodyAdmin) admin.site.register(FoiLaw, FoiLawAdmin) admin....
[ 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 198, 6738, 42625, 14208, 13, 26791, 13, 41519, 1330, 334, 1136, 5239, 355, 4808, 198, 198, 6738, 8400, 485, 13, 11377, 2618, 13,...
3.179104
134
n = int(input()) # @return [0]: [1]: L=[] ans=0 for i in range(1,n+1): if(i%2==0): continue else: for j in range(1,n+1): if(i%j==0): L.append(j) if (len(L)==8): ans+=1 L.clear() print(ans) print(divisor(15))
[ 77, 796, 493, 7, 15414, 28955, 628, 198, 2, 2488, 7783, 685, 15, 5974, 685, 16, 5974, 628, 198, 43, 28, 21737, 198, 504, 28, 15, 198, 1640, 1312, 287, 2837, 7, 16, 11, 77, 10, 16, 2599, 198, 220, 220, 220, 611, 7, 72, 4, 17,...
1.611429
175
import serial #TODO: define the gathering of all of the possible data sets being extracted #Biometrics # Heart Rate # STEPS # CALORIES # SKIN TEMP # PERSPIRATION #Activity # Walking # Running # Biking #Sleep # REM # Mind Refresh # Light # Deep # Body Refresh # Interruptions # Toss & Turn
[ 11748, 11389, 628, 198, 198, 2, 51, 3727, 46, 25, 8160, 262, 11228, 286, 477, 286, 262, 1744, 1366, 5621, 852, 21242, 198, 2, 23286, 908, 10466, 198, 197, 2, 8894, 14806, 198, 197, 2, 24483, 3705, 198, 197, 2, 33290, 1581, 11015, ...
2.695652
115
"""ORM models for multinet."""
[ 37811, 1581, 44, 4981, 329, 1963, 42504, 526, 15931, 198 ]
3.1
10
import bs4 import os import re from typing import Iterable from selenium import webdriver from selenium.webdriver.support.ui import WebDriverWait # for implicit and explict waits from selenium.webdriver.support import expected_conditions as ec from selenium.webdriver.common.by import By from dataPipelines.gc_crawler...
[ 11748, 275, 82, 19, 198, 11748, 28686, 198, 11748, 302, 198, 6738, 19720, 1330, 40806, 540, 198, 198, 6738, 384, 11925, 1505, 1330, 3992, 26230, 198, 6738, 384, 11925, 1505, 13, 12384, 26230, 13, 11284, 13, 9019, 1330, 5313, 32103, 2132...
3.284264
197
import re from django.db.models.signals import m2m_changed, post_save, pre_delete from django.dispatch import receiver from django.urls import reverse from .models import Entry, Notification, User
[ 11748, 302, 198, 198, 6738, 42625, 14208, 13, 9945, 13, 27530, 13, 12683, 874, 1330, 285, 17, 76, 62, 40985, 11, 1281, 62, 21928, 11, 662, 62, 33678, 198, 6738, 42625, 14208, 13, 6381, 17147, 1330, 9733, 198, 6738, 42625, 14208, 13, ...
3.40678
59
from unittest.mock import mock_open from unittest.mock import patch import flow.utils.commons as commons commit_example = [ "223342f Adding ability to specify artifactory user [#134082057]", "4326d00 Adding slack channel option for errors [#130798449]", "09c1983 Merge pull request #25 from ci-cd/revert-18-github-ver...
[ 6738, 555, 715, 395, 13, 76, 735, 1330, 15290, 62, 9654, 198, 6738, 555, 715, 395, 13, 76, 735, 1330, 8529, 198, 198, 11748, 5202, 13, 26791, 13, 9503, 684, 355, 36523, 628, 198, 41509, 62, 20688, 796, 685, 198, 1, 1828, 2091, 368...
2.886105
439
# coding: utf-8 """ finAPI RESTful Services finAPI RESTful Services # noqa: E501 OpenAPI spec version: v1.42.1 Generated by: https://github.com/swagger-api/swagger-codegen.git """ import pprint import re # noqa: F401 import six def to_str(self): """Returns the string represent...
[ 2, 19617, 25, 3384, 69, 12, 23, 198, 198, 37811, 198, 220, 220, 220, 957, 17614, 30617, 913, 6168, 628, 220, 220, 220, 957, 17614, 30617, 913, 6168, 220, 1303, 645, 20402, 25, 412, 33548, 628, 220, 220, 220, 4946, 17614, 1020, 2196,...
2.498462
325
from functools import wraps from flask_jwt_extended import verify_jwt_in_request, get_jwt_claims, exceptions from jwt import exceptions as jwt_exception from utils.custom_response import bad_request
[ 6738, 1257, 310, 10141, 1330, 27521, 198, 6738, 42903, 62, 73, 46569, 62, 2302, 1631, 1330, 11767, 62, 73, 46569, 62, 259, 62, 25927, 11, 651, 62, 73, 46569, 62, 6604, 82, 11, 13269, 198, 6738, 474, 46569, 1330, 13269, 355, 474, 465...
3.389831
59
#!/usr/bin/env python """S/MIME demo. Copyright (c) 2000 Ng Pheng Siong. All rights reserved.""" from M2Crypto import BIO, Rand, SMIME, X509 import sys if __name__ == '__main__': Rand.load_file('../randpool.dat', -1) decrypt_verify(BIO.File(sys.stdin), 'client.pem', 'client2.pem','ca.pem') Rand.save_f...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 37811, 50, 14, 44, 12789, 13605, 13, 198, 198, 15269, 357, 66, 8, 4751, 34786, 350, 31753, 311, 295, 70, 13, 1439, 2489, 10395, 526, 15931, 198, 198, 6738, 337, 17, 23919, 78, ...
2.405594
143
#!/usr/bin/env python """A model for the sky brightness """ from functools import partial from math import pi, cos, acos, sin, sqrt, log10 from datetime import datetime, tzinfo, timedelta from time import strptime from calendar import timegm from copy import deepcopy from sys import argv from collections import namedtu...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 37811, 32, 2746, 329, 262, 6766, 22204, 198, 37811, 198, 6738, 1257, 310, 10141, 1330, 13027, 198, 6738, 10688, 1330, 31028, 11, 8615, 11, 936, 418, 11, 7813, 11, 19862, 17034, 11, 260...
2.268813
2,485
# -*- coding: utf-8 -*- import unittest import arima import os import pandas as pd if __name__ == "__main__": unittest.main()
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 555, 715, 395, 198, 11748, 610, 8083, 198, 11748, 28686, 198, 11748, 19798, 292, 355, 279, 67, 628, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, ...
2.4
55
# -*- coding:utf-8 -*- """ This file is part of OpenSesame. OpenSesame is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. OpenSesame is distr...
[ 2, 532, 9, 12, 19617, 25, 40477, 12, 23, 532, 9, 12, 198, 198, 37811, 198, 1212, 2393, 318, 636, 286, 4946, 50, 34038, 13, 198, 198, 11505, 50, 34038, 318, 1479, 3788, 25, 345, 460, 17678, 4163, 340, 290, 14, 273, 13096, 198, 27...
3.530612
245
#!/usr/bin/env python __author__ = 'Roger Unwin' import socket import time from time import gmtime, strftime import datetime import string import sys import random import asyncore import thread import getopt import select import os ### default values defined below (b/c class is not yet defined) #default_port = 4001 ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 834, 9800, 834, 796, 705, 43719, 791, 5404, 6, 628, 198, 11748, 17802, 198, 11748, 640, 198, 6738, 640, 1330, 308, 76, 2435, 11, 965, 31387, 198, 11748, 4818, 8079, 198, 11748, 4731, ...
2.941577
1,027
import matplotlib.pyplot as plt import numpy as np import pandas as pd data = pd.read_csv('results.csv') labels = [1,2,3,4] width = 0.75 x = np.arange(len(labels)) # the label locations fig = plt.figure(figsize=(9,6)) # Number people waiting ax1 = fig.add_subplot(121) y1 = data['av_waiting'].values.flatten() w...
[ 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 198, 198, 7890, 796, 279, 67, 13, 961, 62, 40664, 10786, 43420, 13, 40664, 11537, 198, 23912, 1424, 796...
2.427861
402
# -*- coding: utf-8 -*- """ Spyder Editor Amritha Subburayan code for STOUT DDA FULL STACK CASE STUDIES """ import pandas as pd import numpy as np import seaborn as sns import matplotlib.pyplot as plt import seaborn as sns %matplotlib inline from sklearn import preprocessing import sklearn.metrics as sm data = pd.r...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 4561, 88, 1082, 12058, 198, 198, 5840, 81, 342, 64, 3834, 6236, 22931, 2438, 329, 3563, 12425, 360, 5631, 34958, 3563, 8120, 42001, 49348, 11015, 198, 198, 3...
2.604979
3,977
""" Datastore is a generic layer of abstraction for data store and database access. It is a **simple** API with the aim to enable application development in a datastore-agnostic way, allowing datastores to be swapped seamlessly without changing application code. Thus, one can leverage different datastores with differen...
[ 37811, 198, 27354, 459, 382, 318, 257, 14276, 7679, 286, 34651, 329, 1366, 3650, 290, 6831, 1895, 13, 198, 1026, 318, 257, 12429, 36439, 1174, 7824, 351, 262, 4031, 284, 7139, 3586, 2478, 287, 257, 198, 19608, 459, 382, 12, 4660, 1513...
3.34878
410
# -*- coding: utf-8 -*- from __future__ import division import random from otree.common import Currency as c, currency_range from . import views from ._builtin import Bot from .models import Constants
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 11593, 37443, 834, 1330, 7297, 198, 198, 11748, 4738, 198, 198, 6738, 267, 21048, 13, 11321, 1330, 20113, 355, 269, 11, 7395, 62, 9521, 198, 198, 6738, 764, 1330, ...
3.416667
60
#!/usr/bin/env python # -*- coding:utf8 -*- # Copyright 2017, Schuberg Philis BV # # 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...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 40477, 23, 532, 9, 12, 198, 198, 2, 220, 220, 220, 220, 220, 15069, 2177, 11, 3059, 84, 3900, 4543, 271, 347, 53, 198, 2, 198, 2, 220, 220, 220, 220, ...
2.824777
896
from os import name from django.db import models from django.contrib.auth.models import User from PIL import Image #Model classes are tables objects in a database. #each variable is a column and its datatype. #__str__ method defines the name of a object (row) in a database table #profile model is meant to be used as ...
[ 6738, 28686, 1330, 1438, 198, 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 13, 27530, 1330, 11787, 198, 6738, 350, 4146, 1330, 7412, 198, 198, 2, 17633, 6097, 389, 8893, 5563, 287, 257, ...
2.982684
231
#!/usr/bin/env python import RPi.GPIO as GPIO GPIO.setwarnings(False) led_color_gpio = { 'yellow': 0, 'orange': 2, 'red': 3, 'green': 4, 'blue': 5, 'white': 6 } buttons_gpio = { 'red': 28, 'blue': 29, } gpio_to_bcm = { 0: 17, 1: 18, 2: 27, 3: 22, 4: 23, 5:...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 11748, 25812, 72, 13, 16960, 9399, 355, 50143, 198, 198, 16960, 9399, 13, 2617, 40539, 654, 7, 25101, 8, 198, 198, 992, 62, 8043, 62, 31197, 952, 796, 1391, 198, 220, 220, 220, 705, ...
1.827372
643
#!/usr/bin/env python ########################################################################### # # Written in 2009 by Ian Katz <ijk5@mit.edu> # Terms: WTFPL (http://sam.zoy.org/wtfpl/) # See COPYING and WARRANTY files included in this distribution # #####################################...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 29113, 29113, 7804, 21017, 198, 2, 220, 220, 220, 220, 198, 2, 220, 220, 220, 22503, 287, 3717, 416, 12930, 36290, 1279, 45961, 20, 31, 2781, 13, 15532, 29, 220, 220, 220, 220, 220, ...
2.631214
865
from unittest import TestCase from unittest.mock import patch from word_vectorizer.constants import Constants from word_vectorizer.model_downloading.gensim_model_downloader import \ GensimModelDownloader
[ 6738, 555, 715, 395, 1330, 6208, 20448, 198, 6738, 555, 715, 395, 13, 76, 735, 1330, 8529, 198, 198, 6738, 1573, 62, 31364, 7509, 13, 9979, 1187, 1330, 4757, 1187, 198, 6738, 1573, 62, 31364, 7509, 13, 19849, 62, 15002, 278, 13, 70,...
3.333333
63
#!/usr/bin/python3 # # Copyright 2018, The Android Open Source Project # # 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 b...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 18, 198, 2, 198, 2, 15069, 2864, 11, 383, 5565, 4946, 8090, 4935, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, ...
2.167563
10,038
#!/usr/bin/env python # -*- coding: utf-8 -*- # File: Ampel-ZTF/ampel/ztf/dev/DevSkyPortalClient.py # Author: Jakob van Santen <jakob.van.santen@desy.de> # Date: 16.09.2020 # Last Modified Date: 16.09.2020 # Last Modified By: Jakob van Santen <jakob.van.santen@desy.de> im...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 9220, 25, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1703, 30242, 12, 57, 10234,...
2.279675
615
""" Reads in a tsv file with pre-trained bottom up attention features and stores it in HDF5 format. Also store {image_id: feature_idx} as a pickle file. Hierarchy of HDF5 file: { 'image_features': num_images x num_boxes x 2048 array of features 'image_bb': num_images x num_boxes x 4 array of bounding boxes } """ ...
[ 37811, 198, 5569, 82, 287, 257, 256, 21370, 2393, 351, 662, 12, 35311, 4220, 510, 3241, 3033, 290, 198, 43409, 340, 287, 5572, 37, 20, 5794, 13, 220, 4418, 3650, 1391, 9060, 62, 312, 25, 3895, 62, 312, 87, 92, 198, 355, 257, 2298,...
2.076378
1,833
from . import views from django.urls import path urlpatterns = [ path('', views.profile, name='profile'), path('sign-up', views.sign_up, name='show_sign_up_form') ]
[ 6738, 764, 1330, 5009, 198, 6738, 42625, 14208, 13, 6371, 82, 1330, 3108, 628, 198, 6371, 33279, 82, 796, 685, 198, 220, 220, 220, 3108, 10786, 3256, 5009, 13, 13317, 11, 1438, 11639, 13317, 33809, 198, 220, 220, 220, 3108, 10786, 126...
2.75
64
from tkinter.font import BOLD from PIL import ImageTk from tkinter import* from PIL import Image from tkinter import messagebox from Tools.log_db import*
[ 6738, 256, 74, 3849, 13, 10331, 1330, 347, 15173, 198, 6738, 350, 4146, 1330, 7412, 51, 74, 198, 6738, 256, 74, 3849, 1330, 9, 198, 6738, 350, 4146, 1330, 7412, 198, 6738, 256, 74, 3849, 1330, 3275, 3524, 198, 6738, 20003, 13, 6404,...
2.859649
57
from functools import partial from typing import Optional, List, Tuple import numpy from numpy.typing import ArrayLike from skimage.restoration import denoise_bilateral as skimage_denoise_bilateral from aydin.it.classic_denoisers import _defaults from aydin.util.crop.rep_crop import representative_crop from aydin.uti...
[ 6738, 1257, 310, 10141, 1330, 13027, 198, 6738, 19720, 1330, 32233, 11, 7343, 11, 309, 29291, 198, 198, 11748, 299, 32152, 198, 6738, 299, 32152, 13, 774, 13886, 1330, 15690, 7594, 198, 6738, 1341, 9060, 13, 2118, 6944, 1330, 2853, 2567...
2.690436
2,342
import logging import time from .exceptions import HostEntryNotValid from .check import CheckFactory from .alert import AlertFactory from .host import Host from .logging import logger
[ 11748, 18931, 198, 11748, 640, 198, 6738, 764, 1069, 11755, 1330, 14504, 30150, 3673, 47139, 198, 6738, 764, 9122, 1330, 6822, 22810, 198, 6738, 764, 44598, 1330, 23276, 22810, 198, 6738, 764, 4774, 1330, 14504, 198, 6738, 764, 6404, 2667...
4.27907
43
import logging import time from django.test import Client from django.conf import settings from django.urls import reverse from django.db import IntegrityError from django.utils import timezone from rest_framework.parsers import JSONParser from rest_framework import serializers from io import BytesIO import json fr...
[ 11748, 18931, 198, 11748, 640, 198, 198, 6738, 42625, 14208, 13, 9288, 1330, 20985, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, 6371, 82, 1330, 9575, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 39348, ...
3.642857
224
import os from bot.TextInput import TextInput from bot.prompt import color_msg
[ 11748, 28686, 201, 198, 6738, 10214, 13, 8206, 20560, 1330, 8255, 20560, 201, 198, 6738, 10214, 13, 16963, 457, 1330, 3124, 62, 19662, 201 ]
3.375
24
from methods.AbstactMethod import AbstractMethod
[ 6738, 5050, 13, 4826, 301, 529, 17410, 1330, 27741, 17410, 628 ]
4.545455
11
# imports from decouple import config import pandas as pd import praw import psycopg2 import schedule from sqlalchemy import create_engine import time # automate script to run at the same time everyday schedule.every().day.at("09:07").do(job) while True: schedule.run_pending() time.sleep(1)
[ 2, 17944, 198, 6738, 875, 43846, 1330, 4566, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 279, 1831, 198, 11748, 17331, 22163, 70, 17, 198, 11748, 7269, 198, 6738, 44161, 282, 26599, 1330, 2251, 62, 18392, 198, 11748, 640, 628, 1...
3.134021
97
#!/bin/python #Frame processing and distance estimation for #goal #------------------------------------------------------------------------------- # IMPORTS #------------------------------------------------------------------------------- import cv2 import math import numpy i...
[ 2, 48443, 8800, 14, 29412, 201, 198, 2, 19778, 7587, 290, 5253, 31850, 329, 201, 198, 2, 35231, 201, 198, 201, 198, 2, 10097, 24305, 201, 198, 2, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 22...
2.521836
3,595
i=1 while i<=4: j=16 while j>=i: print(i,end="") j=j-1 print() i=i+1
[ 72, 28, 16, 198, 4514, 1312, 27, 28, 19, 25, 198, 220, 220, 220, 474, 28, 1433, 198, 220, 220, 220, 981, 474, 29, 28, 72, 25, 198, 220, 220, 220, 220, 220, 220, 220, 3601, 7, 72, 11, 437, 2625, 4943, 198, 220, 220, 220, 220,...
1.428571
70
import logging import weakref from threading import Event from threading import Thread try: from Queue import Queue except ImportError: from queue import Queue try: import gevent from gevent import Greenlet as GThread from gevent.event import Event as GEvent from gevent.queue import Queue as GQ...
[ 11748, 18931, 198, 11748, 4939, 5420, 198, 6738, 4704, 278, 1330, 8558, 198, 6738, 4704, 278, 1330, 14122, 198, 28311, 25, 198, 220, 220, 220, 422, 4670, 518, 1330, 4670, 518, 198, 16341, 17267, 12331, 25, 198, 220, 220, 220, 422, 168...
2.416523
581
#!/usr/bin/python3 from Common.Straw import Straw import pymongo from pymongo import MongoClient from bson.objectid import ObjectId import os if __name__ == "__main__": db()
[ 2, 48443, 14629, 14, 8800, 14, 29412, 18, 198, 6738, 8070, 13, 1273, 1831, 1330, 27279, 198, 11748, 279, 4948, 25162, 198, 6738, 279, 4948, 25162, 1330, 42591, 11792, 198, 6738, 275, 1559, 13, 15252, 312, 1330, 9515, 7390, 198, 11748, ...
2.95082
61
from django.template import Context from django.template import Template from .test_base import LDAPGroupAuthTestBase from django.contrib.auth.models import AnonymousUser
[ 6738, 42625, 14208, 13, 28243, 1330, 30532, 198, 6738, 42625, 14208, 13, 28243, 1330, 37350, 198, 6738, 764, 9288, 62, 8692, 1330, 27178, 2969, 13247, 30515, 14402, 14881, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 13, 27530, 1330...
4
43
# Copyright (c) Facebook, Inc. and its affiliates. # This source code is licensed under the MIT license found in the # LICENSE file in the root directory of this source tree. import torch import torch.nn as nn from torch.nn import functional as F # In EGG, the game designer must implement the core functionality of t...
[ 2, 15069, 357, 66, 8, 3203, 11, 3457, 13, 290, 663, 29116, 13, 198, 198, 2, 770, 2723, 2438, 318, 11971, 739, 262, 17168, 5964, 1043, 287, 262, 198, 2, 38559, 24290, 2393, 287, 262, 6808, 8619, 286, 428, 2723, 5509, 13, 198, 198, ...
4.444444
315
import os import shutil import random if __name__ == '__main__': main()
[ 11748, 28686, 198, 11748, 4423, 346, 198, 11748, 4738, 628, 628, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 1388, 3419, 628 ]
2.793103
29
# generated bbox ground truth from pixel-wise segmentation # it currently only generate one bbox from __future__ import print_function import numpy as np import h5py import os import pdb mask_path = '../data/acce' f = h5py.File(os.path.join(mask_path, "resized_label_ac_2d.h5"), 'r') bbox_path = '../data/acce/bbox' if...
[ 2, 7560, 275, 3524, 2323, 3872, 422, 17465, 12, 3083, 10618, 341, 198, 2, 340, 3058, 691, 7716, 530, 275, 3524, 198, 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 289, 20, 9078, 198, ...
2.065916
622
# some codes refer to Holoclean evaluation function # https://github.com/HoloClean/holoclean import pandas as pd import numpy as np import logging import random import argparse parser = argparse.ArgumentParser(description='Predict on many examples') parser.add_argument("--dataset", type=str, help="dataset path") pars...
[ 2, 617, 12416, 3522, 284, 6479, 420, 13087, 12660, 2163, 198, 2, 3740, 1378, 12567, 13, 785, 14, 39, 14057, 32657, 14, 3937, 420, 13087, 198, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 18931,...
2.446429
448
import numpy as arr n,m=map(int,input().split()) ar=([list(map(int,input().split()))for _ in range(n)]) arr1=arr.min(ar,axis=1) print(max(arr1))
[ 11748, 299, 32152, 355, 5240, 198, 77, 11, 76, 28, 8899, 7, 600, 11, 15414, 22446, 35312, 28955, 198, 283, 16193, 58, 4868, 7, 8899, 7, 600, 11, 15414, 22446, 35312, 3419, 4008, 1640, 4808, 287, 2837, 7, 77, 8, 12962, 198, 3258, 1...
2.265625
64