content
stringlengths
1
1.04M
input_ids
listlengths
1
774k
ratio_char_token
float64
0.38
22.9
token_count
int64
1
774k
import os import re import sys import numpy as np from collections import Counter import collections import h5py import pandas as pd pathname = os.path.abspath('C:\\Users\\Vicky\\Desktop\\Courses\\Avi\\erisk collections_2017_2018\\erisk collections\\2017\\2test') os.chdir(pathname) #############Read Outpu...
[ 11748, 28686, 201, 198, 11748, 302, 201, 198, 11748, 25064, 201, 198, 11748, 299, 32152, 355, 45941, 201, 198, 6738, 17268, 1330, 15034, 201, 198, 11748, 17268, 201, 198, 11748, 289, 20, 9078, 201, 198, 11748, 19798, 292, 355, 279, 67, ...
1.954839
1,240
color =["red", "green", "purple", "orange", "blue", "yellow"] pick = input("What is your favorite color ? ") if pick in color: # Storing the rank of the color picked rank = color.index(pick) + 1 # Check if the color is in your list if rank == 1: print("That is my favorite color.")...
[ 8043, 796, 14692, 445, 1600, 366, 14809, 1600, 366, 14225, 1154, 1600, 366, 43745, 1600, 366, 17585, 1600, 366, 36022, 8973, 198, 198, 27729, 796, 5128, 7203, 2061, 318, 534, 4004, 3124, 5633, 366, 8, 198, 198, 361, 2298, 287, 3124, 2...
2.495968
248
"""This module is used to profile getrecommendations() and bestreds.BestrefsScript().""" from crds.python23 import pickle import crds from crds.tests.test_config import run_and_profile from crds import data_file if __name__ == "__main__": run_and_profile("HST pickle/unpickle", "pickle_unpickle('hst.pmap', 'dat...
[ 37811, 1212, 8265, 318, 973, 284, 7034, 651, 47335, 437, 602, 3419, 290, 1266, 445, 82, 13, 13014, 5420, 82, 7391, 3419, 526, 15931, 198, 198, 6738, 1067, 9310, 13, 29412, 1954, 1330, 2298, 293, 198, 198, 11748, 1067, 9310, 198, 198, ...
2.717557
131
import requests from colorama import Fore, init from threading import Thread import random, time, names, string, json, os from threading import Lock from random import choice s_print_lock = Lock() def s_print(*a, **b): """Thread safe print function""" with s_print_lock: print(*a, **b) def get_prox...
[ 11748, 7007, 198, 6738, 3124, 1689, 1330, 4558, 11, 2315, 198, 6738, 4704, 278, 1330, 14122, 198, 11748, 4738, 11, 640, 11, 3891, 11, 4731, 11, 33918, 11, 28686, 198, 6738, 4704, 278, 1330, 13656, 198, 6738, 4738, 1330, 3572, 628, 198...
2.184473
1,404
# https://leetcode.com/problems/number-of-students-unable-to-eat-lunch
[ 2, 3740, 1378, 293, 316, 8189, 13, 785, 14, 1676, 22143, 14, 17618, 12, 1659, 12, 19149, 658, 12, 403, 540, 12, 1462, 12, 4098, 12, 75, 3316, 628 ]
2.482759
29
# Copyright (C) 2018-2022 Intel Corporation # SPDX-License-Identifier: Apache-2.0 import numpy as np import pytest from openvino.tools.mo.front.common.partial_infer.utils import int64_array, float32_array from unit_tests.utils.graph import build_graph, regular_op_with_shaped_data, connect, \ shaped_data, connect_f...
[ 2, 15069, 357, 34, 8, 2864, 12, 1238, 1828, 8180, 10501, 198, 2, 30628, 55, 12, 34156, 12, 33234, 7483, 25, 24843, 12, 17, 13, 15, 198, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 12972, 9288, 198, 6738, 1280, 85, 2879, 13, 31...
3.055901
161
############################################## # The MIT License (MIT) # Copyright (c) 2014 Kevin Walchko # see LICENSE for full details ############################################## # this directory contains things for testing and fake sources # import pygecko.test.fake_camera as cv2 # from pygecko.test.process impo...
[ 29113, 7804, 4242, 2235, 198, 2, 383, 17168, 13789, 357, 36393, 8, 198, 2, 15069, 357, 66, 8, 1946, 7939, 6445, 354, 7204, 198, 2, 766, 38559, 24290, 329, 1336, 3307, 198, 29113, 7804, 4242, 2235, 198, 2, 428, 8619, 4909, 1243, 329,...
4.275
80
""" Interactive fitting of peaks in noisy 2D images. Copyright (c) 2013, rhambach. This file is part of the TEMimage package and released under the MIT-Licence. See LICENCE file for details. """ import numpy as np import scipy.ndimage as ndimage import scipy.ndimage.filters as filters import matplotlib.py...
[ 37811, 198, 220, 21365, 15830, 286, 25740, 287, 31210, 362, 35, 4263, 13, 628, 220, 15069, 357, 66, 8, 2211, 11, 374, 2763, 19496, 13, 220, 198, 220, 220, 220, 770, 2393, 318, 636, 286, 262, 309, 3620, 9060, 5301, 290, 2716, 198, ...
2.403877
1,857
# Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. # # Use of this source code is governed by a BSD-style license # that can be found in the LICENSE file in the root of the source # tree. An additional intellectual property rights grant can be found # in the file PATENTS. All contributing project au...
[ 2, 15069, 357, 66, 8, 2321, 383, 5313, 49, 4825, 1628, 7035, 13, 1439, 6923, 33876, 13, 198, 2, 198, 2, 5765, 286, 428, 2723, 2438, 318, 21825, 416, 257, 347, 10305, 12, 7635, 5964, 198, 2, 326, 460, 307, 1043, 287, 262, 38559, ...
1.958071
1,431
#!/usr/bin/python # -*- coding: utf-8 -*- import re foodon_lookup = {} siren_lookup = {} nameless = '03301032 03301034 03301067 03301068 03301076 03301078 03301107 03301131 03301149 03301152 03301160 03301163 03301168 03301173 03301183 03301192 03301199 03301206 03301212 03301213 03301221 03301229 03301253 03301287 0...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 302, 198, 198, 19425, 261, 62, 5460, 929, 796, 23884, 198, 82, 24080, 62, 5460, 929, 796, 23884, 198, 198, 7402, 5321...
2.384452
5,184
#encoding=utf-8 ## SOLVED 2014/04/10 ## 134043 # The first two consecutive numbers to have two distinct prime factors are: # 14 = 2 × 7 # 15 = 3 × 5 # The first three consecutive numbers to have three distinct prime factors are: # 644 = 2² × 7 × 23 # 645 = 3 × 5 × 43 # 646 = 2 × 17 × 19. # Find the first four cons...
[ 2, 12685, 7656, 28, 40477, 12, 23, 198, 2235, 36817, 53, 1961, 1946, 14, 3023, 14, 940, 198, 2235, 1511, 1821, 3559, 198, 198, 2, 383, 717, 734, 12785, 3146, 284, 423, 734, 7310, 6994, 5087, 389, 25, 198, 198, 2, 1478, 796, 362, ...
3.102564
195
#!/usr/bin/env python ''' A solution to a ROSALIND bioinformatics problem. Problem Title: Consensus and Profile Rosalind ID: SUBS Rosalind #: 009 URL: http://rosalind.info/problems/subs/ ''' from numpy import zeros from scripts import ReadFASTA # Data is in FASTA form dna_list = ReadFASTA('data/rosalind_cons.txt') ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 7061, 6, 198, 32, 4610, 284, 257, 48263, 1847, 12115, 13401, 259, 18982, 873, 1917, 13, 198, 198, 40781, 11851, 25, 3515, 7314, 290, 13118, 198, 35740, 282, 521, 4522, 25, 13558, 4462,...
2.26378
508
#!/usr/bin/env python """Copies data from RAPID netCDF output to a CF-compliant netCDF file. Remarks: A new netCDF file is created with data from RAPID [1] simulation model output. The result follows CF conventions [2] with additional metadata prescribed by the NODC timeSeries Orthogonal template [3]...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 201, 198, 37811, 13379, 444, 1366, 422, 371, 2969, 2389, 2010, 34, 8068, 5072, 284, 257, 18551, 12, 23855, 3014, 2010, 34, 8068, 2393, 13, 201, 198, 201, 198, 8413, 5558, 25, 201, 198, 22...
2.091722
8,951
# Copyright [2020] [Toyota Research 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 required by applicable law or agre...
[ 2, 15069, 685, 42334, 60, 685, 48236, 4265, 4992, 5136, 60, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13...
3.491379
232
if __name__ == '__main__': victor = Pessoa(nome='Victor') vinicius = Pessoa(victor,nome='Vinicius') print(Pessoa.cumprimentar(vinicius)) print(id(vinicius)) print(vinicius.nome) print(vinicius.idade) for filho in vinicius.filhos: print(filho.nome)
[ 628, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 2210, 273, 796, 350, 408, 12162, 7, 77, 462, 11639, 21944, 273, 11537, 198, 220, 220, 220, 410, 47277, 3754, 796, 350, 408, 12162, 7, 32433, 273...
2.028169
142
"""Example to create a Panel of Ophyd Signals from an object""" import sys import numpy as np from qtpy.QtWidgets import QApplication import typhos from ophyd import Component as Cpt from ophyd import Device, Signal from typhos.utils import SignalRO class Sample(Device): """Simulated Device""" readback = Cp...
[ 37811, 16281, 284, 2251, 257, 18810, 286, 440, 746, 5173, 5865, 874, 422, 281, 2134, 37811, 198, 11748, 25064, 198, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 10662, 83, 9078, 13, 48, 83, 54, 312, 11407, 1330, 1195, 23416, 198, 19...
2.712025
316
import tensorly as tl from tensorly.decomposition import parafac, partial_tucker import numpy as np import torch import torch.nn as nn from typing import * def cp_decomposition_conv_layer(layer, rank): # rank = max(layer.weight.data.numpy().shape) // 3 """Gets a conv layer and a target rank, returns a nn....
[ 11748, 11192, 273, 306, 355, 256, 75, 198, 6738, 11192, 273, 306, 13, 12501, 296, 9150, 1330, 1582, 1878, 330, 11, 13027, 62, 83, 12603, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 28034, 198, 11748, 28034, 13, 20471, 355, 299, 77...
2.170768
2,032
# -*- coding:utf-8 -*- import wave import requests import time import base64 import numpy as np from pyaudio import PyAudio, paInt16 import time from playsound import playsound import os import sys framerate = 16000 # num_samples = 2000 channels = 1 sampwidth = 2 # FILEPATH = 'speech.wav' base_url = "https://opena...
[ 2, 532, 9, 12, 19617, 25, 40477, 12, 23, 532, 9, 12, 198, 11748, 6769, 198, 11748, 7007, 198, 11748, 640, 198, 11748, 2779, 2414, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 12972, 24051, 1330, 9485, 21206, 11, 14187, 5317, 1433, ...
2.104762
420
from glob import glob import os import sys from setuptools import setup name = "pypdc" version="0.0.8" description = "Python asymptotic Partial Directed Coherence and Directed Coherence estimation package for brain connectivity analysis." authors = { "Sameshima": ("Koichi Sameshima", "ksameshi@usp.br"), "Brit...
[ 6738, 15095, 1330, 15095, 198, 11748, 28686, 198, 11748, 25064, 198, 6738, 900, 37623, 10141, 1330, 9058, 628, 198, 3672, 796, 366, 79, 4464, 17896, 1, 198, 9641, 2625, 15, 13, 15, 13, 23, 1, 198, 11213, 796, 366, 37906, 355, 4948, ...
2.666116
605
#!/usr/bin/env python3 # Copyright 2021 The IREE Authors # # Licensed under the Apache License v2.0 with LLVM Exceptions. # See https://llvm.org/LICENSE.txt for license information. # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception """Utils for accessing Android devices.""" import json import re from typing i...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 15069, 33448, 383, 314, 11587, 46665, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 410, 17, 13, 15, 351, 27140, 15996, 1475, 11755, 13, 198, 2, 4091, 3740, 1378, 297, 14761,...
2.616423
889
""" Create a profile from an ASCII CTD datafile =========================================== Use the TAMOC ambient module to create profiles in netCDF format for use by TAMOC from data in text files downloaded from a CTD. This file demonstrates working with the data from the R/V Brooks McCall at Station BM 54 on May ...
[ 37811, 198, 16447, 257, 7034, 422, 281, 37101, 16356, 35, 1366, 7753, 198, 10052, 2559, 18604, 198, 198, 11041, 262, 33112, 4503, 25237, 8265, 284, 2251, 16545, 287, 2010, 34, 8068, 5794, 329, 779, 416, 220, 198, 51, 2390, 4503, 422, ...
2.183461
2,878
import os import json import unittest from pathlib import Path from typing import Dict, Any import jsonschema.exceptions from schema_entry.entrypoint import EntryPoint
[ 11748, 28686, 198, 11748, 33918, 198, 11748, 555, 715, 395, 198, 6738, 3108, 8019, 1330, 10644, 198, 6738, 19720, 1330, 360, 713, 11, 4377, 198, 11748, 44804, 684, 2395, 2611, 13, 1069, 11755, 198, 198, 6738, 32815, 62, 13000, 13, 13000...
3.604167
48
# Copyright 2017 The TensorFlow 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 applica...
[ 2, 15069, 2177, 383, 309, 22854, 37535, 46665, 13, 1439, 6923, 33876, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, ...
3.903448
290
# FileName: Flask-Blog > blog > config.py import os, secrets
[ 2, 9220, 5376, 25, 46947, 12, 42383, 1875, 4130, 1875, 4566, 13, 9078, 201, 198, 11748, 28686, 11, 13141, 201, 198, 201, 198 ]
2.826087
23
# -*- coding: utf-8 -*- """ QR code that be scanned to allow login """ import qrcode import tempfile import webbrowser from decimal import Decimal from qrcode.image.svg import SvgImage from .constants import JIKE_URI_SCHEME_FMT, RENDER2BROWSER_HTML_TEMPLATE
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 37811, 198, 48, 49, 2438, 326, 307, 28660, 284, 1249, 17594, 198, 37811, 198, 198, 11748, 10662, 6015, 1098, 198, 11748, 20218, 7753, 198, 11748, 3992, 40259, 198, ...
2.676768
99
from decorators import debug, do_twice # debug(do_twice(greet())) @debug @do_twice greet("Eva")
[ 6738, 11705, 2024, 1330, 14257, 11, 466, 62, 4246, 501, 198, 198, 2, 14257, 7, 4598, 62, 4246, 501, 7, 70, 2871, 3419, 4008, 198, 31, 24442, 198, 31, 4598, 62, 4246, 501, 628, 198, 70, 2871, 7203, 44239, 4943 ]
2.45
40
import json from collections import defaultdict import numpy as np from tqdm import tqdm from stanza.nlp.corenlp import CoreNLPClient import itertools from jiwer import wer from utils import get_cnet_best_pass import csv from math import exp from functools import reduce import time client = None def cnet_best_n_paths(...
[ 11748, 33918, 198, 6738, 17268, 1330, 4277, 11600, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 256, 80, 36020, 1330, 256, 80, 36020, 198, 6738, 336, 35819, 13, 21283, 79, 13, 7295, 21283, 79, 1330, 7231, 45, 19930, 11792, 198, 11748,...
2.314136
573
#!python from queue import LinkedQueue if __name__ == '__main__': test_binary_search_tree()
[ 2, 0, 29412, 198, 6738, 16834, 1330, 7502, 276, 34991, 628, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 1332, 62, 39491, 62, 12947, 62, 21048, 3419, 198 ]
2.75
36
import asyncio import urllib.parse from dataclasses import dataclass import httpx @dataclass(eq=False)
[ 11748, 30351, 952, 198, 11748, 2956, 297, 571, 13, 29572, 198, 6738, 4818, 330, 28958, 1330, 4818, 330, 31172, 198, 198, 11748, 2638, 87, 628, 198, 31, 19608, 330, 31172, 7, 27363, 28, 25101, 8, 628, 628, 628, 198 ]
2.871795
39
if __name__ == "__main__": tests()
[ 628, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 5254, 3419, 198 ]
2.210526
19
# -*- coding: utf-8 -*- import numpy as np from .signal_interpolate import signal_interpolate from .signal_formatpeaks import _signal_formatpeaks_sanitize def signal_period(peaks, sampling_rate=1000, desired_length=None, interpolation_order="cubic"): """Calculate signal period from a series of ...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 299, 32152, 355, 45941, 198, 198, 6738, 764, 12683, 282, 62, 3849, 16104, 378, 1330, 6737, 62, 3849, 16104, 378, 198, 6738, 764, 12683, 282, 62, 18982, 431, 4730,...
2.597415
1,083
# Import global settings to make it easier to extend settings. from django.conf.global_settings import * # pylint: disable=W0614,W0401 #============================================================================ # Generic Django project settings #=====================================================================...
[ 2, 17267, 3298, 6460, 284, 787, 340, 4577, 284, 9117, 6460, 13, 198, 6738, 42625, 14208, 13, 10414, 13, 20541, 62, 33692, 1330, 1635, 220, 220, 1303, 279, 2645, 600, 25, 15560, 28, 54, 3312, 1415, 11, 54, 3023, 486, 198, 198, 2, 2...
2.967697
2,167
from django.contrib import admin from .models import * admin.site.register(Car) admin.site.register(DriverLicense) admin.site.register(Driver) admin.site.register(Ownership)
[ 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 6738, 764, 27530, 1330, 1635, 198, 198, 28482, 13, 15654, 13, 30238, 7, 9914, 8, 198, 28482, 13, 15654, 13, 30238, 7, 32103, 34156, 8, 198, 28482, 13, 15654, 13, 30238, 7, 32103, ...
3.259259
54
"""Sphinx ReadTheDocs theme. From https://github.com/ryan-roemer/sphinx-bootstrap-theme. """ import os __version__ = '0.2.0' __version_full__ = __version__ def get_html_theme_path(): """Return list of HTML theme paths.""" cur_dir = os.path.abspath(os.path.dirname(os.path.dirname(__file__))) return cur_...
[ 37811, 50, 746, 28413, 4149, 464, 23579, 82, 7505, 13, 198, 198, 4863, 3740, 1378, 12567, 13, 785, 14, 29038, 12, 305, 24677, 14, 82, 746, 28413, 12, 18769, 26418, 12, 43810, 13, 198, 198, 37811, 198, 11748, 28686, 198, 198, 834, 96...
2.511628
129
# Lint as: python2, python3 # Copyright 2019 The TensorFlow 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 # ...
[ 2, 406, 600, 355, 25, 21015, 17, 11, 21015, 18, 198, 2, 15069, 13130, 383, 309, 22854, 37535, 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, 1...
2.764087
1,331
""" Implements Multi-fidelity GP Bandit Optimisaiton. -- kandasamy@cs.cmu.edu """ # pylint: disable=import-error # pylint: disable=no-member # pylint: disable=invalid-name # pylint: disable=relative-import # pylint: disable=super-on-old-class from argparse import Namespace from copy import deepcopy import time imp...
[ 37811, 198, 220, 1846, 1154, 902, 15237, 12, 69, 23091, 14714, 10243, 270, 30011, 271, 4548, 261, 13, 198, 220, 1377, 479, 392, 292, 14814, 31, 6359, 13, 11215, 84, 13, 15532, 198, 37811, 198, 2, 279, 2645, 600, 25, 15560, 28, 11748...
2.41858
11,109
from sqlalchemy import create_engine from sqlalchemy.engine.url import URL from sqlalchemy.orm import scoped_session, sessionmaker from settings import DATABASE TEST_DB = dict(DATABASE) engine = create_engine(URL(**TEST_DB)) Session = scoped_session(sessionmaker(bind=engine)) def delete_rows(db_engine, base_obj):...
[ 6738, 44161, 282, 26599, 1330, 2251, 62, 18392, 198, 6738, 44161, 282, 26599, 13, 18392, 13, 6371, 1330, 10289, 198, 6738, 44161, 282, 26599, 13, 579, 1330, 629, 19458, 62, 29891, 11, 6246, 10297, 198, 198, 6738, 6460, 1330, 360, 1404, ...
2.942584
209
#!/usr/bin/env python3 # -*- coding: utf-8 -*- ################################################## # # make_dict.py # # This module takes a text file, marked up with # units (e.g. w for word, m for morpheme) and ids # and converted to IPA, and produces a # .dict file for processing by PocketSphinx. # ##################...
[ 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, 29113, 14468, 2235, 198, 2, 198, 2, 787, 62, 11600, 13, 9078, 198, 2, 198, 2, 770, 8265, 2753, 257, 2420, ...
2.765376
439
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Fri Jul 19 13:05:23 2019 @author: TempestGuerra """ import numpy as np import math as mt from HerfunChebNodesWeights import chebpolym, cheblb
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 41972, 319, 19480, 5979, 678, 1511, 25, 2713, 25, 1954, 13130, 198, 198, 31, 9800, 25, 34367, 8205, 2...
2.594937
79
from .connection import database, init_db
[ 6738, 764, 38659, 1330, 6831, 11, 2315, 62, 9945, 198 ]
4.2
10
"""Tests for create_data.py.""" import json import shutil import tempfile import unittest from glob import glob from os import path import tensorflow as tf from opensubtitles import create_data _TRAIN_FILE = "\n".join([ "matt: AAAA", # words followed by colons are stripped. "[skip]", # text in brackets is...
[ 37811, 51, 3558, 329, 2251, 62, 7890, 13, 9078, 526, 15931, 198, 198, 11748, 33918, 198, 11748, 4423, 346, 198, 11748, 20218, 7753, 198, 11748, 555, 715, 395, 198, 6738, 15095, 1330, 15095, 198, 6738, 28686, 1330, 3108, 198, 198, 11748,...
2.583969
262
import logging import sys from metriql2metabase.dbt_metabase import MetabaseClient from metriql2metabase.models.metabase import MetabaseModel, MetabaseColumn, MetabaseMetric
[ 11748, 18931, 198, 11748, 25064, 198, 198, 6738, 1138, 380, 13976, 17, 4164, 5754, 13, 9945, 83, 62, 4164, 5754, 1330, 3395, 5754, 11792, 198, 6738, 1138, 380, 13976, 17, 4164, 5754, 13, 27530, 13, 4164, 5754, 1330, 3395, 5754, 17633, ...
3.45098
51
""" # Clover平台变量机制实现。 # author : taoyanli0808 # date : 2020-05-27 # version: 1.2 # -------------------- Clover平台变量机制 -------------------- # clover平台变量分为4种类型,平台内置变量、自定义变量、触发变量与运行时变量 # 1、平台内置变量 # clover平台内置变量目前有response、request、keyword、variable、exception、 # validator、extractor共7个,详见各模块说明文档。 # 2、自定义变量 # 自定义变量(default)通过...
[ 37811, 198, 2, 41154, 33176, 111, 20998, 108, 20998, 246, 34932, 237, 17312, 118, 26344, 114, 22522, 252, 163, 236, 108, 16764, 198, 2, 1772, 1058, 20486, 726, 272, 4528, 15, 28362, 198, 2, 3128, 220, 220, 1058, 12131, 12, 2713, 12, ...
0.920484
1,157
#!/usr/bin/env python3 from Utils import * if __name__ == "__main__": with open("./p059_cipher.txt", "r") as f: contents = f.read() contents = contents[:-1].split(",") contents = [int(x) for x in contents] print(contents) testContents = contents[:120] candidates = [] # Your code...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 6738, 7273, 4487, 1330, 1635, 198, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 351, 1280, 7, 1911, 14, 79, 46712, 62, 66, 10803, 13, ...
1.983425
724
import io import os.path import tarfile import tempfile from abc import ABC, abstractmethod from typing import List import docker import docker.errors from docker.models.containers import Container from docker.models.volumes import Volume from docker.types import Mount
[ 11748, 33245, 198, 11748, 28686, 13, 6978, 198, 11748, 13422, 7753, 198, 11748, 20218, 7753, 198, 6738, 450, 66, 1330, 9738, 11, 12531, 24396, 198, 6738, 19720, 1330, 7343, 198, 198, 11748, 36253, 198, 11748, 36253, 13, 48277, 198, 6738, ...
4.014493
69
#!/usr/bin/env python from tools.multiclass_shared import prepare_data [traindat, label_traindat, testdat, label_testdat] = prepare_data(False) parameter_list = [[traindat,testdat,label_traindat,label_testdat,2.1,1e-5],[traindat,testdat,label_traindat,label_testdat,2.2,1e-5]] if __name__=='__main__': print('Multi...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 6738, 4899, 13, 16680, 291, 31172, 62, 28710, 1330, 8335, 62, 7890, 628, 198, 198, 58, 27432, 19608, 11, 6167, 62, 27432, 19608, 11, 1332, 19608, 11, 6167, 62, 9288, 19608, 60, 796, ...
2.694805
154
#! /usr/bin/env python # -*- coding: utf-8 -*- # from rpython.rlib import jit file_expr_opts = ["-e", "--eval", "-f", "--load", "-t", "--require", "-l", "--lib", "-p", "-r", "--script", "-u", "--require-script",...
[ 2, 0, 1220, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 198, 6738, 374, 29412, 13, 81, 8019, 1330, 474, 270, 198, 198, 7753, 62, 31937, 62, 404, 912, 796, 14631, 12, ...
1.642079
1,193
from io import BytesIO from io import StringIO import re from urllib.parse import urljoin from pdfminer.pdfinterp import PDFResourceManager, PDFPageInterpreter from pdfminer.converter import TextConverter from pdfminer.layout import LAParams from pdfminer.pdfpage import PDFPage from bs4 import BeautifulSoup from common...
[ 6738, 33245, 1330, 2750, 4879, 9399, 198, 6738, 33245, 1330, 10903, 9399, 198, 11748, 302, 198, 6738, 2956, 297, 571, 13, 29572, 1330, 19016, 22179, 198, 6738, 37124, 1084, 263, 13, 12315, 3849, 79, 1330, 12960, 26198, 13511, 11, 14340, ...
2.520325
369
#! usr/bin/env python # -*- coding: utf-8 -*- """ 爬取 星座屋 星座运势 http://tools.2345.com/naonao/ """ import re from functools import reduce import requests from bs4 import BeautifulSoup from everyday_wechat.utils.common import SPIDER_HEADERS __all__ = ['get_2345_horoscope', 'get_today_horoscope'] XZW_BASE_URL_TOD...
[ 2, 0, 514, 81, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 220, 220, 220, 13328, 230, 105, 20998, 244, 10545, 246, 253, 41753, 100, 161, 109, 233, 10545, 246, 253, ...
1.722754
1,670
from django.db import models from django.db.models.signals import post_save from django.dispatch import receiver from django.conf import settings from django.contrib.auth.models import User from django.contrib.postgres.fields import JSONField, ArrayField import uuid @receiver(post_save, sender=User)
[ 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 6738, 42625, 14208, 13, 9945, 13, 27530, 13, 12683, 874, 1330, 1281, 62, 21928, 198, 6738, 42625, 14208, 13, 6381, 17147, 1330, 9733, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 67...
3.319149
94
# -*- coding: utf-8 -*- """ .. module:: sqlite3_db :platform: Unix :synopsis: I/O for sqlite3 database .. moduleauthor:: Ryan Long <ryanlong1004@gmail.com> """ import os import sqlite3 class Sqlite3: """Gateway for I/O to sqlite 3 database ..todo:: Add context manager so we can close the db """ ...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 492, 8265, 3712, 44161, 578, 18, 62, 9945, 198, 220, 220, 1058, 24254, 25, 33501, 198, 220, 220, 1058, 28869, 24608, 25, 314, 14, 46, 329, 44161, 578, 18, ...
2.003484
861
from mongoengine import fields from mongoengine import DynamicDocument from .sequence import Sequence
[ 6738, 285, 25162, 18392, 1330, 7032, 198, 6738, 285, 25162, 18392, 1330, 26977, 24941, 198, 6738, 764, 43167, 1330, 45835, 628 ]
4.904762
21
print([abs(float(num)) for num in input().split()])
[ 4798, 26933, 8937, 7, 22468, 7, 22510, 4008, 329, 997, 287, 5128, 22446, 35312, 3419, 12962, 201, 198 ]
2.944444
18
from .base import GnuRecipe
[ 6738, 764, 8692, 1330, 18509, 84, 37523, 628 ]
3.625
8
############# # Imports # ############# import globalvars import modules.conf as conf import hashlib import os import shutil import subprocess from urllib.request import urlretrieve ############### # Functions # ############### ########## # Main # ########## if __name__ == "__main__": main()
[ 7804, 4242, 2, 198, 1303, 1846, 3742, 1303, 198, 7804, 4242, 2, 198, 198, 11748, 3298, 85, 945, 198, 11748, 13103, 13, 10414, 355, 1013, 198, 11748, 12234, 8019, 198, 11748, 28686, 198, 11748, 4423, 346, 198, 11748, 850, 14681, 198, 6...
3.234043
94
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.shortcuts import render from django.contrib.auth.forms import UserCreationForm from django.urls import reverse_lazy from django.views.generic import CreateView
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 13, ...
3.024691
81
from django.db import models from django.utils.translation import gettext_lazy as _
[ 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 6738, 42625, 14208, 13, 26791, 13, 41519, 1330, 651, 5239, 62, 75, 12582, 355, 4808, 628 ]
3.541667
24
from django.shortcuts import render from django.http import HttpResponse, HttpResponseRedirect from django.shortcuts import redirect, reverse from django import forms from django.views.decorators.csrf import csrf_exempt from django.contrib.auth.decorators import login_required # Create your views here. # @login_requ...
[ 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 11, 367, 29281, 31077, 7738, 1060, 198, 6738, 42625, 14208, 13, 19509, 23779, 1330, 18941, 11, 9575, 198, 6738, 42625, 14208, 13...
2.848101
158
from django.db import models
[ 6738, 42625, 14208, 13, 9945, 1330, 4981, 628 ]
3.75
8
# getHrs.py # Creator: Robert Toribio # Date: 10/28/2021 import statsapi from datetime import date import re if __name__ == "__main__": main()
[ 2, 651, 39, 3808, 13, 9078, 198, 2, 21038, 25, 5199, 4022, 571, 952, 198, 2, 7536, 25, 838, 14, 2078, 14, 1238, 2481, 628, 198, 11748, 9756, 15042, 198, 6738, 4818, 8079, 1330, 3128, 198, 11748, 302, 628, 628, 220, 220, 220, 220, ...
2.104651
86
#061: Refaça o DESAFIO 51, lendo o primeiro termo e a razão de uma PA, mostrando os 10 primeiros termos da progressão usando a estrutura while. print('=-=' * 15) print(f'{"PROGRESSÃO ARITMÉTICA":^40}') print('=-=' * 15) n = int(input('Digite o 1º termo da PA: ')) r = int(input('Digite a razão: ')) c = n z = 0 while...
[ 2, 3312, 16, 25, 6524, 64, 50041, 267, 22196, 8579, 9399, 6885, 11, 22096, 78, 267, 6994, 7058, 3381, 78, 304, 257, 374, 1031, 28749, 390, 334, 2611, 8147, 11, 749, 25192, 78, 28686, 838, 6994, 72, 4951, 3381, 418, 12379, 4371, 2874...
2.164021
189
"""Provide version and author details.""" __title__ = "steelconnection" __description__ = "Simplify access to the Riverbed SteelConnect REST API." __version__ = "0.95.0" __author__ = "Greg Mueller" __author_email__ = "steelconnection@grelleum.com" __copyright__ = "Copyright 2018 Greg Mueller" __license__ = "MIT" __ur...
[ 37811, 15946, 485, 2196, 290, 1772, 3307, 526, 15931, 628, 198, 834, 7839, 834, 796, 366, 44822, 38659, 1, 198, 834, 11213, 834, 796, 366, 8890, 489, 1958, 1895, 284, 262, 5866, 3077, 7851, 13313, 30617, 7824, 526, 198, 834, 9641, 834...
3.144928
138
import unittest import logging from log_analyzer import * import os import imp if __name__ == "__main__": unittest.main()
[ 11748, 555, 715, 395, 201, 198, 11748, 18931, 201, 198, 6738, 2604, 62, 38200, 9107, 1330, 1635, 201, 198, 11748, 28686, 201, 198, 11748, 848, 201, 198, 201, 198, 201, 198, 201, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, ...
2.537037
54
from Robotic_Servos import * import time import sys import pandas as pd print("--------------------------------------------------------------------") print("README") print("The is the calibration function, help you to calibarate the gripper") print("for different device. Stongly reconmmend you calibarate the g...
[ 6738, 3851, 6210, 62, 11838, 418, 1330, 1635, 201, 198, 11748, 640, 201, 198, 11748, 25064, 201, 198, 11748, 19798, 292, 355, 279, 67, 201, 198, 201, 198, 4798, 7203, 10097, 650, 4943, 201, 198, 4798, 7203, 15675, 11682, 4943, 201, 19...
3.14043
883
import typing as t import warnings from collections.abc import Mapping as ABCMapping from functools import wraps from flask import current_app from flask import jsonify from flask import Response from flask.views import MethodViewType from marshmallow import ValidationError as MarshmallowValidationError from webargs.f...
[ 11748, 19720, 355, 256, 198, 11748, 14601, 198, 6738, 17268, 13, 39305, 1330, 337, 5912, 355, 9738, 44, 5912, 198, 6738, 1257, 310, 10141, 1330, 27521, 198, 198, 6738, 42903, 1330, 1459, 62, 1324, 198, 6738, 42903, 1330, 33918, 1958, 19...
2.254045
6,861
import math import unittest import numpy as np import knee.evaluation as evaluation if __name__ == '__main__': unittest.main()
[ 11748, 10688, 198, 11748, 555, 715, 395, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 10329, 13, 18206, 2288, 355, 12660, 628, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 555, 715, 395, 13, 12...
3.069767
43
import argparse from .openpose.lib.utils.common import Human from typing import Sequence import torch import torch.nn as nn from . import converter from .openpose.lib.network.rtpose_vgg import get_model from .openpose.evaluate.coco_eval import get_outputs from .openpose.lib.utils.paf_to_pose import paf_to_pose_cpp fro...
[ 11748, 1822, 29572, 198, 6738, 764, 9654, 3455, 13, 8019, 13, 26791, 13, 11321, 1330, 5524, 198, 6738, 19720, 1330, 45835, 198, 11748, 28034, 198, 11748, 28034, 13, 20471, 355, 299, 77, 198, 198, 6738, 764, 1330, 38394, 198, 6738, 764, ...
2.433269
517
from __future__ import print_function ############################################################################################ # # The MIT License (MIT) # # Intel AI DevJam IDC Demo Classification Server # Copyright (C) 2018 Adam Milton-Barker (AdamMiltonBarker.com) # # Permission is hereby granted, free of charg...
[ 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 198, 29113, 29113, 14468, 7804, 4242, 198, 2, 198, 2, 383, 17168, 13789, 357, 36393, 8, 198, 2, 220, 198, 2, 8180, 9552, 6245, 30380, 4522, 34, 34588, 40984, 9652, 198, 2, 15069, 357, 3...
3.299599
998
from stapy.sta.time import Time from stapy.sta.abstract_entity import AbstractEntity # TODO resultQuality DQ_Element
[ 6738, 336, 12826, 13, 38031, 13, 2435, 1330, 3862, 198, 6738, 336, 12826, 13, 38031, 13, 397, 8709, 62, 26858, 1330, 27741, 32398, 198, 198, 2, 16926, 46, 1255, 35013, 360, 48, 62, 20180, 198 ]
3.371429
35
import d2bot.visualizer as visualizer import d2bot.core.game_env as game_env import d2bot.simulator as simulator from d2bot.torch.a3c.ActorCritic import ActorCritic import torch import torch.nn as nn import torch.nn.functional as F import torch.optim as optim from torch.autograd import Variable import random import ...
[ 11748, 288, 17, 13645, 13, 41464, 7509, 355, 5874, 7509, 198, 11748, 288, 17, 13645, 13, 7295, 13, 6057, 62, 24330, 355, 983, 62, 24330, 198, 11748, 288, 17, 13645, 13, 14323, 8927, 355, 35375, 198, 198, 6738, 288, 17, 13645, 13, 13...
2.632479
234
import numpy as np import dash from dash.dependencies import Input, Output from plotly.graph_objs import * import dash_core_components as dcc import dash_html_components as html app = dash.Dash() # function to plot # default ranges for x0 & x1 xranges = [[0,1], [-np.pi, np.pi]] # dropdown to pick which x to plot again...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 14470, 198, 6738, 14470, 13, 45841, 3976, 1330, 23412, 11, 25235, 198, 6738, 7110, 306, 13, 34960, 62, 672, 8457, 1330, 1635, 198, 11748, 14470, 62, 7295, 62, 5589, 3906, 355, 288, 535, 198, ...
2.55042
476
''' 统计标注类别和各类别数量 2020.4.21 ''' import operator import sys import argparse import matplotlib.pyplot as plt plt.rcParams['font.sans-serif'] = ['SimHei'] # 用来正常显示中文标签 path = 'D:\wsm\pycharm_pjs\data-analysis\scripts\\traffic_anno.txt' #标注txt文件路径 results_files_path = 'D:\wsm\pycharm_pjs\data-analysis\scripts\...
[ 7061, 6, 201, 198, 163, 119, 253, 164, 106, 94, 43718, 229, 37345, 101, 163, 109, 119, 26344, 104, 161, 240, 234, 28938, 226, 163, 109, 119, 26344, 104, 46763, 108, 34932, 237, 201, 198, 42334, 13, 19, 13, 2481, 201, 198, 7061, 6,...
1.92395
881
import math max = 2000000 primes = [2] for i in xrange(3,max,2): prime = True limit = math.ceil(math.sqrt(i)) # tip from SO for j in xrange(3, int(limit)+1, 2): if prime: if i % j == 0: prime = False if prime: primes.append(i) sum = 0 for prime in primes: sum += prime; print sum;
[ 11748, 10688, 198, 198, 9806, 796, 939, 2388, 198, 198, 1050, 999, 796, 685, 17, 60, 198, 198, 1640, 1312, 287, 2124, 9521, 7, 18, 11, 9806, 11, 17, 2599, 198, 197, 35505, 796, 6407, 198, 197, 32374, 796, 10688, 13, 344, 346, 7, ...
2.20438
137
#!/usr/bin/env python # -*- coding:utf-8 -*- import os #查看操作系统 print os.name #获取工作目录 print os.getcwd() #获取某个目录下的所有文件名 print os.listdir('E:\workspace\Python-oldboy') #运行一个shell命令 调用计算器 # os.system("calc") #删除某个文件 #os.remove("E:\workspace\Python-oldboy\my_study\sys_study") #判断是文件还是文件夹 print ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 201, 198, 2, 532, 9, 12, 19617, 25, 40477, 12, 23, 532, 9, 12, 201, 198, 201, 198, 11748, 28686, 201, 198, 201, 198, 2, 162, 253, 98, 40367, 233, 162, 241, 235, 43291, 163, 111, 119, ...
1.578584
579
"""aws_codeartifact_poetry.helpers.cmd unit tests.""" import os import subprocess import sys from unittest.mock import MagicMock, patch import pytest from _pytest.logging import LogCaptureFixture from aws_codeartifact_poetry.helpers.catch_exceptions import CLIError from aws_codeartifact_poetry.helpers.cmd import exe...
[ 37811, 8356, 62, 8189, 433, 29660, 62, 7501, 11973, 13, 16794, 364, 13, 28758, 4326, 5254, 526, 15931, 198, 198, 11748, 28686, 198, 11748, 850, 14681, 198, 11748, 25064, 198, 6738, 555, 715, 395, 13, 76, 735, 1330, 6139, 44, 735, 11, ...
1.921282
4,929
import os import mimetypes import fnmatch import yaml from genesis.shell import ShellProxy, ProcessQuery from genesis.utils import expand, is_windows from genesis.config import load_yaml from genesis.scm import get_scm # TODO: simplify here
[ 11748, 28686, 198, 11748, 17007, 2963, 12272, 198, 11748, 24714, 15699, 198, 198, 11748, 331, 43695, 198, 198, 6738, 48861, 13, 29149, 1330, 17537, 44148, 11, 10854, 20746, 198, 6738, 48861, 13, 26791, 1330, 4292, 11, 318, 62, 28457, 198,...
3.507042
71
#!/usr/bin/env python # -*- coding: utf-8 -*- import simplejson as json from alipay.aop.api.response.AlipayResponse import AlipayResponse
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 2829, 17752, 355, 33918, 198, 198, 6738, 435, 541, 323, 13, 64, 404, 13, 15042, 13, 26209, 13, 2348, 541, 323,...
2.692308
52
#!/usr/bin/python from flask import Flask, render_template from flask_socketio import SocketIO from flask_restful import Resource, Api app = Flask(__name__) api = Api(app) socketio = SocketIO(app, cors_allowed_origins="*") @app.route('/') api.add_resource(Flag, '/flag') api.add_resource(InternalAPI, '/api/inte...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 198, 6738, 42903, 1330, 46947, 11, 8543, 62, 28243, 198, 6738, 42903, 62, 44971, 952, 1330, 47068, 9399, 198, 6738, 42903, 62, 2118, 913, 1330, 20857, 11, 5949, 72, 628, 198, 1324, 796, 46947...
2.806452
155
import math import numpy as np
[ 11748, 10688, 198, 11748, 299, 32152, 355, 45941, 628, 198 ]
3.3
10
from docs_snippets.concepts.io_management.load_from_config import execute_with_config
[ 6738, 34165, 62, 16184, 3974, 1039, 13, 43169, 82, 13, 952, 62, 27604, 13, 2220, 62, 6738, 62, 11250, 1330, 12260, 62, 4480, 62, 11250, 628 ]
3.346154
26
from typing import Any from app import models, schemas from app.api import deps from app.core.celery_app import celery_app from app.utils.utils import send_test_email from fastapi import APIRouter, Depends from pydantic.networks import EmailStr router = APIRouter() @router.post("/test-celery/", response_model=schem...
[ 6738, 19720, 1330, 4377, 198, 198, 6738, 598, 1330, 4981, 11, 3897, 5356, 198, 6738, 598, 13, 15042, 1330, 390, 862, 198, 6738, 598, 13, 7295, 13, 7015, 88, 62, 1324, 1330, 18725, 1924, 62, 1324, 198, 6738, 598, 13, 26791, 13, 26791...
2.585165
364
''' Simple Client Counter for VLC VLM '''
[ 7061, 6, 198, 26437, 20985, 15034, 329, 569, 5639, 569, 31288, 198, 7061, 6, 628 ]
2.866667
15
import importlib import os import io import logging from setuptools import setup, find_packages from typing import List import pathlib PARENT = pathlib.Path(__file__).parent logger = logging.getLogger(__name__) # Kept manually in sync with dask_pipes.__version__ # noinspection PyUnresolvedReferences spec = importlib...
[ 11748, 1330, 8019, 198, 11748, 28686, 198, 11748, 33245, 198, 11748, 18931, 198, 6738, 900, 37623, 10141, 1330, 9058, 11, 1064, 62, 43789, 198, 6738, 19720, 1330, 7343, 198, 11748, 3108, 8019, 198, 198, 27082, 3525, 796, 3108, 8019, 13, ...
2.60596
302
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Dummy conftest.py for energy_demand. If you don't know what this is for, just leave it empty. Read more about conftest.py under: https://pytest.org/latest/plugins.html """ from __future__ import absolute_import, division, print_function from pytest imp...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 220, 220, 220, 360, 13513, 369, 701, 395, 13, 9078, 329, 2568, 62, 28550, 13, 628, 220, 220, 220, 1002, ...
2.91129
124
# -*- coding: utf-8 -*- """ Created on Wed Jan 26 18:33:09 2022 @author: marco """ import pandas as pd import numpy as np import random import math import os from scipy.linalg import pinv as inv from sklearn.linear_model import Lasso from sklearn.linear_model import LassoCV import matplotlib.pyplot as ...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 201, 198, 37811, 201, 198, 41972, 319, 3300, 2365, 2608, 1248, 25, 2091, 25, 2931, 33160, 201, 198, 201, 198, 31, 9800, 25, 1667, 1073, 201, 198, 37811, 201, 198, 201, 198,...
2.359375
320
import random import json for i in range(10): # print("\n{\"Temperature\":{},\"SOC\":{}}\n".format(48.00, 58.00)); print(json.dumps({'Temperature':random.randint(10,100), 'SOC':random.randint(10,100)}))
[ 11748, 4738, 201, 198, 11748, 33918, 201, 198, 201, 198, 1640, 1312, 287, 2837, 7, 940, 2599, 201, 198, 220, 220, 220, 1303, 3601, 7203, 59, 77, 90, 7879, 42492, 30478, 90, 5512, 7879, 50, 4503, 30478, 90, 11709, 59, 77, 1911, 18982...
2.235294
102
import sys sys.setrecursionlimit(10**6) N, Q = map(int, input().split()) ab = [[int(i) for i in input().split()] for _ in range(N - 1)] cd = [[int(i) for i in input().split()] for _ in range(Q)] G = [[] for _ in range(N)] for a, b in ab: G[a - 1].append(b - 1) G[b - 1].append(a - 1) #Euler tour vs = [-1] * (...
[ 11748, 25064, 198, 198, 17597, 13, 2617, 8344, 24197, 32374, 7, 940, 1174, 21, 8, 198, 198, 45, 11, 1195, 796, 3975, 7, 600, 11, 5128, 22446, 35312, 28955, 198, 397, 796, 16410, 600, 7, 72, 8, 329, 1312, 287, 5128, 22446, 35312, 3...
1.862543
291
from amuse.test import amusetest import pickle from amuse.support.exceptions import AmuseException from amuse.units import core from amuse.units import si from amuse.units import nbody_system from amuse.units import generic_unit_system from amuse.units.quantities import zero from amuse.units.units import * from amus...
[ 6738, 26072, 13, 9288, 1330, 716, 385, 316, 395, 198, 198, 11748, 2298, 293, 198, 198, 6738, 26072, 13, 11284, 13, 1069, 11755, 1330, 1703, 1904, 16922, 198, 198, 6738, 26072, 13, 41667, 1330, 4755, 198, 6738, 26072, 13, 41667, 1330, ...
2.560748
214
# -*- coding: utf-8 -*- """ File Name: model Description : 模型层 Author : mick.yi date: 2019/4/1 """ import keras from keras import layers, Input, Model import tensorflow as tf from east.layers.base_net import resnet50 from east.layers.losses import balanced_cross_entropy, iou_lo...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 201, 198, 37811, 201, 198, 220, 220, 9220, 6530, 171, 120, 248, 220, 220, 220, 220, 2746, 201, 198, 220, 220, 12489, 1058, 10545, 101, 94, 161, 252, 233, 161, 109, 224, 2...
1.803873
2,427
from scipy.special import comb from scipy.special import beta as betafunc import numpy as np
[ 6738, 629, 541, 88, 13, 20887, 1330, 1974, 198, 6738, 629, 541, 88, 13, 20887, 1330, 12159, 355, 731, 1878, 19524, 198, 11748, 299, 32152, 355, 45941, 198 ]
3.321429
28
import os # Build paths inside the project like this: os.path.join(BASE_DIR, ...) BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) PROJECT_ROOT = os.path.dirname(os.path.abspath(__file__)) # Quick-start development settings - unsuitable for production # See https://docs.djangoproject.com/en/1.9/...
[ 11748, 28686, 628, 198, 2, 10934, 13532, 2641, 262, 1628, 588, 428, 25, 28686, 13, 6978, 13, 22179, 7, 33, 11159, 62, 34720, 11, 2644, 8, 198, 33, 11159, 62, 34720, 796, 28686, 13, 6978, 13, 15908, 3672, 7, 418, 13, 6978, 13, 1590...
2.227273
1,804
import re import sys from matplotlib.figure import Figure from matplotlib.backends.backend_qt4agg import FigureCanvasQTAgg as FigureCanvas # alternatives: seaborn, plotnine, from PyQt5.QtCore import Qt,pyqtSignal from PyQt5.QtWidgets import QFormLayout from Orange.widgets.widget import OWWidget, Input from Orange.widg...
[ 11748, 302, 198, 11748, 25064, 198, 6738, 2603, 29487, 8019, 13, 26875, 1330, 11291, 198, 6738, 2603, 29487, 8019, 13, 1891, 2412, 13, 1891, 437, 62, 39568, 19, 9460, 1330, 11291, 6090, 11017, 48, 5603, 1130, 355, 11291, 6090, 11017, 19...
3.282443
131
#################################################################################################################################### #################################################################################################################################### #### #### MIT License #### #### ParaMonte: plain p...
[ 29113, 29113, 29113, 29113, 4242, 198, 29113, 29113, 29113, 29113, 4242, 198, 4242, 198, 4242, 220, 220, 17168, 13789, 198, 4242, 198, 4242, 220, 220, 2547, 64, 9069, 660, 25, 8631, 3665, 10730, 22489, 40089, 5888, 13, 198, 4242, 198, 4...
2.288013
20,447
#!/usr/bin/python # -*- coding: utf-8 -*- # author: IBM Corporation # description: Highly-customizable Ansible module # for installing and configuring IBM Spectrum Scale (GPFS) # company: IBM # license: Apache-2.0 ANSIBLE_METADATA = { 'status': ['preview'], 'supported_by...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 2, 1772, 25, 19764, 10501, 198, 2, 6764, 25, 38254, 12, 23144, 13821, 28038, 856, 8265, 220, 198, 2, 329, 15975, 290, ...
2.732824
1,048
# Branch and bound method import queue class Node: ''' upbound: upbound value of node value: value of current node weight: weight of current node level: level number of the current node on the subset tree ''' upbound = 0 value = 0 weight = 0 level = 0 class ...
[ 2, 20551, 290, 5421, 2446, 201, 198, 11748, 16834, 201, 198, 201, 198, 4871, 19081, 25, 201, 198, 220, 220, 220, 705, 7061, 201, 198, 220, 220, 220, 510, 7784, 25, 510, 7784, 1988, 286, 10139, 201, 198, 220, 220, 220, 1988, 25, 22...
2.354312
429
import numpy as np import dataguzzler as dg import dg_metadata as dgm import dg_file as dgf fin = "/home/linuxadm/usr_local/src/freecad-git032314/build/data/Mod/Robot/Lib/Kuka/kr125_3.wrl" fout = "/tmp/robot.dgs" wfmdict={} fh=open(fin,"r"); wfmdict["robot"]=dg.wfminfo() wfmdict["robot"].Name="robot" wfmdict["rob...
[ 11748, 299, 32152, 355, 45941, 198, 198, 11748, 4818, 363, 4715, 1754, 355, 288, 70, 198, 11748, 288, 70, 62, 38993, 355, 288, 39870, 198, 11748, 288, 70, 62, 7753, 355, 288, 70, 69, 198, 198, 15643, 796, 12813, 11195, 14, 23289, 32...
2.008658
231
from setuptools import setup, find_packages setup( package_dir={"": "src"}, packages=find_packages("src") + ['omero.plugins'], use_scm_version={"write_to": "src/napari_omero/_version.py"}, setup_requires=["setuptools_scm"], )
[ 6738, 900, 37623, 10141, 1330, 9058, 11, 1064, 62, 43789, 198, 198, 40406, 7, 198, 220, 220, 220, 5301, 62, 15908, 28, 4895, 1298, 366, 10677, 25719, 198, 220, 220, 220, 10392, 28, 19796, 62, 43789, 7203, 10677, 4943, 1343, 37250, 296...
2.53125
96
print(part_2())
[ 628, 628, 198, 4798, 7, 3911, 62, 17, 28955, 198 ]
2.1
10
import requests import lxml from bs4 import BeautifulSoup import discord import os token = os.environ.get("S3_KEY") webpage = "https://www.worldometers.info/coronavirus/" # ------------- start data gathering ---------------------- # # ------------- end data gathering ---------------------- # client = discord....
[ 11748, 7007, 198, 11748, 300, 19875, 198, 6738, 275, 82, 19, 1330, 23762, 50, 10486, 198, 11748, 36446, 198, 11748, 28686, 198, 198, 30001, 796, 28686, 13, 268, 2268, 13, 1136, 7203, 50, 18, 62, 20373, 4943, 198, 12384, 7700, 796, 366...
3.391304
115
# -*- coding: utf-8 -*- """Integration/acceptance tests for `ndex2.client` package.""" import os import re import sys import io import time import unittest import json import uuid from datetime import datetime import requests from requests.exceptions import HTTPError import ndex2 from ndex2.nice_cx_network import Ni...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 37811, 34500, 1358, 14, 13635, 590, 5254, 329, 4600, 358, 1069, 17, 13, 16366, 63, 5301, 526, 15931, 198, 198, 11748, 28686, 198, 11748, 302, 198, 11748, 25064, 198...
2.721088
294