content
stringlengths
1
1.04M
input_ids
listlengths
1
774k
ratio_char_token
float64
0.38
22.9
token_count
int64
1
774k
#!/usr/bin/env python # -*- coding:utf-8 -*- """================================================================= @Project : Algorithm_YuweiYin/LeetCode-All-Solution/Python3 @File : LC-0393-UTF-8-Validation.py @Author : [YuweiYin](https://github.com/YuweiYin) @Date : 2022-03-13 ==================================...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 40477, 12, 23, 532, 9, 12, 198, 37811, 23926, 28, 198, 31, 16775, 1058, 978, 42289, 62, 40728, 42990, 56, 259, 14, 3123, 316, 10669, 12, 3237, 12, 46344, ...
2.951613
806
''' Python program to create a copy of its own source code ''' main ()
[ 7061, 6, 198, 37906, 1430, 284, 2251, 257, 4866, 286, 663, 898, 2723, 2438, 198, 7061, 6, 628, 220, 220, 220, 220, 198, 12417, 7499 ]
3.04
25
""" Detecting spikes """ import logging import yass from yass import preprocess from yass import detect # configure logging module to get useful information logging.basicConfig(level=logging.INFO) # set yass configuration parameters yass.set_config('config.yaml', 'example-detect') # run preprocessor standardized_pa...
[ 37811, 198, 47504, 278, 27198, 198, 37811, 198, 11748, 18931, 198, 198, 11748, 331, 562, 198, 6738, 331, 562, 1330, 662, 14681, 198, 6738, 331, 562, 1330, 4886, 198, 198, 2, 17425, 18931, 8265, 284, 651, 4465, 1321, 198, 6404, 2667, 1...
2.555556
234
import os from front.logging import logger_setup from front.server import app if __name__ == "__main__": logger_setup() app.run( debug=True, port=os.getenv("FRONT_PORT"), )
[ 11748, 28686, 198, 6738, 2166, 13, 6404, 2667, 1330, 49706, 62, 40406, 198, 6738, 2166, 13, 15388, 1330, 598, 198, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 49706, 62, 40406, 3419, 198, 220, 220...
2.376471
85
# flake8: noqa from .short_term import * from .experience_replay import * __all__ = ( 'ExperienceReplayBuffer', 'MonteCarloCache', 'NStepCache', )
[ 2, 781, 539, 23, 25, 645, 20402, 198, 6738, 764, 19509, 62, 4354, 1330, 1635, 198, 6738, 764, 23100, 1240, 62, 260, 1759, 1330, 1635, 628, 198, 834, 439, 834, 796, 357, 198, 220, 220, 220, 705, 44901, 3041, 1759, 28632, 3256, 198, ...
2.476923
65
from django.db import models
[ 6738, 42625, 14208, 13, 9945, 1330, 4981, 628 ]
3.75
8
import csv from bs4 import BeautifulSoup from requests import get import lxml with open('in_book.csv', 'w') as myFile: writer = csv.writer(myFile, delimiter=";", quoting=csv.QUOTE_MINIMAL) writer.writerow(["NAME", "URL", "Author", "Price", "Number of Ratings", "Average Rating"]) for p...
[ 11748, 269, 21370, 198, 6738, 275, 82, 19, 1330, 23762, 50, 10486, 198, 6738, 7007, 1330, 651, 198, 11748, 300, 19875, 198, 198, 4480, 1280, 10786, 259, 62, 2070, 13, 40664, 3256, 705, 86, 11537, 355, 616, 8979, 25, 198, 220, 220, 2...
1.908438
1,114
from cyber_sdk.core.distribution import ( MsgSetWithdrawAddress, MsgWithdrawDelegationReward, MsgWithdrawValidatorCommission, )
[ 6738, 10075, 62, 21282, 74, 13, 7295, 13, 17080, 3890, 1330, 357, 198, 220, 220, 220, 6997, 70, 7248, 3152, 19334, 20231, 11, 198, 220, 220, 220, 6997, 70, 3152, 19334, 5005, 1455, 341, 48123, 11, 198, 220, 220, 220, 6997, 70, 3152,...
2.75
52
from output.models.nist_data.list_pkg.duration.schema_instance.nistschema_sv_iv_list_duration_max_length_4_xsd.nistschema_sv_iv_list_duration_max_length_4 import NistschemaSvIvListDurationMaxLength4 __all__ = [ "NistschemaSvIvListDurationMaxLength4", ]
[ 6738, 5072, 13, 27530, 13, 77, 396, 62, 7890, 13, 4868, 62, 35339, 13, 32257, 13, 15952, 2611, 62, 39098, 13, 77, 1023, 2395, 2611, 62, 21370, 62, 452, 62, 4868, 62, 32257, 62, 9806, 62, 13664, 62, 19, 62, 87, 21282, 13, 77, 102...
2.529412
102
#!/usr/bin/env python3 # MIT License. # Copyright (c) 2019 The SLANG Authors. """ A sample analysis unit. Every translation unit or program, has to be correctly converted into an equivalent analysis unit (a python module). Use this module as a target template. """ from typing import Dict import span.ir.types as ty...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 2, 17168, 13789, 13, 198, 2, 15069, 357, 66, 8, 13130, 383, 12419, 15567, 46665, 13, 198, 198, 37811, 198, 32, 6291, 3781, 4326, 13, 198, 198, 6109, 11059, 4326, 393, 1430, ...
2.561993
863
from PyQt5 import QtWidgets, QtCore, QtGui from card import Card, Ranks, Suits from enum import Enum from random import shuffle
[ 6738, 9485, 48, 83, 20, 1330, 33734, 54, 312, 11407, 11, 33734, 14055, 11, 33734, 8205, 72, 198, 6738, 2657, 1330, 5172, 11, 371, 2283, 11, 1778, 896, 198, 6738, 33829, 1330, 2039, 388, 198, 6738, 4738, 1330, 36273, 628, 198 ]
3.170732
41
from django.conf import settings from django.http import Http404, HttpResponse from rest_framework.views import APIView from rest_framework.response import Response from rest_framework.pagination import LimitOffsetPagination from rest_framework import status, generics from backend.hierarchy.models import Hierarchy fro...
[ 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 26429, 11, 367, 29281, 31077, 198, 6738, 1334, 62, 30604, 13, 33571, 1330, 3486, 3824, 769, 198, 6738, 1334, 62, 30604, 13, 26209, 1330, 182...
3.791667
144
from django.urls import include, path from . import views urlpatterns = [ path('', views.home, name='home'), path('page/<int:page>/', views.PostListView.as_view(), name='page'), path('post/<int:pk>/', views.PostView.as_view(), name='post'), path( 'search/', include([ path(...
[ 6738, 42625, 14208, 13, 6371, 82, 1330, 2291, 11, 3108, 198, 198, 6738, 764, 1330, 5009, 628, 198, 6371, 33279, 82, 796, 685, 198, 220, 220, 220, 3108, 10786, 3256, 5009, 13, 11195, 11, 1438, 11639, 11195, 33809, 198, 220, 220, 220, ...
2.196581
351
import tensorflow as tf from kerod.core.standard_fields import BoxField from kerod.utils.ops import get_full_indices from kerod.core.box_ops import convert_to_xyxy_coordinates def post_processing(boxes: tf.Tensor, logits: tf.Tensor, image_information: tf.Tensor, ...
[ 11748, 11192, 273, 11125, 355, 48700, 198, 6738, 41927, 375, 13, 7295, 13, 20307, 62, 25747, 1330, 8315, 15878, 198, 6738, 41927, 375, 13, 26791, 13, 2840, 1330, 651, 62, 12853, 62, 521, 1063, 198, 6738, 41927, 375, 13, 7295, 13, 3524...
2.689451
1,185
PY_WRAPPER = """ import dash import dash_bootstrap_components as dbc app = dash.Dash(external_stylesheets=[dbc.themes.BOOTSTRAP]) {snippet} app.layout = html.Div([{components}]) """ R_WRAPPER = """ library(dash) library(dashBootstrapComponents) library(dashHtmlComponents) app <- Dash$new(external_stylesheets = dbc...
[ 47, 56, 62, 18564, 2969, 18973, 796, 37227, 198, 11748, 14470, 198, 11748, 14470, 62, 18769, 26418, 62, 5589, 3906, 355, 288, 15630, 198, 198, 1324, 796, 14470, 13, 43041, 7, 22615, 62, 47720, 258, 1039, 41888, 9945, 66, 13, 1169, 688...
2.516
250
""" Module to provide tests related to the MD026 rule. """ from test.markdown_scanner import MarkdownScanner import pytest @pytest.mark.rules def test_md041_bad_configuration_level(): """ Test to make sure we get the expected behavior after scanning a good file from the test/resources/rules/md004 directo...
[ 37811, 198, 26796, 284, 2148, 5254, 3519, 284, 262, 10670, 45987, 3896, 13, 198, 37811, 198, 6738, 1332, 13, 4102, 2902, 62, 35836, 1008, 1330, 2940, 2902, 33351, 1008, 198, 198, 11748, 12972, 9288, 628, 198, 31, 9078, 9288, 13, 4102, ...
2.631616
7,066
#!/usr/bin/env python3 # native imports from asyncio.subprocess import DEVNULL import subprocess import argparse import re from os.path import exists # 3rd party imports from colorama import Fore, Back, Style from tabulate import tabulate # Bold table headers bolded_string_Task = "\033[1m" + "Task name" + "\033[0m" b...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 6868, 17944, 198, 6738, 30351, 952, 13, 7266, 14681, 1330, 5550, 53, 33991, 198, 11748, 850, 14681, 198, 11748, 1822, 29572, 198, 11748, 302, 198, 6738, 28686, 13, 6978, 1330, 7...
2.817715
40,519
"""Module for DataService SPARQL-queries.""" from string import Template def build_dataservices_by_publisher_query() -> str: """Build query to count dataservices grouped by publisher.""" return """ PREFIX dct: <http://purl.org/dc/terms/> PREFIX dcat: <http://www.w3.org/ns/dcat#> SELECT ?organizationNumber (CO...
[ 37811, 26796, 329, 6060, 16177, 6226, 1503, 9711, 12, 421, 10640, 526, 15931, 198, 6738, 4731, 1330, 37350, 628, 198, 4299, 1382, 62, 19608, 292, 712, 1063, 62, 1525, 62, 12984, 8191, 62, 22766, 3419, 4613, 965, 25, 198, 220, 220, 220...
2.630342
468
#!/usr/bin/env python3 import os import shutil import gzip import sys import re from itertools import groupby from collections import defaultdict from subprocess import Popen, call, PIPE from multiprocessing import Pool import timeit # set variables from snakemake params, wildcards, input and threads CHUNK = snakemak...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 11748, 28686, 198, 11748, 4423, 346, 198, 11748, 308, 13344, 198, 11748, 25064, 198, 11748, 302, 198, 6738, 340, 861, 10141, 1330, 1448, 1525, 198, 6738, 17268, 1330, 4277, 1160...
2.202088
2,395
from code import cancer import pylab as py from config import config XSIZE = config['XSIZE'] YSIZE = config['YSIZE'] config['first_cancer_cell_xoffset']=-1.0*config['XSIZE']/(3.0*config['basal_wavenumber']) config['pressure_filename']= 'pressure/bottom_basal_membrane_pressure.dat' config['cancer_evolution_filename']=...
[ 6738, 2438, 1330, 4890, 198, 11748, 279, 2645, 397, 355, 12972, 198, 198, 6738, 4566, 1330, 4566, 198, 198, 55, 33489, 796, 4566, 17816, 55, 33489, 20520, 198, 56, 33489, 796, 4566, 17816, 56, 33489, 20520, 198, 11250, 17816, 11085, 62,...
2.302703
370
#!/usr/bin/env python # -*- coding: utf-8 -*- # # By: Gianni Galbiati # Standard libraries from collections import OrderedDict # External libraries import torch.nn as nn # Internal libraries
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 198, 2, 2750, 25, 30851, 8461, 5027, 65, 5375, 72, 198, 198, 2, 8997, 12782, 198, 6738, 17268, 1330, 14230, 1068, ...
2.954545
66
#!/usr/bin/env python # -*- coding: utf-8 -*- # emacs: -*- mode: python; py-indent-offset: 4; indent-tabs-mode: nil -*- # vi: set ft=python sts=4 ts=4 sw=4 et: """ Handling connectivity ~~~~~~~~~~~~~~~~~~~~~ Combines FreeSurfer surfaces with subcortical volumes """ import os from glob import glob import json import n...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 795, 16436, 25, 532, 9, 12, 4235, 25, 21015, 26, 12972, 12, 521, 298, 12, 28968, 25, 604, 26, 33793, 12, 8658, ...
1.89665
4,925
#!/usr/bin/python # This script pulls the list of Mozilla trusted certificate authorities # from the web at the "mozurl" below, parses the file to grab the PEM # for each cert, and then generates DER files in a new ./data directory # Upload these to a SPIFFS filesystem and use the CertManager to parse # and use them f...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 198, 2, 770, 4226, 16194, 262, 1351, 286, 29258, 13467, 10703, 4773, 198, 2, 422, 262, 3992, 379, 262, 366, 5908, 89, 6371, 1, 2174, 11, 13544, 274, 262, 2393, 284, 5552, 262, 350, 3620, ...
2.640339
709
import os import datetime from django.core.exceptions import ValidationError from django.db import models from django.db.models.signals import post_delete from binder.models import BinderModel # From the api docs: a zoo with a name. It also has a founding date, # which is nullable (representing "unknown"). post_del...
[ 11748, 28686, 198, 11748, 4818, 8079, 198, 6738, 42625, 14208, 13, 7295, 13, 1069, 11755, 1330, 3254, 24765, 12331, 198, 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 6738, 42625, 14208, 13, 9945, 13, 27530, 13, 12683, 874, 1330, 1281, ...
3.442308
104
# # Copyright (c) Contributors to the Open 3D Engine Project. # For complete copyright and license terms please see the LICENSE at the root of this distribution. # # SPDX-License-Identifier: Apache-2.0 OR MIT # # import argparse import boto3 import logging import sys from botocore.config import Config log = logging.g...
[ 2, 198, 2, 15069, 357, 66, 8, 25767, 669, 284, 262, 4946, 513, 35, 7117, 4935, 13, 198, 2, 1114, 1844, 6634, 290, 5964, 2846, 3387, 766, 262, 38559, 24290, 379, 262, 6808, 286, 428, 6082, 13, 198, 2, 198, 2, 30628, 55, 12, 34156...
2.629796
2,450
# Copyright 2021 D-Wave Systems 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...
[ 2, 15069, 33448, 360, 12, 39709, 11998, 3457, 13, 198, 2, 198, 2, 220, 220, 220, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 220, 220, 220, 345, 743, 407, 779, 428, 2393, 2845, 287,...
3.383495
206
""" This script prints the current system date. """ import datetime print(datetime.date.today())
[ 37811, 198, 1212, 4226, 20842, 262, 1459, 1080, 3128, 13, 198, 37811, 198, 11748, 4818, 8079, 220, 198, 4798, 7, 19608, 8079, 13, 4475, 13, 40838, 28955 ]
3.592593
27
""" Code derived from WebHelpers: https://bitbucket.org/bbangert/webhelpers Licensed under the MIT license: https://bitbucket.org/bbangert/webhelpers/src/tip/LICENSE """ from markupsafe import escape_silent def format_attrs(**attrs): """Format HTML attributes into a string of ' key="value"' pairs which can ...
[ 37811, 198, 10669, 10944, 422, 5313, 12621, 19276, 25, 3740, 1378, 2545, 27041, 316, 13, 2398, 14, 11848, 648, 861, 14, 12384, 16794, 364, 198, 198, 26656, 15385, 739, 262, 17168, 5964, 25, 3740, 1378, 2545, 27041, 316, 13, 2398, 14, ...
2.572899
1,166
# This class describes a person agent class person(object): """An individual person"""
[ 2, 770, 1398, 8477, 257, 1048, 5797, 198, 198, 4871, 1048, 7, 15252, 2599, 198, 197, 37811, 2025, 1981, 1048, 37811, 198, 197, 197 ]
3.791667
24
from __future__ import unicode_literals import frappe from frappe import _ from frappe.integrations.utils import create_request_log,make_post_request from frappe.utils import get_datetime,now_datetime,format_datetime,format_date,format_time,getdate, duration_to_seconds,format_duration from datetime import timedelta imp...
[ 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, 11748, 5306, 27768, 198, 6738, 5306, 27768, 1330, 4808, 198, 6738, 5306, 27768, 13, 18908, 9143, 13, 26791, 1330, 2251, 62, 25927, 62, 6404, 11, 15883, 62, 7353, 62, 25927...
2.912664
229
import configparser import unittest import tmpbfextract #---------------------------- # Set to your cfg file cfg_file = 'src/local.cfg' #---------------------------- config = configparser.ConfigParser() config.read(cfg_file) if __name__ == '__main__': unittest.main()
[ 11748, 4566, 48610, 198, 11748, 555, 715, 395, 198, 198, 11748, 45218, 19881, 2302, 974, 198, 198, 2, 1783, 10541, 198, 2, 5345, 284, 534, 30218, 70, 2393, 198, 37581, 62, 7753, 796, 705, 10677, 14, 12001, 13, 37581, 6, 198, 2, 1783...
3.181818
88
from setuptools import setup with open("README.md", encoding="utf-8") as f: long_description = f.read() with open("requirements.txt") as f: required = f.read().splitlines() setup( name="AirBnbModel", version="1.0.0", packages=["AirBnbModel"], long_description=long_description, long_descri...
[ 6738, 900, 37623, 10141, 1330, 9058, 198, 198, 4480, 1280, 7203, 15675, 11682, 13, 9132, 1600, 21004, 2625, 40477, 12, 23, 4943, 355, 277, 25, 198, 220, 220, 220, 890, 62, 11213, 796, 277, 13, 961, 3419, 198, 198, 4480, 1280, 7203, ...
2.701389
144
from .equals_builder import * from .hash_code_builder import * from .helpers import *
[ 6738, 764, 4853, 874, 62, 38272, 1330, 1635, 198, 6738, 764, 17831, 62, 8189, 62, 38272, 1330, 1635, 198, 6738, 764, 16794, 364, 1330, 1635, 198 ]
3.307692
26
# Copyright (c) 2018 PaddlePaddle Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by app...
[ 2, 220, 220, 15069, 357, 66, 8, 2864, 350, 37382, 47, 37382, 46665, 13, 1439, 6923, 33876, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, ...
3.587719
228
from .classification.doc_classification import DocumentClassification from .classification.doc_classification import DocumentClassificationConfiguration from .classification.record_classification import RecordClassification from .classification.record_classification import RecordClassificationConfiguration from .classi...
[ 6738, 764, 4871, 2649, 13, 15390, 62, 4871, 2649, 1330, 16854, 9487, 2649, 198, 6738, 764, 4871, 2649, 13, 15390, 62, 4871, 2649, 1330, 16854, 9487, 2649, 38149, 198, 6738, 764, 4871, 2649, 13, 22105, 62, 4871, 2649, 1330, 13266, 9487, ...
4.320122
328
from django.views.generic import View from django.http import JsonResponse import json from . import models
[ 6738, 42625, 14208, 13, 33571, 13, 41357, 1330, 3582, 198, 6738, 42625, 14208, 13, 4023, 1330, 449, 1559, 31077, 198, 11748, 33918, 198, 6738, 764, 1330, 4981 ]
3.962963
27
import pygame import sys from pygame import draw, surfarray import numpy import random pygame.init() size = width,height = (1200,1200) actualRes = (100,100) screen = pygame.display.set_mode(size) scr = pygame.Surface(actualRes) balls = [] for b in range(5): balls.append(ball(random.randint(0,actualRe...
[ 11748, 12972, 6057, 201, 198, 11748, 25064, 201, 198, 6738, 12972, 6057, 1330, 3197, 11, 9053, 18747, 201, 198, 11748, 299, 32152, 201, 198, 11748, 4738, 201, 198, 9078, 6057, 13, 15003, 3419, 201, 198, 7857, 796, 9647, 11, 17015, 796, ...
2.009153
437
def pars_to_eq(pars, ip, lmodel='alpha', pmodel='quadratic', beta=0.0, n=101, ret='all', corr='cyl', d=0.01, a=0.52, Ra=1.50): """Input lambda model pars=parameters, ip=ip in A, lmodel=lambda-model type, ret=what to return, pmodel=pressure-model type, beta=beta_poloidal, and n=number of radial p...
[ 4299, 13544, 62, 1462, 62, 27363, 7, 79, 945, 11, 20966, 11, 198, 220, 220, 220, 300, 19849, 11639, 26591, 3256, 279, 19849, 11639, 421, 41909, 1512, 3256, 12159, 28, 15, 13, 15, 11, 299, 28, 8784, 11, 1005, 11639, 439, 3256, 198, ...
1.906772
17,012
import json import tensorflow as tf import numpy as np from tensorflow.keras.preprocessing.text import Tokenizer from tensorflow.keras.preprocessing.sequence import pad_sequences with open("AnQnA.json", 'r') as f: datastore = json.load(f) questions = [] intentions = [] for item in datastore: ...
[ 11748, 33918, 201, 198, 11748, 11192, 273, 11125, 355, 48700, 201, 198, 11748, 299, 32152, 355, 45941, 201, 198, 6738, 11192, 273, 11125, 13, 6122, 292, 13, 3866, 36948, 13, 5239, 1330, 29130, 7509, 201, 198, 6738, 11192, 273, 11125, 13...
2.373396
857
#!/usr/bin/env python # -*- coding:utf-8 -*- # @FileName : confusion_matrix.py # @Time : 2020/10/2 15:29 # @Author : 陈嘉昕 # @Demand : 混淆矩阵 import build_network from sklearn.metrics import confusion_matrix import itertools import numpy as np import matplotlib.pyplot as plt
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 40477, 12, 23, 532, 9, 12, 198, 2, 2488, 8979, 5376, 220, 1058, 10802, 62, 6759, 8609, 13, 9078, 198, 2, 2488, 7575, 220, 220, 220, 220, 220, 1058, 1213...
2.212121
132
from scipy.spatial import ConvexHull, Delaunay import numpy as np
[ 6738, 629, 541, 88, 13, 2777, 34961, 1330, 1482, 303, 87, 39, 724, 11, 4216, 1942, 323, 198, 11748, 299, 32152, 355, 45941, 628 ]
2.791667
24
import onnx from ksc.parse_ks import parse_ks_file from ksc.typeannot import typeannot_decls import onnx2ks
[ 11748, 319, 77, 87, 198, 198, 6738, 479, 1416, 13, 29572, 62, 591, 1330, 21136, 62, 591, 62, 7753, 198, 6738, 479, 1416, 13, 4906, 34574, 1330, 2099, 34574, 62, 32446, 82, 198, 11748, 319, 77, 87, 17, 591, 628, 198 ]
2.707317
41
# # Jason Zheng (jzzheng) # 10/23/19 # import argparse import numpy as np import sys import os import pandas as pd import plotly.graph_objects as go from plotly.offline import plot import plotly.graph_objs as go AIRSIM_DATASET = 'datasets/airsim/depth_data.csv' # this only contains one time frame CARLA_DATASET = 'da...
[ 2, 198, 2, 8982, 44583, 357, 73, 3019, 31753, 8, 198, 2, 838, 14, 1954, 14, 1129, 198, 2, 198, 198, 11748, 1822, 29572, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 25064, 198, 11748, 28686, 198, 11748, 19798, 292, 355, 279, 67, ...
2.339952
2,065
import face_recognition import cv2 import data import requests
[ 11748, 1986, 62, 26243, 653, 198, 11748, 269, 85, 17, 198, 11748, 1366, 198, 11748, 7007, 198 ]
3.705882
17
#!/usr/bin/env python3 # Space Invadersishkebab. from trabant import * # ASCII geometries. shipascii = r''' /\ /XXXXXXXX\ v v ''' invader = r''' /XXXXXX\ /XXXXXXXX\ XXXXXXXXXX XX XX XX \XXXXXXXX/ /XX XX\ /X/ \/ \X\ X/ \X ''' cam(distance=250) gravity((0,0,0)) ship = create_ascii_object(...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 4687, 41671, 680, 365, 65, 397, 13, 198, 198, 6738, 491, 397, 415, 1330, 1635, 198, 198, 2, 37101, 4903, 908, 1678, 13, 198, 6720, 292, 979, 72, 796, 374, 7061, 6, 198, 22...
2.090287
731
import os import copy from typing import Callable, Sequence, List import torch import numpy as np from loguru import logger from nndet.planning.estimator import MemoryEstimator, MemoryEstimatorDetection from nndet.planning.architecture.boxes.base import BoxC001 from nndet.planning.architecture.boxes.utils import ( ...
[ 11748, 28686, 198, 11748, 4866, 198, 6738, 19720, 1330, 4889, 540, 11, 45835, 11, 7343, 198, 198, 11748, 28034, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 2604, 14717, 1330, 49706, 198, 198, 6738, 299, 358, 316, 13, 11578, 768, 13, ...
2.703125
192
from flask import request from flask_jwt_extended import current_user as user from flask_jwt_extended import jwt_required from flask.views import MethodView from jamaah.utils.wrapper import requires_groups from jamaah.provider.user_provider import UsersProvider
[ 6738, 42903, 1330, 2581, 198, 6738, 42903, 62, 73, 46569, 62, 2302, 1631, 1330, 1459, 62, 7220, 355, 2836, 198, 6738, 42903, 62, 73, 46569, 62, 2302, 1631, 1330, 474, 46569, 62, 35827, 198, 6738, 42903, 13, 33571, 1330, 11789, 7680, 1...
3.635135
74
import os import time from typing import Any, Tuple import pytest from autouri.abspath import AbsPath from autouri.autouri import AutoURI, URIBase from autouri.httpurl import ReadOnlyStorageError from .files import ( common_paths, make_files_in_dir, recurse_raise_if_uri_not_exist, v6_txt_contents, ) ...
[ 11748, 28686, 198, 11748, 640, 198, 6738, 19720, 1330, 4377, 11, 309, 29291, 198, 198, 11748, 12972, 9288, 198, 198, 6738, 1960, 10300, 13, 397, 2777, 776, 1330, 13051, 15235, 198, 6738, 1960, 10300, 13, 2306, 10300, 1330, 11160, 47269, ...
2.40332
4,639
from lightdict import WordDict, HanziDict hanzi_dic = HanziDict(r'D:\Data\NLP\corpus\words\hanzi.csv', keep=False) word_dict = WordDict(r'D:\Data\NLP\corpus\words\words.csv', keep=False) with hanzi_dic: print('和' in hanzi_dic) with word_dict: print('开云见日' in word_dict)
[ 6738, 1657, 11600, 1330, 9678, 35, 713, 11, 9530, 17027, 35, 713, 198, 198, 7637, 17027, 62, 67, 291, 796, 9530, 17027, 35, 713, 7, 81, 6, 35, 7479, 6601, 59, 45, 19930, 59, 10215, 79, 385, 59, 10879, 59, 7637, 17027, 13, 40664, ...
2.028777
139
import os from tests import SputrTest start_dir = os.path.join(os.path.dirname(__file__), 'fixtures', 'discover')
[ 11748, 28686, 198, 6738, 5254, 1330, 1338, 315, 81, 14402, 198, 198, 9688, 62, 15908, 796, 28686, 13, 6978, 13, 22179, 7, 418, 13, 6978, 13, 15908, 3672, 7, 834, 7753, 834, 828, 705, 69, 25506, 3256, 705, 67, 29392, 11537, 628 ]
2.761905
42
from colab.plugins.views import ColabProxyView from django.contrib.staticfiles.views import serve from django.http import HttpResponse from revproxy.transformer import DiazoTransformer import os
[ 6738, 951, 397, 13, 37390, 13, 33571, 1330, 1623, 397, 44148, 7680, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 12708, 16624, 13, 33571, 1330, 4691, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 198, 6738, 2710, 36436, 13,...
3.769231
52
from django.urls import path from django.conf import settings from django.conf.urls.static import static from . import views urlpatterns = [ path('', views.home, name='earlydating-home'), path('about/', views.about, name='earlydating-about'), path('login/', views.login_page, name='earlydating-login'), ...
[ 6738, 42625, 14208, 13, 6371, 82, 1330, 3108, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, 10414, 13, 6371, 82, 13, 12708, 1330, 9037, 198, 6738, 764, 1330, 5009, 628, 198, 6371, 33279, 82, 796, 685, 19...
2.967552
339
from setuptools import setup setup( name='azure_jwt_validation', version='0.1', description='Helper to validate jwt tokens signed by Azure AD.', url='https://github.com/JonnyWaffles/azure_jwt_validation', author='Jonny Fuller', author_email='jfuller@markelcorp.com', packages=[ 'azu...
[ 6738, 900, 37623, 10141, 1330, 9058, 628, 198, 40406, 7, 198, 220, 220, 220, 1438, 11639, 1031, 495, 62, 73, 46569, 62, 12102, 341, 3256, 198, 220, 220, 220, 2196, 11639, 15, 13, 16, 3256, 198, 220, 220, 220, 6764, 11639, 47429, 284...
2.254098
244
import os, yaml from pathlib import Path from click.testing import CliRunner from luna.radiology.cli.window_volume import cli import medpy.io import numpy as np
[ 11748, 28686, 11, 331, 43695, 198, 6738, 3108, 8019, 1330, 10644, 198, 6738, 3904, 13, 33407, 1330, 1012, 72, 49493, 198, 198, 6738, 300, 9613, 13, 6335, 12371, 13, 44506, 13, 17497, 62, 29048, 1330, 537, 72, 220, 198, 198, 11748, 111...
3.173077
52
# -*- coding: utf-8 -*- DEBUG = False HOST = '0.0.0.0' BME280_ADDRESS = 0x77 ILLUMINANCE_SENSOR_ADDRESS = 0x39 # 0x29 for TSL2561 BME280_MODE = 'normal' BME280_FILTER = 16 BME280_HUMIDITY_OVERSAMPLING = 1 BME280_PRESSURE_OVERSAMPLING = 16 BME280_TEMPERATURE_OVERSAMPLING = 2 BME280_INACTIVE_DURATION = 1000 ILLUMINAN...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 628, 198, 30531, 796, 10352, 198, 39, 10892, 796, 705, 15, 13, 15, 13, 15, 13, 15, 6, 198, 33, 11682, 21033, 62, 2885, 7707, 7597, 796, 657, 87, 3324, 198, 8267, 5883, ...
2.011765
170
import time import sys import functools import numpy as np from pvtrace import * world = Node( name="world (air)", geometry=Sphere( radius=10.0, material=Material(refractive_index=1.0), ), ) sphere = Node( name="sphere (glass)", geometry=Sphere( radius=1.0, material...
[ 11748, 640, 198, 11748, 25064, 198, 11748, 1257, 310, 10141, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 279, 85, 40546, 1330, 1635, 198, 198, 6894, 796, 19081, 7, 198, 220, 220, 220, 1438, 2625, 6894, 357, 958, 42501, 198, 220, 22...
2.396896
451
#!/usr/bin/env python # -*- coding: utf-8 -*- from setuptools import setup, find_packages with open('README.md', encoding='utf-8') as f: long_description = f.read() with open('requirements.txt', 'r') as f: requirements = f.read() setup( name='bcf', packages=find_packages(), version='@@VERSION@@'...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 6738, 900, 37623, 10141, 1330, 9058, 11, 1064, 62, 43789, 198, 198, 4480, 1280, 10786, 15675, 11682, 13, 9132, 325...
2.483607
488
from architectures import DENOISERS_ARCHITECTURES, get_architecture, IMAGENET_CLASSIFIERS, AUTOENCODER_ARCHITECTURES from datasets import get_dataset, DATASETS from torch.nn import MSELoss, CrossEntropyLoss from torch.optim import SGD, Optimizer, Adam from torch.optim.lr_scheduler import StepLR, MultiStepLR from torch....
[ 6738, 45619, 1330, 37692, 46, 1797, 4877, 62, 31315, 2043, 9782, 29514, 11, 651, 62, 998, 5712, 495, 11, 8959, 4760, 1677, 2767, 62, 31631, 5064, 40, 4877, 11, 47044, 46, 24181, 3727, 1137, 62, 31315, 2043, 9782, 29514, 198, 6738, 405...
2.010576
29,690
from typing import List from libra_client.canoser import Struct, Uint64, BoolT, StrT, RustEnum, Uint8, Uint16 from libra_client.lbrtypes.account_state import AccountState from libra_client.lbrtypes.bytecode import get_code_type, CodeType from libra_client.canoser import RustOptional
[ 6738, 19720, 1330, 7343, 198, 6738, 9195, 430, 62, 16366, 13, 5171, 13416, 1330, 32112, 11, 471, 600, 2414, 11, 347, 970, 51, 11, 4285, 51, 11, 17103, 4834, 388, 11, 471, 600, 23, 11, 471, 600, 1433, 198, 6738, 9195, 430, 62, 1636...
3.105263
95
# Copyright 2017 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. """URL endpoint to add new histograms to the datastore.""" import json import sys # TODO(eakuefner): Move these helpers so we don't have to import add_poin...
[ 2, 15069, 2177, 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, 198, 198, 37811...
2.739741
1,852
# list(map(int, input().split())) # int(input()) if __name__ == '__main__': X, K, D = list(map(int, input().split())) main(X, K, D)
[ 2, 1351, 7, 8899, 7, 600, 11, 5128, 22446, 35312, 3419, 4008, 198, 2, 493, 7, 15414, 28955, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 1395, 11, 509, 11, 360, 796, 1351, 7, 8899, 7, 6...
2.203125
64
import numpy as np from functools import reduce from collections import Counter from itertools import combinations import threading import os import copy import logging import math logging.basicConfig(format='%(levelname)s:%(message)s', level=logging.DEBUG) class Origami: """ """ def _matrix_details(s...
[ 11748, 299, 32152, 355, 45941, 198, 6738, 1257, 310, 10141, 1330, 4646, 198, 6738, 17268, 1330, 15034, 198, 6738, 340, 861, 10141, 1330, 17790, 198, 11748, 4704, 278, 198, 11748, 28686, 198, 11748, 4866, 198, 11748, 18931, 198, 11748, 106...
2.232546
7,448
""" Contents: make_votable_given_source_ids given_votable_get_df given_source_ids_get_gaia_data query_neighborhood given_dr2_sourceids_get_edr3_xmatch edr3_propermotion_to_ICRF parallax_to_distance_highsn """ ########### # imports # ########### import os import numpy as np, matplotlib.py...
[ 37811, 198, 15842, 25, 628, 220, 220, 220, 787, 62, 85, 313, 540, 62, 35569, 62, 10459, 62, 2340, 198, 220, 220, 220, 1813, 62, 85, 313, 540, 62, 1136, 62, 7568, 628, 220, 220, 220, 1813, 62, 10459, 62, 2340, 62, 1136, 62, 4908,...
2.013699
8,760
from shopkit.cart import signals
[ 6738, 6128, 15813, 13, 26674, 1330, 10425, 628, 198 ]
3.888889
9
from pathlib import Path from typing import Any, Dict, List, Tuple, Union import pandas as pd import pdfplumber as pdf from pdfplumber.page import Page from settings.conf import assets_cols, liabilities_cols, loss_cols, profit_cols from utils import amounts_to_int, get_date, is_digit, list_to_df assets_liabs_idxs = [...
[ 6738, 3108, 8019, 1330, 10644, 198, 6738, 19720, 1330, 4377, 11, 360, 713, 11, 7343, 11, 309, 29291, 11, 4479, 198, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 37124, 489, 4494, 355, 37124, 198, 6738, 37124, 489, 4494, 13, 7700,...
1.970149
1,541
"""Add metadata to media. Revision ID: c434a5920104 Revises: 02bc5fd54e77 Create Date: 2016-03-25 11:14:59.791090 """ # revision identifiers, used by Alembic. revision = 'c434a5920104' down_revision = '02bc5fd54e77' branch_labels = None depends_on = None from alembic import op import sqlalchemy as sa
[ 37811, 4550, 20150, 284, 2056, 13, 198, 198, 18009, 1166, 4522, 25, 269, 47101, 64, 3270, 1264, 3023, 198, 18009, 2696, 25, 7816, 15630, 20, 16344, 4051, 68, 3324, 198, 16447, 7536, 25, 1584, 12, 3070, 12, 1495, 1367, 25, 1415, 25, ...
2.545455
121
import dash_core_components print(dash_core_components.__version__)
[ 11748, 14470, 62, 7295, 62, 5589, 3906, 198, 4798, 7, 42460, 62, 7295, 62, 5589, 3906, 13, 834, 9641, 834, 8 ]
3.190476
21
import math #pythagorean theorem #a**2+b**2=c**2 main()
[ 11748, 10688, 198, 2, 79, 5272, 363, 29456, 44728, 220, 198, 2, 64, 1174, 17, 10, 65, 1174, 17, 28, 66, 1174, 17, 628, 198, 12417, 3419, 628, 628, 628, 198 ]
2.096774
31
# # Copyright (c) 2019, NVIDIA CORPORATION. All rights reserved. # # NVIDIA CORPORATION and its licensors retain all intellectual property # and proprietary rights in and to this software, related documentation # and any modifications thereto. Any use, reproduction, disclosure or # distribution of this software and r...
[ 2, 198, 2, 15069, 357, 66, 8, 13130, 11, 15127, 23929, 44680, 6234, 13, 220, 1439, 2489, 10395, 13, 198, 2, 198, 2, 15127, 23929, 44680, 6234, 290, 663, 8240, 669, 12377, 477, 9028, 3119, 198, 2, 290, 20622, 2489, 287, 290, 284, 4...
2.20796
1,005
# Copyright (C) 2016 Universidad Politecnica de Madrid # # 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 la...
[ 2, 15069, 357, 34, 8, 1584, 26986, 32482, 2165, 578, 31522, 3970, 390, 14708, 198, 2, 198, 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, 1...
3.664336
286
import random print('-=' * 15) print(' VAMOS JOGAR PAR OU ÍMPAR?!') print('-=' * 15) lista = range(1, 11) computador = random.choice(lista) result = '' x = '' cont = 0 while x == result: v = int(input('Digite um valor: ')) x = str(input('Par ou Ímpar? [P/I] ')).upper().strip() soma = v + computador if ...
[ 11748, 4738, 198, 4798, 10786, 12, 11639, 1635, 1315, 8, 198, 4798, 10786, 220, 569, 2390, 2640, 449, 7730, 1503, 29463, 47070, 6184, 235, 7378, 1503, 12248, 11537, 198, 4798, 10786, 12, 11639, 1635, 1315, 8, 198, 4868, 64, 796, 2837, ...
2.123116
398
import os import requests from fbmq import Template """ Returns a Template.List which is essentially just a wrapper for a python list of Template.Elements. The list is the 'elements' field of the payload paramter (which is a dictionary) """ def offcampus_dining_request_msg( result, latitude=40.806209,...
[ 11748, 28686, 198, 11748, 7007, 198, 6738, 277, 20475, 80, 1330, 37350, 198, 198, 37811, 198, 35561, 257, 37350, 13, 8053, 543, 318, 6986, 655, 257, 29908, 329, 257, 220, 198, 29412, 1351, 286, 37350, 13, 36, 3639, 13, 198, 464, 1351,...
3.097561
287
import json import ast import hashlib def team_setup_convert(): """ Update the game data from plaintext format to JSON format """ print("This module converts the old team plaintext data to JSON data") teamname = input("Team name: ") # Name of the text file where the team data will be saved. input...
[ 11748, 33918, 198, 11748, 6468, 198, 11748, 12234, 8019, 628, 198, 4299, 1074, 62, 40406, 62, 1102, 1851, 33529, 198, 220, 220, 220, 37227, 10133, 262, 983, 1366, 422, 8631, 5239, 5794, 284, 19449, 5794, 37227, 628, 220, 220, 220, 3601,...
2.211018
1,071
""" Dev HTTP server serving static files using asyncio. Highlights: - Allows to drop ".html" in URLs - which corresponds to nginx `try_files $uri $uri.html $uri/index.html =404;` - Can inject live-reload JS to HTML. Mostly stolen from picoweb -- web pico-framework for Pycopy 2019 MIT """ from __future__ import an...
[ 37811, 198, 13603, 14626, 4382, 7351, 9037, 3696, 1262, 30351, 952, 13, 198, 198, 11922, 8091, 25, 198, 12, 40402, 284, 4268, 27071, 6494, 1, 287, 32336, 198, 220, 220, 220, 532, 543, 24866, 284, 299, 42822, 4600, 28311, 62, 16624, 72...
2.501275
1,961
# # This file is part of pyasn1-modules software. # # Created by Russ Housley with assistance from asn1ate v.0.6.0. # # Copyright (c) 2019, Vigil Security, LLC # License: http://snmplabs.com/pyasn1/license.html # # TEST Company Classification Policies # # ASN.1 source from: # https://www.rfc-editor.org/rfc/r...
[ 2, 201, 198, 2, 770, 2393, 318, 636, 286, 12972, 292, 77, 16, 12, 18170, 3788, 13, 201, 198, 2, 201, 198, 2, 15622, 416, 1887, 367, 516, 1636, 351, 6829, 422, 355, 77, 16, 378, 410, 13, 15, 13, 21, 13, 15, 13, 201, 198, 2, ...
2.473888
517
#!/usr/local/bin/python3 # Get data from database # Yang Xu # 2/22/2017 import MySQLdb import csv import sys import string # get db connection ## # select Switchboard entropy data ## # select Switchboard text from db ## # Select BNC entropy data # The `entropy_DEM100` table contains 2398 rows where `topicID` and `...
[ 2, 48443, 14629, 14, 12001, 14, 8800, 14, 29412, 18, 198, 2, 3497, 1366, 422, 6831, 198, 2, 10998, 33591, 198, 2, 362, 14, 1828, 14, 5539, 198, 198, 11748, 33476, 9945, 198, 11748, 269, 21370, 198, 11748, 25064, 198, 11748, 4731, 19...
3.088889
360
#!/usr/bin/python # -*- coding: utf-8 -*- import numpy as np import pandas as pd import quantipy as qp from quantipy.core.tools.dp.io import ( read_quantipy as r_quantipy, read_dimensions as r_dimensions, read_decipher as r_decipher, read_spss as r_spss, read_ascribe as r_ascribe, read_confirmi...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 5554, 541, 88, 355, 10662, 79, 198, 198, 67...
2.116171
119,780
#-------------------------------------------------------------- # # PyGUI - NumPy interface - Cocoa # #-------------------------------------------------------------- from AppKit import NSBitmapImageRep, \ NSAlphaNonpremultipliedBitmapFormat, NSCalibratedRGBColorSpace from GUI import Image # HACK! PyObjC 2.3 incorr...
[ 2, 47232, 26171, 198, 2, 198, 2, 220, 220, 9485, 40156, 532, 31835, 20519, 7071, 532, 18490, 12162, 198, 2, 198, 2, 47232, 26171, 198, 198, 6738, 2034, 20827, 1330, 10896, 13128, 8899, 5159, 6207, 11, 3467, 198, 197, 8035, 38077, 1541...
2.982609
690
#!/usr/bin/env python3 import unittest import main as hashtag_generator if __name__ == '__main__': unittest.main()
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 11748, 555, 715, 395, 198, 11748, 1388, 355, 23950, 62, 8612, 1352, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 555, 715, 395, 13, 124...
2.652174
46
from qgis.gui import QgsMapToolPan from GMapCanvas import GMapCanvas
[ 6738, 10662, 70, 271, 13, 48317, 1330, 1195, 14542, 13912, 25391, 15730, 198, 198, 6738, 6951, 499, 6090, 11017, 1330, 6951, 499, 6090, 11017, 628 ]
2.84
25
# -*- coding: utf-8 -*- import nova.conf from nova import config from nova import utils utils.period_heartbeat_file.func_defaults CONF = nova.conf.CONF argv = [] default_config_files = ['/etc/ironic-nova-compute/ironic-nova-compute.conf'] config.parse_args(argv, default_config_files=default_config_files) utils.period...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 11748, 645, 6862, 13, 10414, 198, 6738, 645, 6862, 1330, 4566, 198, 6738, 645, 6862, 1330, 3384, 4487, 198, 198, 26791, 13, 41007, 62, 11499, 12945, 62, 7753, 13, ...
2.666667
156
"""Implements the core parts of flow graph creation, in tandem with rpython.flowspace.objspace. """ import sys import collections from rpython.tool.error import source_lines from rpython.tool.stdlib_opcode import host_bytecode_spec from rpython.flowspace.argument import ArgumentsForTranslation from rpython.flowspace....
[ 37811, 3546, 1154, 902, 262, 4755, 3354, 286, 5202, 4823, 6282, 11, 287, 32969, 198, 4480, 374, 29412, 13, 44041, 10223, 13, 26801, 13200, 13, 198, 37811, 198, 198, 11748, 25064, 198, 11748, 17268, 198, 198, 6738, 374, 29412, 13, 25981,...
2.506161
2,029
"""Test module import""" def tests_init(): """Test __version__ presence and format""" from pytest import raises from collections import namedtuple import sys sys_version_info = sys.version_info version_info = namedtuple( "Version_Info", ["major", "minor", "micro", "releaselevel", "ser...
[ 37811, 14402, 8265, 1330, 37811, 628, 198, 4299, 5254, 62, 15003, 33529, 198, 220, 220, 220, 37227, 14402, 11593, 9641, 834, 4931, 290, 5794, 37811, 198, 220, 220, 220, 422, 12972, 9288, 1330, 12073, 198, 220, 220, 220, 422, 17268, 1330...
2.661728
405
import sys if __name__ == '__main__': fname = sys.argv[1] interpreter = BrainFuck(fname) interpreter.run()
[ 11748, 25064, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 277, 3672, 796, 25064, 13, 853, 85, 58, 16, 60, 198, 220, 220, 220, 28846, 796, 14842, 34094, 7, 69, 3672, 8, 198, 220, 220, 220...
2.44898
49
import pickle #date = '22-02-08 1051' file = f'results/kilonova_uvboostmodel_shockdata_0h_delay/40Mpc_no_opticalband_NUV_Dband_parameters' with open(file,'rb') as data: information=pickle.load(data)
[ 11748, 2298, 293, 198, 198, 2, 4475, 796, 705, 1828, 12, 2999, 12, 2919, 838, 4349, 6, 198, 198, 7753, 796, 277, 821, 82, 8376, 14, 74, 33576, 10071, 62, 14795, 39521, 19849, 62, 39563, 7890, 62, 15, 71, 62, 40850, 14, 1821, 44, ...
2.367816
87
#!/usr/bin/python # # Copyright 2020 Google 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 required b...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 2, 198, 2, 15069, 12131, 3012, 3457, 13, 1439, 6923, 33876, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407,...
2.847195
1,034
# -*- coding: utf-8 -*- from django.core.cache import cache # Time to live for cache entry 10 minutes, so it gets cleaned if we don't catch # something - don't make higher; groups may be problematic because of no signals # when adding / removing from group TTL = 600 permission_cache_keys = [] all_keys = [] get_c...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 42625, 14208, 13, 7295, 13, 23870, 1330, 12940, 198, 198, 2, 3862, 284, 2107, 329, 12940, 5726, 838, 2431, 11, 523, 340, 3011, 20750, 611, 356, 836, 470, 4929, 2...
2.795402
435
#!/usr/bin/env python3 ############################################## # # # Ferdinand 0.40, Ian Thompson, LLNL # # # # gnd,endf,fresco,azure,hyrma # # # ##############...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 29113, 7804, 4242, 2235, 198, 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, 220, 220, 220, 2...
2.056106
303
from dataclasses import dataclass, field from typing import Optional @dataclass class BaseType: """ :ivar a: :ivar b: :ivar c: :ivar d: :ivar e: :ivar f: :ivar g: :ivar x: """ a: Optional[int] = field( default=None, metadata=dict( type="Attribute...
[ 6738, 4818, 330, 28958, 1330, 4818, 330, 31172, 11, 2214, 198, 6738, 19720, 1330, 32233, 628, 198, 31, 19608, 330, 31172, 198, 4871, 31783, 25, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 1058, 452, 283, 257, 25, 198, 220, 220, 2...
1.767584
1,308
#!/usr/bin/env python import unittest import serial import datetime import re import time
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 11748, 555, 715, 395, 198, 11748, 11389, 198, 11748, 4818, 8079, 198, 11748, 302, 198, 11748, 640, 198 ]
3.333333
27
import subprocess import boto3 # GitHub tokens and http request authentication. ENV_VARS = subprocess.check_output("printenv", shell=True).decode().split("\n") # Finds all GitHub tokens stored as environment variables. # GitHub token variables must be prefixed with 'GITHUB_TOKEN' # (e.g. export GITHUB_TOKEN1="...") ...
[ 11748, 850, 14681, 198, 11748, 275, 2069, 18, 628, 198, 2, 21722, 16326, 290, 2638, 2581, 18239, 13, 198, 1677, 53, 62, 53, 27415, 796, 850, 14681, 13, 9122, 62, 22915, 7203, 4798, 24330, 1600, 7582, 28, 17821, 737, 12501, 1098, 22446...
2.534483
406
"""Testing file for volume.py.""" # Authors: Afshine Amidi <lastname@mit.edu> # Shervine Amidi <firstname@stanford.edu> # MIT License from typing import Text import unittest import numpy as np from enzynet import volume from parameterized import parameterized _N_DIMENSIONS = 3 if __name__ == '__main_...
[ 37811, 44154, 2393, 329, 6115, 13, 9078, 526, 15931, 198, 198, 2, 46665, 25, 2483, 19489, 1703, 19830, 1279, 12957, 3672, 31, 2781, 13, 15532, 29, 198, 2, 220, 220, 220, 220, 220, 220, 220, 220, 220, 6528, 26818, 1703, 19830, 1279, ...
2.774194
124
from app import db, bcrypt from sqlalchemy.dialects.postgresql import JSON from passlib.hash import pbkdf2_sha256 as sha256
[ 6738, 598, 1330, 20613, 11, 275, 29609, 201, 198, 6738, 44161, 282, 26599, 13, 38969, 478, 82, 13, 7353, 34239, 13976, 1330, 19449, 201, 198, 6738, 1208, 8019, 13, 17831, 1330, 279, 65, 74, 7568, 17, 62, 26270, 11645, 355, 427, 64, ...
2.54717
53
# TODO Documentation from __future__ import absolute_import import wx from . import GDSLogEventPanelGUI from fprime_gds.common.data_types.event_data import EventData from fprime_gds.common.utils.event_severity import EventSeverity from fprime_gds.common.utils.config_manager import ConfigManager ######################...
[ 2, 16926, 46, 43925, 198, 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 198, 198, 11748, 266, 87, 198, 6738, 764, 1330, 402, 5258, 11187, 9237, 26639, 40156, 198, 6738, 277, 35505, 62, 70, 9310, 13, 11321, 13, 7890, 62, 19199, 13, ...
2.292157
6,541
from psecas.grids.grid import Grid class FourierGrid(Grid): """ This grid uses the Fourier grid on z ∈ [zmin, zmax] to dicretize the system. The grid is periodic. N: The number of grid points zmin: The z value at the lower boundary zmax: The z value at the upper boundary Optional: z:...
[ 6738, 279, 2363, 292, 13, 2164, 2340, 13, 25928, 1330, 24846, 628, 198, 4871, 34296, 5277, 41339, 7, 41339, 2599, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 770, 10706, 3544, 262, 34296, 5277, 10706, 319, 1976, 18872, 230, 685, 89...
1.947896
998
tweets = ["https://twitter.com/GateOfHeavens/status/246739124193751041", "https://twitter.com/abigailb/status/360482662491754496", "https://twitter.com/suleimenov/status/366952592200314880" ]
[ 83, 732, 1039, 796, 14631, 5450, 1378, 6956, 13, 785, 14, 22628, 5189, 1544, 4005, 82, 14, 13376, 14, 1731, 3134, 2670, 17464, 1129, 22318, 940, 3901, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 366, 5450, 1378, 6956, 13...
2.156863
102
INVALID_AMOUNT = -2 INVALID_ACTION = -4 TRANSACTION_NOT_FOUND = -6 ORDER_NOT_FOUND = -5 PREPARE = '0' COMPLETE = '1' A_LACK_OF_MONEY = '-5017' A_LACK_OF_MONEY_CODE = -9 AUTHORIZATION_FAIL = 'AUTHORIZATION_FAIL' AUTHORIZATION_FAIL_CODE = -1 ORDER_FOUND = True
[ 1268, 23428, 2389, 62, 2390, 28270, 796, 532, 17, 198, 1268, 23428, 2389, 62, 44710, 796, 532, 19, 198, 5446, 15037, 44710, 62, 11929, 62, 37, 15919, 796, 532, 21, 198, 12532, 1137, 62, 11929, 62, 37, 15919, 796, 532, 20, 198, 47, ...
1.962121
132
import dash import yaml import os import setup from dash import dash_table from dash import dcc from dash import html from pandas import Timestamp as ts from dash.dependencies import Input, Output from datetime import timedelta import plotly.express as px import pandas as pd import plotly.graph_objects as go from plotl...
[ 11748, 14470, 198, 11748, 331, 43695, 198, 11748, 28686, 198, 11748, 9058, 198, 6738, 14470, 1330, 14470, 62, 11487, 198, 6738, 14470, 1330, 288, 535, 198, 6738, 14470, 1330, 27711, 198, 6738, 19798, 292, 1330, 5045, 27823, 355, 40379, 19...
2.427755
1,924
test = { 'name': 'Question no_girls', 'points': 10, 'suites': [ { 'cases': [ { 'code': r""" >>> # You need to set the value for 'p_3_of_5' >>> 'p_3_of_5' in vars() True """, 'hidden': False, 'locked': False }, ...
[ 9288, 796, 1391, 198, 220, 705, 3672, 10354, 705, 24361, 645, 62, 36960, 3256, 198, 220, 705, 13033, 10354, 838, 11, 198, 220, 705, 2385, 2737, 10354, 685, 198, 220, 220, 220, 1391, 198, 220, 220, 220, 220, 220, 705, 33964, 10354, 6...
1.71567
619
""" The real newline and carriage return characters in these strings will be replaced by the reverse_rep_ch. Keep in mind that messages in this format are for DEBUG PURPOSES ONLY. """ DATA = ''' MSH|^~\&|1100|BN|OPTX|BN002234|201210180743||ORU^R01|0417|P|2.3<CR> PID|1|123456789|112233|1234567|Test^Patient||19820620|F|...
[ 37811, 198, 464, 1103, 649, 1370, 290, 25739, 1441, 3435, 287, 777, 13042, 481, 307, 6928, 416, 262, 198, 50188, 62, 7856, 62, 354, 13, 220, 9175, 287, 2000, 326, 6218, 287, 428, 5794, 389, 329, 16959, 33079, 37997, 1546, 22224, 13, ...
2.061166
703