content
stringlengths
1
1.04M
input_ids
listlengths
1
774k
ratio_char_token
float64
0.38
22.9
token_count
int64
1
774k
import torch import random import struct from torch import nn from torch.utils.data import TensorDataset, DataLoader from typing import Union def binary_float(num: float, network=True) -> list[float]: """Convert a float to a 32-long list of bits according to IEEE 754. :param: num number to be converted, mu...
[ 11748, 28034, 198, 11748, 4738, 198, 11748, 2878, 198, 6738, 28034, 1330, 299, 77, 198, 6738, 28034, 13, 26791, 13, 7890, 1330, 309, 22854, 27354, 292, 316, 11, 6060, 17401, 198, 6738, 19720, 1330, 4479, 628, 628, 198, 4299, 13934, 62, ...
2.948936
235
import os import pygame from config import DIR_FRAMES_POTENTIAL, DIR_FRAMES_SIGNS, DIR_CROPPED_SIGNS, DIR_FRAMES_NO_SIGNS, IMAGE_HEIGHT, IMAGE_WIDTH, IMAGES_PER_SECOND, CROPPED_SIZE from window import Window, get_rnd_filename, save_cropped if __name__ == "__main__": main()
[ 198, 11748, 28686, 198, 11748, 12972, 6057, 198, 6738, 4566, 1330, 360, 4663, 62, 10913, 29559, 62, 47, 2394, 3525, 12576, 11, 360, 4663, 62, 10913, 29559, 62, 50, 3528, 8035, 11, 360, 4663, 62, 9419, 3185, 47, 1961, 62, 50, 3528, 8...
2.369748
119
########################################################################### # # Copyright 2020 Google LLC # # 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 # # https://www.apache.org/l...
[ 29113, 29113, 7804, 21017, 198, 2, 198, 2, 220, 15069, 12131, 3012, 11419, 198, 2, 198, 2, 220, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 220, 345, 743, 407, 779, 428, 2393, 2845, ...
4.061069
262
#!/usr/bin/python3.4 import socket import pickle import struct import serial import time from datetime import datetime import sys import math import snap7 client = snap7.client.Client() client.connect('137.138.192.181', 0, 0) topo = client.db_read(402,36,1) topo2 = client.db_read(402,44,1) print(hex(topo[0]), h...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 18, 13, 19, 198, 198, 11748, 17802, 198, 11748, 2298, 293, 198, 11748, 2878, 198, 11748, 11389, 198, 11748, 640, 198, 6738, 4818, 8079, 1330, 4818, 8079, 198, 11748, 25064, 198, 11748, 10688, 198, ...
2.271967
239
from django.test import TestCase, override_settings from switchboard.mailer import generate_message TEST_EMAIL_FROM_ADDRESS='noreply@domain.com' @override_settings(EMAIL_FROM_ADDRESS=TEST_EMAIL_FROM_ADDRESS)
[ 6738, 42625, 14208, 13, 9288, 1330, 6208, 20448, 11, 20957, 62, 33692, 198, 6738, 5078, 3526, 13, 4529, 263, 1330, 7716, 62, 20500, 198, 198, 51, 6465, 62, 27630, 4146, 62, 10913, 2662, 62, 2885, 7707, 7597, 11639, 77, 382, 2145, 31, ...
2.705128
78
# ex:ts=4:sw=4:sts=4:et # -*- tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*- """ BitBake Utility Functions """ # Copyright (C) 2004 Michael Lauer # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License version 2 as # published by the F...
[ 2, 409, 25, 912, 28, 19, 25, 2032, 28, 19, 25, 6448, 28, 19, 25, 316, 198, 2, 532, 9, 12, 7400, 12, 10394, 25, 604, 26, 269, 12, 35487, 12, 28968, 25, 604, 26, 33793, 12, 8658, 82, 12, 14171, 25, 18038, 532, 9, 12, 198, 37...
2.122867
9,376
#!/usr/bin/env python import time import argparse import os import socket import math import numpy as np from icecube import (dataio, tableio, astro, toprec, dataclasses, icetray, phys_services, stochastics, millipede, ddddr) from icecube.frame_object_diff.segments import uncompress from I3Tray i...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 11748, 640, 198, 11748, 1822, 29572, 198, 11748, 28686, 198, 11748, 17802, 198, 11748, 10688, 198, 11748, 299, 32152, 355, 45941, 198, 198, 6738, 4771, 40296, 1330, 357, 7890, 952, ...
1.944214
6,274
# Copyright 2018 - Vitrage team # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writi...
[ 2, 15069, 2864, 532, 18271, 8394, 1074, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 345, 743, 198, 2, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, 921, 743, 7...
3.605769
208
from timemachines.skatertools.testing.allregressiontests import REGRESSION_TESTS import time import random TIMEOUT = 60*5 # Regression tests run occasionally to check various parts of hyper-param spaces, etc. if __name__=='__main__': start_time = time.time() elapsed = time.time()-start_time while elapsed ...
[ 6738, 4628, 368, 620, 1127, 13, 8135, 729, 31391, 13, 33407, 13, 439, 2301, 2234, 41989, 1330, 4526, 10761, 47621, 62, 51, 1546, 4694, 198, 11748, 640, 198, 11748, 4738, 198, 34694, 12425, 796, 3126, 9, 20, 198, 198, 2, 3310, 2234, ...
2.661202
183
#!/usr/bin/python """A script for manual testing and experimenting with the ks server. TODO(jlewi): Should we use this as the basis for doing E2E integration testing? We can run the server in a subprocess. Send requests to it and then run various checks on the results. """ import argparse import datetime import loggi...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 37811, 32, 4226, 329, 10107, 4856, 290, 27826, 351, 262, 479, 82, 4382, 13, 628, 198, 51, 3727, 46, 7, 73, 293, 37686, 2599, 10358, 356, 779, 428, 355, 262, 4308, 329, 1804, 198, 36, 17, ...
2.276451
293
import glob import numpy as np import time import zarr import torch import torch.utils.data as data
[ 11748, 15095, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 640, 198, 11748, 1976, 3258, 198, 11748, 28034, 198, 11748, 28034, 13, 26791, 13, 7890, 355, 1366, 628, 198 ]
3.517241
29
# Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT license. import torch import torch.nn as nn import torch.autograd as autograd class CRFLoss(nn.Module): """CRFLoss use for crf output layer for sequence tagging task. """ def _score_sentence(self, scores,...
[ 2, 15069, 357, 66, 8, 5413, 10501, 13, 1439, 2489, 10395, 13, 198, 2, 49962, 739, 262, 17168, 5964, 13, 198, 198, 11748, 28034, 198, 11748, 28034, 13, 20471, 355, 299, 77, 198, 11748, 28034, 13, 2306, 519, 6335, 355, 1960, 519, 6335...
2.275307
1,304
''' Get sha1 hash of a file or string. usage: sha1sum.py [-h] [-c] [file [file ...]] positional arguments: file String or file to hash. optional arguments: -h, --help show this help message and exit -c, --check Check a file with sha1 hashes and file names for a match. format: ...
[ 7061, 6, 198, 3855, 427, 64, 16, 12234, 286, 257, 2393, 393, 4731, 13, 198, 198, 26060, 25, 427, 64, 16, 16345, 13, 9078, 25915, 71, 60, 25915, 66, 60, 685, 7753, 685, 7753, 2644, 11907, 198, 198, 1930, 1859, 7159, 25, 198, 220, ...
2.087957
739
# coding=utf-8 """Configuration""" import os SECRET_KEY: str = os.environ.get('SECRET_KEY', 'SUPER_SECRET') PORT: int = int(os.environ.get('PORT', 5000)) DATABASE_URL: str = os.environ.get('RSES_DB_URL') or os.environ.get('DATABASE_URL') # Do you want a flask client RSES_WEB_CLIENT: bool = True
[ 2, 19617, 28, 40477, 12, 23, 198, 37811, 38149, 37811, 198, 11748, 28686, 198, 198, 23683, 26087, 62, 20373, 25, 965, 796, 28686, 13, 268, 2268, 13, 1136, 10786, 23683, 26087, 62, 20373, 3256, 705, 40331, 1137, 62, 23683, 26087, 11537, ...
2.475
120
import quandl import pandas as pd import numpy as np import datetime from sklearn.linear_model import LinearRegression from sklearn import preprocessing, cross_validation df = quandl.get("WIKI/AMZN") df = df[['Adj. Close']] # print(df) # # exit() forecast_out = int(30) # predicting 30 days into future df['Predi...
[ 11748, 627, 392, 75, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 4818, 8079, 198, 198, 6738, 1341, 35720, 13, 29127, 62, 19849, 1330, 44800, 8081, 2234, 198, 6738, 1341, 35720, 1330, 662, 36948,...
2.680556
360
import logging from itertools import product from force_bdss.api import BaseMCO, DataValue log = logging.getLogger(__name__) def parameter_grid_generator(parameters): """Function to calculate the number of Gromacs experiments required and the combinations of each fragment concentrations""" ranges = [...
[ 11748, 18931, 198, 6738, 340, 861, 10141, 1330, 1720, 198, 198, 6738, 2700, 62, 17457, 824, 13, 15042, 1330, 7308, 44, 8220, 11, 6060, 11395, 628, 198, 6404, 796, 18931, 13, 1136, 11187, 1362, 7, 834, 3672, 834, 8, 628, 198, 198, 42...
2.759076
303
# Licensed under a 3-clause BSD style license - see LICENSE.rst from __future__ import division import re import os import logging from pathlib import Path import numpy as np from Chandra.Time import DateTime ORBIT_POINTS_DTYPE = [('date', 'U21'), ('name', 'U8'), ('orbit_num', 'i4'), ('descr...
[ 2, 49962, 739, 257, 513, 12, 565, 682, 347, 10305, 3918, 5964, 532, 766, 38559, 24290, 13, 81, 301, 198, 6738, 11593, 37443, 834, 1330, 7297, 198, 198, 11748, 302, 198, 11748, 28686, 198, 11748, 18931, 198, 6738, 3108, 8019, 1330, 106...
2.08831
8,289
#!/usr/bin/env python """ ZMQ proxy for info queues. Publish Queue: tcp:5550 """ import zmq # these are the ports we are doing proxy for proxies = ['5551'] if __name__ == '__main__': main_proxy_info()
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 37811, 198, 198, 57, 49215, 15741, 329, 7508, 43359, 13, 220, 198, 14876, 1836, 4670, 518, 25, 48265, 25, 2816, 1120, 198, 198, 37811, 198, 11748, 1976, 76, 80, 198, 198, 2, 777, 389...
2.573171
82
import pkg_resources, subprocess import os def get_all_pythons(): '''https://stackoverflow.com/a/52123490''' output, err = subprocess.Popen( ['which', '-a', 'python', 'python3','python2'], stdout=subprocess.PIPE, stderr=subprocess.PIPE ).communicate() return output.decode('utf8').s...
[ 11748, 279, 10025, 62, 37540, 11, 850, 14681, 198, 11748, 28686, 198, 198, 4299, 651, 62, 439, 62, 79, 5272, 684, 33529, 198, 220, 220, 220, 705, 7061, 5450, 1378, 25558, 2502, 11125, 13, 785, 14, 64, 14, 4309, 1065, 2682, 3829, 706...
2.27027
148
""" Augment the dataset according to the loss functions. Input: - a regression data set (x, a, y), which may be obtained using the data_parser - loss function - Theta, a set of thresholds in between 0 and 1 Output: a weighted classification dataset (X, A, Y, W) """ import functools import numpy as np import pandas a...
[ 37811, 198, 12512, 434, 262, 27039, 1864, 284, 262, 2994, 5499, 13, 198, 198, 20560, 25, 198, 12, 257, 20683, 1366, 900, 357, 87, 11, 257, 11, 331, 828, 543, 743, 307, 6492, 1262, 262, 1366, 62, 48610, 198, 12, 2994, 2163, 198, 12...
2.329189
1,689
assert unique('aa') == False assert unique('abadkjsld') == False assert unique('aa') == False assert unique('fsl') == True
[ 198, 30493, 3748, 10786, 7252, 11537, 6624, 10352, 198, 30493, 3748, 10786, 17325, 74, 8457, 335, 11537, 6624, 10352, 198, 30493, 3748, 10786, 7252, 11537, 6624, 10352, 198, 30493, 3748, 10786, 69, 6649, 11537, 6624, 6407 ]
3.416667
36
# Copyright (C) 2019-2021, TomTom (http://tomtom.com). # # 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 o...
[ 2, 15069, 357, 34, 8, 13130, 12, 1238, 2481, 11, 4186, 13787, 357, 4023, 1378, 39532, 39532, 13, 785, 737, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407,...
2.764353
2,003
#!/usr/bin/python # encoding: utf-8 import os import json from time import sleep import signal import requests import re from werkzeug import secure_filename from flask import (Flask, request, render_template, session, redirect, url_for, escape, send_from_directory, Blueprint, abort) new_jp = Blueprint('webhooks',...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 2, 21004, 25, 3384, 69, 12, 23, 198, 11748, 28686, 198, 11748, 33918, 198, 6738, 640, 1330, 3993, 198, 11748, 6737, 198, 11748, 7007, 198, 11748, 302, 198, 6738, 266, 9587, 2736, 1018, 1330, ...
3.08871
124
import os import random import numpy as np import torch import torch.distributed as distributed from torch.nn import SyncBatchNorm from zerovl.models import PIPELINE from zerovl.utils import ENV, build_from_cfg from zerovl.utils import ( is_list_of, logger ) try: from apex.parallel import convert_syncbn_...
[ 11748, 28686, 198, 11748, 4738, 198, 11748, 299, 32152, 355, 45941, 198, 198, 11748, 28034, 198, 11748, 28034, 13, 17080, 6169, 355, 9387, 198, 6738, 28034, 13, 20471, 1330, 35908, 33, 963, 35393, 198, 198, 6738, 1976, 263, 709, 75, 13,...
2.681063
301
''' tests for the serializers ''' # from django.test import TestCase from unittest import TestCase, main from .serializers import _get_attr_value, UserLDAPSerializer from .models import User from django.conf import settings LDAP_USER_EXAMPLE = ('uid=chiahsuanyang,ou=People,dc=adrf,dc=info', { ...
[ 7061, 6, 5254, 329, 262, 11389, 11341, 705, 7061, 198, 2, 422, 42625, 14208, 13, 9288, 1330, 6208, 20448, 198, 6738, 555, 715, 395, 1330, 6208, 20448, 11, 1388, 198, 6738, 764, 46911, 11341, 1330, 4808, 1136, 62, 35226, 62, 8367, 11, ...
1.653722
1,236
from tkinter import * import tkinter.messagebox as tmsg root = Tk() root.title("Place Order") root.geometry("400x400") scrollbar = Scrollbar(root) scrollbar.pack(side= RIGHT, fill = Y) lbx = Listbox(root, yscrollcommand = scrollbar.set) # lbx.insert(1, "firstItem") # lbx.insert(2, "secondItem") # lbx.insert(3, "thir...
[ 6738, 256, 74, 3849, 1330, 1635, 198, 11748, 256, 74, 3849, 13, 20500, 3524, 355, 256, 19662, 198, 15763, 796, 309, 74, 3419, 198, 15763, 13, 7839, 7203, 27271, 8284, 4943, 198, 15763, 13, 469, 15748, 7203, 7029, 87, 7029, 4943, 198, ...
2.575758
231
#!/usr/bin/python3 # mari von steinkirch @2013 # steinkirch at gmail import string def delete_unique_word(str1): ''' find and delete all the duplicate characters in a string ''' # create ordered dict table_c = { key : 0 for key in string.ascii_lowercase} # fill the table with the chars in the ...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 18, 198, 2, 1667, 72, 18042, 2876, 676, 343, 354, 2488, 6390, 198, 2, 2876, 676, 343, 354, 379, 308, 4529, 198, 198, 11748, 4731, 198, 198, 4299, 12233, 62, 34642, 62, 4775, 7, 2536, 16, 2599,...
2.388235
255
''' This script solves the exercises of days that have been completed. Jut in case the students did not made it by their own. ''' import sys import urllib2 def download_and_replace(url, target_file): ''' Downloads file through http with progress report. Version by PabloG obtained in stack overflow ...
[ 7061, 6, 198, 1212, 4226, 39107, 262, 13565, 286, 1528, 326, 423, 587, 5668, 13, 449, 315, 287, 1339, 198, 1169, 2444, 750, 407, 925, 340, 416, 511, 898, 13, 198, 7061, 6, 198, 11748, 25064, 198, 11748, 2956, 297, 571, 17, 198, 19...
2.063946
1,470
"""Module of app configuration""" import os basedir = os.path.abspath(os.path.dirname(__file__)) class Config: """Class of configuration""" # Form SECRET_KEY = os.environ.get('SECRET_KEY') or \ b'\x876\xeb_\xc9<?\xb8r\xcak\r[\xa0\xf4\xfe\xdbP\xae\x17\x15S\xa5^' # Mail MAIL_SERVER...
[ 37811, 26796, 286, 598, 8398, 37811, 198, 11748, 28686, 198, 3106, 343, 796, 28686, 13, 6978, 13, 397, 2777, 776, 7, 418, 13, 6978, 13, 15908, 3672, 7, 834, 7753, 834, 4008, 628, 198, 4871, 17056, 25, 198, 220, 220, 220, 37227, 9487...
2.303465
837
# coding: utf8 import sys from setuptools import find_packages, setup from setuptools.command.test import test as TestCommand setup( name="dogerpc", version="0.1.4", description="A RPC Framework", long_description=open("README.md").read(), long_description_content_type="text/markdown", auth...
[ 2, 19617, 25, 3384, 69, 23, 198, 198, 11748, 25064, 198, 198, 6738, 900, 37623, 10141, 1330, 1064, 62, 43789, 11, 9058, 198, 6738, 900, 37623, 10141, 13, 21812, 13, 9288, 1330, 1332, 355, 6208, 21575, 628, 198, 198, 40406, 7, 198, 2...
2.607748
413
""" Adaptor for reading and writing any generic text file. This is a good example of a very simple adaptor class. """ from .adaptor import Adaptor, SleapObjectType from .filehandle import FileHandle
[ 37811, 198, 48003, 273, 329, 3555, 290, 3597, 597, 14276, 2420, 2393, 13, 198, 198, 1212, 318, 257, 922, 1672, 286, 257, 845, 2829, 6068, 273, 1398, 13, 198, 37811, 198, 198, 6738, 764, 42552, 273, 1330, 30019, 273, 11, 19498, 499, ...
3.811321
53
#rearrangeNumber(kg, s, v) # # #(kg, s, v) = extractNumber('ref.txt') #(kgs_c, kgr_c, ss_c, sr_c, vs_c, vr_c) = rearrangeNumber(kg, s, v) #kg_matrix = addToMatrix(kg_matrix, kgs_c, kgr_c, 0) #s_matrix = addToMatrix(s_matrix, ss_c, sr_c, 0) #v_matrix = addToMatrix(v_matrix, vs_c, vr_c,...
[ 201, 198, 2, 260, 3258, 858, 15057, 7, 10025, 11, 264, 11, 410, 8, 201, 198, 201, 198, 201, 198, 201, 198, 2, 201, 198, 2, 201, 198, 220, 220, 220, 1303, 7, 10025, 11, 264, 11, 410, 8, 796, 7925, 15057, 10786, 5420, 13, 14116,...
1.750809
618
#!/usr/bin/env python import load from gna.bundle import execute_bundle from gna.configurator import NestedDict, uncertaindict, uncertain from gna.env import env # # Bundle configuration # cfg = NestedDict( bundle = dict( name='parameters', version='ex01', ), pars = uncertaindict( ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 11748, 3440, 198, 6738, 308, 2616, 13, 65, 31249, 1330, 12260, 62, 65, 31249, 198, 6738, 308, 2616, 13, 11250, 333, 1352, 1330, 399, 7287, 35, 713, 11, 8627, 11600, 11, 8627, 19...
2.07438
363
from django.conf.urls import url from django.contrib import admin from message import views # template tagging for relative url app_name = 'message' urlpatterns = [ url(r'^$', views.home, name='home'), url(r'^inbox$', views.inbox, name='inbox'), url(r'^outbox$', views.outbox, name='outbox'), url(r'^compo...
[ 6738, 42625, 14208, 13, 10414, 13, 6371, 82, 1330, 19016, 198, 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 6738, 3275, 1330, 5009, 198, 198, 2, 11055, 49620, 329, 3585, 19016, 198, 1324, 62, 3672, 796, 705, 20500, 6, 198, 198...
2.654412
136
# Copyright (C) 2022 Intel Corporation # SPDX-License-Identifier: Apache-2.0 # from mmcls.datasets.builder import DATASETS from .multi_cls_dataset import MultiClsDataset from .cls_csv_dataset import CSVDatasetCls from mpa.modules.utils.task_adapt import map_class_names import numpy as np @DATASETS.register_module() ...
[ 2, 15069, 357, 34, 8, 33160, 8180, 10501, 198, 2, 30628, 55, 12, 34156, 12, 33234, 7483, 25, 24843, 12, 17, 13, 15, 198, 2, 198, 198, 6738, 8085, 565, 82, 13, 19608, 292, 1039, 13, 38272, 1330, 360, 1404, 1921, 32716, 198, 6738, ...
2.734375
128
# Should be smallest now n=input print("IO hb,e cmoym ek etyhbeo agrudy!. "[int(n())>len(set(n().split()[1:]+n().split()[1:]))::2])
[ 2, 10358, 307, 18197, 783, 198, 198, 77, 28, 15414, 198, 4798, 7203, 9399, 289, 65, 11, 68, 12067, 726, 76, 304, 74, 304, 774, 71, 1350, 78, 556, 81, 463, 88, 43179, 12878, 600, 7, 77, 28955, 29, 11925, 7, 2617, 7, 77, 22446, ...
2.095238
63
# Configuration file for the Sphinx documentation builder. # # This file only contains a selection of the most common options. For a full # list see the documentation: # https://www.sphinx-doc.org/en/master/usage/configuration.html # -- Path setup -------------------------------------------------------------- # If ex...
[ 2, 28373, 2393, 329, 262, 45368, 28413, 10314, 27098, 13, 198, 2, 198, 2, 770, 2393, 691, 4909, 257, 6356, 286, 262, 749, 2219, 3689, 13, 1114, 257, 1336, 198, 2, 1351, 766, 262, 10314, 25, 198, 2, 3740, 1378, 2503, 13, 82, 746, ...
3.284855
997
from sevenbridges.meta.fields import StringField from sevenbridges.meta.resource import Resource class VolumeFile(Resource): """ VolumeFile resource describes the location of the file on the external volume. """ volume = StringField(read_only=True) location = StringField(read_only=True)
[ 6738, 3598, 10236, 3212, 13, 28961, 13, 25747, 1330, 10903, 15878, 198, 6738, 3598, 10236, 3212, 13, 28961, 13, 31092, 1330, 20857, 628, 198, 4871, 14701, 8979, 7, 26198, 2599, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 14701, 8979,...
3.376344
93
from common.webdriver_factory import get_driver from selenium.webdriver.support.wait import WebDriverWait from selenium.webdriver.support import expected_conditions as EC from selenium.webdriver.common.by import By driver = get_driver('chrome') wait = WebDriverWait(driver, 5) driver.get('https://www.mlb.com/es/standin...
[ 6738, 2219, 13, 12384, 26230, 62, 69, 9548, 1330, 651, 62, 26230, 198, 6738, 384, 11925, 1505, 13, 12384, 26230, 13, 11284, 13, 17077, 1330, 5313, 32103, 21321, 198, 6738, 384, 11925, 1505, 13, 12384, 26230, 13, 11284, 1330, 2938, 62, ...
3.238095
105
from core.modules import BaseClass
[ 6738, 4755, 13, 18170, 1330, 7308, 9487, 628 ]
4.5
8
# Generated by Django 2.1.1 on 2018-10-09 01:31 from django.db import migrations, models
[ 2, 2980, 515, 416, 37770, 362, 13, 16, 13, 16, 319, 2864, 12, 940, 12, 2931, 5534, 25, 3132, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 628 ]
2.84375
32
"""Pass."""
[ 37811, 14478, 526, 15931, 198 ]
2.4
5
import numpy as np from gym.spaces import Box from metaworld.envs import reward_utils from metaworld.envs.asset_path_utils import full_v2_path_for from metaworld.envs.mujoco.sawyer_xyz.sawyer_xyz_env import SawyerXYZEnv, _assert_task_is_set
[ 11748, 299, 32152, 355, 45941, 198, 6738, 11550, 13, 2777, 2114, 1330, 8315, 198, 198, 6738, 1138, 707, 1764, 13, 268, 14259, 1330, 6721, 62, 26791, 198, 6738, 1138, 707, 1764, 13, 268, 14259, 13, 562, 316, 62, 6978, 62, 26791, 1330, ...
2.641304
92
from metarl.envs import MetaRLEnv from metarl.experiment import LocalTFRunner from metarl.np.algos import CMAES from metarl.np.baselines import LinearFeatureBaseline from metarl.sampler import OnPolicyVectorizedSampler from metarl.tf.policies import CategoricalMLPPolicy from tests.fixtures import snapshot_config, TfGra...
[ 6738, 1138, 7063, 13, 268, 14259, 1330, 30277, 49, 2538, 48005, 198, 6738, 1138, 7063, 13, 23100, 3681, 1330, 10714, 10234, 49493, 198, 6738, 1138, 7063, 13, 37659, 13, 14016, 418, 1330, 327, 5673, 1546, 198, 6738, 1138, 7063, 13, 37659...
3.42268
97
import testutils import json import psycopg2
[ 11748, 1332, 26791, 198, 11748, 33918, 198, 11748, 17331, 22163, 70, 17, 628, 628 ]
3.428571
14
# -*- coding: utf-8 -*- from __future__ import print_function, division, absolute_import import unittest from flypy import jit, ijit #===------------------------------------------------------------------=== # Tests #===------------------------------------------------------------------=== if __name__ == '__main__': ...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 11, 7297, 11, 4112, 62, 11748, 198, 198, 11748, 555, 715, 395, 198, 198, 6738, 6129, 9078, 1330, 474, 270, 11, 1312, 450...
4.084337
83
# Copyright 2021 Google LLC # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, ...
[ 2, 15069, 33448, 3012, 11419, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, 198, 2, 921, 743, 733...
2.585155
1,738
from helpfuncs import bitdecoding # initialize and fill list for set based on base relations bsplit = [(len(bitdecoding(i+1)),bitdecoding(i+1)) for i in xrange(255)]
[ 6738, 1037, 12543, 6359, 1330, 1643, 12501, 7656, 198, 198, 2, 41216, 290, 6070, 1351, 329, 900, 1912, 319, 2779, 2316, 198, 1443, 489, 270, 796, 47527, 11925, 7, 2545, 12501, 7656, 7, 72, 10, 16, 36911, 2545, 12501, 7656, 7, 72, 10...
3.111111
54
SECRET_KEY = "changeme please"
[ 23683, 26087, 62, 20373, 796, 366, 354, 648, 34755, 3387, 1, 198 ]
2.583333
12
from server.controller.controllers import RobotController, TextRobot
[ 6738, 4382, 13, 36500, 13, 3642, 36667, 1330, 16071, 22130, 11, 8255, 14350, 313, 628, 198 ]
4.4375
16
mystring = mystring.expandtabs()
[ 1820, 8841, 796, 616, 8841, 13, 11201, 392, 8658, 82, 3419, 198 ]
2.75
12
from app import app from app import controller from flask import request control = controller.Controller() @app.route('/api/login', methods=['POST']) @app.route('/api/logout') @app.route('/mailboxes') @app.route('/search_emails') @app.route('/emails') @app.route('/email')
[ 6738, 598, 1330, 598, 198, 6738, 598, 1330, 10444, 198, 6738, 42903, 1330, 2581, 628, 198, 13716, 796, 10444, 13, 22130, 3419, 628, 198, 31, 1324, 13, 38629, 10786, 14, 15042, 14, 38235, 3256, 5050, 28, 17816, 32782, 6, 12962, 628, 19...
2.89899
99
# Generated by Django 3.2.3 on 2021-05-14 07:39 from django.db import migrations
[ 2, 2980, 515, 416, 37770, 513, 13, 17, 13, 18, 319, 33448, 12, 2713, 12, 1415, 8753, 25, 2670, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 628 ]
2.766667
30
""" gathering of blocks/group of layers used in domainnet. author: David-Alexandre Beaupre date: 2020-04-27 """ import torch import torch.nn as nn import torch.nn.functional as F
[ 37811, 198, 70, 25545, 286, 7021, 14, 8094, 286, 11685, 973, 287, 7386, 3262, 13, 198, 198, 9800, 25, 3271, 12, 15309, 49078, 32831, 3866, 198, 4475, 25, 12131, 12, 3023, 12, 1983, 198, 37811, 198, 198, 11748, 28034, 198, 11748, 28034...
3.172414
58
from os.path import split, join, abspath, exists from os import environ class PathHelper: """This class provides a set of assisting functions to deal with path issues.""" @classmethod def abspath_of_executable(cls, path: str): """Given a command that can run in shell (with the current environ...
[ 6738, 28686, 13, 6978, 1330, 6626, 11, 4654, 11, 2352, 6978, 11, 7160, 198, 6738, 28686, 1330, 551, 2268, 628, 198, 4871, 10644, 47429, 25, 198, 220, 220, 220, 37227, 1212, 1398, 3769, 257, 900, 286, 26508, 5499, 284, 1730, 351, 198, ...
2.20197
609
# Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may...
[ 2, 220, 49962, 284, 262, 24843, 10442, 5693, 357, 1921, 37, 8, 739, 530, 198, 2, 220, 393, 517, 18920, 5964, 11704, 13, 220, 4091, 262, 28536, 2393, 198, 2, 220, 9387, 351, 428, 670, 329, 3224, 1321, 198, 2, 220, 5115, 6634, 9238,...
3.357782
559
# Copyright (c) 2020, NVIDIA CORPORATION. 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 applic...
[ 2, 15069, 357, 66, 8, 12131, 11, 15127, 23929, 44680, 6234, 13, 1439, 2489, 10395, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 284...
3.871345
171
import numpy as np import torch
[ 11748, 299, 32152, 355, 45941, 198, 11748, 28034, 628, 628, 628 ]
3.363636
11
import re import hashlib import requests import cv2 import numpy as np from bs4 import BeautifulSoup from SunGazer.Collectors.Camera import Cam class GeoVisionCam(Cam): """ GeoVision IP camera class. """ def __init__(self, cam_address): """ Construct a cam object. Parameters...
[ 11748, 302, 198, 11748, 12234, 8019, 198, 198, 11748, 7007, 198, 11748, 269, 85, 17, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 275, 82, 19, 1330, 23762, 50, 10486, 198, 198, 6738, 3825, 38, 19178, 13, 31337, 669, 13, 35632, 1330,...
1.974144
1,431
from ipywidgets import DOMWidget from traitlets import Unicode, Int
[ 6738, 20966, 88, 28029, 11407, 1330, 24121, 38300, 198, 6738, 1291, 2578, 912, 1330, 34371, 11, 2558, 198 ]
3.777778
18
#!/usr/bin/env python #pythonlib import os import re import sys import math import time import glob import numpy import shutil import subprocess #appion from appionlib import apFile from appionlib import apParam from appionlib import apImage from appionlib import apDisplay from appionlib import apDatabase from appionl...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 2, 29412, 8019, 198, 11748, 28686, 198, 11748, 302, 198, 11748, 25064, 198, 11748, 10688, 198, 11748, 640, 198, 11748, 15095, 198, 11748, 299, 32152, 198, 11748, 4423, 346, 198, 117...
3.203557
506
#Importing os module and defining application's path import os basedir = os.path.abspath(os.path.dirname(__file__)) DEBUG = True SQLALCHEMY_ECHO = True #Cross-site_request_forgery_(CSRF)_protection_provided_by_WTforms WTF_CSRF_ENABLED = True #The secret key that scrf uses for authentication SECRET_KEY = '...
[ 2, 20939, 278, 28686, 8265, 290, 16215, 3586, 338, 3108, 201, 198, 11748, 28686, 201, 198, 3106, 343, 796, 28686, 13, 6978, 13, 397, 2777, 776, 7, 418, 13, 6978, 13, 15908, 3672, 7, 834, 7753, 834, 4008, 201, 198, 201, 198, 30531, ...
2.604167
288
#coding=utf-8 import logging import hashlib import urlparse import random from django.core.urlresolvers import reverse from django.utils import timezone from django.conf import settings from django.contrib.auth.models import User, Permission from django.db import models from django.utils.translation import ugettext_l...
[ 2, 66, 7656, 28, 40477, 12, 23, 198, 198, 11748, 18931, 198, 11748, 12234, 8019, 198, 11748, 19016, 29572, 198, 11748, 4738, 198, 198, 6738, 42625, 14208, 13, 7295, 13, 6371, 411, 349, 690, 1330, 9575, 198, 6738, 42625, 14208, 13, 267...
2.714583
480
# -*- coding: utf-8 -*- import json import datetime from geoposition import Geoposition from web.processors.event import create_or_update_event
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 33918, 198, 11748, 4818, 8079, 198, 198, 6738, 30324, 3507, 1330, 2269, 404, 3507, 198, 198, 6738, 3992, 13, 14681, 669, 13, 15596, 1330, 2251, 62, 273, 62, 19119...
3.12766
47
#coding=utf-8 # # # Copyright (C) 2013 INAF -IRA Italian institute of radioastronomy, bartolini@ira.inaf.it # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of th...
[ 2, 66, 7656, 28, 40477, 12, 23, 198, 198, 2, 198, 2, 198, 2, 220, 220, 220, 15069, 357, 34, 8, 2211, 220, 3268, 8579, 532, 40, 3861, 8200, 24224, 286, 5243, 459, 1313, 9145, 11, 30539, 43232, 31, 8704, 13, 1437, 69, 13, 270, 1...
2.270921
4,278
#!/usr/bin/env python # -*- coding: utf-8 -*- ''' ## © Copyright (C) 2016-2020 Xilinx, Inc ## ## Licensed under the Apache License, Version 2.0 (the "License"). You may ## not use this file except in compliance with the License. A copy of the ## License is located at ## ## http://www.apache.org/licenses/LICENSE-2....
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 7061, 6, 198, 2235, 10673, 15069, 357, 34, 8, 1584, 12, 42334, 1395, 346, 28413, 11, 3457, 198, 2235, 198, 2235,...
2.521173
921
import os from yattag import Doc, indent from libs.utils import create_stamped_temp, slugify import matplotlib.pyplot as plt # NOTE - Does not work out of the box, needs a fix: # # Annoyingly, the js loading of subpages violates Cross-Origin Requests policy in all browsers # when files are served locally via f...
[ 11748, 28686, 201, 198, 6738, 331, 1078, 363, 1330, 14432, 11, 33793, 201, 198, 6738, 9195, 82, 13, 26791, 1330, 2251, 62, 301, 13322, 62, 29510, 11, 31065, 1958, 201, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 201,...
3.092664
518
version = '2.3.1' version_cmd = 'elasticsearch -version' download_url = 'http://packages.elasticsearch.org/GPG-KEY-elasticsearch' install_script = """ apt-key add GPG-KEY-elasticsearch echo "deb http://packages.elasticsearch.org/elasticsearch/VERSION/debian stable main" > /etc/apt/sources.list.d/elasticsearch.list apt-...
[ 9641, 796, 705, 17, 13, 18, 13, 16, 6, 198, 9641, 62, 28758, 796, 705, 417, 3477, 12947, 532, 9641, 6, 198, 15002, 62, 6371, 796, 705, 4023, 1378, 43789, 13, 417, 3477, 12947, 13, 2398, 14, 38, 6968, 12, 20373, 12, 417, 3477, 12...
3.053435
131
# Converts a 'str.out' file to the VASP POSCAR format. # # Assumes: # + You have installed the "ase" python package. # + You have the "str2cif" tool from ATAT in your path. # # Author: Jesper Kristensen import os, sys from ase import io #=== USER SETTINGS: structure_from = 'str.out' structure_to = 'str...
[ 2, 220, 220, 1482, 24040, 257, 705, 2536, 13, 448, 6, 2393, 284, 262, 569, 1921, 47, 28069, 20034, 5794, 13, 198, 2, 198, 2, 220, 220, 2195, 8139, 25, 198, 2, 220, 220, 1343, 921, 423, 6589, 262, 366, 589, 1, 21015, 5301, 13, ...
2.666667
372
import logging from iribaker import to_iri from rdflib import URIRef, Literal, Namespace from representation import Predicate, Entity, Triple, Provenance logger = logging.getLogger(__name__)
[ 11748, 18931, 198, 198, 6738, 4173, 571, 3110, 1330, 284, 62, 14783, 198, 6738, 374, 67, 2704, 571, 1330, 37902, 4663, 891, 11, 25659, 1691, 11, 28531, 10223, 198, 198, 6738, 10552, 1330, 14322, 5344, 11, 20885, 11, 19817, 11, 1041, 5...
3.305085
59
from .platform import OS from .windows.win import winPass from .linUni.linUni import linUniPass from .manager import Manager import inquirer if __name__ == "__main__": main()
[ 6738, 764, 24254, 1330, 7294, 198, 6738, 764, 28457, 13, 5404, 1330, 1592, 14478, 198, 6738, 764, 2815, 3118, 72, 13, 2815, 3118, 72, 1330, 9493, 3118, 72, 14478, 198, 6738, 764, 37153, 1330, 9142, 198, 11748, 38212, 81, 628, 198, 198...
3.05
60
import os from logging import Logger from typing import Dict, Optional from src.app.io import (get_checkpoints_dir, get_train_log_file, get_train_logs_dir, load_trainset, load_valset, save_prep_name, save_testset, save_trainset, save_valset) from ...
[ 11748, 28686, 198, 6738, 18931, 1330, 5972, 1362, 198, 6738, 19720, 1330, 360, 713, 11, 32233, 198, 198, 6738, 12351, 13, 1324, 13, 952, 1330, 357, 1136, 62, 9122, 13033, 62, 15908, 11, 651, 62, 27432, 62, 6404, 62, 7753, 11, 198, 2...
2.266795
521
"""Template class.""" import os # For Mypy typing from typing import Any # noqa pylint: disable=unused-import from typing import Dict # noqa pylint: disable=unused-import import jinja2 class Template(object): # pylint: disable=too-few-public-methods """Represents tepmplate which can be rendered.""" def...
[ 37811, 30800, 1398, 526, 15931, 198, 11748, 28686, 198, 198, 2, 1114, 2011, 9078, 19720, 198, 6738, 19720, 1330, 4377, 220, 1303, 645, 20402, 279, 2645, 600, 25, 15560, 28, 403, 1484, 12, 11748, 198, 6738, 19720, 1330, 360, 713, 220, ...
2.454741
464
import datetime from django.shortcuts import render from django.http import HttpResponse from django.db.models import F from django.conf import settings from models import Counter
[ 11748, 4818, 8079, 198, 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 198, 6738, 42625, 14208, 13, 9945, 13, 27530, 1330, 376, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460,...
3.8125
48
""" Polarisation animation... the animate_vectors() method creates an interactive 3D plot, visualising the resultant polarisation for a given input of Ex, Ey and the phase difference (in radians) between them Last updated 2018-02-19 JK """ # py 2.7 compatibility from __future__ import (division, print_function, absol...
[ 37811, 198, 47, 6192, 5612, 11034, 986, 198, 198, 1169, 43828, 62, 303, 5217, 3419, 2446, 8075, 281, 14333, 513, 35, 7110, 11, 5874, 1710, 262, 43440, 13559, 5612, 329, 257, 198, 35569, 5128, 286, 1475, 11, 21566, 290, 262, 7108, 3580...
3
275
# Generated by Django 3.1.7 on 2021-08-10 17:14 from django.db import migrations, models import django.db.models.deletion
[ 2, 2980, 515, 416, 37770, 513, 13, 16, 13, 22, 319, 33448, 12, 2919, 12, 940, 1596, 25, 1415, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 198, 11748, 42625, 14208, 13, 9945, 13, 27530, 13, 2934, 1616, 295, ...
2.818182
44
import logging import torch import torch.nn as nn import torchtext import os from torch.autograd import Variable from tqdm import tqdm from tensorboardX import SummaryWriter from typing import List from framenet_tools.config import ConfigManager
[ 11748, 18931, 198, 11748, 28034, 198, 11748, 28034, 13, 20471, 355, 299, 77, 198, 11748, 28034, 5239, 198, 11748, 28686, 198, 198, 6738, 28034, 13, 2306, 519, 6335, 1330, 35748, 198, 6738, 256, 80, 36020, 1330, 256, 80, 36020, 198, 6738...
3.676471
68
#!/usr/bin/env python # Ymake MatrixNet support import sys import os import shutil import re import subprocess if __name__ == '__main__': if len(sys.argv) < 2: print >>sys.stderr, "Usage: build_mn.py <funcName> <args...>" sys.exit(1) if (sys.argv[2:]): globals()[sys.argv[1]]...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 575, 15883, 24936, 7934, 1104, 198, 198, 11748, 25064, 198, 11748, 28686, 198, 11748, 4423, 346, 198, 11748, 302, 198, 11748, 850, 14681, 628, 628, 628, 628, 628, 198, 198, 361, 115...
2.1
180
# Generated by Django 3.2.9 on 2022-01-20 19:34 from django.conf import settings import django.core.validators from django.db import migrations, models import django.db.models.deletion import uuid
[ 2, 2980, 515, 416, 37770, 513, 13, 17, 13, 24, 319, 33160, 12, 486, 12, 1238, 678, 25, 2682, 198, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 11748, 42625, 14208, 13, 7295, 13, 12102, 2024, 198, 6738, 42625, 14208, 13, 9945...
3.061538
65
if __name__=='__main__': n,m = map(int,input().split()) arr = list(map(int,input().split())) brr = list(map(int,input().split())) count = 0 for i in range(max(arr),min(brr)+1): flag = True for j in arr: if i%j!=0: flag = False break ...
[ 361, 11593, 3672, 834, 855, 6, 834, 12417, 834, 10354, 198, 220, 220, 220, 299, 11, 76, 796, 3975, 7, 600, 11, 15414, 22446, 35312, 28955, 198, 220, 220, 220, 5240, 796, 1351, 7, 8899, 7, 600, 11, 15414, 22446, 35312, 3419, 4008, ...
1.658863
299
# -*- coding: utf-8 -*- """ jes.bridge.terpcontrol ====================== This interacts with the interpreter, to keep the GUI locked down while the interpreter runs. (In JES, "terp" is short for "interpreter," not "terrapin.") :copyright: (C) 2014 Matthew Frazier and Mark Guzdial :license: GNU GPL v2 or later, see...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 73, 274, 13, 9458, 13, 353, 79, 13716, 198, 4770, 50155, 198, 1212, 44020, 351, 262, 28846, 11, 284, 1394, 262, 25757, 8970, 866, 981, 198, 1169, 28846, 45...
3.262195
164
"""Creating/edition of ICUs.""" from absl import logging import io import json import tornado.web from icubam.backoffice.handlers import base from icubam.db import synchronizer from typing import Dict, Callable
[ 37811, 32071, 14, 28736, 286, 12460, 5842, 526, 15931, 198, 6738, 2352, 75, 1330, 18931, 198, 11748, 33245, 198, 11748, 33918, 198, 11748, 33718, 13, 12384, 198, 198, 6738, 14158, 549, 321, 13, 1891, 31810, 13, 4993, 8116, 1330, 2779, 1...
3.55
60
from django.conf import settings USERPROFILE_SETTINGS = { 'app_verbose_name': "Custom User", 'register_proxy_auth_group_model': True, } if hasattr(settings, 'USERPROFILE'): USERPROFILE_SETTINGS.update(settings.USERPROFILE)
[ 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 198, 29904, 31190, 25664, 62, 28480, 51, 20754, 796, 1391, 198, 220, 220, 220, 705, 1324, 62, 19011, 577, 62, 3672, 10354, 366, 15022, 11787, 1600, 198, 220, 220, 220, 705, 30238, 62, 36...
2.662921
89
import random with open('09.loc', 'w') as f: for i in range(1, 1001): s = str(i) + ' ' + str(random.randint(1, 100)) + '\n' f.write(s)
[ 11748, 4738, 198, 198, 4480, 1280, 10786, 2931, 13, 17946, 3256, 705, 86, 11537, 355, 277, 25, 198, 220, 220, 220, 329, 1312, 287, 2837, 7, 16, 11, 1802, 16, 2599, 198, 220, 220, 220, 220, 220, 220, 220, 264, 796, 965, 7, 72, 8,...
1.962025
79
import scipy.signal as signal import numpy as np
[ 11748, 629, 541, 88, 13, 12683, 282, 355, 6737, 201, 198, 11748, 299, 32152, 355, 45941, 201, 198, 201, 198, 201, 198 ]
2.5
22
# Generated by Django 2.1 on 2018-08-27 07:36 from django.db import migrations, models import django.db.models.deletion
[ 2, 2980, 515, 416, 37770, 362, 13, 16, 319, 2864, 12, 2919, 12, 1983, 8753, 25, 2623, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 198, 11748, 42625, 14208, 13, 9945, 13, 27530, 13, 2934, 1616, 295, 628 ]
2.904762
42
### # Copyright (c) 2019-2020 Micro Focus or one of its affiliates. # # Licensed under the MIT License (the "License"); you may not use this file # except in compliance with the License. # # The only warranties for products and services of Micro Focus and its affiliates # and licensors ("Micro Focus") are as may be set...
[ 21017, 198, 2, 15069, 357, 66, 8, 13130, 12, 42334, 4527, 17061, 393, 530, 286, 663, 29116, 13, 198, 2, 198, 2, 49962, 739, 262, 17168, 13789, 357, 1169, 366, 34156, 15341, 345, 743, 407, 779, 428, 2393, 198, 2, 2845, 287, 11846, ...
4.641026
156
from conans import ConanFile, CMake, tools import os
[ 6738, 369, 504, 1330, 31634, 8979, 11, 327, 12050, 11, 4899, 198, 11748, 28686, 628 ]
3.6
15
import platform if platform.python_version() < '2.7': unittest = __import__('unittest2') else: import unittest from . import SKIP_BTYPES from riak.bucket import RiakBucket, BucketType from riak import RiakError, RiakObject
[ 11748, 3859, 198, 198, 361, 3859, 13, 29412, 62, 9641, 3419, 1279, 705, 17, 13, 22, 10354, 198, 220, 220, 220, 555, 715, 395, 796, 11593, 11748, 834, 10786, 403, 715, 395, 17, 11537, 198, 17772, 25, 198, 220, 220, 220, 1330, 555, ...
2.752941
85
import sys import csv import scraper if __name__ == "__main__": source_filename = sys.argv[1] destination_filename = sys.argv[2] word_column = int(sys.argv[3]) definition_column = int(sys.argv[4]) with open(source_filename, "r") as source_file: with open(destination_filename, "w") as destin...
[ 11748, 25064, 198, 11748, 269, 21370, 198, 11748, 19320, 525, 198, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 2723, 62, 34345, 796, 25064, 13, 853, 85, 58, 16, 60, 198, 220, 220, 220, 10965, 62...
2.289655
290
from flask import render_template from . import arturo @arturo.route('/es/machine-learning', methods=['GET']) @arturo.route('/machine-learning', methods=['GET']) @arturo.route('/en/machine-learning', methods=['GET'])
[ 6738, 42903, 1330, 8543, 62, 28243, 198, 6738, 764, 1330, 1242, 1434, 198, 198, 31, 433, 1434, 13, 38629, 10786, 14, 274, 14, 30243, 12, 40684, 3256, 5050, 28, 17816, 18851, 6, 12962, 198, 31, 433, 1434, 13, 38629, 10786, 14, 30243, ...
3.041667
72
from cog.torque import Graph import unittest import os import shutil DIR_NAME = "TorqueTest4" if __name__ == '__main__': unittest.main()
[ 6738, 43072, 13, 13165, 4188, 1330, 29681, 198, 11748, 555, 715, 395, 198, 11748, 28686, 198, 11748, 4423, 346, 198, 198, 34720, 62, 20608, 796, 366, 15884, 4188, 14402, 19, 1, 628, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 124...
2.636364
55
import sys print(sys.argv[0])
[ 11748, 25064, 628, 198, 4798, 7, 17597, 13, 853, 85, 58, 15, 12962, 198 ]
2.285714
14
from plugins import BasePlugin from plugins import PluginsData from etllib.conf import Conf from etllib.csv import CSV import os
[ 6738, 20652, 1330, 7308, 37233, 198, 6738, 20652, 1330, 22689, 1040, 6601, 198, 198, 6738, 2123, 297, 571, 13, 10414, 1330, 7326, 198, 6738, 2123, 297, 571, 13, 40664, 1330, 44189, 198, 198, 11748, 28686, 628, 220, 220, 220, 220, 220, ...
3.232558
43
from django.urls import path from django.conf.urls import url from django.views import generic from .views import ( BookListView, BookDetailView, BookUpdateView, delete_book, user_booklist, user_booklist_update, BookCreateView, ReviewCreateView, review_update_view ) app_name = 'books' urlpatterns = [ url...
[ 6738, 42625, 14208, 13, 6371, 82, 1330, 3108, 198, 6738, 42625, 14208, 13, 10414, 13, 6371, 82, 1330, 19016, 198, 6738, 42625, 14208, 13, 33571, 1330, 14276, 198, 6738, 764, 33571, 1330, 357, 198, 220, 220, 220, 4897, 8053, 7680, 11, ...
2.629717
424
#!/usr/bin/env python # -*- coding: utf-8 -*- from collections import defaultdict from datetime import datetime import numpy as np import pandas as pd class Word(object): """ Word definition. """ # Variables of SIR-like model N = "Population" S = "Susceptible" C = "Confirmed" CI = "In...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 6738, 17268, 1330, 4277, 11600, 198, 6738, 4818, 8079, 1330, 4818, 8079, 198, 11748, 299, 32152, 355, 45941, 198, ...
2.196358
2,801
import datetime import os import time import timeit import numpy as np import torch as th class Generator(th.nn.Module): """ Generator of the GAN network """ def turn_on_spectral_norm(self): """ private helper for turning on the spectral normalization :return: None (has side effect) ...
[ 11748, 4818, 8079, 198, 11748, 28686, 198, 11748, 640, 198, 11748, 640, 270, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 28034, 355, 294, 628, 198, 4871, 35986, 7, 400, 13, 20471, 13, 26796, 2599, 198, 220, 220, 220, 37227, 35986, ...
2.402579
1,396
# Load modules from inferelator import inferelator_workflow, inferelator_verbose_level, MPControl, crossvalidation_workflow from inferelator.benchmarking.scenic import SCENICWorkflow, SCENICRegression from inferelator.distributed.inferelator_mp import MPControl # Set verbosity level to "Talky" inferelator_verbose_leve...
[ 2, 8778, 13103, 198, 6738, 1167, 567, 41880, 1330, 1167, 567, 41880, 62, 1818, 11125, 11, 1167, 567, 41880, 62, 19011, 577, 62, 5715, 11, 4904, 15988, 11, 3272, 12102, 341, 62, 1818, 11125, 198, 6738, 1167, 567, 41880, 13, 26968, 4102...
2.040959
5,005
import os from flask_final.config import Debug, Secrets from flask_final import db, create_app is_env_var_set = os.getenv("SQLALCHEMY_DATABASE_URI") if not is_env_var_set: config = Secrets() else: config = Debug # Support for relative sqlite URIs if config.SQLALCHEMY_DATABASE_URI == "sqlite:///site.db": ...
[ 11748, 28686, 198, 198, 6738, 42903, 62, 20311, 13, 11250, 1330, 31687, 11, 23561, 198, 6738, 42903, 62, 20311, 1330, 20613, 11, 2251, 62, 1324, 198, 198, 271, 62, 24330, 62, 7785, 62, 2617, 796, 28686, 13, 1136, 24330, 7203, 17861, 1...
2.59707
273
import numpy as np import numpy.ma as ma from numpy.testing import assert_array_equal import pytest import netCDF4 from cloudnetpy.categorize.lidar import Lidar WAVELENGTH = 900.0 @pytest.fixture(scope='session') def fake_lidar_file(tmpdir_factory): """Creates a simple lidar file for testing.""" file_name = ...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 299, 32152, 13, 2611, 355, 17266, 198, 6738, 299, 32152, 13, 33407, 1330, 6818, 62, 18747, 62, 40496, 198, 11748, 12972, 9288, 198, 11748, 2010, 34, 8068, 19, 198, 6738, 6279, 3262, 9078, 13, ...
1.975741
742