content
stringlengths
1
1.04M
input_ids
listlengths
1
774k
ratio_char_token
float64
0.38
22.9
token_count
int64
1
774k
from slothql.types.scalars import IntegerType, FloatType, StringType, BooleanType, IDType from slothql.types.json import JsonStringType from slothql.types.datetime import DateTimeType, DateType, TimeType from .field import Field
[ 6738, 1017, 849, 13976, 13, 19199, 13, 1416, 282, 945, 1330, 34142, 6030, 11, 48436, 6030, 11, 10903, 6030, 11, 41146, 6030, 11, 4522, 6030, 198, 6738, 1017, 849, 13976, 13, 19199, 13, 17752, 1330, 449, 1559, 10100, 6030, 198, 6738, 1...
3.4
70
import psycopg2 import json import os import sys def create_tables(): """ create tables in the PostgreSQL database""" commands = ( """DROP TABLE main; """, """ CREATE TABLE main ( package VARCHAR NOT NULL, category VARCHAR NOT NULL, downloads ...
[ 11748, 17331, 22163, 70, 17, 198, 11748, 33918, 198, 11748, 28686, 198, 11748, 25064, 198, 198, 4299, 2251, 62, 83, 2977, 33529, 198, 220, 220, 220, 37227, 2251, 8893, 287, 262, 2947, 47701, 6831, 37811, 198, 220, 220, 220, 9729, 796, ...
2.29783
507
import tensorflow as tf import numpy class GaussianBoundaryCondition(tf.keras.layers.Layer): """A simple module for applying an exponential boundary condition in N dimensions Note that the exponent is *inside* of the power of 2 in the exponent. This is to prevent divergence when it is trainable and goes n...
[ 11748, 11192, 273, 11125, 355, 48700, 198, 11748, 299, 32152, 198, 198, 4871, 12822, 31562, 49646, 560, 48362, 7, 27110, 13, 6122, 292, 13, 75, 6962, 13, 49925, 2599, 198, 220, 220, 220, 37227, 32, 2829, 8265, 329, 11524, 281, 39682, ...
2.694501
491
# Copyright 2017 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
[ 2, 15069, 2177, 3012, 3457, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, 198, 2, 921, 743, ...
2.328012
28,627
import dedupe import unittest if __name__ == "__main__": unittest.main()
[ 11748, 4648, 48722, 198, 11748, 555, 715, 395, 628, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 555, 715, 395, 13, 12417, 3419, 198 ]
2.548387
31
#get_data.py #234567890123456789012345678901234567890123456789012345678901234567890123456789 # Imports here import torch from torchvision import datasets, transforms # The command line parser for train.py
[ 2, 1136, 62, 7890, 13, 9078, 198, 2, 1954, 2231, 3134, 4531, 486, 1954, 2231, 3134, 4531, 486, 1954, 2231, 3134, 4531, 486, 1954, 2231, 3134, 4531, 486, 1954, 2231, 3134, 4531, 486, 1954, 2231, 3134, 4531, 486, 1954, 2231, 3134, 4531,...
2.746667
75
"""create bed_capacity table Revision ID: f8791d49d830 Revises: b84312f6532e Create Date: 2020-11-26 15:22:19.299937 """ from alembic import op # revision identifiers, used by Alembic. revision = 'f8791d49d830' down_revision = '4fcda072e8c6' branch_labels = None depends_on = None
[ 37811, 17953, 3996, 62, 42404, 3084, 198, 198, 18009, 1166, 4522, 25, 277, 23, 3720, 16, 67, 2920, 67, 48341, 198, 18009, 2696, 25, 275, 23, 3559, 1065, 69, 2996, 2624, 68, 198, 16447, 7536, 25, 12131, 12, 1157, 12, 2075, 1315, 25, ...
2.383333
120
# Copyright 2019 Jij Inc. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/licenses/LICENSE-2.0 # Unless required by applicable law or agreed to in writing, softwa...
[ 2, 15069, 13130, 449, 2926, 3457, 13, 198, 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...
2.219853
1,501
B()
[ 198, 33, 3419 ]
1.333333
3
# # add_numbers() # x = add_numbers_version_01(20,30) # print(x) # ? # not returning anything to you # add_numbers_version_01(50, 10) # add_numbers_version_01(300, 29) # add_numbers_version_01(20.78, 56.89) # # Average of two numbers # Add 2 nos and then divide the sum with nos. of value # no_one = 50 # n...
[ 2, 220, 198, 198, 2, 751, 62, 77, 17024, 3419, 198, 198, 2, 2124, 796, 751, 62, 77, 17024, 62, 9641, 62, 486, 7, 1238, 11, 1270, 8, 198, 2, 3601, 7, 87, 8, 220, 1303, 5633, 628, 197, 2, 407, 8024, 1997, 284, 345, 220, 198, ...
2.456103
467
# Note: # 1. Need dependency autoinstall # 2. GDAL import os os.environ['PATH'] import gtfs2gmns as gg gtfs_path = "H:\\ChromeDownload\\gtfscota" gmns_path = "H:\\ChromeDownload\\gtfscota\\output" node_transit,link_transit = gg.Convert_GTFS(gtfs_path,gmns_path)
[ 2, 5740, 25, 198, 2, 352, 13, 10664, 20203, 8295, 17350, 198, 2, 362, 13, 27044, 1847, 198, 198, 11748, 28686, 198, 418, 13, 268, 2268, 17816, 34219, 20520, 198, 11748, 308, 83, 9501, 17, 39870, 5907, 355, 308, 70, 198, 198, 13655, ...
2.336283
113
import numpy as np from .arpack import _arpack # type: ignore[attr-defined] from . import eigsh from scipy.sparse.linalg.interface import LinearOperator from scipy.sparse import isspmatrix from scipy.sparse.sputils import is_pydata_spmatrix from scipy.sparse.linalg.eigen.lobpcg import lobpcg # type: ignore[no-redef...
[ 11748, 299, 32152, 355, 45941, 198, 198, 6738, 764, 5117, 441, 1330, 4808, 5117, 441, 220, 1303, 2099, 25, 8856, 58, 35226, 12, 23211, 60, 198, 6738, 764, 1330, 304, 328, 1477, 198, 198, 6738, 629, 541, 88, 13, 82, 29572, 13, 75, ...
2.259536
3,749
from __future__ import absolute_import __author__ = 'Shyue Ping Ong' __copyright__ = 'Copyright 2013, The Materials Project' __version__ = '0.1' __maintainer__ = 'Shyue Ping Ong' __email__ = 'ongsp@ucsd.edu' __date__ = '1/24/14' import os from contextlib import contextmanager @contextmanager def cd(path): """ ...
[ 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 198, 198, 834, 9800, 834, 796, 705, 2484, 88, 518, 34263, 48041, 6, 198, 834, 22163, 4766, 834, 796, 705, 15269, 2211, 11, 383, 24310, 4935, 6, 198, 834, 9641, 834, 796, 705, 15, 13, ...
2.521898
274
""" Infinite evaluation loop going through the checkpoints in the model directory as they appear and evaluating them. Accuracy and average loss are printed and added as tensorboard summaries. """ from __future__ import absolute_import from __future__ import division from __future__ import print_function from ...
[ 37811, 201, 198, 18943, 9504, 12660, 9052, 1016, 832, 262, 36628, 287, 262, 2746, 8619, 201, 198, 292, 484, 1656, 290, 22232, 606, 13, 33222, 290, 2811, 2994, 389, 10398, 290, 201, 198, 29373, 355, 11192, 273, 3526, 30114, 3166, 13, 2...
2.146518
1,522
from unittest import TestCase import pandas as pd from pytz import UTC from exchange_calendars.exchange_calendar_xbse import XBSEExchangeCalendar from .test_exchange_calendar import ExchangeCalendarTestBase
[ 6738, 555, 715, 395, 1330, 6208, 20448, 198, 198, 11748, 19798, 292, 355, 279, 67, 198, 6738, 12972, 22877, 1330, 18119, 198, 198, 6738, 5163, 62, 9948, 44942, 13, 1069, 3803, 62, 9948, 9239, 62, 30894, 325, 1330, 1395, 4462, 36, 3109...
3.349206
63
# author: kagemeka # created: 2019-11-06 12:47:30(JST) import sys # import collections # import math # import string # import bisect # import re # import itertools # import statistics if __name__ == "__main__": # execute only if run as a script ...
[ 2, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1772, 25, 220, 479, 363, 368, 38001, 201, 198, 2, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220...
2.075472
159
# This an autogenerated file # # Generated with PlotNode from typing import Dict,Sequence,List from dmt.entity import Entity from dmt.blueprint import Blueprint from .blueprints.plotnode import PlotNodeBlueprint from typing import Dict from sima.post.controlsignalinputslot import ControlSignalInputSlot from sima.post....
[ 2, 770, 281, 1960, 519, 877, 515, 2393, 198, 2, 220, 198, 2, 2980, 515, 351, 28114, 19667, 198, 6738, 19720, 1330, 360, 713, 11, 44015, 594, 11, 8053, 198, 6738, 288, 16762, 13, 26858, 1330, 20885, 198, 6738, 288, 16762, 13, 17585, ...
2.39818
2,637
# pylint: disable=invalid-name """ Tests for photo.utils """ import uuid from django.test import TestCase from photo import utils # pylint: disable=too-few-public-methods class DummyInstance: """ Dummy instance object for passing into UploadToPathAndRename """ pk = None class UploadToPathAndRenameT...
[ 2, 279, 2645, 600, 25, 15560, 28, 259, 12102, 12, 3672, 198, 37811, 198, 51, 3558, 329, 4590, 13, 26791, 198, 37811, 198, 11748, 334, 27112, 198, 198, 6738, 42625, 14208, 13, 9288, 1330, 6208, 20448, 198, 198, 6738, 4590, 1330, 3384, ...
2.109238
4,806
# Copyright (c) 2021 - present, Timur Shenkao # 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 appl...
[ 2, 15069, 357, 66, 8, 33448, 532, 1944, 11, 5045, 333, 22323, 4914, 78, 198, 2, 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, 7...
3.967816
435
#!/usr/bin/env python """Searches specified directory for miss named files.""" import os class bcolors: """Color text in terminal.""" HEADER = '\033[95m' OKBLUE = '\033[94m' OKGREEN = '\033[92m' WARNING = '\033[93m' FAIL = '\033[91m' ENDC = '\033[0m' BOLD = '\033[1m' UNDERLINE =...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 37811, 50, 451, 2052, 7368, 8619, 329, 2051, 3706, 3696, 526, 15931, 628, 198, 11748, 28686, 628, 198, 4871, 275, 4033, 669, 25, 198, 220, 220, 220, 37227, 10258, 2420, 287, 12094, 526...
1.917
2,747
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ openSMILE_dir_to_csv.py Script to format openSMILE emobase *.csv output for a given set of files into a single csv. Also returns the data as a pandas dataframe. Created on Mon Jan 23 10:43:34 2017 Author: – Jon Clucas, 2017 (jon.clucas@childmind.org) © 2017...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 9654, 50, 8895, 2538, 62, 15908, 62, 1462, 62, 40664, 13, 9078, 198, 198, 7391, 284, 5794, 1280, 50, ...
2.212573
1,877
# ClearML - Example of CatBoost training, saving model and loading model # import argparse from catboost import CatBoostRegressor, Pool from catboost.datasets import msrank from clearml import Task import numpy as np from sklearn.model_selection import train_test_split if __name__ == "__main__": Task.init(pr...
[ 2, 11459, 5805, 532, 17934, 286, 5181, 45686, 3047, 11, 8914, 2746, 290, 11046, 2746, 198, 2, 198, 11748, 1822, 29572, 198, 198, 6738, 3797, 39521, 1330, 5181, 45686, 8081, 44292, 11, 19850, 198, 6738, 3797, 39521, 13, 19608, 292, 1039,...
3.206061
165
from django.template.defaultfilters import slugify def slug_generator(sender, instance, *args, **kwargs): ''' capitalize first letter of each word and generates slug ''' instance.name = instance.name.title() slug = slugify(instance.name) exists = sender.objects.filter(slug=slug).exists() if not exists...
[ 6738, 42625, 14208, 13, 28243, 13, 12286, 10379, 1010, 1330, 31065, 1958, 628, 198, 4299, 31065, 62, 8612, 1352, 7, 82, 2194, 11, 4554, 11, 1635, 22046, 11, 12429, 46265, 22046, 2599, 198, 220, 220, 705, 7061, 35160, 717, 3850, 286, 1...
2.854167
144
# -*- coding: utf-8 -*- import unittest import os import re from iktomi.utils import html from lxml.html import Element from lxml import etree import lxml.html as h class TestSanitizer(unittest.TestCase): '''Tests for sanitizer based on lxml''' @unittest.skip('lxml does not provide css filtration') def te...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 555, 715, 395, 198, 11748, 28686, 198, 11748, 302, 198, 6738, 220, 1134, 83, 12753, 13, 26791, 1330, 27711, 198, 6738, 300, 19875, 13, 6494, 1330, 11703, 198, 673...
1.97082
1,268
#!/usr/bin/env python # from any given string, remove all vowels # NON REGEX VERSION sample_string='Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Ne...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 2, 422, 597, 1813, 4731, 11, 4781, 477, 23268, 1424, 198, 198, 2, 44521, 23337, 6369, 44156, 2849, 198, 39873, 62, 8841, 11639, 50, 276, 3384, 2774, 16564, 5375, 271, 44192, 22284...
2.874704
423
# -*- coding: utf-8 -*- # This file is part of CairoSVG # Copyright © 2010-2012 Kozea # # This library is free software: you can redistribute it and/or modify it under # the terms of the GNU Lesser General Public License as published by the Free # Software Foundation, either version 3 of the License, or (at your option...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 770, 2393, 318, 636, 286, 23732, 50, 43490, 198, 2, 15069, 10673, 3050, 12, 6999, 17634, 2736, 64, 198, 2, 198, 2, 770, 5888, 318, 1479, 3788, 25, 345, 460, 17678...
2.176844
2,522
from onegov.core.security import Private, Public from onegov.form import FormCollection, FormDefinition from onegov.org.forms.form_definition import FormDefinitionUrlForm from onegov.org.views.form_definition import get_form_class, \ handle_new_definition, handle_edit_definition, handle_defined_form, \ handle_c...
[ 6738, 530, 9567, 13, 7295, 13, 12961, 1330, 15348, 11, 5094, 198, 6738, 530, 9567, 13, 687, 1330, 5178, 36307, 11, 5178, 36621, 198, 6738, 530, 9567, 13, 2398, 13, 23914, 13, 687, 62, 46758, 1330, 5178, 36621, 28165, 8479, 198, 6738, ...
3.006231
321
import cv2 from time import time from random import randint from object_manager import DefaultCircleManager, PackmanManager, MoovingCircleManager from utils import log, Joint from drawing import draw_objects from config import config
[ 11748, 269, 85, 17, 198, 6738, 640, 1330, 640, 198, 6738, 4738, 1330, 43720, 600, 198, 6738, 2134, 62, 37153, 1330, 15161, 31560, 293, 13511, 11, 6400, 805, 13511, 11, 4270, 5165, 31560, 293, 13511, 198, 6738, 3384, 4487, 1330, 2604, ...
4.103448
58
from __future__ import print_function, absolute_import, division import sys import os.path import re from contextlib import contextmanager import subprocess import numpy as np from numba import unittest_support as unittest from numba import config from ..support import captured_stdout from ..test_dispatcher import ...
[ 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 11, 4112, 62, 11748, 11, 7297, 198, 198, 11748, 25064, 198, 11748, 28686, 13, 6978, 198, 11748, 302, 198, 6738, 4732, 8019, 1330, 4732, 37153, 198, 11748, 850, 14681, 198, 198, 11748, 299, ...
2.472779
1,047
""" this is an attempt to convert a readable patt format (similar to the ones compatible with arbitrarypatterngenerator) into the 4-word format that can be cat into pattern generator v2 it reads pattfile written in the following format and generate the corresponding dpatt: #triggered input_line use_table threshold_...
[ 37811, 201, 198, 5661, 318, 281, 2230, 284, 10385, 257, 31744, 279, 1078, 5794, 357, 38610, 284, 262, 3392, 11670, 351, 14977, 33279, 8612, 1352, 8, 656, 262, 604, 12, 4775, 5794, 326, 460, 307, 3797, 656, 3912, 17301, 410, 17, 201, ...
3.13069
1,362
# Create your tasks here from __future__ import absolute_import, unicode_literals from celery import shared_task import time @shared_task @shared_task
[ 198, 2, 13610, 534, 8861, 994, 198, 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 11, 28000, 1098, 62, 17201, 874, 198, 6738, 18725, 1924, 1330, 4888, 62, 35943, 198, 11748, 640, 198, 198, 31, 28710, 62, 35943, 628, 198, 31, 28710, ...
3.5
44
from rest_framework import serializers from .models import Course
[ 6738, 1334, 62, 30604, 1330, 11389, 11341, 198, 6738, 764, 27530, 1330, 20537 ]
5
13
# Copyright (c) 2017 The WebRTC project authors. All Rights Reserved. # # Use of this source code is governed by a BSD-style license # that can be found in the LICENSE file in the root of the source # tree. An additional intellectual property rights grant can be found # in the file PATENTS. All contributing project au...
[ 2, 15069, 357, 66, 8, 2177, 383, 5313, 49, 4825, 1628, 7035, 13, 1439, 6923, 33876, 13, 198, 2, 198, 2, 5765, 286, 428, 2723, 2438, 318, 21825, 416, 257, 347, 10305, 12, 7635, 5964, 198, 2, 326, 460, 307, 1043, 287, 262, 38559, ...
3.005229
765
ICAO = { "Anaa": "NTGA", "Apalachicola Regional": "KAAF", "Malamala": "FAMD", "Al Ain International": "OMAL", "Atlantic City": "KACY", "Albany International": "KBAL", "Baise Youjiang": "ZGBS", "Albuquerque International Sunport": "KABQ", "RAF Abisko": "EAAK", "RAF Leuchars": "EGQ...
[ 25241, 46, 796, 1391, 198, 220, 220, 220, 366, 2025, 7252, 1298, 366, 11251, 9273, 1600, 198, 220, 220, 220, 366, 32, 18596, 620, 291, 5708, 15994, 1298, 366, 42, 38540, 1600, 198, 220, 220, 220, 366, 15029, 321, 6081, 1298, 366, 37...
2.188172
186
import sys import logging import ply.lex logger = logging.getLogger(__name__) class Lexer(object): ''' A Lexical analyzer for Python Typelanguage. ''' def tokenize(self, string): ''' Maps a string to an iterator over tokens. In other words: [char] -> [token] ''' ...
[ 11748, 25064, 198, 11748, 18931, 198, 198, 11748, 35960, 13, 2588, 198, 198, 6404, 1362, 796, 18931, 13, 1136, 11187, 1362, 7, 834, 3672, 834, 8, 198, 198, 4871, 17210, 263, 7, 15252, 2599, 198, 220, 220, 220, 705, 7061, 198, 220, 2...
2.119867
901
from output.models.nist_data.list_pkg.normalized_string.schema_instance.nistschema_sv_iv_list_normalized_string_length_5_xsd.nistschema_sv_iv_list_normalized_string_length_5 import NistschemaSvIvListNormalizedStringLength5 __all__ = [ "NistschemaSvIvListNormalizedStringLength5", ]
[ 6738, 5072, 13, 27530, 13, 77, 396, 62, 7890, 13, 4868, 62, 35339, 13, 11265, 1143, 62, 8841, 13, 15952, 2611, 62, 39098, 13, 77, 1023, 2395, 2611, 62, 21370, 62, 452, 62, 4868, 62, 11265, 1143, 62, 8841, 62, 13664, 62, 20, 62, ...
2.633028
109
from __future__ import print_function from orphics import maps,io,cosmology,catalogs from pixell import enmap import numpy as np import os,sys ifile = "paper/E-D56Clusters.fits" #catalogs.convert_hilton_catalog_to_enplot_annotate_file('public_clusters.csv',ifile,radius=15,width=3,color='red') catalogs.convert_hilton_...
[ 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 198, 6738, 393, 746, 873, 1330, 8739, 11, 952, 11, 6966, 29126, 11, 9246, 11794, 82, 198, 6738, 279, 844, 695, 1330, 551, 8899, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 28686, 11, ...
2.660377
159
import glfw from glfw import gl import numpy as np def opengl_supported(major, minor): '''Determines if opengl is supported for the version provided''' assert glfw.core.init() != 0 version = (major, minor) glfw.core.window_hint(glfw.CONTEXT_VERSION_MAJOR, major) glfw.core.window_hint(glfw.CONTEXT...
[ 11748, 1278, 44482, 198, 6738, 1278, 44482, 1330, 1278, 198, 11748, 299, 32152, 355, 45941, 628, 198, 198, 4299, 1280, 4743, 62, 15999, 7, 22478, 11, 4159, 2599, 198, 220, 220, 220, 705, 7061, 35, 13221, 274, 611, 1280, 4743, 318, 485...
2.307203
472
# Copyright 2014 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. import sys import os import exceptions import itertools import re def GetNinjaOutputDirectory(chrome_root): """Returns <chrome_root>/<output_dir>/(Relea...
[ 2, 15069, 1946, 383, 18255, 1505, 46665, 13, 1439, 2489, 10395, 13, 198, 2, 5765, 286, 428, 2723, 2438, 318, 21825, 416, 257, 347, 10305, 12, 7635, 5964, 326, 460, 307, 198, 2, 1043, 287, 262, 38559, 24290, 2393, 13, 628, 198, 11748...
2.757037
675
from tkinter import * import PySimpleGUI as sg window = Tk() window.title("Kill Confirm Calculator") global oppKilPer promptLabel = Label(window, text="Select your Opponents Rival").grid(row=1, column=4) promptLabel1 = Label(window, text="by clicking a Button").grid(row=2, column=4) #Functions containing e...
[ 6738, 256, 74, 3849, 1330, 1635, 201, 198, 11748, 9485, 26437, 40156, 355, 264, 70, 201, 198, 17497, 796, 309, 74, 3419, 201, 198, 17497, 13, 7839, 7203, 27100, 7326, 2533, 43597, 4943, 201, 198, 201, 198, 20541, 1269, 42, 346, 5990, ...
2.760618
777
import warnings warnings.simplefilter(action='ignore', category=FutureWarning) from Bio import SeqIO from Bio.Seq import Seq import numpy as np import random import itertools from textwrap import wrap from collections import defaultdict if __name__ == '__main__': ...
[ 198, 11748, 14601, 198, 40539, 654, 13, 36439, 24455, 7, 2673, 11639, 46430, 3256, 6536, 28, 29783, 20361, 8, 198, 198, 6738, 16024, 1330, 1001, 80, 9399, 198, 6738, 16024, 13, 4653, 80, 1330, 1001, 80, 198, 11748, 299, 32152, 355, 45...
2.092486
519
import requests from utils.time_utils import get_target_date_as_timestamp if __name__ == "__main__": main()
[ 11748, 7007, 198, 198, 6738, 3384, 4487, 13, 2435, 62, 26791, 1330, 651, 62, 16793, 62, 4475, 62, 292, 62, 16514, 27823, 628, 628, 628, 628, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 1388, 341...
2.75
44
from __future__ import print_function import sys import traceback import inspect import types from ConfigParser import ConfigParser import os from functools import partial from pox.boot import _do_imports from pox.core import core from pox.lib.revent.revent import EventHalt log = core.getLogger("ComponentLauncher")...
[ 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 198, 198, 11748, 25064, 198, 11748, 12854, 1891, 198, 11748, 10104, 198, 11748, 3858, 198, 6738, 17056, 46677, 1330, 17056, 46677, 198, 11748, 28686, 198, 6738, 1257, 310, 10141, 1330, 13027, ...
3.004545
220
from django.views.generic.base import RedirectView from rest_framework.generics import RetrieveAPIView from rest_framework.settings import api_settings from wagtail.core.models import Page from wagtail.core.views import serve as serve_page from wagtail.documents.views.serve import serve as serve_doc from wagtail.images...
[ 6738, 42625, 14208, 13, 33571, 13, 41357, 13, 8692, 1330, 2297, 1060, 7680, 198, 6738, 1334, 62, 30604, 13, 8612, 873, 1330, 4990, 30227, 2969, 3824, 769, 198, 6738, 1334, 62, 30604, 13, 33692, 1330, 40391, 62, 33692, 198, 6738, 266, ...
2.882353
510
__source__ = 'https://leetcode.com/problems/cheapest-flights-within-k-stops/' # Time: O() # Space: O() # # Description: Leetcode # 787. Cheapest Flights Within K Stops # # There are n cities connected by m flights. # Each fight starts from city u and arrives at v with a price w. # # Now given all the cities and flight...
[ 834, 10459, 834, 796, 705, 5450, 1378, 293, 316, 8189, 13, 785, 14, 1676, 22143, 14, 2395, 35746, 12, 2704, 2337, 12, 33479, 12, 74, 12, 301, 2840, 14, 6, 198, 2, 3862, 25, 220, 440, 3419, 198, 2, 4687, 25, 440, 3419, 198, 2, ...
2.209213
2,084
import json import os import tempfile from modelstore.model_store import ModelStore _DOMAIN_NAME = "example-model-file"
[ 11748, 33918, 198, 11748, 28686, 198, 11748, 20218, 7753, 198, 198, 6738, 2746, 8095, 13, 19849, 62, 8095, 1330, 9104, 22658, 198, 198, 62, 39170, 29833, 62, 20608, 796, 366, 20688, 12, 19849, 12, 7753, 1, 628, 628 ]
3.289474
38
import json import os import numpy as np from tokenizers import BertWordPieceTokenizer from transformers import BertTokenizer class SquadExample: """ Process SQUAD dataset """ def read_data(filename, settings): """ Helper function to read and preprocess SQUAD data for training and validation w...
[ 11748, 33918, 198, 11748, 28686, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 11241, 11341, 1330, 22108, 26449, 47, 8535, 30642, 7509, 198, 6738, 6121, 364, 1330, 22108, 30642, 7509, 628, 198, 4871, 11630, 16281, 25, 198, 220, 220, 220,...
2.858726
361
import os import random import numpy as np import scipy.misc as misc import imageio from tqdm import tqdm import cv2 from PIL import Image import torch import torch.nn.functional as F IMG_EXTENSIONS = ['.jpg', '.JPG', '.jpeg', '.JPEG', '.png', '.PNG', '.ppm', '.PPM', '.bmp', '.BMP'] BINARY_EXTENSIONS = ['.npy'] BENCH...
[ 11748, 28686, 198, 11748, 4738, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 629, 541, 88, 13, 44374, 355, 12747, 198, 11748, 2939, 952, 198, 6738, 256, 80, 36020, 1330, 256, 80, 36020, 198, 11748, 269, 85, 17, 198, 6738, 350, 4146...
2.930348
201
print("Entre com os dados de um trangulo") lado1 = int(input("Lado 1: ")) lado2 = int(input("Lado 2: ")) lado3 = int(input("Lado 3: ")) if lado1 < lado2 + lado3 and lado2 < lado1 + lado3 and lado3 < lado1 + lado2: if lado1 == lado2 == lado3: print("Triângulo equilatero") elif lado1 != lado2 != lado3 != ...
[ 4798, 7203, 14539, 260, 401, 28686, 9955, 418, 390, 23781, 491, 648, 43348, 4943, 198, 75, 4533, 16, 796, 493, 7, 15414, 7203, 43, 4533, 352, 25, 366, 4008, 198, 75, 4533, 17, 796, 493, 7, 15414, 7203, 43, 4533, 362, 25, 366, 4008...
2.110092
218
# -------------------------------------------------------------------- # # game.py # contains main game loop, # including events, drawing, and update # -------------------------------------------------------------------- # # General imports: import sys # Game related imports: import pygame import pyscroll import py...
[ 2, 16529, 650, 1303, 198, 2, 983, 13, 9078, 198, 2, 220, 220, 4909, 1388, 983, 9052, 11, 198, 2, 197, 8201, 2995, 11, 8263, 11, 290, 4296, 198, 2, 16529, 650, 1303, 198, 198, 2, 3611, 17944, 25, 198, 11748, 25064, 198, 198, 2, ...
4.121339
239
# YOLOv5 🚀 by Ultralytics, GPL-3.0 license """ Auto-anchor utils """ import random import numpy as np import torch import yaml from tqdm import tqdm from utils.general import LOGGER, colorstr, emojis PREFIX = colorstr("AutoAnchor: ") def kmean_anchors( dataset="./data/coco128.yaml", n=9, img_size=640, thr=...
[ 2, 575, 3535, 46, 85, 20, 12520, 248, 222, 416, 6172, 1373, 88, 14094, 11, 38644, 12, 18, 13, 15, 5964, 198, 37811, 198, 27722, 12, 3702, 273, 3384, 4487, 198, 37811, 198, 198, 11748, 4738, 198, 198, 11748, 299, 32152, 355, 45941, ...
2.114318
1,767
""" SMTP.sendmail and SMTP.send_message method testing. """ import copy import email.generator import email.header import pytest from aiosmtplib import ( SMTPNotSupported, SMTPRecipientsRefused, SMTPResponseException, SMTPStatus, ) pytestmark = pytest.mark.asyncio() async def test_rset_af...
[ 37811, 198, 12310, 7250, 13, 21280, 4529, 290, 9447, 7250, 13, 21280, 62, 20500, 2446, 4856, 13, 198, 37811, 198, 11748, 4866, 198, 11748, 3053, 13, 8612, 1352, 198, 11748, 3053, 13, 25677, 198, 198, 11748, 12972, 9288, 198, 198, 6738, ...
2.512695
1,024
from .tool.func import *
[ 6738, 764, 25981, 13, 20786, 1330, 1635 ]
3.428571
7
""" MOON PHASE CLOCK for Adafruit Matrix Portal: displays current time, lunar phase and time of next moonrise or moonset. Requires WiFi internet access. Written by Phil 'PaintYourDragon' Burgess for Adafruit Industries. MIT license, all text above must be included in any redistribution. BDF fonts from the X.Org proje...
[ 37811, 198, 11770, 1340, 9370, 11159, 7852, 11290, 329, 1215, 1878, 4872, 24936, 25663, 25, 11298, 1459, 640, 11, 25572, 198, 40715, 290, 640, 286, 1306, 8824, 17163, 393, 31093, 316, 13, 26848, 24904, 5230, 1895, 13, 198, 198, 25354, 4...
2.262004
8,393
from ignite.metrics.metric import Metric from ignite.engine import Events class MetricsLambda(Metric): """ Apply a function to other metrics to obtain a new metric. The result of the new metric is defined to be the result of applying the function to the result of argument metrics. When update, th...
[ 6738, 44794, 13, 4164, 10466, 13, 4164, 1173, 1330, 3395, 1173, 198, 6738, 44794, 13, 18392, 1330, 18715, 628, 198, 4871, 3395, 10466, 43, 4131, 6814, 7, 9171, 1173, 2599, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 27967, 257, 216...
2.821596
426
#!/usr/bin/python # -*- coding:utf-8 -*- """ 北邮人网关登录脚本: 使用方法: 登录:python loginBuptGw.py i 退出:python loginBuptGw.py o """ import urllib2 import urllib import cookielib import hashlib import os import re import sys reload(sys) sys.setdefaultencoding('utf8') uname = XXXXXX #请正确填写学号 upass = 'XXXXXX' #请正确填写密码 if __na...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 2, 532, 9, 12, 19617, 25, 40477, 12, 23, 532, 9, 12, 198, 198, 37811, 198, 44293, 245, 165, 224, 106, 21689, 163, 121, 239, 17739, 111, 163, 247, 119, 37605, 243, 164, 226, 248, 17312, ...
1.734637
358
from scipy.interpolate import interp1d import numpy as np def vectorize(func_orig): """ A function that takes a function and returns another that can fun on lists and arrays :param func_orig: any functions :return: vectorized function """ return func def get_interp_extrapolate_functions(...
[ 6738, 629, 541, 88, 13, 3849, 16104, 378, 1330, 987, 79, 16, 67, 198, 11748, 299, 32152, 355, 45941, 628, 198, 4299, 15879, 1096, 7, 20786, 62, 11612, 2599, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 317, 2163, 326, 2753, 257, ...
3.091205
307
# uncompyle6 version 3.7.4 # Python bytecode 3.7 (3394) # Decompiled from: Python 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:58:18) [MSC v.1900 64 bit (AMD64)] # Embedded file name: T:\InGame\Gameplay\Scripts\Server\objects\decorative\__init__.py # Compiled at: 2009-11-20 02:49:20 # Size of source mod 2**32: 106 by...
[ 2, 34318, 2349, 21, 2196, 513, 13, 22, 13, 19, 198, 2, 11361, 18022, 8189, 513, 13, 22, 357, 2091, 5824, 8, 198, 2, 4280, 3361, 3902, 422, 25, 11361, 513, 13, 22, 13, 24, 357, 31499, 14, 85, 18, 13, 22, 13, 24, 25, 1485, 66,...
2.447761
134
import random from unittest import TestCase import peb
[ 11748, 4738, 198, 6738, 555, 715, 395, 1330, 6208, 20448, 198, 198, 11748, 613, 65, 628, 198 ]
3.411765
17
# Generated by Django 3.1.2 on 2020-11-04 15:53 from django.db import migrations, models
[ 2, 2980, 515, 416, 37770, 513, 13, 16, 13, 17, 319, 12131, 12, 1157, 12, 3023, 1315, 25, 4310, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 628 ]
2.84375
32
import argparse import matplotlib matplotlib.use('agg') import csv import json import multiprocessing as mp import os import random import re import sys from functools import partial from operator import attrgetter, itemgetter import networkx as nx import numpy as np import pandas as pd import time from sofa_aisi impor...
[ 11748, 1822, 29572, 198, 11748, 2603, 29487, 8019, 198, 6759, 29487, 8019, 13, 1904, 10786, 9460, 11537, 198, 11748, 269, 21370, 198, 11748, 33918, 198, 11748, 18540, 305, 919, 278, 355, 29034, 198, 11748, 28686, 198, 11748, 4738, 198, 11...
3.340102
197
import MySQLdb db = MySQLdb.connect("db", "root", "my-secret-pw", "bd_notes") cursor = db.cursor() global resultsExportEtudiants resultsExportEtudiants = []
[ 11748, 33476, 9945, 198, 198, 9945, 796, 33476, 9945, 13, 8443, 7203, 9945, 1600, 366, 15763, 1600, 366, 1820, 12, 21078, 12, 79, 86, 1600, 366, 17457, 62, 17815, 4943, 198, 198, 66, 21471, 796, 20613, 13, 66, 21471, 3419, 198, 20541,...
2.758621
58
import abc import asyncio from typing import Any from typing import Dict from typing import Optional from async_blp.enums import ErrorBehaviour from async_blp.utils import log # pylint: disable=ungrouped-imports try: import blpapi except ImportError: from async_blp.utils import env_test as blpapi LOGGER = lo...
[ 11748, 450, 66, 198, 11748, 30351, 952, 198, 6738, 19720, 1330, 4377, 198, 6738, 19720, 1330, 360, 713, 198, 6738, 19720, 1330, 32233, 198, 198, 6738, 30351, 62, 2436, 79, 13, 268, 5700, 1330, 13047, 25267, 37716, 198, 6738, 30351, 62, ...
3.054545
110
import collections from typing import Any, Dict, Tuple def format_keyword(keyword: str, val: Any, lop_off: bool = True) -> Tuple[str, str]: """Function to reformat value `val` for `keyword` from python into nwchem-speak.""" # Transform string booleans into " " if val is True: return keyword.lower...
[ 11748, 17268, 198, 6738, 19720, 1330, 4377, 11, 360, 713, 11, 309, 29291, 628, 198, 4299, 5794, 62, 2539, 4775, 7, 2539, 4775, 25, 965, 11, 1188, 25, 4377, 11, 300, 404, 62, 2364, 25, 20512, 796, 6407, 8, 4613, 309, 29291, 58, 253...
2.052632
1,482
from common.file_tools import delete_old_files_directories import time
[ 6738, 2219, 13, 7753, 62, 31391, 1330, 12233, 62, 727, 62, 16624, 62, 12942, 1749, 198, 11748, 640, 198 ]
3.736842
19
from smbus2 import SMBus import time # RPi Channel 1 channel = 1 bus = SMBus(channel) # ADS1115 address and registers address = 0x48 reg_config = 0x01 # Config value: # - Single conversion # - A0 input # - 4.096V reference config = [0xC2, 0xB3] while True: reg_conversion = 0x00 # Start conversion bus.write...
[ 198, 6738, 895, 10885, 17, 1330, 9447, 16286, 198, 11748, 640, 198, 198, 2, 25812, 72, 11102, 352, 198, 17620, 796, 352, 198, 198, 10885, 796, 9447, 16286, 7, 17620, 8, 198, 2, 44784, 1157, 1314, 2209, 290, 28441, 198, 21975, 796, 6...
2.60198
505
import numpy as np import math # Copyright 2020 Joshua Laniado and Todd O. Yeates. __author__ = "Joshua Laniado and Todd O. Yeates" __copyright__ = "Copyright 2020, Nanohedra" __version__ = "1.0" # ROTATION RANGE DEG C2 = 180 C3 = 120 C4 = 90 C5 = 72 C6 = 60 RotRangeDict = {"C2": C2, "C3": C3, "C4": C4, "C5": C5, "...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 10688, 628, 198, 2, 15069, 12131, 20700, 406, 3216, 4533, 290, 14377, 440, 13, 11609, 689, 13, 198, 834, 9800, 834, 796, 366, 47740, 406, 3216, 4533, 290, 14377, 440, 13, 11609, 689, 1, 198, ...
2.317241
145
from precious import Value, assign_attributes, copy
[ 6738, 14186, 1330, 11052, 11, 8333, 62, 1078, 7657, 11, 4866, 628, 198 ]
4.153846
13
"""Tests for maven_releases.py.""" # import pytest # TODO enable when new test(s) will be added # from f8a_jobs.handlers.maven_releases import MavenReleasesAnalyses class TestMavenReleasesAnalyses(object): """Tests for MavenReleasesAnalyses class.""" def setup_method(self, method): """Set up any st...
[ 37811, 51, 3558, 329, 285, 4005, 62, 260, 29329, 13, 9078, 526, 15931, 198, 198, 2, 1330, 12972, 9288, 198, 198, 2, 16926, 46, 7139, 618, 649, 1332, 7, 82, 8, 481, 307, 2087, 198, 2, 422, 277, 23, 64, 62, 43863, 13, 4993, 8116, ...
2.910053
189
#!/usr/bin/env python # −*− coding: UTF−8 −*− import abc if __name__ == '__main__': test()
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 9746, 9, 14095, 19617, 25, 41002, 14095, 23, 9746, 9, 14095, 198, 198, 11748, 450, 66, 628, 628, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220,...
2.148936
47
import threading import requests import os import time urls = [ "https://unsplash.com/photos/CTflmHHVrBM/download?force=true", "https://unsplash.com/photos/pWV8HjvHzk8/download?force=true", # "https://unsplash.com/photos/1jn_3WBp60I/download?force=true", # "https://unsplash.com/photos/8E5HawfqCMM/download?force=t...
[ 11748, 4704, 278, 198, 11748, 7007, 198, 11748, 28686, 198, 11748, 640, 628, 198, 6371, 82, 796, 685, 198, 197, 1, 5450, 1378, 13271, 489, 1077, 13, 785, 14, 24729, 14, 4177, 2704, 76, 16768, 53, 81, 12261, 14, 15002, 30, 3174, 28, ...
2.472727
330
from .ami import prepare_ami from .broadcast_news import prepare_broadcast_news from .librimix import prepare_librimix from .librispeech import prepare_librispeech from .switchboard import prepare_switchboard __all__ = [ 'prepare_ami', 'prepare_broadcast_news', 'prepare_librimix', 'prepare_librispeech'...
[ 6738, 764, 6277, 1330, 8335, 62, 6277, 198, 6738, 764, 36654, 2701, 62, 10827, 1330, 8335, 62, 36654, 2701, 62, 10827, 198, 6738, 764, 75, 2889, 320, 844, 1330, 8335, 62, 75, 2889, 320, 844, 198, 6738, 764, 8019, 2442, 431, 3055, 13...
2.713178
129
import re from selenium import webdriver from selenium.webdriver.chrome.options import Options import argparse import ncz import chromedriver_binary parser = argparse.ArgumentParser() parser.add_argument('keyword1', help="main_city_name") parser.add_argument('keyword2', help="sub_city_name") parser.add_argument('key...
[ 11748, 302, 198, 6738, 384, 11925, 1505, 1330, 3992, 26230, 198, 6738, 384, 11925, 1505, 13, 12384, 26230, 13, 46659, 13, 25811, 1330, 18634, 198, 11748, 1822, 29572, 198, 11748, 299, 26691, 198, 198, 11748, 15358, 276, 38291, 62, 39491, ...
2.432018
456
from tools import loadCmsProcess,writeCfg from addPoolDBESSource import addPoolDBESSource from CmsswTask import CmsswTask import os
[ 6738, 4899, 1330, 3440, 34, 907, 18709, 11, 13564, 34, 40616, 198, 6738, 751, 27201, 11012, 1546, 7416, 1330, 751, 27201, 11012, 1546, 7416, 198, 6738, 327, 76, 824, 86, 25714, 1330, 327, 76, 824, 86, 25714, 198, 11748, 28686, 198 ]
3.219512
41
import networkx as nx import matplotlib.pyplot as plt ## add a node G = nx.Graph() G.add_node(1) G.add_nodes_from([2, 3]) H = nx.path_graph(10) G.add_nodes_from(H) G.add_node(H) G.add_node('shopping') ## edges G.add_edge(1, 2, {'weight': 3.1415}) e = (2, 3) G.add_edge(*e) G.add_edges_from([(1,2), (1,3)]) # G.add_edg...
[ 11748, 3127, 87, 355, 299, 87, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 198, 2235, 751, 257, 10139, 220, 198, 38, 796, 299, 87, 13, 37065, 3419, 198, 38, 13, 2860, 62, 17440, 7, 16, 8, 198, 38, 13, 2860...
1.901887
265
from core.advbase import * from module.template import Adv_INFUTP variants = {None: Mona, "RNG": Mona_RNG, "INFUTP": Mona_INFUTP}
[ 6738, 4755, 13, 32225, 8692, 1330, 1635, 198, 6738, 8265, 13, 28243, 1330, 8007, 62, 1268, 37, 3843, 47, 628, 628, 198, 198, 25641, 1187, 796, 1391, 14202, 25, 2892, 64, 11, 366, 49, 10503, 1298, 2892, 64, 62, 49, 10503, 11, 366, ...
2.368421
57
username = '' #enter your facebook user name password = '' #enter your facebook password
[ 29460, 796, 10148, 1303, 9255, 534, 23960, 2836, 1438, 198, 28712, 796, 10148, 1303, 9255, 534, 23960, 9206, 198 ]
4.684211
19
import sys from datetime import datetime import error_handler import valr UNKNOWN_TREND = "unknown" DOWN_TREND = "down" UP_TREND = "up" if __name__ == "__main__": sys.excepthook = error_handler.excepthook orders = [x for x in valr.get_open_orders() if x["side"].upper() == "BUY"] if len(orders) > 0: ...
[ 11748, 25064, 198, 6738, 4818, 8079, 1330, 4818, 8079, 198, 198, 11748, 4049, 62, 30281, 198, 11748, 1188, 81, 198, 198, 4944, 44706, 62, 5446, 10619, 796, 366, 34680, 1, 198, 41925, 62, 5446, 10619, 796, 366, 2902, 1, 198, 8577, 62, ...
2.377841
352
import csv from google.cloud import storage import logging def write_tsv(filename, files, fieldnames=None): """ write to tsv file Args: filename(str): file name files(list(dict)): list of file info [ { "GUID": "guid_example", "filename":...
[ 11748, 269, 21370, 198, 6738, 23645, 13, 17721, 1330, 6143, 198, 198, 11748, 18931, 628, 198, 4299, 3551, 62, 912, 85, 7, 34345, 11, 3696, 11, 2214, 14933, 28, 14202, 2599, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 3551, 284, 2...
2.16444
973
from sublime_db.core.typecheck import ( Any, Callable, Optional ) import sublime import sublime_plugin from sublime_db import core from sublime_db import ui from sublime_db.main.breakpoints import Breakpoints, Breakpoint, FunctionBreakpoint from .commands import AutoCompleteTextInputHandler @core.async @core.a...
[ 6738, 41674, 62, 9945, 13, 7295, 13, 4906, 9122, 1330, 357, 198, 197, 7149, 11, 198, 197, 14134, 540, 11, 198, 197, 30719, 198, 8, 198, 198, 11748, 41674, 198, 11748, 41674, 62, 33803, 198, 198, 6738, 41674, 62, 9945, 1330, 4755, 19...
3.360825
97
__author__ = 'wanglei02' from django import template from django.utils.html import conditional_escape from django.utils.safestring import mark_safe register = template.Library() @register.filter(name='join_link', needs_autoescape=True)
[ 834, 9800, 834, 796, 705, 86, 9248, 72, 2999, 6, 198, 198, 6738, 42625, 14208, 1330, 11055, 198, 6738, 42625, 14208, 13, 26791, 13, 6494, 1330, 26340, 62, 41915, 198, 6738, 42625, 14208, 13, 26791, 13, 49585, 395, 1806, 1330, 1317, 62...
3.287671
73
import copy from dataclasses import dataclass import dataclasses import functools import io import logging from multiprocessing.connection import wait import uuid from typing import Any, Dict, List, Optional, Tuple, Union from attr import field from concurrent.futures import ProcessPoolExecutor import pandas as pd impo...
[ 11748, 4866, 198, 6738, 4818, 330, 28958, 1330, 4818, 330, 31172, 198, 11748, 4818, 330, 28958, 198, 11748, 1257, 310, 10141, 198, 11748, 33245, 198, 11748, 18931, 198, 6738, 18540, 305, 919, 278, 13, 38659, 1330, 4043, 198, 11748, 334, ...
2.034531
4,257
# -*- coding: utf-8 -*- from functionsex import * from VombatiDB import VombatiDB, showDB, showStats, Workspace from VombatiDB import errors as dbError from importMail import ImportMail_MBox import errors as storeError import api from utils import RepairDialogLinking from libs.plainText import plaintext import textw...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 2163, 8044, 1330, 1635, 198, 198, 6738, 569, 2381, 7246, 11012, 1330, 569, 2381, 7246, 11012, 11, 905, 11012, 11, 905, 29668, 11, 10933, 10223, 198, 6738, 569, 238...
2.165113
751
from cytopy.data.gating_strategy import GatingStrategy, DuplicatePopulationError from cytopy.data.gate import ThresholdGate, PolygonGate, EllipseGate from cytopy.data.project import Project import matplotlib.pyplot as plt import pandas as pd import pytest @pytest.mark.parametrize("gate,child_n", ...
[ 6738, 3075, 4852, 88, 13, 7890, 13, 70, 803, 62, 2536, 4338, 1330, 402, 803, 13290, 4338, 11, 49821, 5344, 45251, 12331, 198, 6738, 3075, 4852, 88, 13, 7890, 13, 10494, 1330, 536, 10126, 22628, 11, 12280, 14520, 22628, 11, 7122, 541, ...
2.141058
397
import dotenv dotenv.load_dotenv() from time import sleep import schedule import requests import json from service.image_recognition import check_image_similarity from model import UMKM, UMKMValidator, Verification, Campaign schedule.every().minute.do(process_verifications) while True: try: sched...
[ 11748, 16605, 24330, 198, 26518, 24330, 13, 2220, 62, 26518, 24330, 3419, 198, 198, 6738, 640, 1330, 3993, 198, 11748, 7269, 198, 11748, 7007, 198, 11748, 33918, 198, 198, 6738, 2139, 13, 9060, 62, 26243, 653, 1330, 2198, 62, 9060, 62, ...
2.807143
140
__author__ = 'ehiller@css.edu' # Module to support custom teacher views in CourseBuilder dashboard # Views include: # Section Roster - list of students in section # Sections - list of sections for current user # Student Dashboard - view of a single student's performance in the course # Teacher...
[ 834, 9800, 834, 796, 705, 17231, 4665, 31, 25471, 13, 15532, 6, 628, 198, 2, 19937, 284, 1104, 2183, 4701, 5009, 287, 20537, 32875, 30415, 198, 2, 29978, 2291, 25, 198, 2, 220, 220, 220, 220, 220, 220, 7275, 371, 6197, 532, 1351, ...
2.469857
8,609
#!/usr/bin/env python # Copyright 2016, 2017 F5 Networks, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appli...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 2, 15069, 1584, 11, 2177, 376, 20, 27862, 11, 3457, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, ...
2.155861
6,108
""" Reads in current year's Arctic sea ice extent from Sea Ice Index 3 (NSIDC) Website : ftp://sidads.colorado.edu/DATASETS/NOAA/G02135/north/daily/data/ Author : Zachary M. Labe Date : 5 September 2016 """ ### Import modules import numpy as np import urllib as UL import datetime import matplotlib.pyplot as...
[ 37811, 198, 5569, 82, 287, 1459, 614, 338, 15723, 5417, 4771, 6287, 422, 6896, 6663, 12901, 513, 357, 8035, 2389, 34, 8, 198, 198, 33420, 220, 220, 1058, 10117, 79, 1378, 30255, 5643, 13, 8043, 4533, 13, 15532, 14, 35, 1404, 1921, 3...
2.248232
2,969
import collections import nltk import tensorflow as tf import numpy as np from tensorflow.contrib import rnn from utils import chunks import json import os import shutil def word_indexing(words): """ :param words: a string :return: a vocabulary dictionary {word1: 1, word2: 2, ...} and its reveres {...
[ 11748, 17268, 198, 11748, 299, 2528, 74, 198, 11748, 11192, 273, 11125, 355, 48700, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 11192, 273, 11125, 13, 3642, 822, 1330, 374, 20471, 198, 6738, 3384, 4487, 1330, 22716, 198, 11748, 33918, ...
2.323529
1,734
import numpy as np import matplotlib.pyplot as pl from vaccontrib.covid import ( get_covid_matrices ) from vaccontrib.main import ( get_reduced_vaccinated_susceptible_contribution_matrix, get_reduced_vaccinated_susceptible_eigenvector, get_eigenvector, get_next_generation_...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 628, 198, 6738, 6658, 3642, 822, 13, 66, 709, 312, 1330, 357, 198, 220, 220, 220, 220, 220, 220, 220, 651, 62, 66, 709, 312, 62, 6759, 45977, ...
2.005162
1,356
""" 15483 : 최소 편집 URL : https://www.acmicpc.net/problem/15483 Input #1 : abc ab Output #1 : 1 Input #2 : ca abc Output #2 : 3 Input #3 : abc cba Output #3 : 2 Input #4 : abcd bcde Output #4 : ...
[ 37811, 198, 220, 220, 220, 1315, 38783, 1058, 23821, 113, 250, 168, 228, 234, 220, 169, 236, 116, 168, 100, 239, 198, 220, 220, 220, 10289, 1058, 3740, 1378, 2503, 13, 330, 9383, 14751, 13, 3262, 14, 45573, 14, 1314, 38783, 198, 220...
1.637782
577
#!/usr/bin/env python3 """ Utility functions for JensenLab REST APIs. https://api.jensenlab.org/Textmining?type1=-26&id1=DOID:10652&type2=9606&limit=10&format=json https://api.jensenlab.org/Textmining?query=jetlag[tiab]%20OR%20jet-lag[tiab]&type2=9606&limit=10&format=json https://api.jensenlab.org/Knowledge?type1=-26&i...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 37811, 198, 18274, 879, 5499, 329, 32623, 17822, 30617, 23113, 13, 198, 5450, 1378, 15042, 13, 73, 18756, 23912, 13, 2398, 14, 8206, 45374, 30, 4906, 16, 10779, 2075, 5, 312, 16, ...
2.61194
603
import numpy as np import joblib from rllab.sampler.utils import rollout import os from rllab import config from rllab.misc import ext from tqdm import trange, tqdm import IPython import matplotlib matplotlib.use("Agg") import matplotlib.pyplot as plt import itertools from sandbox.finetuning.envs.mujoco.modified.modifi...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 1693, 8019, 198, 6738, 374, 297, 397, 13, 37687, 20053, 13, 26791, 1330, 38180, 198, 11748, 28686, 198, 6738, 374, 297, 397, 1330, 4566, 198, 6738, 374, 297, 397, 13, 44374, 1330, 1070, 198, ...
3.049751
201
from django.shortcuts import render_to_response from django.http import HttpResponseRedirect from django.http import HttpResponse from django.core.urlresolvers import reverse from django.views.decorators.csrf import csrf_exempt from django.template import RequestContext ## The home page.
[ 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 62, 1462, 62, 26209, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 7738, 1060, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 198, 6738, 42625, 14208, 13, 7295, ...
3.52439
82
# Generated by Django 2.0.5 on 2018-05-07 00:47 from django.db import migrations
[ 2, 2980, 515, 416, 37770, 362, 13, 15, 13, 20, 319, 2864, 12, 2713, 12, 2998, 3571, 25, 2857, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 628 ]
2.766667
30
################################## # Basik-Calc # Calculator for basic operations # Author: Ricardo Dimas ################################## import sys if __name__ == '__main__': try: main() except KeyboardInterrupt: print('\nExiting...') sys.exit()
[ 29113, 2235, 198, 2, 6455, 1134, 12, 9771, 66, 198, 2, 43597, 329, 4096, 4560, 198, 2, 6434, 25, 38847, 14048, 292, 198, 29113, 2235, 198, 198, 11748, 25064, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 2...
3
95
import multiprocessing import os import re import shutil import tempfile import zipfile from datetime import datetime from django.core.management.base import BaseCommand, CommandError import sh from corehq.apps.export.dbaccessors import get_properly_wrapped_export_instance from corehq.apps.export.multiprocess import...
[ 11748, 18540, 305, 919, 278, 198, 11748, 28686, 198, 11748, 302, 198, 11748, 4423, 346, 198, 11748, 20218, 7753, 198, 11748, 19974, 7753, 198, 6738, 4818, 8079, 1330, 4818, 8079, 198, 198, 6738, 42625, 14208, 13, 7295, 13, 27604, 13, 86...
2.944099
161
""" Interface for custom data. This module handles datasets and is the class that you need to inherit from for your custom dataset. This class gives you all the handles so that you can train with a new –dataset=mydataset. The particular configuration of keypoints and skeleton is specified in the headmeta instances """...
[ 37811, 198, 39317, 329, 2183, 1366, 13, 198, 198, 1212, 8265, 17105, 40522, 290, 318, 262, 1398, 326, 345, 761, 284, 16955, 422, 329, 534, 2183, 27039, 13, 198, 1212, 1398, 3607, 345, 477, 262, 17105, 523, 326, 345, 460, 4512, 351, ...
2.833068
629
# pydumper.py # # This is being worked on - it does not yet work at all, in ay way # shape or form :-) # # A new script engine, derived from the standard scripting engine, # which dumps information. # This generally can be used to grab all sorts of useful details about # an engine - expose bugs in it or Pytho...
[ 2, 279, 5173, 15829, 13, 9078, 201, 198, 2, 201, 198, 2, 770, 318, 852, 3111, 319, 532, 340, 857, 407, 1865, 670, 379, 477, 11, 287, 38762, 835, 201, 198, 2, 5485, 393, 1296, 47226, 201, 198, 2, 201, 198, 2, 317, 649, 4226, 31...
3.041985
262
import pandas as pd import numpy as np import csv #################Obtain the List of All bpts that sent Political Tweets [i.e. Political Bots]:####################### dfn = pd.read_csv("/root/.encrypted/.pythonSai/kCoreBots/CoreBotEN/MachineLearning/NaiveBayes/datasets/CoreBotTweetsCombinedEN.csv", sep=",", skiprows=...
[ 11748, 19798, 292, 355, 279, 67, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 269, 21370, 198, 198, 14468, 2, 5944, 3153, 262, 7343, 286, 1439, 275, 457, 82, 326, 1908, 14611, 24205, 1039, 685, 72, 13, 68, 13, 14611, 40946, 5974, ...
2.926966
178