content
stringlengths
1
1.05M
input_ids
listlengths
1
883k
ratio_char_token
float64
1
22.9
token_count
int64
1
883k
import sys from .sitimeunit import SITimeUnit isPython3Compat = (sys.version_info.major == 3) isPython36Compat = (isPython3Compat and (sys.version_info.minor >= 6)) def normalize_frac_seconds(a, b): """Returns 3-tuple containing (normalized frac_seconds for a, normalized frac_seconds for b, most precise (sm...
[ 11748, 25064, 198, 198, 6738, 764, 82, 22552, 20850, 1330, 311, 2043, 524, 26453, 198, 198, 271, 37906, 18, 40073, 796, 357, 17597, 13, 9641, 62, 10951, 13, 22478, 6624, 513, 8, 198, 271, 37906, 2623, 40073, 796, 357, 271, 37906, 18, ...
2.353578
1,663
""" An agent representing the (retail) customer behavior following a Poisson distribution for demand. """ import networkx as nx from scse.api.module import Agent import numpy as np import logging logger = logging.getLogger(__name__)
[ 37811, 198, 2025, 5797, 10200, 262, 357, 1186, 603, 8, 6491, 4069, 1708, 257, 7695, 30927, 6082, 329, 3512, 13, 198, 37811, 198, 11748, 3127, 87, 355, 299, 87, 198, 6738, 629, 325, 13, 15042, 13, 21412, 1330, 15906, 198, 11748, 299, ...
3.671875
64
import numpy as np import os from utils import MINERL_DATA_ROOT, CUMULATIVE_REWARDS import sys import pandas def time_to_rewards(data_set, trajectory): """ Takes a data_set and a trajectory, and returns times (in ticks) to achieve each cumulative reward (from the last cumulative reward, not from...
[ 11748, 299, 32152, 355, 45941, 201, 198, 11748, 28686, 201, 198, 6738, 3384, 4487, 1330, 20625, 1137, 43, 62, 26947, 62, 13252, 2394, 11, 327, 5883, 6239, 37045, 62, 2200, 16279, 5258, 201, 198, 11748, 25064, 201, 198, 11748, 19798, 292...
2.384075
427
# coding: utf-8 # # Copyright 2022 :Barry-Thomas-Paul: Moss # # 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 applicab...
[ 2, 19617, 25, 3384, 69, 12, 23, 198, 2, 198, 2, 15069, 33160, 1058, 33, 6532, 12, 22405, 12, 12041, 25, 19935, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 4943, 198, 2, 345, 743,...
3.468531
286
import typing as t from ....extensions import ExtensionMixin from ...flarum.core.discussions import DiscussionFromBulk
[ 11748, 19720, 355, 256, 198, 198, 6738, 19424, 2302, 5736, 1330, 27995, 35608, 259, 198, 6738, 2644, 2704, 283, 388, 13, 7295, 13, 15410, 21585, 1330, 27766, 4863, 33, 12171, 628, 628, 198 ]
3.757576
33
import os import json from copy import copy from subprocess import call, Popen, PIPE, STDOUT import time import numpy as np import pandas as pd from pyproj import Transformer import rasterio import fiona from affine import Affine from shapely.geometry import shape from scipy.ndimage.morphology import binary_erosion fr...
[ 11748, 28686, 198, 11748, 33918, 198, 6738, 4866, 1330, 4866, 198, 6738, 850, 14681, 1330, 869, 11, 8099, 268, 11, 350, 4061, 36, 11, 48571, 12425, 198, 11748, 640, 198, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, ...
2.617391
920
# Importing libraries import imaplib, email user = 'vsjtestmail@gmail.com' password = 'TestMa1lPass' imap_url = 'imap.gmail.com' # Function to get email content part i.e its body part # Function to search for a key value pair # Function to get the list of emails under this label # this is done to make SSL connecti...
[ 2, 17267, 278, 12782, 198, 11748, 545, 64, 489, 571, 11, 3053, 198, 198, 7220, 796, 705, 14259, 73, 9288, 4529, 31, 14816, 13, 785, 6, 198, 28712, 796, 705, 14402, 21467, 16, 75, 14478, 6, 198, 320, 499, 62, 6371, 796, 705, 320, ...
2.975104
241
# 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,...
3.572271
339
from dataclasses import dataclass
[ 6738, 4818, 330, 28958, 1330, 4818, 330, 31172, 628 ]
3.888889
9
import logging import os import argparse from collections import defaultdict logger = logging.getLogger("paddle") logger.setLevel(logging.INFO)
[ 11748, 18931, 198, 11748, 28686, 198, 11748, 1822, 29572, 198, 6738, 17268, 1330, 4277, 11600, 198, 198, 6404, 1362, 796, 18931, 13, 1136, 11187, 1362, 7203, 79, 37382, 4943, 198, 6404, 1362, 13, 2617, 4971, 7, 6404, 2667, 13, 10778, 8,...
3.386364
44
from .models import Card from .helpers import fetch_unidentified, populate_db from django.shortcuts import render, redirect from django.http import Http404, HttpResponse import json
[ 6738, 764, 27530, 1330, 5172, 198, 6738, 764, 16794, 364, 1330, 21207, 62, 403, 19107, 11, 48040, 62, 9945, 198, 198, 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 11, 18941, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 2642...
3.410714
56
"""Calculate opinion perplexity for different numbers of topics Calclulate opinion perplexity for the test set as described in [Fang et al. 2012] section 5.1.1. This script should be run after experiment_number_of_topics.py. Usage: python cptm/experiment_calculate_perplexity.py /path/to/experiment.json. """ import p...
[ 37811, 9771, 3129, 378, 4459, 35682, 414, 329, 1180, 3146, 286, 10233, 198, 198, 9771, 565, 5039, 4459, 35682, 414, 329, 262, 1332, 900, 355, 3417, 287, 685, 37, 648, 2123, 435, 13, 198, 6999, 60, 2665, 642, 13, 16, 13, 16, 13, 19...
2.598404
752
from flask_restful import Resource import app from app.services.healthcheck import HealthApi
[ 6738, 42903, 62, 2118, 913, 1330, 20857, 198, 11748, 598, 198, 6738, 598, 13, 30416, 13, 13948, 9122, 1330, 3893, 32, 14415, 198 ]
4.043478
23
#Eulers method import numpy as np #Note: change the derivative function based on question!!!!!! Example: y-x y0 = 0.5 #float(input"what is the y(0)?") h = 0.1 #float(input"h?") x_final = 0.3 #float(input"x_final") #initiating input variables x = 0 y = y0 # remember to change yn+1 and xn+1 values if you already k...
[ 2, 36, 377, 364, 2446, 198, 11748, 299, 32152, 355, 45941, 198, 1303, 6425, 25, 1487, 262, 27255, 2163, 1912, 319, 1808, 13896, 3228, 220, 17934, 25, 331, 12, 87, 198, 198, 88, 15, 796, 657, 13, 20, 220, 1303, 22468, 7, 15414, 1, ...
2.223529
340
""" Contains Net and NetDictionary class for creating a random collection of CNN structures or loading a previously created collection. """ from __future__ import division, print_function from random import random import os.path import torch from torch import nn from torch import optim from torch.nn import functional...
[ 37811, 198, 4264, 1299, 3433, 290, 3433, 35, 14188, 1398, 329, 4441, 257, 4738, 4947, 286, 8100, 8573, 198, 273, 11046, 257, 4271, 2727, 4947, 13, 198, 37811, 198, 6738, 11593, 37443, 834, 1330, 7297, 11, 3601, 62, 8818, 198, 198, 673...
3.556122
196
import asyncio import logging import os from vmshepherd.drivers import Drivers from vmshepherd.http import WebServer from vmshepherd.utils import gen_id, prefix_logging from vmshepherd.worker import Worker
[ 11748, 30351, 952, 198, 11748, 18931, 198, 11748, 28686, 198, 6738, 410, 907, 258, 23111, 13, 36702, 1330, 36577, 198, 6738, 410, 907, 258, 23111, 13, 4023, 1330, 5313, 10697, 198, 6738, 410, 907, 258, 23111, 13, 26791, 1330, 2429, 62, ...
3.568966
58
"""Classes to describe different kinds of Slack specific event.""" import json from opsdroid.events import Message
[ 37811, 9487, 274, 284, 6901, 1180, 6982, 286, 36256, 2176, 1785, 526, 15931, 198, 198, 11748, 33918, 198, 198, 6738, 39628, 67, 3882, 13, 31534, 1330, 16000, 628 ]
4.214286
28
from .object_tracker import ObjectTracker
[ 6738, 764, 15252, 62, 2213, 10735, 1330, 9515, 35694, 198 ]
4.2
10
from os.path import join import argparse import pickle import warnings import pandas as pd from keras.callbacks import ModelCheckpoint, EarlyStopping from keras.models import load_model import utils from malconv import Malconv from preprocess import preprocess warnings.filterwarnings("ignore") parser = argparse.Argu...
[ 6738, 28686, 13, 6978, 1330, 4654, 198, 11748, 1822, 29572, 198, 11748, 2298, 293, 198, 11748, 14601, 198, 11748, 19798, 292, 355, 279, 67, 198, 6738, 41927, 292, 13, 13345, 10146, 1330, 9104, 9787, 4122, 11, 12556, 1273, 33307, 198, 67...
2.716959
855
'''We will test all routegetter methods in this test suite''' from os.path import join, abspath, sep import unittest import logging import routesparser from faker import Faker LOG_FILE = join(sep.join(sep.split(abspath(__file__))[:-1]), 'log', 'testing', 'testing.log') if __name__ == '__main__': logging.basicCo...
[ 7061, 6, 1135, 481, 1332, 477, 6339, 1136, 353, 5050, 287, 428, 1332, 18389, 7061, 6, 198, 198, 6738, 28686, 13, 6978, 1330, 4654, 11, 2352, 6978, 11, 41767, 198, 11748, 555, 715, 395, 198, 11748, 18931, 198, 11748, 3441, 9774, 28198,...
2.842105
133
from setuptools import setup VERSION = '0.0.4' DESCRIPTION = 'Hello world checking' # Setting up setup( name="hello_world", version=VERSION, author="Kishan Tongrao", author_email="kishan.tongs@gmail.com", description=DESCRIPTION, long_description_content_type="text/markdown", ...
[ 6738, 900, 37623, 10141, 1330, 9058, 201, 198, 201, 198, 43717, 796, 705, 15, 13, 15, 13, 19, 6, 201, 198, 30910, 40165, 796, 705, 15496, 995, 10627, 6, 201, 198, 201, 198, 2, 25700, 510, 201, 198, 40406, 7, 201, 198, 220, 220, ...
2.52669
281
import hashlib
[ 11748, 12234, 8019, 628 ]
4
4
# -*- coding:utf-8 -*- import certifi import pycurl import requests import os import json import uuid from StringIO import StringIO #--------------------- # #CSDN #https://blog.csdn.net/joyjun_1/article/details/52563713 #
[ 2, 532, 9, 12, 19617, 25, 40477, 12, 23, 532, 9, 12, 201, 198, 11748, 5051, 22238, 201, 198, 11748, 12972, 66, 6371, 201, 198, 11748, 7007, 201, 198, 11748, 28686, 201, 198, 11748, 33918, 201, 198, 11748, 334, 27112, 201, 198, 6738,...
2.484536
97
# CannyStill.py import cv2 import numpy as np import os ################################################################################################### ################################################################################################### if __name__ == "__main__": main()
[ 2, 327, 7737, 9590, 13, 9078, 198, 198, 11748, 269, 85, 17, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 28686, 198, 198, 29113, 29113, 29113, 21017, 198, 198, 29113, 29113, 29113, 21017, 198, 361, 11593, 3672, 834, 6624, 366, 834, ...
5.823529
51
""" Timeseries from DataFrame ========================= """ import seaborn as sns sns.set(style="darkgrid") gammas = sns.load_dataset("gammas") sns.tsplot(gammas, "timepoint", "subject", "ROI", "BOLD signal")
[ 37811, 198, 28595, 10640, 422, 6060, 19778, 198, 4770, 2559, 28, 198, 198, 37811, 198, 198, 11748, 384, 397, 1211, 355, 3013, 82, 198, 82, 5907, 13, 2617, 7, 7635, 2625, 21953, 25928, 4943, 198, 198, 28483, 5356, 796, 3013, 82, 13, ...
2.717949
78
from datetime import date import boundaries boundaries.register('British Columbia electoral districts', domain='British Columbia', last_updated=date(2011, 12, 12), name_func=boundaries.attr('edname'), id_func=boundaries.attr('edabbr'), authority='Elections BC', source_url='http://www.elections...
[ 6738, 4818, 8079, 1330, 3128, 198, 198, 11748, 13215, 198, 198, 7784, 3166, 13, 30238, 10786, 25631, 9309, 13901, 12815, 3256, 198, 220, 220, 220, 7386, 11639, 25631, 9309, 3256, 198, 220, 220, 220, 938, 62, 43162, 28, 4475, 7, 9804, ...
2.776042
192
import logging import magic import os from cms.medias.utils import get_file_type_size from django.conf import settings from django.core.files.uploadedfile import InMemoryUploadedFile from . import settings as app_settings from . utils import to_webp logger = logging.getLogger(__name__) FILETYPE_IMAGE = getattr(sett...
[ 11748, 18931, 198, 11748, 5536, 198, 11748, 28686, 198, 198, 6738, 269, 907, 13, 2379, 292, 13, 26791, 1330, 651, 62, 7753, 62, 4906, 62, 7857, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, 7295, 13, 166...
2.804196
143
from django_fsu import url from . import views urlpatterns = [ url('login/', views.login, name='login'), url('logout/', views.logout, name='logout'), url('profile/<int:pk>', views.profile, name='profile'), ]
[ 6738, 42625, 14208, 62, 69, 2385, 1330, 19016, 198, 6738, 764, 1330, 5009, 628, 198, 6371, 33279, 82, 796, 685, 198, 220, 220, 220, 19016, 10786, 38235, 14, 3256, 5009, 13, 38235, 11, 1438, 11639, 38235, 33809, 198, 220, 220, 220, 190...
2.674699
83
""" This is a setup.py script generated by py2applet Usage: python setup.py py2app """ from setuptools import setup APP = ['PocLibrary.py'] APP_NAME = "PocLibrary" DATA_FILES = [] OPTIONS = { 'iconfile': 'logo.icns', 'plist': { 'CFBundleName': APP_NAME, 'CFBundleDisplayName': APP_NAME, ...
[ 37811, 198, 1212, 318, 257, 9058, 13, 9078, 4226, 7560, 416, 12972, 17, 1324, 1616, 198, 198, 28350, 25, 198, 220, 220, 220, 21015, 9058, 13, 9078, 12972, 17, 1324, 198, 37811, 198, 198, 6738, 900, 37623, 10141, 1330, 9058, 198, 198, ...
2.295385
325
# encoding: utf-8 import base64 import hashlib import hmac import re import six from six.moves.urllib.parse import quote from Crypto.Cipher import AES
[ 2, 21004, 25, 3384, 69, 12, 23, 198, 11748, 2779, 2414, 198, 11748, 12234, 8019, 198, 11748, 289, 20285, 198, 11748, 302, 198, 11748, 2237, 198, 6738, 2237, 13, 76, 5241, 13, 333, 297, 571, 13, 29572, 1330, 9577, 198, 198, 6738, 365...
3.1
50
""" Config class for training the InvNet """ import argparse from dp_layer.graph_layer.edge_functions import edge_f_dict as d def get_parser(name): """ :param name: String for Config Name :return: parser """ parser = argparse.ArgumentParser(name, formatter_class=argparse.ArgumentDefaultsHelpFo...
[ 37811, 17056, 1398, 329, 3047, 262, 10001, 7934, 37227, 198, 198, 11748, 1822, 29572, 198, 198, 6738, 288, 79, 62, 29289, 13, 34960, 62, 29289, 13, 14907, 62, 12543, 2733, 1330, 5743, 62, 69, 62, 11600, 355, 288, 628, 198, 4299, 651, ...
3.026087
115
# -*- coding: utf-8 -*- """ flask-rst.modules.tags ~~~~~~~~~~~~~~~~~~~~~~ :copyright: (c) 2011 by Christoph Heer. :license: BSD, see LICENSE for more details. """ from math import log from flask import Blueprint, render_template from jinja2 import Markup from flaskrst.modules.blog import posts t...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 220, 220, 220, 42903, 12, 81, 301, 13, 18170, 13, 31499, 198, 220, 220, 220, 220, 27156, 8728, 4907, 198, 220, 220, 220, 220, 198, 220, 220, 220, 1058, 2...
2.710059
169
# coding: utf-8 from __future__ import print_function, unicode_literals import re import pytest import sqlitefts as fts from sqlitefts import fts5, fts5_aux apsw = pytest.importorskip("apsw") def test_createtable(): c = apsw.Connection(":memory:") name = "simple" sql = "CREATE VIRTUAL TABLE fts USIN...
[ 2, 19617, 25, 3384, 69, 12, 23, 198, 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 11, 28000, 1098, 62, 17201, 874, 198, 198, 11748, 302, 198, 198, 11748, 12972, 9288, 198, 198, 11748, 44161, 578, 35594, 355, 277, 912, 198, 6738, 4...
2.023814
5,291
#!/usr/bin/python # -*- coding: utf-8 -*- """ """ import random print ''.join([random.choice(list('123456789qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM')) for x in range(12)])
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 220, 220, 198, 37811, 198, 11748, 4738, 198, 198, 4798, 705, 4458, 22179, 26933, 25120, 13, 25541, 7, 4868, 10786,...
2.136364
88
import mxnet as mx from mxnet import nd from mxnet import gluon from mxnet.gluon import nn, rnn from config import config nJoints = config.NETWORK.nJoints
[ 11748, 285, 87, 3262, 355, 285, 87, 198, 6738, 285, 87, 3262, 1330, 299, 67, 198, 6738, 285, 87, 3262, 1330, 1278, 84, 261, 198, 6738, 285, 87, 3262, 13, 70, 2290, 261, 1330, 299, 77, 11, 374, 20471, 198, 6738, 4566, 1330, 4566, ...
2.610169
59
from math import ceil, floor if __name__ == "__main__": print(k_multiply(2104, 2421)) print(k_multiply(21, 24)) print(k_multiply(1, 4))
[ 6738, 10688, 1330, 2906, 346, 11, 4314, 198, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 3601, 7, 74, 62, 16680, 541, 306, 7, 17, 13464, 11, 1987, 2481, 4008, 198, 220, 220, 220, 3601, 7, 74, ...
2.128571
70
import sys if __name__ == '__main__': main()
[ 11748, 25064, 628, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 1388, 3419, 198 ]
2.363636
22
import re import random import string import os supported_types = ['a', 'n', 's'] count_types = [] if __name__ == '__main__': s = fuzzyfy('ans', 10) print(s)
[ 11748, 302, 198, 11748, 4738, 198, 11748, 4731, 198, 11748, 28686, 198, 198, 15999, 62, 19199, 796, 37250, 64, 3256, 705, 77, 3256, 705, 82, 20520, 198, 9127, 62, 19199, 796, 17635, 628, 628, 198, 198, 361, 11593, 3672, 834, 6624, 705...
2.529412
68
import pytest # This function is based upon the example of how to # "[make] test result information available in fixtures" at: # https://pytest.org/latest/example/simple.html#making-test-result-information-available-in-fixtures # and: # https://github.com/pytest-dev/pytest/issues/288
[ 11748, 12972, 9288, 628, 198, 2, 770, 2163, 318, 1912, 2402, 262, 1672, 286, 703, 284, 198, 2, 12878, 15883, 60, 1332, 1255, 1321, 1695, 287, 34609, 1, 379, 25, 198, 2, 220, 3740, 1378, 9078, 9288, 13, 2398, 14, 42861, 14, 20688, ...
3.333333
87
# Copyright 2015 PerfKitBenchmarker 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, 1853, 2448, 69, 20827, 44199, 4102, 263, 46665, 13, 1439, 2489, 10395, 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.794702
302
import arcade arcade.open_window(500,750,"Rainbow") arcade.set_background_color(arcade.color.SKY_BLUE) arcade.start_render() arcade.draw_parabola_filled(25,80,500,300,arcade.color.RED,0) arcade.draw_parabola_filled(50,80,470,280,arcade.color.ORANGE,0) arcade.draw_parabola_filled(75,80,440,260,arcade.color.YELLOW ,0) ar...
[ 11748, 27210, 198, 5605, 671, 13, 9654, 62, 17497, 7, 4059, 11, 15426, 553, 31443, 8176, 4943, 198, 5605, 671, 13, 2617, 62, 25249, 62, 8043, 7, 5605, 671, 13, 8043, 13, 18831, 56, 62, 9148, 8924, 8, 198, 5605, 671, 13, 9688, 62, ...
2.252747
273
# -*- coding: utf-8 -*- # Generated by Django 1.10.5 on 2019-02-13 18:49 from __future__ import unicode_literals from django.db import migrations
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 2980, 515, 416, 37770, 352, 13, 940, 13, 20, 319, 13130, 12, 2999, 12, 1485, 1248, 25, 2920, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, ...
2.690909
55
#!/usr/bin/env python ''' simple bottle drop module''' import time mpstate = None hold_pwm = 983 release_pwm = 1776 drop_channel = 5 drop_time = 2.0 def name(): '''return module name''' return "drop" def description(): '''return module description''' return "bottle drop control" def cmd_drop(args):...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 7061, 6, 2829, 9294, 4268, 8265, 7061, 6, 198, 198, 11748, 640, 198, 198, 3149, 5219, 796, 6045, 198, 2946, 62, 79, 26377, 796, 860, 5999, 198, 20979, 62, 79, 26377, 796, 1596, 4304,...
2.396581
585
import pandas as pd import numpy as np from numpy.random import randn from craft_ai.pandas import MISSING_VALUE, OPTIONAL_VALUE from random import random, randint NB_OPERATIONS = 300 NB_MANY_OPERATIONS = 1000 SIMPLE_AGENT_BOOSTING_CONFIGURATION = { "model_type": "boosting", "context": { "a": {"type": ...
[ 11748, 19798, 292, 355, 279, 67, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 299, 32152, 13, 25120, 1330, 43720, 77, 198, 6738, 5977, 62, 1872, 13, 79, 392, 292, 1330, 49684, 2751, 62, 39488, 11, 39852, 2849, 1847, 62, 39488, 198, ...
1.984949
4,651
import tornado.web from content import PAGES
[ 11748, 33718, 13, 12384, 198, 198, 6738, 2695, 1330, 350, 25552, 628 ]
3.916667
12
#!/usr/bin/python3 # Copyright (C) 2020 Sam Steele # 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...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 18, 198, 198, 2, 220, 15069, 357, 34, 8, 12131, 3409, 28549, 198, 2, 220, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 220, 345, 743, 407, 779, ...
2.733672
1,378
# Molecule # # This program takes in a molecular formula and creates a Lewis diagram and a 3D # model of the molecule as the output. # # Author: Ved Pradhan # Since: December 31, 2021 import json import matplotlib.pyplot as plt import sys import math # Opens the JSON file for use. with open("elements.json", "r", enc...
[ 2, 25726, 23172, 198, 2, 198, 2, 770, 1430, 2753, 287, 257, 18955, 10451, 290, 8075, 257, 10174, 16362, 290, 257, 513, 35, 198, 2, 2746, 286, 262, 27756, 355, 262, 5072, 13, 198, 2, 198, 2, 6434, 25, 36101, 1736, 324, 7637, 198, ...
3.201802
555
from flask import Blueprint from flask import render_template, redirect, url_for, request, session, jsonify from flask_login import login_user, logout_user, current_user from app.transaction import bp from app.transaction.model_att import Attendence, AttendenceSchema , CompanySchema from app.employee.model import Emplo...
[ 6738, 42903, 1330, 39932, 198, 6738, 42903, 1330, 8543, 62, 28243, 11, 18941, 11, 19016, 62, 1640, 11, 2581, 11, 6246, 11, 33918, 1958, 198, 6738, 42903, 62, 38235, 1330, 17594, 62, 7220, 11, 2604, 448, 62, 7220, 11, 1459, 62, 7220, ...
2.734328
335
#!/usr/bin/env python3 """ Usage: python monitor.py randopt_results/simple_example/ """ import sys import os import time import curses import randopt as ro USE_MPL = True USE_CURSES = True try: from terminaltables import AsciiTable, SingleTable except: raise('run pip install terminaltables') try: ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 37811, 198, 28350, 25, 198, 220, 220, 220, 21015, 5671, 13, 9078, 43720, 8738, 62, 43420, 14, 36439, 62, 20688, 14, 198, 37811, 198, 198, 11748, 25064, 198, 11748, 28686, 198,...
1.937101
1,097
from django.contrib import admin from .models import Post, Comment admin.site.register(Post,PostAdmin) admin.site.register(Comment,CommentAdmin)
[ 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 6738, 764, 27530, 1330, 2947, 11, 18957, 628, 628, 198, 198, 28482, 13, 15654, 13, 30238, 7, 6307, 11, 6307, 46787, 8, 198, 28482, 13, 15654, 13, 30238, 7, 21357, 11, 21357, 46787, ...
3.409091
44
import os import ray from ray import tune if __name__ == "__main__": ray.init() print("ray.get_gpu_ids(): {}".format(ray.get_gpu_ids())) #print("CUDA_VISIBLE_DEVICES: {}".format(os.environ["CUDA_VISIBLE_DEVICES"]))
[ 11748, 28686, 198, 11748, 26842, 198, 6738, 26842, 1330, 14009, 628, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 628, 197, 2433, 13, 15003, 3419, 198, 197, 4798, 7203, 2433, 13, 1136, 62, 46999, 62, 2340, 33529, 23884,...
2.54023
87
#!/usr/bin/env python # # Copyright (C) 2006 Huub van Dam, Science and Technology Facilities Council, # Daresbury Laboratory. # All rights reserved. # # Developed by: Huub van Dam # Science and Technology Facilities Council # Daresbury Laboratory # C...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 198, 2, 15069, 357, 34, 8, 4793, 11256, 549, 5719, 5245, 11, 5800, 290, 8987, 48939, 4281, 11, 198, 2, 360, 3565, 10711, 18643, 13, 198, 2, 1439, 2489, 10395, 13, 198, 2, 198, ...
2.562062
16,121
from Methods.utils import rmsd, mde from datetime import datetime import logging import json import sys
[ 6738, 25458, 13, 26791, 1330, 374, 907, 67, 11, 285, 2934, 198, 6738, 4818, 8079, 1330, 4818, 8079, 198, 11748, 18931, 198, 11748, 33918, 198, 11748, 25064, 628 ]
3.75
28
import unittest import sys import helpers sys.path.append('../LODStats') sys.path.append('../src/restriction-types-stats') from A69DisjointProperties import A69DisjointProperties import lodstats from lodstats import RDFStats testfile_path = helpers.resources_path
[ 11748, 555, 715, 395, 198, 198, 11748, 25064, 198, 11748, 49385, 198, 17597, 13, 6978, 13, 33295, 10786, 40720, 38543, 29668, 11537, 198, 17597, 13, 6978, 13, 33295, 10786, 40720, 10677, 14, 2118, 46214, 12, 19199, 12, 34242, 11537, 198, ...
3.3125
80
from kavenegar import KavenegarAPI, APIException, HTTPException from src.core.settings import OTP_API_KEY
[ 6738, 479, 4005, 1533, 283, 1330, 509, 4005, 1533, 283, 17614, 11, 7824, 16922, 11, 14626, 16922, 198, 198, 6738, 12351, 13, 7295, 13, 33692, 1330, 440, 7250, 62, 17614, 62, 20373, 628 ]
3.272727
33
from pytaraxa.test import * blockNumber()
[ 6738, 12972, 18870, 897, 64, 13, 9288, 1330, 1635, 198, 198, 9967, 15057, 3419, 198 ]
2.866667
15
import random import logging import time from datetime import timedelta from pymavlink import mavutil _log = logging.getLogger(__name__)
[ 11748, 4738, 198, 11748, 18931, 198, 11748, 640, 198, 6738, 4818, 8079, 1330, 28805, 12514, 198, 6738, 279, 4948, 615, 8726, 1330, 285, 615, 22602, 198, 198, 62, 6404, 796, 18931, 13, 1136, 11187, 1362, 7, 834, 3672, 834, 8, 628, 628 ...
3.357143
42
''' Created on 2020-09-19 @author: wf ''' import os.path import tempfile import unittest from pathlib import Path from lodstorage.storageconfig import StorageConfig import geograpy import getpass from geograpy.locator import Locator, City,CountryManager, Location, LocationContext from collections import Counter from...
[ 7061, 6, 198, 41972, 319, 12131, 12, 2931, 12, 1129, 198, 198, 31, 9800, 25, 266, 69, 198, 7061, 6, 198, 11748, 28686, 13, 6978, 198, 11748, 20218, 7753, 198, 11748, 555, 715, 395, 198, 6738, 3108, 8019, 1330, 10644, 198, 198, 6738,...
3.152866
157
# example of automatically starting a thread from time import sleep from threading import Thread # custom thread class that automatically starts threads when they are constructed # task function def task(): print('Task starting') # block for a moment sleep(1) # report print('Task all...
[ 2, 1672, 286, 6338, 3599, 257, 4704, 201, 198, 6738, 640, 1330, 3993, 201, 198, 6738, 4704, 278, 1330, 14122, 201, 198, 220, 201, 198, 2, 2183, 4704, 1398, 326, 6338, 4940, 14390, 618, 484, 389, 12006, 201, 198, 220, 201, 198, 2, ...
3.328467
137
#!/usr/bin/python # -*- coding: utf-8 -*- # Copyright (C) 2015 Marcel Bollmann <bollmann@linguistics.rub.de> # # Permission is hereby granted, free of charge, to any person obtaining a copy of # this software and associated documentation files (the "Software"), to deal in # the Software without restriction, including ...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 2, 15069, 357, 34, 8, 1853, 36547, 43479, 9038, 1279, 65, 692, 9038, 31, 1359, 84, 3969, 13, 25089, 13, 2934, 29, 198...
2.453965
1,097
from typing import Union import matplotlib.pyplot as plt import torch import torchvision # Validate dataset loading code
[ 6738, 19720, 1330, 4479, 198, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 11748, 28034, 198, 11748, 28034, 10178, 628, 198, 198, 2, 3254, 20540, 27039, 11046, 2438, 198 ]
3.787879
33
import os import json import logging import argparse from src.common.translate import translate_time_expression_templates, get_client logging.basicConfig(format='%(asctime)s - %(levelname)s - %(name)s - %(message)s', level=logging.INFO) logger = logging.getLogger(__name__) if __name__ == '__main__': main()
[ 11748, 28686, 198, 11748, 33918, 198, 11748, 18931, 198, 11748, 1822, 29572, 198, 198, 6738, 12351, 13, 11321, 13, 7645, 17660, 1330, 15772, 62, 2435, 62, 38011, 62, 11498, 17041, 11, 651, 62, 16366, 198, 198, 6404, 2667, 13, 35487, 169...
2.830357
112
from django.contrib.auth.decorators import login_required from django.shortcuts import render, redirect from django.contrib.auth import get_user_model from .forms import DriverSignupForm, RiderSignupForm from driver.models import Driver User = get_user_model() # Create your views here.
[ 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 13, 12501, 273, 2024, 1330, 17594, 62, 35827, 198, 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 11, 18941, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 1330, 651, 62, 7220, 62, ...
3.536585
82
from manimlib.imports import * from manim_projects.tony_useful.imports import * def smooth2(t, inflection=6): error = sigmoid(-inflection / 2) return np.clip( (sigmoid(inflection * (t - 0.5)) - error) / (1 - 2 * error), 0, 1, )
[ 6738, 582, 320, 8019, 13, 320, 3742, 1330, 1635, 198, 6738, 582, 320, 62, 42068, 13, 1122, 88, 62, 1904, 913, 13, 320, 3742, 1330, 1635, 628, 628, 628, 628, 220, 220, 220, 220, 220, 220, 220, 220, 628, 198, 198, 4299, 7209, 17, ...
2.153846
130
import os import subprocess import sys import time import pkg_resources from satella.coding import silence_excs from satella.coding.sequences import smart_enumerate from satella.files import write_to_file, read_in_file from socatlord.parse_config import parse_etc_socatlord
[ 11748, 28686, 198, 11748, 850, 14681, 198, 11748, 25064, 198, 11748, 640, 198, 198, 11748, 279, 10025, 62, 37540, 198, 6738, 8983, 64, 13, 66, 7656, 1330, 9550, 62, 1069, 6359, 198, 6738, 8983, 64, 13, 66, 7656, 13, 3107, 3007, 1330, ...
3.255814
86
""" Provide a basic set of endpoints for an application to implement OAuth client functionality. These endpoints assume that the ``current_app`` has already been configured with an OAuth client instance from the ``authlib`` package as follows: .. code-block:: python from authutils.oauth2.client import OAuthClien...
[ 37811, 198, 15946, 485, 257, 4096, 900, 286, 886, 13033, 329, 281, 3586, 284, 3494, 440, 30515, 5456, 198, 8818, 1483, 13, 198, 198, 4711, 886, 13033, 7048, 326, 262, 7559, 14421, 62, 1324, 15506, 468, 1541, 587, 17839, 198, 4480, 281...
2.766017
359
import unittest from flower.utils import bugreport from celery import Celery
[ 11748, 555, 715, 395, 198, 198, 6738, 15061, 13, 26791, 1330, 5434, 13116, 198, 6738, 18725, 1924, 1330, 15248, 1924, 628 ]
3.761905
21
"""Methods to generate a SINGLE image to represent any ABF. There are several categories which are grossly analyzed. gain function: * current clamp recording where command traces differ by sweep. * must also have something that looks like an action potential * will be analyzed with AP detection information...
[ 37811, 46202, 284, 7716, 257, 311, 2751, 2538, 2939, 284, 2380, 597, 9564, 37, 13, 198, 1858, 389, 1811, 9376, 543, 389, 40316, 15475, 13, 198, 198, 48544, 2163, 25, 198, 220, 220, 220, 1635, 1459, 29405, 8296, 810, 3141, 20675, 13238...
2.257252
1,827
from dataclasses import dataclass, field from typing import List, Optional from bindings.csw.abstract_general_operation_parameter_ref_type import ( OperationParameterGroup, ) from bindings.csw.actuate_type import ActuateType from bindings.csw.base_unit import BaseUnit from bindings.csw.cartesian_cs import Cartesian...
[ 6738, 4818, 330, 28958, 1330, 4818, 330, 31172, 11, 2214, 198, 6738, 19720, 1330, 7343, 11, 32233, 198, 6738, 34111, 13, 66, 2032, 13, 397, 8709, 62, 24622, 62, 27184, 62, 17143, 2357, 62, 5420, 62, 4906, 1330, 357, 198, 220, 220, 2...
3.495504
1,001
#!/usr/bin/env python3 # -*- coding: utf-8 -*- from .package import txt2epub as txt2epub from .package import txt2pdf as txt2pdf import argparse __version__ = "0.1.0"
[ 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, 6738, 764, 26495, 1330, 256, 742, 17, 538, 549, 355, 256, 742, 17, 538, 549, 198, 6738, 764, 26495, 1330, ...
2.356164
73
from .Scripts import *
[ 6738, 764, 7391, 82, 1330, 1635 ]
3.666667
6
import os import shutil import unittest import bpy from mmd_tools.core import pmx from mmd_tools.core.model import Model TESTS_DIR = os.path.dirname(os.path.abspath(__file__)) SAMPLES_DIR = os.path.join(os.path.dirname(TESTS_DIR), 'samples') if __name__ == '__main__': import sys sys.argv = [__file__] + (sys...
[ 11748, 28686, 198, 11748, 4423, 346, 198, 11748, 555, 715, 395, 198, 198, 11748, 275, 9078, 198, 198, 6738, 8085, 67, 62, 31391, 13, 7295, 1330, 9114, 87, 198, 6738, 8085, 67, 62, 31391, 13, 7295, 13, 19849, 1330, 9104, 198, 198, 51...
2.350877
171
""" Module for gocdapi Stage class """ from gocdapi.gobase import GoBase
[ 37811, 198, 26796, 329, 308, 420, 67, 15042, 15371, 1398, 198, 37811, 198, 198, 6738, 308, 420, 67, 15042, 13, 44270, 589, 1330, 1514, 14881, 628 ]
2.884615
26
import pyaf.tests.exog.test_random_exogenous as testrandexog testrandexog.test_random_exogenous( 32,20);
[ 11748, 12972, 1878, 13, 41989, 13, 1069, 519, 13, 9288, 62, 25120, 62, 1069, 27897, 355, 1332, 25192, 1069, 519, 628, 198, 9288, 25192, 1069, 519, 13, 9288, 62, 25120, 62, 1069, 27897, 7, 3933, 11, 1238, 1776 ]
2.789474
38
# Desenvolva um programa que leia o comprimento de trs retas e diga ao usurio se elas podem ou no formar um tringulo (pesquisar o princpio matemtico que explica a formao de um triangulo). r1 = float(input('Informe o comprimento da primeira reta: ')) r2 = float(input('Informe o comprimento da segunda reta: ')) r3 = flo...
[ 2, 2935, 268, 10396, 6862, 23781, 1430, 64, 8358, 443, 544, 267, 552, 3036, 50217, 390, 491, 82, 1005, 292, 304, 3100, 64, 257, 78, 39954, 952, 384, 1288, 292, 24573, 368, 267, 84, 645, 1296, 283, 23781, 491, 278, 43348, 357, 12272,...
2.404082
245
from functools import partial from typing import Dict import copy from torch.nn import Module from torchvision.models.resnet import * from .ssd_resnet import SSD300_ResNet from .ssd_vgg import SSD300_VGG16 from .backbones import * __REGISTERED_MODELS__ = { "SSD300_ResNet": SSD300_ResNet, "SSD3...
[ 6738, 1257, 310, 10141, 1330, 13027, 201, 198, 6738, 19720, 1330, 360, 713, 201, 198, 11748, 4866, 201, 198, 201, 198, 6738, 28034, 13, 20471, 1330, 19937, 201, 198, 6738, 28034, 10178, 13, 27530, 13, 411, 3262, 1330, 1635, 201, 198, ...
2.345178
197
inp = input("Enter string: ") input_string = ord(inp) print(input_string)
[ 259, 79, 796, 5128, 7203, 17469, 4731, 25, 366, 8, 198, 15414, 62, 8841, 796, 2760, 7, 259, 79, 8, 198, 198, 4798, 7, 15414, 62, 8841, 8, 198 ]
2.586207
29
# https://www.codewars.com/kata/5536a85b6ed4ee5a78000035 import math
[ 2, 3740, 1378, 2503, 13, 19815, 413, 945, 13, 785, 14, 74, 1045, 14, 2816, 2623, 64, 5332, 65, 21, 276, 19, 1453, 20, 64, 3695, 2388, 2327, 198, 11748, 10688, 628 ]
2.1875
32
import numpy as np from numba import njit from ._api import * # noqa: F403 from .handle import mkl_h __all__ = [ 'mult_ab', 'mult_abt' ]
[ 11748, 299, 32152, 355, 45941, 198, 6738, 997, 7012, 1330, 299, 45051, 198, 198, 6738, 47540, 15042, 1330, 1635, 220, 1303, 645, 20402, 25, 376, 31552, 198, 6738, 764, 28144, 1330, 33480, 75, 62, 71, 198, 198, 834, 439, 834, 796, 685,...
2.323077
65
# Copyright (C) 2021, A10 Networks Inc. All rights reserved. # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless requi...
[ 2, 15069, 357, 34, 8, 33448, 11, 317, 940, 27862, 3457, 13, 1439, 2489, 10395, 13, 198, 198, 2, 220, 220, 220, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 345, 743, 198, 2, 220, 220, 220, ...
3.382075
212
from engine.gameobject import Gameobject objects = []
[ 6738, 3113, 13, 6057, 15252, 1330, 3776, 15252, 198, 198, 48205, 796, 17635, 198 ]
3.928571
14
input1str = 'R998,U367,R735,U926,R23,U457,R262,D473,L353,U242,L930,U895,R321,U683,L333,U623,R105,D527,R437,D473,L100,D251,L958,U384,R655,U543,L704,D759,R529,D176,R835,U797,R453,D650,L801,U437,L468,D841,R928,D747,L803,U677,R942,D851,R265,D684,L206,U763,L566,U774,L517,U337,L86,D585,R212,U656,L799,D953,L24,U388,L465,U656,...
[ 15414, 16, 2536, 796, 705, 49, 34808, 11, 52, 27824, 11, 49, 22, 2327, 11, 52, 24, 2075, 11, 49, 1954, 11, 52, 33032, 11, 49, 29119, 11, 35, 37804, 11, 43, 33319, 11, 52, 27877, 11, 43, 45418, 11, 52, 23, 3865, 11, 49, 36453, ...
1.690574
2,440
from django.db import models from django.utils import timezone from django.core.validators import MaxValueValidator, MinValueValidator from django.core.urlresolvers import reverse from django.conf import settings # # # # # # # # # # # # # # # # # # # # # # # # # # # # Level 0: base abstract and infrastructure classes...
[ 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 6738, 42625, 14208, 13, 26791, 1330, 640, 11340, 198, 6738, 42625, 14208, 13, 7295, 13, 12102, 2024, 1330, 5436, 11395, 47139, 1352, 11, 1855, 11395, 47139, 1352, 198, 6738, 42625, 14208, 13,...
2.504415
906
import os import boto3 from getpass import getpass from dotenv import load_dotenv dotenv_path = os.path.join(os.path.dirname(__file__), ".env") load_dotenv(dotenv_path) client = boto3.client("cognito-idp", region_name=os.getenv("REGION_NAME")) username = input("[*] Enter Your Email Address: ") password = getpass("[*]...
[ 11748, 28686, 198, 11748, 275, 2069, 18, 198, 6738, 651, 6603, 1330, 651, 6603, 198, 6738, 16605, 24330, 1330, 3440, 62, 26518, 24330, 198, 198, 26518, 24330, 62, 6978, 796, 28686, 13, 6978, 13, 22179, 7, 418, 13, 6978, 13, 15908, 367...
2.699717
353
from rest_framework import serializers from .models import VirtualNetwork
[ 6738, 1334, 62, 30604, 1330, 11389, 11341, 198, 6738, 764, 27530, 1330, 15595, 26245 ]
5.214286
14
from bisect import bisect_left, bisect_right from collections import deque, Counter from itertools import combinations, permutations from math import gcd, sin, cos, tan, degrees, radians import sys input = lambda: sys.stdin.readline().rstrip() MOD = 10 ** 9 + 7 INF = float("inf") n, d, a = map(int, input().split()) mo...
[ 6738, 47457, 478, 1330, 47457, 478, 62, 9464, 11, 47457, 478, 62, 3506, 198, 6738, 17268, 1330, 390, 4188, 11, 15034, 198, 6738, 340, 861, 10141, 1330, 17790, 11, 9943, 32855, 198, 6738, 10688, 1330, 308, 10210, 11, 7813, 11, 8615, 11...
2.484848
297
from tkinter import* from tkinter import font from experta import * raiz = Tk() raiz.title("Sistema experto- Tipos de covid") raiz.config(bg="#f4f7fa") #raiz.resizable(0,0) mi0Frame = Frame(raiz)#, width="1200", height="700") mi0Frame.grid(row=1, column=0) mi0Frame.config(bg="#f4f7fa") mi3Frame = Frame(raiz)#, width=...
[ 6738, 256, 74, 3849, 1330, 9, 198, 6738, 256, 74, 3849, 1330, 10369, 198, 6738, 5887, 64, 1330, 1635, 198, 198, 430, 528, 796, 309, 74, 3419, 198, 430, 528, 13, 7839, 7203, 50, 396, 19687, 1121, 1462, 12, 23095, 418, 390, 39849, 3...
2.25525
3,381
import socket import time import shelve preset_command = { 1: ['MB0023,1', 'MI0695,'], 2: ['MB0024,1', 'MI0696,'], 3: ['MB0076,1', 'MI0697,'], 4: ['MB0026,1', 'MI0698,'], } force_command = 'MB0336,1' start_command = 'MB0020,0' stop_command = 'MB0020,1' if __name__ == '__main__': temperature = Te...
[ 11748, 17802, 198, 11748, 640, 198, 11748, 7497, 303, 198, 198, 18302, 316, 62, 21812, 796, 1391, 198, 220, 220, 220, 352, 25, 37250, 10744, 405, 1954, 11, 16, 3256, 705, 8895, 3312, 3865, 4032, 4357, 198, 220, 220, 220, 362, 25, 37...
2.175325
154
from django.conf import settings from django.core.mail import send_mail from django.db import models from django.db.models import ForeignKey, OneToOneField, TextField, CharField, \ SET_NULL, CASCADE, BooleanField, UniqueConstraint from django.db.models.signals import post_save from django.dispatch import receiver f...
[ 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, 7295, 13, 4529, 1330, 3758, 62, 4529, 198, 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 6738, 42625, 14208, 13, 9945, 13, 27530, 1330, 8708, 9218, 11, 1881, 2514,...
2.584098
2,943
from datetime import date from datetime import datetime dateToday = date.today() print(dateToday)
[ 6738, 4818, 8079, 1330, 3128, 198, 6738, 4818, 8079, 1330, 4818, 8079, 628, 198, 4475, 8888, 796, 3128, 13, 40838, 3419, 198, 198, 4798, 7, 4475, 8888, 8 ]
3.571429
28
# Copyright 2021 Marco Nicola # # 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, ...
[ 2, 15069, 33448, 16556, 40396, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, 198, 2, 921, 743, 73...
3.86802
197
#!/usr/bin/env python # -*- mode: python; coding: koi8-r; -*- import os import gtk, gobject imdir = 'images' imtype = 'png' background = '#efebe7' #fill_color = 0xff000000 # red fill_color = int('ff000000', 16) if not os.path.exists(imdir): os.mkdir(imdir) gc = None done = False win = gtk....
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 4235, 25, 21015, 26, 19617, 25, 479, 23013, 23, 12, 81, 26, 532, 9, 12, 198, 198, 11748, 28686, 198, 11748, 308, 30488, 11, 48484, 752, 198, 198, 320, 15908, 796, ...
2.434412
587
from __future__ import division import matplotlib.pyplot as plt import MDAnalysis as md import numpy as np coil_distance, ASP_distance, ASP_distance1, ASP_distance2 = calculate_dists('structure.pdb', 'equ.dcd') x_vals = [x / 10 for x in range(0, len(coil_distance))] plt.plot(x_vals, coil_distance, linewidth=0.5) #leg ...
[ 6738, 11593, 37443, 834, 1330, 7297, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 11748, 10670, 32750, 355, 45243, 198, 11748, 299, 32152, 355, 45941, 198, 198, 1073, 346, 62, 30246, 11, 34658, 62, 30246, 11, 34658...
2.275109
687
import datetime as dt import json from flask_restful import ( Resource, reqparse, ) from flask_security import current_user from marshmallow_sqlalchemy import ModelSchema from .utils import auth_required from .. import db from ..core.utils import log_exception from ..models import ContentFlag flag_schema ...
[ 11748, 4818, 8079, 355, 288, 83, 198, 11748, 33918, 198, 198, 6738, 42903, 62, 2118, 913, 1330, 357, 198, 220, 220, 220, 20857, 11, 198, 220, 220, 220, 43089, 29572, 11, 198, 8, 198, 6738, 42903, 62, 12961, 1330, 1459, 62, 7220, 198...
3.270833
144
# -*- coding: utf-8 -*- """ Copyright: Frank Nussbaum (frank.nussbaum@uni-jena.de) This file contains various functions used in the module including - sparse norms and shrinkage operators - a stable logsumexp implementation - array printing-method that allows pasting the output into Python code """ import...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 201, 198, 37811, 201, 198, 15269, 25, 5278, 399, 1046, 24738, 357, 8310, 962, 13, 77, 1046, 24738, 31, 35657, 12, 73, 8107, 13, 2934, 8, 201, 198, 201, 198, 1212, 2393, 4...
2.13626
6,128
# Generated by Django 2.2.4 on 2020-02-07 18:11 from django.db import migrations, models import django.db.models.deletion import jsonfield.fields
[ 2, 2980, 515, 416, 37770, 362, 13, 17, 13, 19, 319, 12131, 12, 2999, 12, 2998, 1248, 25, 1157, 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.96
50
import torch.nn as nn import torch.nn.functional as F from ssd.modeling.anchor import make_anchor_generator from ssd.utils import bbox from .inference import make_post_processor from .loss import make_loss_evaluator from .predictor import make_ssd_predictor
[ 11748, 28034, 13, 20471, 355, 299, 77, 198, 11748, 28034, 13, 20471, 13, 45124, 355, 376, 198, 198, 6738, 264, 21282, 13, 4666, 10809, 13, 3702, 273, 1330, 787, 62, 3702, 273, 62, 8612, 1352, 198, 6738, 264, 21282, 13, 26791, 1330, ...
3.13253
83
"""Find max element""" #!/usr/bin/env python3 """Find max element""" import random from collections import Counter List = [random.randrange(1, 15) for num in range(10)] frequent_number, frequency = most_frequent(List)[0] print(f"List {List}: \nMost frequent number {frequent_number} \nFrequency: {frequency}")
[ 37811, 16742, 3509, 5002, 37811, 198, 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 37811, 16742, 3509, 5002, 37811, 198, 11748, 4738, 198, 6738, 17268, 1330, 15034, 198, 198, 8053, 796, 685, 25120, 13, 25192, 9521, 7, 16, 11, ...
3.183673
98
# -*- coding: utf-8 -*- import xbmcgui
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 11748, 2124, 20475, 66, 48317 ]
1.95
20
# ex:ts=4:sw=4:sts=4:et # -*- tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- # # Copyright (C) 2003, 2004 Chris Larson # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License version 2 as # published by the Free Software Foundation. #...
[ 2, 409, 25, 912, 28, 19, 25, 2032, 28, 19, 25, 6448, 28, 19, 25, 316, 198, 2, 532, 9, 12, 7400, 12, 10394, 25, 604, 26, 269, 12, 35487, 12, 28968, 25, 604, 26, 33793, 12, 8658, 82, 12, 14171, 25, 18038, 532, 9, 12, 198, 2,...
3.417722
237