content
stringlengths
1
1.04M
input_ids
listlengths
1
774k
ratio_char_token
float64
0.38
22.9
token_count
int64
1
774k
""" Tombstone stream. """ from typing import Union from eventstore_grpc.proto import streams_pb2, streams_pb2_grpc, shared_pb2 from eventstore_grpc import constants def tombstone_stream( stub: streams_pb2_grpc.StreamsStub, stream: str, expected_version: Union[int, str], **kwargs, ): """Tombstone....
[ 37811, 198, 51, 2381, 6440, 4269, 13, 198, 37811, 198, 198, 6738, 19720, 1330, 4479, 198, 6738, 1785, 8095, 62, 2164, 14751, 13, 1676, 1462, 1330, 15190, 62, 40842, 17, 11, 15190, 62, 40842, 17, 62, 2164, 14751, 11, 4888, 62, 40842, ...
2.648318
327
from django.apps import AppConfig
[ 6738, 42625, 14208, 13, 18211, 1330, 2034, 16934, 628 ]
3.888889
9
# Predicting the orbit trajectory # Function created to plot the output # Build model # Instantiate a Sequential model model = Sequential() # Add a Dense layer with 50 neurons and an input of 1 neuron model.add(Dense(50, input_shape=(1,), activation='relu')) # Add two Dense layers with 50 neurons and relu activatio...
[ 2, 49461, 278, 262, 13066, 22942, 198, 198, 2, 15553, 2727, 284, 7110, 262, 5072, 198, 198, 2, 10934, 2746, 198, 2, 24470, 9386, 257, 24604, 1843, 2746, 198, 19849, 796, 24604, 1843, 3419, 198, 198, 2, 3060, 257, 360, 1072, 7679, 35...
3.369305
417
# Copyright 2016 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 or at # https://developers.google.com/open-source/licenses/bsd """Business objects for the Monorail issue tracker. These are classes and functions that opera...
[ 2, 15069, 1584, 383, 18255, 1505, 46665, 13, 1439, 2489, 10395, 13, 198, 2, 5765, 286, 428, 2723, 2438, 318, 21825, 416, 257, 347, 10305, 12, 7635, 198, 2, 5964, 326, 460, 307, 1043, 287, 262, 38559, 24290, 2393, 393, 379, 198, 2, ...
2.748121
23,015
""" Copyright 2017 JetBrains, s.r.o 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 ...
[ 37811, 198, 220, 220, 15069, 2177, 19013, 9414, 1299, 11, 264, 13, 81, 13, 78, 628, 220, 220, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 220, 220, 345, 743, 407, 779, 428, 2393, 2845, ...
2.78
900
import numpy as np from .unit import Unit class WordExactMatch(Unit): """ WordExactUnit Class. Process unit to get a binary match list of two word index lists. The word index list is the word representation of a text. Examples: >>> import pandas >>> input_ = pandas.DataFrame({ ...
[ 11748, 299, 32152, 355, 45941, 198, 198, 6738, 764, 20850, 1330, 11801, 628, 198, 4871, 9678, 3109, 529, 23850, 7, 26453, 2599, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 9678, 3109, 529, 26453, 5016, 13, 628, 220, 220, 220, 10854...
2.091916
903
import pickle from pathlib import Path import click from click import ClickException from omigami.authentication import encrypt_credentials from omigami.omi_settings import get_credentials_path, get_credentials_folder_path @click.command() @click.option("--username", help="Your Omigami.com username") @click.option(...
[ 11748, 2298, 293, 198, 6738, 3108, 8019, 1330, 10644, 198, 198, 11748, 3904, 198, 6738, 3904, 1330, 6914, 16922, 198, 198, 6738, 39030, 328, 6277, 13, 41299, 3299, 1330, 34117, 62, 66, 445, 14817, 198, 6738, 39030, 328, 6277, 13, 12753,...
2.867925
477
import moeda moeda.limpar() v = float(input('Digite um valor: R$ ')) print(f'Aumentando 10% temos: {moeda.aumentar(v, 10, True)}') print(f'Diminuindo 20% temos: {moeda.diminuir(v, 20, True)}') print(f'O dobro é {moeda.dobro(v, True)}') print(f'A metade é {moeda.metade(v, True)}')
[ 11748, 6941, 18082, 198, 5908, 18082, 13, 2475, 1845, 3419, 198, 198, 85, 796, 12178, 7, 15414, 10786, 19511, 578, 23781, 1188, 273, 25, 371, 3, 705, 4008, 198, 198, 4798, 7, 69, 6, 32, 1713, 25440, 838, 4, 2169, 418, 25, 1391, 59...
2.143939
132
import tensorflow as tf import tensorflow_datasets as tfds from tensorflow import keras from keras_cv_attention_models.imagenet.data import init_mean_std_by_rescale_mode, random_crop_fraction COCO_LABELS = """person, bicycle, car, motorcycle, airplane, bus, train, truck, boat, traffic light, fire hydrant, stop sign, ...
[ 11748, 11192, 273, 11125, 355, 48700, 198, 11748, 11192, 273, 11125, 62, 19608, 292, 1039, 355, 48700, 9310, 198, 6738, 11192, 273, 11125, 1330, 41927, 292, 198, 6738, 41927, 292, 62, 33967, 62, 1078, 1463, 62, 27530, 13, 320, 11286, 31...
2.424748
2,279
# Generated by Django 3.0.3 on 2021-03-22 08:32 from django.db import migrations, models import django.utils.timezone
[ 2, 2980, 515, 416, 37770, 513, 13, 15, 13, 18, 319, 33448, 12, 3070, 12, 1828, 8487, 25, 2624, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 198, 11748, 42625, 14208, 13, 26791, 13, 2435, 11340, 628 ]
2.926829
41
#!/usr/bin/env python3 """ This example shows usage of ImageManip to crop a rotated rectangle area on a frame, or perform various image transforms: rotate, mirror, flip, perspective transform. """ import depthai as dai import cv2 import numpy as np keyRotateDecr = 'z' keyRotateIncr = 'x' keyResizeInc = 'v' keyWarpTe...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 37811, 198, 1212, 1672, 2523, 8748, 286, 7412, 5124, 541, 284, 13833, 257, 38375, 35991, 1989, 319, 257, 5739, 11, 198, 273, 1620, 2972, 2939, 31408, 25, 23064, 11, 10162, 11,...
2.025216
2,895
# Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. import json import azure.functions as func
[ 2, 15069, 357, 66, 8, 5413, 10501, 13, 1439, 2489, 10395, 13, 198, 2, 49962, 739, 262, 17168, 13789, 13, 198, 11748, 33918, 198, 11748, 35560, 495, 13, 12543, 2733, 355, 25439, 628 ]
4.181818
33
from functools import partial from lazy import lazy from ploy.common import BaseMaster, BaseInstance from ploy.common import SSHKeyFingerprint from ploy.common import SSHKeyFingerprintAsk from ploy.common import SSHKeyFingerprintIgnore from ploy.common import SSHKeyFingerprintInstance from ploy.common import SSHKeyInfo...
[ 6738, 1257, 310, 10141, 1330, 13027, 198, 6738, 16931, 1330, 16931, 198, 6738, 46945, 13, 11321, 1330, 7308, 18254, 11, 7308, 33384, 198, 6738, 46945, 13, 11321, 1330, 33825, 9218, 37, 3889, 4798, 198, 6738, 46945, 13, 11321, 1330, 33825,...
3.565934
182
# -*- coding: utf-8 -*- """ Contains functions to find the time-zero and to interpolate the data. """ import numpy as np import skultrafast.dv as dv import scipy.ndimage as nd import matplotlib.pyplot as plt #from skultrafast.fitter import _coh_gaussian from scipy.linalg import lstsq from scipy.optimize import least_...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 4264, 1299, 5499, 284, 1064, 262, 640, 12, 22570, 290, 284, 39555, 378, 262, 1366, 13, 198, 37811, 198, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 1341,...
1.891068
2,295
####################################################################### # Tests for cmpdirs.py ####################################################################### import unittest import os import tempfile import shutil from bcftbx.Md5sum import Md5Checker from bcftbx.test.mock_data import TestUtils,ExampleDirLangu...
[ 29113, 29113, 4242, 21017, 198, 2, 30307, 329, 269, 3149, 15908, 82, 13, 9078, 198, 29113, 29113, 4242, 21017, 198, 198, 11748, 555, 715, 395, 198, 11748, 28686, 198, 11748, 20218, 7753, 198, 11748, 4423, 346, 198, 6738, 47125, 701, 65,...
3.81982
111
from rubicon.repository.utils.slugify import slugify __all__ = ["slugify"]
[ 6738, 6437, 4749, 13, 260, 1930, 37765, 13, 26791, 13, 6649, 1018, 1958, 1330, 31065, 1958, 198, 198, 834, 439, 834, 796, 14631, 6649, 1018, 1958, 8973, 198 ]
2.714286
28
#!/bin/python import sys, numpy, os.path, re import argparse from Bio import SeqIO if __name__ == '__main__': parser = argparse.ArgumentParser() parser.add_argument('-l', '--library_file', help="File containing the library report generated by the script prepare_libraries.py") parser.add_argument('-p', '--p...
[ 2, 48443, 8800, 14, 29412, 198, 11748, 25064, 11, 299, 32152, 11, 28686, 13, 6978, 11, 302, 198, 11748, 1822, 29572, 198, 6738, 16024, 1330, 1001, 80, 9399, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220,...
3.116343
361
# -*- coding: utf-8 -*- # @Author: amaneureka # @Date: 2017-03-30 13:53:13 # @Last Modified by: amaneureka # @Last Modified time: 2017-03-30 22:10:02 from dateutil import parser from .. import app @app.template_filter('strftime')
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 2488, 13838, 25, 716, 1531, 495, 4914, 198, 2, 2488, 10430, 25, 220, 220, 2177, 12, 3070, 12, 1270, 1511, 25, 4310, 25, 1485, 198, 2, 2488, 5956, 40499, 416, 25, ...
2.510638
94
import argparse if __name__ == "__main__": myCli = EnjCLI() myvars = myCli.create_parser() print(myvars)
[ 11748, 1822, 29572, 198, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 616, 2601, 72, 796, 2039, 73, 5097, 40, 3419, 198, 220, 220, 220, 616, 85, 945, 796, 616, 2601, 72, 13, 17953, 62, 48610, 3...
2.166667
54
from unittest import TestCase from unittest.mock import patch with patch('serial.Serial'): from controls.valloxcontrol import ValloxControl from valloxserial import vallox_serial
[ 6738, 555, 715, 395, 1330, 6208, 20448, 198, 6738, 555, 715, 395, 13, 76, 735, 1330, 8529, 198, 4480, 8529, 10786, 46911, 13, 32634, 6, 2599, 198, 220, 220, 220, 422, 6973, 13, 85, 439, 1140, 13716, 1330, 46929, 1140, 15988, 198, 67...
3.407407
54
""" Simple lock interface. """ import os import time from dataclasses import dataclass from pathlib import Path from fasteners import InterProcessLock from dataladmetadatamodel.log import logger PID = os.getpid() GIT_MAPPER_LOCK_FILE_NAME = "metadata-model-git.lock" read_write_locked = dict() @dataclass
[ 37811, 198, 26437, 5793, 7071, 13, 198, 37811, 198, 11748, 28686, 198, 11748, 640, 198, 6738, 4818, 330, 28958, 1330, 4818, 330, 31172, 198, 6738, 3108, 8019, 1330, 10644, 198, 198, 6738, 3049, 36014, 1330, 4225, 18709, 25392, 198, 198, ...
3.009524
105
import argparse import sys import csv import os import numpy as np import matplotlib.pyplot as plt import tensorflow as tf BATCH = 1 NUM_GENES = 4 N1 = 91 EXPLICIT_NOISE_LEVEL = 0.05 FLAGS = None if __name__ == "__main__": parser = argparse.ArgumentParser() parser.add_argument('--output_name', type=int, default...
[ 11748, 1822, 29572, 198, 11748, 25064, 198, 11748, 269, 21370, 198, 11748, 28686, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 11748, 11192, 273, 11125, 355, 48700, 628, 198, 33, ...
2.60119
168
#!/usr/bin/python # -*- coding: utf-8 -*- from tkinter import Tk, Text, BOTH, DISABLED, NORMAL, END APPNAME = "WRITER TEST" WELCOME_MSG = "Welcome to {}\n".format(APPNAME) ui = UI()
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 6738, 256, 74, 3849, 1330, 309, 74, 11, 8255, 11, 347, 26946, 11, 13954, 6242, 30465, 11, 25273, 42126, 11, 23578, 198,...
2.190476
84
# This file is generated by objective.metadata # # Last update: Mon Mar 16 08:52:15 2020 # # flake8: noqa import objc, sys if sys.maxsize > 2 ** 32: else: misc = {} misc.update( { "CFXMLEntityInfo": objc.createStructType( "CFXMLEntityInfo", sel32or64( b"{_CFXMLE...
[ 2, 770, 2393, 318, 7560, 416, 9432, 13, 38993, 198, 2, 198, 2, 4586, 4296, 25, 2892, 1526, 1467, 8487, 25, 4309, 25, 1314, 12131, 198, 2, 198, 2, 781, 539, 23, 25, 645, 20402, 198, 198, 11748, 26181, 66, 11, 25064, 198, 198, 361...
1.897908
94,366
import argparse import xml.etree.ElementTree as ET import requests import numpy from progress.bar import Bar bar = Bar('Sending', max=4000) try : dictdata = numpy.load("stockDictionary.npy",allow_pickle=True) except : if args.downloadStock or args.syncDictionary : pass else: print("Try ...
[ 11748, 1822, 29572, 220, 198, 11748, 35555, 13, 316, 631, 13, 20180, 27660, 355, 12152, 198, 11748, 7007, 198, 11748, 299, 32152, 220, 198, 6738, 4371, 13, 5657, 1330, 2409, 198, 198, 5657, 796, 2409, 10786, 50, 1571, 3256, 3509, 28, ...
2.502183
229
import json import docker from django.conf import settings
[ 11748, 33918, 198, 11748, 36253, 198, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 628, 198 ]
3.875
16
"""empty message Revision ID: 3acf60608a7d Revises: 48a5caa0a762 Create Date: 2015-03-26 11:26:40.461247 """ # revision identifiers, used by Alembic. revision = '3acf60608a7d' down_revision = '48a5caa0a762' from alembic import op import sqlalchemy as sa
[ 37811, 28920, 3275, 198, 198, 18009, 1166, 4522, 25, 513, 330, 69, 1899, 28688, 64, 22, 67, 198, 18009, 2696, 25, 4764, 64, 20, 6888, 64, 15, 64, 48194, 198, 16447, 7536, 25, 1853, 12, 3070, 12, 2075, 1367, 25, 2075, 25, 1821, 13,...
2.385321
109
#!/usr/bin/env python3 # Copyright 2018 EMBL - European Bioinformatics Institute # # 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 require...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 2, 15069, 2864, 17228, 9148, 532, 3427, 16024, 259, 18982, 873, 5136, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 19...
3.445531
716
from datetime import datetime, timedelta from fastapi import HTTPException from typing import Optional from fastapi.security import OAuth2PasswordBearer from fastapi import Depends from jose import JWTError, jwt from sqlalchemy.orm import Session from database import get_db from repository.user import User as ModelU...
[ 198, 6738, 4818, 8079, 1330, 4818, 8079, 11, 28805, 12514, 198, 6738, 3049, 15042, 1330, 14626, 16922, 198, 6738, 19720, 1330, 32233, 198, 6738, 3049, 15042, 13, 12961, 1330, 440, 30515, 17, 35215, 3856, 11258, 198, 198, 6738, 3049, 15042...
2.805263
190
from scrapy import Selector
[ 6738, 15881, 88, 1330, 9683, 273, 628 ]
4.142857
7
import discord from discord.ext import commands, tasks class History(commands.Cog): """History commands."""
[ 11748, 36446, 198, 6738, 36446, 13, 2302, 1330, 9729, 11, 8861, 198, 198, 4871, 7443, 7, 9503, 1746, 13, 34, 519, 2599, 198, 220, 220, 220, 37227, 18122, 9729, 526, 15931 ]
3.612903
31
import numpy as np import random from torch.utils.data.dataset import Dataset def cross_entropy(input, target, size_average=True): """ Cross entropy that accepts soft targets Args: pred: predictions for neural network targets: targets, can be soft size_average: if false, sum is retu...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 4738, 198, 6738, 28034, 13, 26791, 13, 7890, 13, 19608, 292, 316, 1330, 16092, 292, 316, 628, 198, 4299, 3272, 62, 298, 28338, 7, 15414, 11, 2496, 11, 2546, 62, 23913, 28, 17821, 2599, 198, ...
2.371429
385
#Author: Zifan Wang | frank@zifan.wang import re import urllib.request import collections import time from textblob import TextBlob if __name__ == '__main__': print("Please input key words: ", end='') key_words = input().strip().replace(" ", "+") print("Please input result number limit: ", end='') l...
[ 2, 13838, 25, 1168, 361, 272, 15233, 930, 14346, 31, 89, 361, 272, 13, 47562, 198, 198, 11748, 302, 198, 11748, 2956, 297, 571, 13, 25927, 198, 11748, 17268, 198, 11748, 640, 198, 6738, 2420, 2436, 672, 1330, 8255, 3629, 672, 198, 1...
2.040895
4,695
import numpy as np import net.utilities
[ 11748, 299, 32152, 355, 45941, 198, 11748, 2010, 13, 315, 2410, 628 ]
3.416667
12
from insta.forms import CommentForm, ImageForm, ProfileForm, SignupForm from django.shortcuts import render,redirect # Create your views here. from django.http import HttpResponse from django.contrib.auth import login, authenticate from django.contrib.sites.shortcuts import get_current_site from django.utils.encoding...
[ 6738, 916, 64, 13, 23914, 1330, 18957, 8479, 11, 7412, 8479, 11, 13118, 8479, 11, 5865, 929, 8479, 198, 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 11, 445, 1060, 198, 198, 2, 13610, 534, 5009, 994, 13, 198, 6738, 42625, 14208, ...
2.778431
510
# -*- coding: utf-8 -*- ############################################################################### """ This file is a part of the VeRyPy classical vehicle routing problem heuristic library and implements intra route (i.e. within one route) local search improvement heuristics such as 2-opt, one-point-move etc. All...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 29113, 29113, 7804, 4242, 21017, 198, 37811, 770, 2393, 318, 257, 636, 286, 262, 8016, 46987, 20519, 15993, 4038, 28166, 1917, 198, 258, 27915, 5888, 290, 23986, 23422, 63...
1.727668
8,049
import logging from pbase.papp import TRAIN_TAG, VALID_TAG, TEST_TAG from pbase.papp.logger import Logger
[ 11748, 18931, 198, 198, 6738, 279, 8692, 13, 79, 1324, 1330, 29125, 1268, 62, 42197, 11, 26173, 2389, 62, 42197, 11, 43001, 62, 42197, 198, 6738, 279, 8692, 13, 79, 1324, 13, 6404, 1362, 1330, 5972, 1362, 198 ]
2.815789
38
#!/usr/bin/env python3.8 # -*- coding: utf-8 -*- """ **Created:** ??.??.2022 **Modified:** ??.??.2022 **Authors:** [Tobias Rosskopf](mailto:tobirosskopf@gmail.com) <module_name>'s docstring """ class ClassName: """ Class for <ClassName> """ def __init__(self, name: str = "") -> None: ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 13, 23, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 37811, 198, 1174, 41972, 25, 1174, 220, 220, 220, 19153, 13, 3548, 13, 1238, 1828, 198, 1174, 5841, ...
2.120482
581
import numpy as np from shfl.federated_aggregator.fedavg_aggregator import FedAvgAggregator
[ 11748, 299, 32152, 355, 45941, 198, 198, 6738, 427, 2704, 13, 69, 5702, 515, 62, 9460, 2301, 1352, 13, 19082, 615, 70, 62, 9460, 2301, 1352, 1330, 10169, 48997, 46384, 2301, 1352, 628 ]
2.848485
33
from scipy.sparse import load_npz from scipy.spatial import distance from joblib import Parallel from joblib import delayed def chunks(lst, n): """ Yield successive n-sized chunks from lst. from: https://stackoverflow.com/questions/312443/how-do-you-split-a-list-into-evenly-sized-chunks """ f...
[ 198, 6738, 629, 541, 88, 13, 82, 29572, 1330, 3440, 62, 37659, 89, 198, 6738, 629, 541, 88, 13, 2777, 34961, 1330, 5253, 198, 6738, 1693, 8019, 1330, 42945, 198, 6738, 1693, 8019, 1330, 11038, 628, 198, 4299, 22716, 7, 75, 301, 11, ...
2.049713
523
import csv import numpy as np import os import re import scipy.stats import sys import time # Given a regular expression, list the files that match it, and ask for user input # Given a regular expression, list the directories that match it, and ask for user input # List the files with a regular expression # Change...
[ 11748, 269, 21370, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 28686, 198, 11748, 302, 198, 11748, 629, 541, 88, 13, 34242, 198, 11748, 25064, 198, 11748, 640, 198, 198, 2, 11259, 257, 3218, 5408, 11, 1351, 262, 3696, 326, 2872, 3...
3.009763
717
import threading import time from datetime import datetime class StartOverException(Exception): """Raise to restart the reminder thread loop""" pass # TODO set a limit on reminders per user? also same for offlinemessages
[ 11748, 4704, 278, 198, 11748, 640, 198, 6738, 4818, 8079, 1330, 4818, 8079, 628, 198, 4871, 7253, 5886, 16922, 7, 16922, 2599, 198, 220, 220, 220, 37227, 21762, 786, 284, 15765, 262, 15438, 4704, 9052, 37811, 198, 220, 220, 220, 1208, ...
3.698413
63
from flask.views import MethodView from flask import jsonify, request, abort, redirect, url_for from impi.get_impi import * import logging import json
[ 6738, 42903, 13, 33571, 1330, 11789, 7680, 198, 6738, 42903, 1330, 33918, 1958, 11, 2581, 11, 15614, 11, 18941, 11, 19016, 62, 1640, 198, 6738, 848, 72, 13, 1136, 62, 11011, 72, 1330, 1635, 198, 11748, 18931, 198, 11748, 33918, 198 ]
3.682927
41
import os from threading import Condition from typing import Any, List, Optional, Tuple from socketio import Client, ClientNamespace from .common.configuration import configure from .comparator import JsonDataComparator from .interaction import Interaction, InteractionLoader from .runner import FailedInteraction, Sce...
[ 11748, 28686, 198, 6738, 4704, 278, 1330, 24295, 198, 6738, 19720, 1330, 4377, 11, 7343, 11, 32233, 11, 309, 29291, 198, 198, 6738, 17802, 952, 1330, 20985, 11, 20985, 36690, 10223, 198, 198, 6738, 764, 11321, 13, 11250, 3924, 1330, 174...
2.91954
261
# -*- coding: utf-8 -*- import numpy as np np.set_printoptions(precision=3, linewidth=256) from dyconnmap.ts import fdr, surrogate_analysis if __name__ == "__main__": rng = np.random.RandomState(0) data = np.load( "/home/makism/Github/dyconnmap/examples/data/eeg_32chans_10secs.npy") ts1 = data[...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 11748, 299, 32152, 355, 45941, 198, 37659, 13, 2617, 62, 4798, 25811, 7, 3866, 16005, 28, 18, 11, 9493, 413, 5649, 28, 11645, 8, 198, 198, 6738, 20268, 37043, 889...
2.07781
347
import setuptools setuptools.setup( name="xgbatch", version="0.0.2", author="Eric Henry", description="High Performance Serving for XGBoost", url="https://github.com/ehenry2/xgbatch", packages=["xgbatch"], classifiers=[ "Programming Language :: Python :: 3", "License :: OSI...
[ 11748, 900, 37623, 10141, 628, 198, 2617, 37623, 10141, 13, 40406, 7, 198, 220, 220, 220, 1438, 2625, 87, 22296, 963, 1600, 198, 220, 220, 220, 2196, 2625, 15, 13, 15, 13, 17, 1600, 198, 220, 220, 220, 1772, 2625, 25004, 8616, 1600,...
2.149254
268
# -*- coding: utf-8 -*- # Generated by Django 1.10.2 on 2016-11-26 10:54 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 2980, 515, 416, 37770, 352, 13, 940, 13, 17, 319, 1584, 12, 1157, 12, 2075, 838, 25, 4051, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, 1...
2.73913
69
from eth_account.signers.local import LocalAccount from web3.middleware import construct_sign_and_send_raw_middleware from flashbots import flashbot from flashbots.types import SignTx from eth_account.account import Account from web3 import Web3, HTTPProvider from web3.types import TxParams, Wei import os """ In thi...
[ 6738, 4555, 62, 23317, 13, 12683, 364, 13, 12001, 1330, 10714, 30116, 198, 6738, 3992, 18, 13, 27171, 1574, 1330, 5678, 62, 12683, 62, 392, 62, 21280, 62, 1831, 62, 27171, 1574, 198, 198, 6738, 7644, 42478, 1330, 7644, 13645, 198, 673...
2.557166
1,242
import cv2 as cv #hsv 调试 ## 调用次方法,传入文件路径 if __name__ == '__main__': ##使用: h=Hsv_change() h.inRange_byFilePath("chest/stage.jpg")
[ 11748, 269, 85, 17, 355, 269, 85, 198, 220, 220, 220, 1303, 11994, 85, 5525, 108, 225, 46237, 243, 198, 220, 198, 220, 198, 220, 220, 220, 22492, 5525, 108, 225, 18796, 101, 162, 105, 94, 43095, 37345, 243, 11, 27670, 254, 17739, ...
1.4375
112
# -*- coding: utf-8 -*- """ @author: Ondrej Dyck """ from __future__ import division, print_function, absolute_import, unicode_literals import numpy as np from scipy.optimize import least_squares import itertools as itt import multiprocessing as mp import time as tm import matplotlib.pyplot as plt from ....
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 201, 198, 37811, 201, 198, 31, 9800, 25, 440, 358, 260, 73, 23524, 694, 201, 198, 37811, 201, 198, 201, 198, 6738, 11593, 37443, 834, 1330, 7297, 11, 3601, 62, 8818, 11, ...
2.06013
10,494
import string import unittest from collections import Counter from main import extract_characters, generate_password if __name__ == '__main__': unittest.main()
[ 11748, 4731, 198, 11748, 555, 715, 395, 198, 6738, 17268, 1330, 15034, 198, 6738, 1388, 1330, 7925, 62, 10641, 19858, 11, 7716, 62, 28712, 628, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 555, 71...
3.586957
46
import asyncio import os import sys from datetime import datetime, timedelta import aiohttp import pytest from bungieapi.base import Token from bungieapi.client import Client, Credentials from bungieapi.forge import forge @pytest.fixture @pytest.fixture @pytest.fixture @pytest.fixture @pytest.fixture @pyt...
[ 11748, 30351, 952, 198, 11748, 28686, 198, 11748, 25064, 198, 6738, 4818, 8079, 1330, 4818, 8079, 11, 28805, 12514, 198, 198, 11748, 257, 952, 4023, 198, 11748, 12972, 9288, 198, 198, 6738, 43974, 494, 15042, 13, 8692, 1330, 29130, 198, ...
2.752874
174
#! /usr/bin/env python """Parse event definitions out of comments in source files.""" import re import sys import os import string import getopt import glob import fileinput import pprint if __name__ == '__main__': sys.exit(main())
[ 2, 0, 1220, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 37811, 10044, 325, 1785, 17336, 503, 286, 3651, 287, 2723, 3696, 526, 15931, 198, 198, 11748, 302, 198, 11748, 25064, 198, 11748, 28686, 198, 11748, 4731, 198, 11748, 651, 8738, ...
3.186667
75
#code based on example found at: #http://www.pyimagesearch.com/2015/09/14/ball-tracking-with-opencv/ # import the necessary packages from collections import deque import numpy as np import argparse import imutils import cv2 import time as t # construct the argument parse and parse the arguments ap = argparse.ArgumentP...
[ 2, 8189, 1912, 319, 1672, 1043, 379, 25, 198, 2, 4023, 1378, 2503, 13, 9078, 17566, 3679, 13, 785, 14, 4626, 14, 2931, 14, 1415, 14, 1894, 12, 36280, 12, 4480, 12, 9654, 33967, 14, 198, 2, 1330, 262, 3306, 10392, 198, 6738, 17268,...
2.499409
1,692
import io import requests import os from .input_file import InputFile from .exception import AppwriteException
[ 11748, 33245, 198, 11748, 7007, 198, 11748, 28686, 198, 6738, 764, 15414, 62, 7753, 1330, 23412, 8979, 198, 6738, 764, 1069, 4516, 1330, 2034, 13564, 16922, 628 ]
4.148148
27
import click import requests import yaml from dtool_lookup_server.utils import ( iter_datasets_in_base_uri, generate_dataset_info, ) def get_projects(fpath): """Return projects dictionary.""" with open(fpath) as fh: projects = yaml.load(fh, Loader=yaml.FullLoader) return projects def ge...
[ 11748, 3904, 198, 11748, 7007, 198, 11748, 331, 43695, 198, 198, 6738, 288, 25981, 62, 5460, 929, 62, 15388, 13, 26791, 1330, 357, 198, 220, 220, 220, 11629, 62, 19608, 292, 1039, 62, 259, 62, 8692, 62, 9900, 11, 198, 220, 220, 220,...
2.48913
2,024
# Filename: test_ch.py # pylint: disable=locally-disabled,C0111,R0904,C0301,C0103,W0212 from km3pipe.testing import TestCase, patch, Mock from km3pipe.io.ch import CHPump __author__ = "Tamas Gal" __copyright__ = "Copyright 2018, Tamas Gal and the KM3NeT collaboration." __credits__ = [] __license__ = "MIT" __maintainer...
[ 2, 7066, 12453, 25, 1332, 62, 354, 13, 9078, 198, 2, 279, 2645, 600, 25, 15560, 28, 17946, 453, 12, 47730, 11, 34, 486, 1157, 11, 49, 2931, 3023, 11, 34, 3070, 486, 11, 34, 486, 3070, 11, 54, 2999, 1065, 198, 6738, 10571, 18, ...
2.609272
151
#!/usr/bin/env python # coding: utf-8 import rospy from traj_generator import TrajectoryGenerator from controller import Controller if __name__ == '__main__': # 1. Create new node rospy.init_node("main_node") rate = rospy.Rate(5) # controller freq in Hz # init our trajectory generator and co...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 19617, 25, 3384, 69, 12, 23, 198, 11748, 686, 2777, 88, 198, 198, 6738, 1291, 73, 62, 8612, 1352, 1330, 4759, 752, 652, 8645, 1352, 198, 6738, 10444, 1330, 22741, 628, 198, 361, ...
2.21174
477
from django.test import TestCase from qatrack.qa import utils #============================================================================ #----------------------------------------------------------------------
[ 6738, 42625, 14208, 13, 9288, 1330, 6208, 20448, 198, 198, 6738, 10662, 265, 39638, 13, 20402, 1330, 3384, 4487, 198, 198, 2, 23926, 25609, 628, 198, 220, 220, 220, 1303, 10097, 23031, 198 ]
6.666667
33
import json # import json module # with statement with open('./data/spider/train_raw.json') as json_file: json_data = json.load(json_file) type(json_data) re_data = [] for idx, row in enumerate(json_data): bb = {} for i in ['db_id', 'query', 'question']: bb[i] = row[i] re_data.append(bb) ...
[ 198, 198, 11748, 33918, 1303, 1330, 33918, 8265, 198, 198, 2, 351, 2643, 198, 4480, 1280, 7, 4458, 14, 7890, 14, 2777, 1304, 14, 27432, 62, 1831, 13, 17752, 11537, 355, 33918, 62, 7753, 25, 198, 220, 220, 220, 33918, 62, 7890, 796, ...
2.339408
439
# Example of Dynamic Programming for the fibonacci sequence. Extracted from https://www.youtube.com/watch?v=vYquumk4nWw # A naive recursive solution # A memoized solution # A bottom-up solution
[ 2, 17934, 286, 26977, 30297, 329, 262, 12900, 261, 44456, 8379, 13, 5683, 20216, 422, 3740, 1378, 2503, 13, 11604, 13, 785, 14, 8340, 30, 85, 28, 85, 56, 421, 388, 74, 19, 77, 54, 86, 198, 198, 2, 317, 24354, 45115, 4610, 628, 1...
3.413793
58
import sys import xml.etree.ElementTree as ET LINE_THRESHOLD = 10 TEXT_MATCHES = [".//HedLine_hl1/*/*", ".//Content/*/*"] TEXT_NODES = ['W','Q'] if __name__ == "__main__": main(sys.argv)
[ 11748, 25064, 198, 11748, 35555, 13, 316, 631, 13, 20180, 27660, 355, 12152, 198, 198, 24027, 62, 4221, 19535, 39, 15173, 796, 838, 198, 32541, 62, 44, 11417, 1546, 796, 685, 1911, 1003, 39, 276, 13949, 62, 18519, 16, 15211, 15211, 16...
2.180851
94
from software_defined_assets.spark_weather_assets import spark_weather_assets from dagster import materialize from dagster.core.test_utils import instance_for_test
[ 6738, 3788, 62, 23211, 62, 19668, 13, 2777, 668, 62, 23563, 62, 19668, 1330, 9009, 62, 23563, 62, 19668, 198, 198, 6738, 48924, 1706, 1330, 2587, 1096, 198, 6738, 48924, 1706, 13, 7295, 13, 9288, 62, 26791, 1330, 4554, 62, 1640, 62, ...
3.772727
44
# Copyright (c) 2011-2016 Rackspace US, 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 ...
[ 2, 15069, 357, 66, 8, 2813, 12, 5304, 37927, 13200, 1294, 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, 407, 779, 428, 2393, 2845, 287, 11846, ...
2.841693
1,276
import pandas as pd from pandas import DataFrame import matplotlib.pyplot as plt from mpl_toolkits.mplot3d import Axes3D df = pd.read_csv('Lite_Coin_12_Mos.csv') print(df.head()) print(df.tail()) print(df.index) print(df.columns) print("-----") print(df.describe()) #print mediuan print('median') print(df.median()...
[ 11748, 19798, 292, 355, 279, 67, 198, 6738, 19798, 292, 1330, 6060, 19778, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 6738, 285, 489, 62, 25981, 74, 896, 13, 76, 29487, 18, 67, 1330, 12176, 274, 18, 35, 198, ...
2.700297
337
#!/usr/bin/python3 # -*- coding: utf-8 -*- # Name: CodyCloud Ngrok Server # Author: Icy(enderman1024@foxmail.com) # OS: Linux import time, socket, threading, os, sys, json if __name__ == "__main__": main()
[ 2, 48443, 14629, 14, 8800, 14, 29412, 18, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 6530, 25, 27035, 18839, 399, 27333, 74, 9652, 198, 2, 6434, 25, 314, 948, 7, 2194, 805, 35500, 31, 12792, 4529, 13,...
2.363636
110
# Test osqp python module import osqp from osqp import constant, default_algebra # import osqppurepy as osqp import numpy as np from scipy import sparse # Unit Test import unittest import pytest import numpy.testing as nptest
[ 2, 6208, 28686, 80, 79, 21015, 8265, 198, 11748, 28686, 80, 79, 198, 6738, 28686, 80, 79, 1330, 6937, 11, 4277, 62, 282, 29230, 198, 2, 1330, 28686, 80, 381, 495, 9078, 355, 28686, 80, 79, 198, 11748, 299, 32152, 355, 45941, 198, ...
3.081081
74
from __future__ import annotations import base64 import base58 # type: ignore from neo3 import vm, contracts from neo3.contracts.interop import register @register("System.Binary.Serialize", 1 << 12, contracts.CallFlags.NONE) @register("System.Binary.Deserialize", 1 << 14, contracts.CallFlags.NONE) @register("Sys...
[ 6738, 11593, 37443, 834, 1330, 37647, 198, 11748, 2779, 2414, 198, 11748, 2779, 3365, 220, 1303, 2099, 25, 8856, 198, 6738, 19102, 18, 1330, 45887, 11, 8592, 198, 6738, 19102, 18, 13, 28484, 82, 13, 3849, 404, 1330, 7881, 628, 198, 31...
3
250
from json import loads from os.path import isfile, splitext from sys import argv, exit from highcharts import Highchart DOCS = 'docs' RESPONSE = 'response' LANG = 'tweet_lang' COUNTRY = 'user_location' TITLE = 'title' TEXT = 'text' # Make sure we have the correct command line arguments if len(argv) ...
[ 6738, 33918, 1330, 15989, 198, 6738, 28686, 13, 6978, 1330, 318, 7753, 11, 4328, 578, 742, 198, 6738, 25064, 1330, 1822, 85, 11, 8420, 198, 198, 6738, 1029, 354, 5889, 1330, 3334, 40926, 628, 198, 38715, 50, 220, 220, 220, 220, 796, ...
2.572308
650
from PyQt5 import QtCore, QtWidgets import sys from multiprocessing import Process, Queue from time import time import vtk from vtk.qt.QVTKRenderWindowInteractor import QVTKRenderWindowInteractor import numpy as np from time import sleep # Some other functions I toyed with before I got the vtk example working ...
[ 198, 198, 6738, 9485, 48, 83, 20, 1330, 33734, 14055, 11, 33734, 54, 312, 11407, 198, 11748, 25064, 198, 6738, 18540, 305, 919, 278, 1330, 10854, 11, 4670, 518, 198, 6738, 640, 1330, 640, 198, 11748, 410, 30488, 198, 6738, 410, 30488,...
3.020408
147
import os import pandas as pd from tqdm import tqdm if os.environ.get("USER") == "ian": ROOT = "/home/ian/data/kaggle/optiver_volatility/" else: ROOT = "/kaggle/input/optiver-realized-volatility-prediction" print(f"Utility says ROOT is {ROOT}") TRAIN_CSV = os.path.join(ROOT, "train.csv") TEST_CSV = os.path.jo...
[ 11748, 28686, 198, 11748, 19798, 292, 355, 279, 67, 198, 6738, 256, 80, 36020, 1330, 256, 80, 36020, 198, 198, 361, 28686, 13, 268, 2268, 13, 1136, 7203, 29904, 4943, 6624, 366, 666, 1298, 198, 220, 220, 220, 15107, 2394, 796, 12813, ...
2.072863
1,743
n = int(input('digite um número:')) d = n * 2 t = n * 3 r = n ** (1/2) print ('o dobro de {} é {} o triplo {} e a raiz quadrada é {:.0f}'.format(n,d,t,r))
[ 77, 796, 493, 7, 15414, 10786, 12894, 578, 23781, 299, 21356, 647, 78, 32105, 4008, 220, 198, 67, 796, 299, 1635, 362, 198, 83, 796, 299, 1635, 513, 198, 81, 796, 299, 12429, 357, 16, 14, 17, 8, 198, 4798, 19203, 78, 466, 7957, ...
2
78
''' Created by auto_sdk on 2015.11.25 ''' from aliyun.api.base import RestApi
[ 7061, 6, 201, 198, 41972, 416, 8295, 62, 21282, 74, 319, 1853, 13, 1157, 13, 1495, 201, 198, 7061, 6, 201, 198, 6738, 435, 7745, 403, 13, 15042, 13, 8692, 1330, 8324, 32, 14415, 201, 198 ]
2.277778
36
import numpy as np
[ 198, 11748, 299, 32152, 355, 45941, 198 ]
2.857143
7
"""Neural net classes.""" import fnmatch from itertools import chain from functools import partial import re import tempfile import warnings import numpy as np from sklearn.base import BaseEstimator import torch from torch.utils.data import DataLoader from skorch.callbacks import EpochTimer from skorch.callbacks imp...
[ 37811, 8199, 1523, 2010, 6097, 526, 15931, 198, 198, 11748, 24714, 15699, 198, 6738, 340, 861, 10141, 1330, 6333, 198, 6738, 1257, 310, 10141, 1330, 13027, 198, 11748, 302, 198, 11748, 20218, 7753, 198, 11748, 14601, 198, 198, 11748, 299,...
2.380154
16,225
# -*- coding: UTF-8 -*- #Colours Defined Variables W = '\033[1;37m' N = '\033[0m' R="\033[1;37m\033[31m" B = '\033[1;37m\033[34m' G = '\033[1;32m' Y = '\033[1;33;40m' #Decorators SBR = W+"("+R+"π"+W+")" SBG = W+"("+G+"π"+W+")" SRO = W+"("+R+">"+W+")" SGO = W+"("+G+">"+W+")" SEO = W+"("+R+"!"+W+")" newlin = "\...
[ 198, 2, 532, 9, 12, 19617, 25, 41002, 12, 23, 532, 9, 12, 198, 198, 2, 5216, 4662, 2896, 1389, 15965, 2977, 198, 198, 54, 220, 796, 705, 59, 44427, 58, 16, 26, 2718, 76, 6, 198, 45, 220, 796, 705, 59, 44427, 58, 15, 76, 6, ...
1.643202
1,449
import numpy as np import unittest from chainercv.utils import assert_is_image from chainercv.utils import testing @testing.parameterize( { 'img': np.random.randint(0, 256, size=(3, 48, 64)), 'color': True, 'check_range': True, 'valid': True}, { 'img': np.random.randint(0, 256, size=(...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 555, 715, 395, 198, 198, 6738, 6333, 2798, 85, 13, 26791, 1330, 6818, 62, 271, 62, 9060, 198, 6738, 6333, 2798, 85, 13, 26791, 1330, 4856, 628, 198, 31, 33407, 13, 17143, 2357, 1096, 7, 198...
2.134211
760
import os import numpy as np theta_spacing = 0.07 phi_spacing = 0.02 R1 = 1 R2 = 2 K2 = 5 screen_width = 50 screen_height = 50 K1 = screen_width * K2 * 3 / (8 * (R1 + R2)) def calc_luminance(cos_a, cos_b, cos_phi, cos_theta, sin_a, sin_b, sin_phi, sin_theta): """ Luminance should be equal to: cosphi...
[ 11748, 28686, 198, 11748, 299, 32152, 355, 45941, 198, 198, 1169, 8326, 62, 2777, 4092, 796, 657, 13, 2998, 198, 34846, 62, 2777, 4092, 796, 657, 13, 2999, 198, 198, 49, 16, 796, 352, 198, 49, 17, 796, 362, 198, 42, 17, 796, 642, ...
2.027091
849
#!/usr/bin/python #This script assumes that gnuplot is in the environment PATH import getopt, logging, sys, SneeqlLib, TossimLib, AvroraLib, os, UtilLib, checkTupleCount, RandomSeeder, networkLib, StatLib, GraphData optSneeqlRoot = os.getenv("SNEEQLROOT") optNumAgendaEvals = 2 optQueryDuration = UtilLib.monthsToSecond...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 2, 1212, 4226, 18533, 326, 19967, 84, 29487, 318, 287, 262, 2858, 46490, 198, 11748, 651, 8738, 11, 18931, 11, 25064, 11, 311, 21381, 13976, 25835, 11, 309, 793, 320, 25835, 11, 5184, 1472, ...
3.075282
797
import os import tensorflow as tf from ..experiments import runner import copy # noqa import numpy as np from datetime import datetime # noqa from ..data import pointcloud_fetcher as pfetcher from ..model import transforms as trans # noqa from ..experiments import simplebase_experiment as set_exp from ..experiments ...
[ 11748, 28686, 198, 11748, 11192, 273, 11125, 355, 48700, 198, 6738, 11485, 23100, 6800, 1330, 17490, 198, 11748, 4866, 220, 1303, 645, 20402, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 4818, 8079, 1330, 4818, 8079, 220, 1303, 645, 204...
3.60177
113
from __future__ import division, print_function, absolute_import
[ 6738, 11593, 37443, 834, 1330, 7297, 11, 3601, 62, 8818, 11, 4112, 62, 11748, 198 ]
4.333333
15
# Copyright (c) 2008, Humanized, Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # 1. Redistributions of source code must retain the above copyright # notice, this list of conditi...
[ 2, 15069, 357, 66, 8, 3648, 11, 5524, 1143, 11, 3457, 13, 198, 2, 1439, 2489, 10395, 13, 198, 2, 220, 198, 2, 2297, 396, 3890, 290, 779, 287, 2723, 290, 13934, 5107, 11, 351, 393, 1231, 198, 2, 17613, 11, 389, 10431, 2810, 326, ...
2.576548
5,637
# flake8: noqa import wirepas_mesh_messaging # Define list of default values used during testing GATEWAY_ID = "test_gateway" GATEWAY_STATE = wirepas_mesh_messaging.GatewayState.ONLINE SINK_ID = "sink3" RES_OK = wirepas_mesh_messaging.GatewayResultCode.GW_RES_OK RES_KO = wirepas_mesh_messaging.GatewayResultCode.GW_RES...
[ 2, 781, 539, 23, 25, 645, 20402, 198, 198, 11748, 6503, 44429, 62, 76, 5069, 62, 37348, 3039, 198, 198, 2, 2896, 500, 1351, 286, 4277, 3815, 973, 1141, 4856, 198, 38, 6158, 27285, 62, 2389, 796, 366, 9288, 62, 10494, 1014, 1, 198,...
2.205962
738
from ics import Calendar from urllib.request import urlopen url1 = "https://calendar.google.com/calendar/ical/marcel%40intuitionmachines.com/public/basic.ics" url2 = "https://calendar.google.com/calendar/ical/dreamflasher%40dreamflasher.de/public/basic.ics" c1 = Calendar(urlopen(url1).read().decode()) c2 = Calendar(url...
[ 6738, 220, 873, 1330, 26506, 198, 6738, 2956, 297, 571, 13, 25927, 1330, 19016, 9654, 198, 6371, 16, 796, 366, 5450, 1378, 9948, 9239, 13, 13297, 13, 785, 14, 9948, 9239, 14, 605, 14, 3876, 5276, 4, 1821, 600, 84, 653, 76, 620, 11...
2.565714
175
from django.shortcuts import render from rest_framework import viewsets from rest_framework.filters import SearchFilter,OrderingFilter from rest_framework.pagination import LimitOffsetPagination, PageNumberPagination,CursorPagination from .pagination import PersonPageNumberPagination,PersonLimitOffsetPagination,Person...
[ 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 198, 6738, 1334, 62, 30604, 1330, 5009, 1039, 198, 6738, 1334, 62, 30604, 13, 10379, 1010, 1330, 11140, 22417, 11, 18743, 278, 22417, 198, 6738, 1334, 62, 30604, 13, 79, 363, 1883, 1330,...
3.847458
118
import yaml __all__ = ['Renderer', 'StatusRenderer']
[ 11748, 331, 43695, 198, 198, 834, 439, 834, 796, 37250, 49, 437, 11882, 3256, 705, 19580, 49, 437, 11882, 20520, 628, 198 ]
2.545455
22
from django.db import transaction from api.management.data_script import OperationalDataScript from api.models.NotionalTransferType import NotionalTransferType class AddNotionalTransferTypes(OperationalDataScript): """ Adds Notional Transfer Types """ is_revertable = False comment = 'Adds Notiona...
[ 6738, 42625, 14208, 13, 9945, 1330, 8611, 198, 198, 6738, 40391, 13, 27604, 13, 7890, 62, 12048, 1330, 6564, 864, 6601, 7391, 198, 6738, 40391, 13, 27530, 13, 3673, 1538, 43260, 6030, 1330, 1892, 1538, 43260, 6030, 628, 198, 4871, 3060,...
3.513043
115
#!/usr/bin/env python3 """ Usage: poetry run test_parser FR production """ import datetime import logging import pprint import time import arrow import click from parsers.lib.parsers import PARSER_KEY_TO_DICT from parsers.lib.quality import ( ValidationError, validate_consumption, validate_exchange, ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 37811, 198, 28350, 25, 19518, 1057, 1332, 62, 48610, 8782, 3227, 198, 37811, 198, 198, 11748, 4818, 8079, 198, 11748, 18931, 198, 11748, 279, 4798, 198, 11748, 640, 198, 198, 11748, ...
2.332476
1,555
# -*- coding: utf-8 -*- __author__ = 'vincent' import uuid import json from redis_help import redis_client from werkzeug.security import generate_password_hash, check_password_hash from . import redis_help # 下面这个包 itsdangerous 用于生成确认令牌 from itsdangerous import TimedJSONWebSignatureSerializer as Serializer def gen...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 834, 9800, 834, 796, 705, 7114, 1087, 6, 198, 198, 11748, 334, 27112, 198, 11748, 33918, 198, 6738, 2266, 271, 62, 16794, 1330, 2266, 271, 62, 16366, 198, 198, 6738, 2...
1.628931
795
import time from redis.exceptions import WatchError
[ 11748, 640, 198, 198, 6738, 2266, 271, 13, 1069, 11755, 1330, 6305, 12331, 628 ]
3.857143
14
"""user bank updates Revision ID: 273b8bcef694 Revises: 2e02a681aeaa Create Date: 2021-06-22 17:22:00.102134 """ import logging from alembic import op import sqlalchemy as sa from sqlalchemy.orm import sessionmaker logger = logging.getLogger(__name__) # revision identifiers, used by Alembic. revision = "273b8bcef69...
[ 37811, 7220, 3331, 5992, 198, 198, 18009, 1166, 4522, 25, 38549, 65, 23, 65, 344, 69, 45214, 198, 18009, 2696, 25, 362, 68, 2999, 64, 48564, 3609, 7252, 198, 16447, 7536, 25, 33448, 12, 3312, 12, 1828, 1596, 25, 1828, 25, 405, 13, ...
2.733766
154
from datetime import date #Importa biblioteca para pegar data e hora do pc print('='*6, 'DESAFIO 032 - ANO BISSEXTO', '='*6) ano = int(input('| Digite o ano que quer analisar ou digite 0 para analisar o ano atual: ')) #Recebe ano digitado if ano == 0: ...
[ 6738, 4818, 8079, 1330, 3128, 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, 220, 220, 220, 1303, 20939, 64, 275, 29142, 313, 31047, 31215, 61...
2.087324
355
from __future__ import absolute_import from __future__ import division from __future__ import print_function import shutil import sys import tempfile from observations.r.bthe_b import bthe_b def test_bthe_b(): """Test module bthe_b.py by downloading bthe_b.csv and testing shape of extracted data has 100 row...
[ 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 198, 6738, 11593, 37443, 834, 1330, 7297, 198, 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 198, 198, 11748, 4423, 346, 198, 11748, 25064, 198, 11748, 20218, 7753, 198, 198, 6738, 13050, ...
2.865169
178
from pwncli import * cli_script() p = gift['io'] e = gift['elf'] if gift['debug']: libc = gift['libc'] else: libc = ELF("/root/LibcSearcher/libc-database/other_libc_so/libc-2.23.so") p.sendline("%41$p,%43$p") msg = p.recvline() code_addr, libc_addr = msg.split(b",") code_base_addr = int16(code_addr.decode...
[ 6738, 279, 675, 44506, 1330, 1635, 198, 198, 44506, 62, 12048, 3419, 198, 198, 79, 796, 6979, 17816, 952, 20520, 198, 68, 796, 6979, 17816, 7046, 20520, 198, 198, 361, 6979, 17816, 24442, 6, 5974, 198, 220, 220, 220, 9195, 66, 796, ...
2.297468
316
############################################################################### # Copyright (c) 2019, Lawrence Livermore National Security, LLC. # Produced at the Lawrence Livermore National Laboratory # Written by the Merlin dev team, listed in the CONTRIBUTORS file. # <merlin@llnl.gov> # # LLNL-CODE-797170 # All righ...
[ 29113, 29113, 7804, 4242, 21017, 198, 2, 15069, 357, 66, 8, 13130, 11, 13914, 45036, 3549, 2351, 4765, 11, 11419, 13, 198, 2, 21522, 771, 379, 262, 13914, 45036, 3549, 2351, 18643, 198, 2, 22503, 416, 262, 32918, 1614, 1074, 11, 5610,...
2.768793
1,583
#!/usr/bin/env python3 # -*- coding: utf-8 -*- from Commands.PythonCommandBase import PythonCommand, ImageProcPythonCommand from Commands.Keys import KeyPress, Button, Direction, Stick, Hat
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 6738, 49505, 13, 37906, 21575, 14881, 1330, 11361, 21575, 11, 7412, 2964, 66, 37906, 21575, 198, 6738, 49505, ...
3.392857
56
from .signal import * __all__ = ["orthogonal_wavelet", "DAUBECHIES_D4"] class orthogonal_wavelet: """Orthogonal wavelet consisting of a scaling (low-pass) filter and a wavelet (high-pass) filter that together form a conjugate mirror filter (CMF) pair.""" @staticmethod def from_scaling_filter(scaling_fil...
[ 6738, 764, 12683, 282, 1330, 1635, 198, 198, 834, 439, 834, 796, 14631, 1506, 519, 20996, 62, 19204, 1616, 1600, 366, 5631, 10526, 25994, 11015, 62, 35, 19, 8973, 628, 198, 4871, 29617, 519, 20996, 62, 19204, 1616, 25, 198, 220, 220, ...
2.517889
1,118
import numpy as np import torch from torch import nn from torch import optim import torch.nn.functional as F from torchvision import datasets, transforms, models from torch.utils.data.sampler import SubsetRandomSampler datadir = './data/train' valid_size = .3 epochs = 3 steps = 0 running_loss = 0 print_every = 10...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 28034, 198, 6738, 28034, 1330, 299, 77, 198, 6738, 28034, 1330, 6436, 198, 11748, 28034, 13, 20471, 13, 45124, 355, 376, 198, 6738, 28034, 10178, 1330, 40522, 11, 31408, 11, 4981, 198, 6738, 28...
2.609964
823
#!/usr/bin/env python # -*- coding: utf-8 -*- from __future__ import division, print_function, unicode_literals import os import sys from os import path from setuptools import find_packages, setup from distutils.command.bdist import bdist from distutils.command.sdist import sdist version = '0.9.0.rc1' cmdclass = dic...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 11593, 37443, 834, 1330, 7297, 11, 3601, 62, 8818, 11, 28000, 1098, 62, 17201, 874, 198, 11748, 28686, 198, 11748...
2.260341
822
import os import sys from stat import S_IREAD, S_IWRITE from robot.api import logger
[ 11748, 28686, 198, 11748, 25064, 198, 6738, 1185, 1330, 311, 62, 40, 15675, 11, 311, 62, 40, 18564, 12709, 198, 198, 6738, 9379, 13, 15042, 1330, 49706, 628 ]
3.107143
28