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 pandas as pd from phenotrex.io.flat import load_genotype_file, DEFAULT_TRAIT_SIGN_MAPPING from phenotrex.io.serialization import load_classifier from phenotrex.ml.shap_handler import ShapHandler try: from phenotrex.transforms import fastas_to_grs except ModuleNotFoundError: from phenotrex.uti...
[ 11748, 28686, 198, 11748, 19798, 292, 355, 279, 67, 198, 198, 6738, 6566, 313, 21510, 13, 952, 13, 38568, 1330, 3440, 62, 5235, 8690, 62, 7753, 11, 5550, 38865, 62, 51, 3861, 2043, 62, 46224, 62, 44, 24805, 2751, 198, 6738, 6566, 31...
2.504647
1,829
import sqlite3 if __name__ == '__main__': main()
[ 11748, 44161, 578, 18, 628, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 1388, 3419, 198 ]
2.333333
24
import collections import heapq import numpy as np ans = solveWithBackTracking(7, 7)
[ 11748, 17268, 198, 11748, 24575, 80, 198, 11748, 299, 32152, 355, 45941, 220, 628, 198, 198, 504, 796, 8494, 3152, 7282, 2898, 5430, 7, 22, 11, 767, 8 ]
3.142857
28
import json from cryptojwt.utils import as_unicode from cryptojwt.jws.utils import alg2keytype from cryptojwt.jws.jws import JWS from cryptojwt.jws.jws import factory from fedoidcmsg import MetadataStatement from fedoidcmsg.bundle import jwks_to_keyjar from oidcmsg.oidc import JsonWebToken from cryptojwt.jwt import ...
[ 11748, 33918, 198, 198, 6738, 8194, 13210, 46569, 13, 26791, 1330, 355, 62, 46903, 1098, 198, 6738, 8194, 13210, 46569, 13, 73, 18504, 13, 26791, 1330, 435, 70, 17, 2539, 4906, 198, 6738, 8194, 13210, 46569, 13, 73, 18504, 13, 73, 185...
2.340708
1,582
from PyQt4 import QtGui import bisect
[ 6738, 9485, 48, 83, 19, 1330, 33734, 8205, 72, 198, 11748, 47457, 478, 628 ]
2.785714
14
import re registers = {} MAX_VAL = 0 instruction_re = re.compile("([a-z]+) (inc|dec) (-*\d+) if ([a-z]+) (.+ -*\d+)") with open("inputs/day8.txt") as f: for line in f: line = line.strip() (register, command, value, condition_register, condition) = instruction_re.match(line).groups() expre...
[ 11748, 302, 198, 198, 2301, 6223, 796, 23884, 198, 22921, 62, 23428, 796, 657, 198, 198, 8625, 2762, 62, 260, 796, 302, 13, 5589, 576, 7203, 26933, 64, 12, 89, 60, 28988, 357, 1939, 91, 12501, 8, 13841, 9, 59, 67, 28988, 611, 2956...
2.415179
224
import unittest import pandas as pd from pandas.testing import assert_frame_equal from zenml.preprocessing import parse_date from zenml.utils import array_to_series if __name__ == '__main__': unittest.main()
[ 11748, 555, 715, 395, 198, 11748, 19798, 292, 355, 279, 67, 198, 6738, 19798, 292, 13, 33407, 1330, 6818, 62, 14535, 62, 40496, 198, 6738, 1976, 268, 4029, 13, 3866, 36948, 1330, 21136, 62, 4475, 198, 6738, 1976, 268, 4029, 13, 26791,...
3.014085
71
import pandas as pd from data.process_data.process_data import process_data TA_FENG_PATH = 'data/tafeng/tafeng.csv' TA_FENG_OUTPUT = 'tafeng' TA_FENG_USER_COL = 'CUSTOMER_ID' TA_FENG_TIME_COL = 'TRANSACTION_DT' TA_FENG_ITEM_COL = 'PRODUCT_ID' TA_FENG_ITEM_TYPE_COL = 'PRODUCT_SUBCLASS' TA_FENG_TIME_FORMAT = '%m/%d/%Y' ...
[ 11748, 19798, 292, 355, 279, 67, 198, 6738, 1366, 13, 14681, 62, 7890, 13, 14681, 62, 7890, 1330, 1429, 62, 7890, 198, 198, 5603, 62, 37, 26808, 62, 34219, 796, 705, 7890, 14, 83, 1878, 1516, 14, 83, 1878, 1516, 13, 40664, 6, 198,...
2.011858
253
# coding: utf-8 # /*########################################################################## # # Copyright (c) 2018-2020 European Synchrotron Radiation Facility # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to d...
[ 2, 19617, 25, 3384, 69, 12, 23, 198, 2, 11900, 29113, 29113, 7804, 2235, 198, 2, 198, 2, 15069, 357, 66, 8, 2864, 12, 42334, 3427, 16065, 354, 10599, 1313, 47532, 29118, 198, 2, 198, 2, 2448, 3411, 318, 29376, 7520, 11, 1479, 286,...
2.481855
4,464
import pytest from redbot.core import modlog __all__ = ["mod"] @pytest.fixture
[ 11748, 12972, 9288, 198, 6738, 2266, 13645, 13, 7295, 1330, 953, 6404, 198, 198, 834, 439, 834, 796, 14631, 4666, 8973, 628, 198, 31, 9078, 9288, 13, 69, 9602, 198 ]
2.733333
30
from datetime import date import pyimgur
[ 6738, 4818, 8079, 1330, 3128, 198, 11748, 12972, 19791, 198 ]
4.1
10
from unittest.case import TestCase from probability.distributions import Lomax
[ 6738, 555, 715, 395, 13, 7442, 1330, 6208, 20448, 198, 198, 6738, 12867, 13, 17080, 2455, 507, 1330, 406, 296, 897, 628 ]
3.681818
22
import math import os import numpy as np from pathlib import Path from data_functions import * from random_forest import * # printing modifiers PRINT_BOLD_COLOR = "\033[1m" PRINT_DISABLE_COLOR = "\033[0m" def clear_file(file_name): """Clear the contents of a file""" # clear any previous content in the f...
[ 11748, 10688, 198, 11748, 28686, 198, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 3108, 8019, 1330, 10644, 198, 6738, 1366, 62, 12543, 2733, 1330, 1635, 198, 6738, 4738, 62, 29623, 1330, 1635, 628, 198, 2, 13570, 37395, 198, 198, 480...
2.574807
1,945
from os import getenv from typing import List, Tuple from subprocess import check_output CONFIG = { "REPOS": { "AUTH": { "CONTAINER": "hashcloak/authority", "REPOSITORY": "https://github.com/katzenpost/authority", "BRANCH": "master", "GITHASH": "", ...
[ 6738, 28686, 1330, 651, 24330, 198, 6738, 19720, 1330, 7343, 11, 309, 29291, 198, 6738, 850, 14681, 1330, 2198, 62, 22915, 198, 198, 10943, 16254, 796, 1391, 198, 220, 220, 220, 366, 35316, 2640, 1298, 1391, 198, 220, 220, 220, 220, 2...
2.114919
1,488
#!/usr/bin/python3 """ User class module """ from models.base_model import BaseModel class User(BaseModel): """ class User which inherits from class BaseModel """ email = "" password = "" first_name = "" last_name = ""
[ 2, 48443, 14629, 14, 8800, 14, 29412, 18, 198, 37811, 11787, 1398, 8265, 37227, 198, 198, 6738, 4981, 13, 8692, 62, 19849, 1330, 7308, 17633, 628, 198, 4871, 11787, 7, 14881, 17633, 2599, 198, 220, 220, 220, 37227, 1398, 11787, 543, 1...
3
81
############## ## Script listens to serial port and writes contents into a file import serial # sudo pip install pyserial should work from datetime import datetime serial_port = '/dev/cu.usbmodem1411'; baud_rate = 9600; #In arduino, Serial.begin(baud_rate) write_to_file_path = "week.txt"; output_file = open(write_...
[ 7804, 4242, 2235, 198, 2235, 12327, 35019, 284, 11389, 2493, 290, 6797, 10154, 656, 257, 2393, 198, 198, 11748, 11389, 220, 1303, 21061, 7347, 2721, 279, 893, 48499, 815, 670, 198, 6738, 4818, 8079, 1330, 4818, 8079, 198, 198, 46911, 62...
2.698113
265
#!/usr/bin/env python3 from flask import Flask, render_template, request, send_from_directory, url_for, redirect from flask_basicauth import BasicAuth from flask_apscheduler import APScheduler import requests import json import copy import atexit import time import timeago from datetime import datetime import paho.mqtt...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 6738, 42903, 1330, 46947, 11, 8543, 62, 28243, 11, 2581, 11, 3758, 62, 6738, 62, 34945, 11, 19016, 62, 1640, 11, 18941, 198, 6738, 42903, 62, 12093, 3970, 1071, 1330, 14392, 30515,...
2.797721
702
import numpy as np from railrl.envs.contextual import ContextualEnv from railrl.policies.base import Policy from railrl.samplers.data_collector import MdpPathCollector
[ 11748, 299, 32152, 355, 45941, 198, 6738, 6787, 45895, 13, 268, 14259, 13, 22866, 723, 1330, 30532, 723, 4834, 85, 198, 6738, 6787, 45895, 13, 79, 4160, 444, 13, 8692, 1330, 7820, 198, 6738, 6787, 45895, 13, 37687, 489, 364, 13, 7890,...
3.25
52
from collections import defaultdict from datetime import datetime from typing import Dict, List, Optional, Tuple from ..models import CategoryModel, ProjectModel from . import subscribe @subscribe
[ 6738, 17268, 1330, 4277, 11600, 198, 6738, 4818, 8079, 1330, 4818, 8079, 198, 6738, 19720, 1330, 360, 713, 11, 7343, 11, 32233, 11, 309, 29291, 198, 198, 6738, 11485, 27530, 1330, 21743, 17633, 11, 4935, 17633, 198, 6738, 764, 1330, 123...
4.1875
48
import pandas as pd from .classes import Dependencies def normalize(dependencies, df): """ Normalizes the dependency relationships in dependencies into new groups by breaking up all partial and transitive dependencies. Arguments: dependencies (Dependencies) : the dependencies to be split up ...
[ 11748, 19798, 292, 355, 279, 67, 198, 198, 6738, 764, 37724, 1330, 37947, 3976, 628, 198, 4299, 3487, 1096, 7, 45841, 3976, 11, 47764, 2599, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 14435, 4340, 262, 20203, 6958, 287, 20086, 656...
2.315919
5,264
from typing import Any, Union, List from rdict.macros import INDEX_SPECIAL_CHARACTER
[ 6738, 19720, 1330, 4377, 11, 4479, 11, 7343, 198, 198, 6738, 374, 11600, 13, 20285, 4951, 1330, 24413, 6369, 62, 48451, 12576, 62, 38019, 2246, 5781, 628, 628, 628 ]
3.137931
29
""" Space time dataset import functions Usage: .. code-block:: python import grass.temporal as tgis input="/tmp/temp_1950_2012.tar.gz" output="temp_1950_2012" directory="/tmp" title="My new dataset" descr="May new shiny dataset" location=None link=True exp=True overr=False ...
[ 37811, 198, 14106, 640, 27039, 1330, 5499, 198, 198, 28350, 25, 198, 198, 492, 2438, 12, 9967, 3712, 21015, 628, 220, 220, 220, 1330, 8701, 13, 11498, 35738, 355, 256, 70, 271, 628, 220, 220, 220, 5128, 35922, 22065, 14, 29510, 62, ...
2.087342
7,213
from flask import Flask import os app = Flask(__name__)
[ 6738, 42903, 1330, 46947, 198, 11748, 28686, 198, 198, 1324, 796, 46947, 7, 834, 3672, 834, 8 ]
3.294118
17
#!/usr/bin/env python # coding: utf-8 # zdy.py ''' Squid+站大爷搭建代理IP池 Author: Nathan Blog: www.xnathan.com Github: github.com/xNathan ''' from gevent import monkey monkey.patch_all() import os import time import logging import requests from gevent.pool import Pool logger = logging.getLogger(__name__) logger.setLevel(lo...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 19617, 25, 3384, 69, 12, 23, 198, 2, 1976, 9892, 13, 9078, 198, 7061, 6, 198, 22266, 312, 10, 44165, 247, 32014, 163, 230, 115, 162, 238, 255, 161, 119, 118, 47987, 49426, 228, ...
2.024316
658
# The MIT License (MIT) # # Copyright (c) 2016 Ivan Gavrilin # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, mod...
[ 2, 383, 17168, 13789, 357, 36393, 8, 198, 2, 198, 2, 15069, 357, 66, 8, 1584, 21798, 402, 615, 22379, 259, 198, 2, 198, 2, 2448, 3411, 318, 29376, 7520, 11, 1479, 286, 3877, 11, 284, 597, 1048, 16727, 257, 4866, 198, 2, 286, 428...
3.133333
540
# Numpy # from numpy import linspace, arange # Numpy array from numpy import array, append, zeros, ones, where # Numpy common math function from numpy import exp, sqrt, arctan2, cos, sin, angle, radians, sign, log, ceil # Numpy constant from numpy import pi from pandas import infer_freq # def set_QubitRegister()...
[ 2, 399, 32152, 198, 2, 220, 198, 6738, 299, 32152, 1330, 300, 1040, 10223, 11, 610, 858, 198, 2, 399, 32152, 7177, 198, 6738, 299, 32152, 1330, 7177, 11, 24443, 11, 1976, 27498, 11, 3392, 11, 810, 198, 2, 399, 32152, 2219, 10688, ...
2.090741
1,080
from loguru import logger import subprocess import os PROJECT_PATH = os.path.dirname(os.path.dirname(__file__)) VIDEO_PATH = os.path.join(PROJECT_PATH, "demo.mp4") from test_cutter import test_default as cutter_default from test_cutter import RESULT_DIR as CUTTER_RESULT_DIR # prepare cutter_default()
[ 6738, 2604, 14717, 1330, 49706, 198, 11748, 850, 14681, 198, 11748, 28686, 198, 198, 31190, 23680, 62, 34219, 796, 28686, 13, 6978, 13, 15908, 3672, 7, 418, 13, 6978, 13, 15908, 3672, 7, 834, 7753, 834, 4008, 198, 42937, 62, 34219, 79...
2.87037
108
from .base import AuthenticatedHandler
[ 6738, 764, 8692, 1330, 31885, 3474, 25060, 628 ]
5
8
import os import glob current_path = os.path.dirname(__file__) __all__ = [os.path.basename(x) for x in glob.glob(os.path.join(current_path, "*")) if os.path.isdir(x) and not os.path.basename(x).startswith("_")] if __name__ == '__main__': print(__all__)
[ 11748, 28686, 198, 11748, 15095, 198, 198, 14421, 62, 6978, 796, 28686, 13, 6978, 13, 15908, 3672, 7, 834, 7753, 834, 8, 198, 834, 439, 834, 796, 685, 418, 13, 6978, 13, 12093, 12453, 7, 87, 8, 329, 2124, 287, 15095, 13, 4743, 672...
2.339286
112
""" Clustering users with k-means algorithm :Author: Yassmine Chebaro <yassmnine.chebaro@mssm.edu> :Date: 2019-09-25 :License: MIT """ # Import Libraries import pandas as pd import matplotlib.pyplot as plt import numpy as np from scipy.sparse import csr_matrix from sklearn.cluster import KMeans from sklearn.metrics i...
[ 37811, 1012, 436, 1586, 2985, 351, 479, 12, 1326, 504, 11862, 198, 198, 25, 13838, 25, 575, 562, 3810, 2580, 5657, 78, 1279, 88, 562, 10295, 500, 13, 2395, 5657, 78, 31, 76, 824, 76, 13, 15532, 29, 198, 25, 10430, 25, 13130, 12, ...
3.053571
168
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import migrations, models
[ 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, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 628 ]
2.891892
37
def define(hub): ''' Define how the onchanges requisite should run ''' return { 'result': True, 'changes': True, }
[ 4299, 8160, 7, 40140, 2599, 198, 220, 220, 220, 705, 7061, 198, 220, 220, 220, 2896, 500, 703, 262, 319, 36653, 37088, 815, 1057, 198, 220, 220, 220, 705, 7061, 198, 220, 220, 220, 1441, 1391, 198, 220, 220, 220, 220, 220, 220, 22...
2.152778
72
number = int(input()) n_to_count = int(input()) counter = 0 while number > 0: result = number % 2 number //= 2 if result == n_to_count: counter += 1 print(counter)
[ 17618, 796, 493, 7, 15414, 28955, 198, 77, 62, 1462, 62, 9127, 796, 493, 7, 15414, 28955, 198, 24588, 796, 657, 198, 198, 4514, 1271, 1875, 657, 25, 198, 220, 220, 220, 1255, 796, 1271, 4064, 362, 198, 220, 220, 220, 1271, 3373, 2...
2.447368
76
# coding=UTF8 # Python TicTacToe game with Tk GUI and minimax AI # Author: Maurits van der Schee <maurits@vdschee.nl> # Repo: https://github.com/mevdschee/python-tictactoe """ Run this file to play manually with any agent. """ from Tkinter import Tk, Button, PhotoImage from PIL import ImageTk, Image from tkFont impo...
[ 2, 19617, 28, 48504, 23, 198, 198, 2, 11361, 309, 291, 51, 330, 2514, 68, 983, 351, 309, 74, 25757, 290, 10356, 897, 9552, 198, 2, 6434, 25, 18867, 896, 5719, 4587, 10011, 68, 1279, 2611, 333, 896, 31, 20306, 15952, 68, 13, 21283,...
2.480337
356
"""Utilities for EveryVoter project"""
[ 37811, 18274, 2410, 329, 3887, 53, 19543, 1628, 37811, 198 ]
3.9
10
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'designer/ui_binningWindow.ui' # # Created by: PyQt5 UI code generator 5.6 # # WARNING! All changes made in this file will be lost! from PyQt5 import QtCore, QtGui, QtWidgets
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 2, 5178, 7822, 7560, 422, 3555, 334, 72, 2393, 705, 26124, 263, 14, 9019, 62, 8800, 768, 27703, 13, 9019, 6, 198, 2, 198, 2, 15622, 416, 25, 9485, 48, 83, 20,...
2.865169
89
import cv2 import os from PIL import Image from PIL import ImageFile ImageFile.LOAD_TRUNCATED_IMAGES = True video_path = '/home/shixi/C3D-keras/datasets/ucf101/' save_path = '/home/shixi/C3D-keras/datasets/ucfimgs/' action_list = os.listdir(video_path) for action in action_list: if not os.path.exists(save_path+a...
[ 11748, 269, 85, 17, 198, 11748, 28686, 198, 6738, 350, 4146, 1330, 7412, 198, 6738, 350, 4146, 1330, 7412, 8979, 198, 5159, 8979, 13, 35613, 62, 5446, 4944, 34, 11617, 62, 3955, 25552, 796, 6407, 198, 198, 15588, 62, 6978, 796, 31051,...
1.71536
931
# Copyright (c) 2019, NVIDIA CORPORATION. # # 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...
[ 2, 15069, 357, 66, 8, 13130, 11, 15127, 23929, 44680, 6234, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262...
3.443662
284
from fastapi import APIRouter, HTTPException import pandas as pd import plotly.express as px import os router = APIRouter() DATA_FILEPATH1 = os.path.join(os.path.dirname(__file__), "..", "..","data", "current_pop_data_final.csv") DATA_FILEPATH2 = os.path.join(os.path.dirname(__file__), "..", "..","data", "his...
[ 6738, 3049, 15042, 1330, 3486, 4663, 39605, 11, 14626, 16922, 201, 198, 11748, 19798, 292, 355, 279, 67, 201, 198, 11748, 7110, 306, 13, 42712, 355, 279, 87, 201, 198, 11748, 28686, 201, 198, 201, 198, 472, 353, 796, 3486, 4663, 39605...
2.223222
1,111
# Digit fifth powers # # Problem 30 # # Surprisingly there are only three numbers that can be written as the sum of fourth powers of their digits: # # 1634 = 14 + 64 + 34 + 44 # 8208 = 84 + 24 + 04 + 84 # 9474 = 94 + 44 + 74 + 44 # As 1 = 14 is not a sum it is not included. # # The sum of these numbers is 1634 + 8208 +...
[ 2, 7367, 270, 8150, 5635, 198, 2, 198, 2, 20647, 1542, 198, 2, 198, 2, 47183, 612, 389, 691, 1115, 3146, 326, 460, 307, 3194, 355, 262, 2160, 286, 5544, 5635, 286, 511, 19561, 25, 198, 2, 198, 2, 1467, 2682, 796, 1478, 1343, 559...
2.996575
292
# Copyright 2021 The SODA Authors. # # 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 wri...
[ 2, 15069, 33448, 383, 311, 3727, 32, 46665, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, 198...
3.365314
271
import cv2 import numpy as np from keras.models import load_model from statistics import mode from utils.datasets import get_labels from utils.inference import detect_faces from utils.inference import draw_text from utils.inference import draw_bounding_box from utils.inference import apply_offsets from utils.inference ...
[ 11748, 269, 85, 17, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 41927, 292, 13, 27530, 1330, 3440, 62, 19849, 198, 6738, 7869, 1330, 4235, 198, 6738, 3384, 4487, 13, 19608, 292, 1039, 1330, 651, 62, 23912, 1424, 198, 6738, 3384, 44...
3.266447
304
_NOOP=const(0) _DIGIT0=const(1) _DIGIT1=const(2) _DIGIT2=const(3) _DIGIT3=const(4) _DIGIT4=const(5) _DIGIT5=const(6) _DIGIT6=const(7) _DIGIT7=const(8) _DECODEMODE=const(9) _INTENSITY=const(10) _SCANLIMIT=const(11) _SHUTDOWN=const(12) _DISPLAYTEST=const(15)
[ 62, 15285, 3185, 28, 9979, 7, 15, 8, 198, 62, 35, 3528, 2043, 15, 28, 9979, 7, 16, 8, 198, 62, 35, 3528, 2043, 16, 28, 9979, 7, 17, 8, 198, 62, 35, 3528, 2043, 17, 28, 9979, 7, 18, 8, 198, 62, 35, 3528, 2043, 18, 28, 997...
1.708609
151
from flask import Flask, request, render_template, redirect, url_for from decouple import config from flask_pymongo import PyMongo from flask_cors import CORS from apps.city_spelling_matcher import * from apps.charts import * from apps.pred_models import * from apps.data_rangle import * from flask import json from flas...
[ 6738, 42903, 1330, 46947, 11, 2581, 11, 8543, 62, 28243, 11, 18941, 11, 19016, 62, 1640, 198, 6738, 875, 43846, 1330, 4566, 198, 6738, 42903, 62, 79, 4948, 25162, 1330, 9485, 44, 25162, 198, 6738, 42903, 62, 66, 669, 1330, 327, 20673,...
3.553719
121
import pytest,torch from fastai.basics import have_min_pkg_version from fastai.gen_doc.doctest import this_tests from fastai.text.models.qrnn import ForgetMultGPU, BwdForgetMultGPU, forget_mult_CPU, QRNN, QRNNLayer @pytest.mark.cuda @pytest.mark.cpp @pytest.mark.cuda @pytest.mark.cpp # bug in pytorch=1.0.1, fixed in...
[ 11748, 12972, 9288, 11, 13165, 354, 198, 6738, 3049, 1872, 13, 12093, 873, 1330, 423, 62, 1084, 62, 35339, 62, 9641, 198, 6738, 3049, 1872, 13, 5235, 62, 15390, 13, 4598, 310, 395, 1330, 428, 62, 41989, 198, 6738, 3049, 1872, 13, 52...
2.465969
191
import sys import torch import torchvision from embryovision.torchnn import Classifier
[ 11748, 25064, 198, 198, 11748, 28034, 198, 11748, 28034, 10178, 198, 198, 6738, 20748, 709, 1166, 13, 13165, 1349, 77, 1330, 5016, 7483, 628, 198 ]
3.64
25
#!/usr/bin/env python from Bio import SeqIO from Bio import Seq import sys inFile = open(sys.argv[1]) for rec in SeqIO.parse(inFile, "fasta"): i = 0 l = len(rec.seq) while (i < l): j=i while (j < l and rec.seq[j] == 'N'): j += 1 if (j - i > 100000): print r...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 6738, 16024, 1330, 1001, 80, 9399, 198, 6738, 16024, 1330, 1001, 80, 198, 198, 11748, 25064, 198, 198, 259, 8979, 796, 1280, 7, 17597, 13, 853, 85, 58, 16, 12962, 198, 1640, 664...
1.842365
203
# Copyright 2020 Alexis Lopez Zubieta # # Permission is hereby granted, free of charge, to any person obtaining a # copy of this software and associated documentation files (the "Software"), # to deal in the Software without restriction, including without limitation the # rights to use, copy, modify, merge, publi...
[ 2, 220, 15069, 220, 12131, 31078, 22593, 47828, 1155, 64, 198, 2, 198, 2, 220, 2448, 3411, 318, 29376, 7520, 11, 1479, 286, 3877, 11, 284, 597, 1048, 16727, 257, 198, 2, 220, 4866, 286, 428, 3788, 290, 3917, 10314, 3696, 357, 1169, ...
4.252941
170
'''Autogenerated by xml_generate script, do not edit!''' from OpenGL import platform as _p, arrays # Code generation uses this from OpenGL.raw.GLX import _types as _cs # End users want this... from OpenGL.raw.GLX._types import * from OpenGL.raw.GLX import _errors from OpenGL.constant import Constant as _C imp...
[ 7061, 6, 16541, 519, 877, 515, 416, 35555, 62, 8612, 378, 4226, 11, 466, 407, 4370, 0, 7061, 6, 201, 198, 6738, 30672, 1330, 3859, 355, 4808, 79, 11, 26515, 201, 198, 2, 6127, 5270, 3544, 428, 201, 198, 6738, 30672, 13, 1831, 13, ...
1.884091
1,320
if __name__ == '__main__': p = HEAP() q = [1, 2, 3] e = [] while True: a = str(input()) q = [] qq = [] senten = "" kk = 0 k = 1 if a[0] == ";": break if a[0] == "+": p.insert(int(a[1:len(a)])) if a[0] == ...
[ 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 201, 198, 201, 198, 220, 220, 220, 279, 796, 11179, 2969, 3419, 201, 198, 220, 220, 220, 10662, 796, 685, 16, 11, 362, 11, 513, 60, 201, 198, 220, 220, 220, 304, 796, 17635...
1.451117
716
"""Base class for collections interactive tests. """ import difflib import os from typing import Generator import pytest from ....defaults import FIXTURES_COLLECTION_DIR from ..._common import copytree from ..._common import retrieve_fixture_for_step from ..._common import update_fixtures from ..._interactions impor...
[ 37811, 14881, 1398, 329, 17268, 14333, 5254, 13, 198, 37811, 198, 11748, 814, 8019, 198, 11748, 28686, 198, 198, 6738, 19720, 1330, 35986, 198, 198, 11748, 12972, 9288, 198, 198, 6738, 19424, 12286, 82, 1330, 44855, 51, 29514, 62, 25154, ...
2.361102
2,941
# # 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, software # ...
[ 2, 198, 2, 220, 220, 220, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 345, 743, 198, 2, 220, 220, 220, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, 921, 743, 7330, 198, 2, ...
2.387211
6,490
my_list = [7, 5, 3, 3, 2] i = int(input('Ввидите новый элемент рейтинга: ')) my_list.append(i) my_list.sort() my_list.reverse() print(my_list)
[ 1820, 62, 4868, 796, 685, 22, 11, 642, 11, 513, 11, 513, 11, 362, 60, 198, 72, 796, 493, 7, 15414, 10786, 140, 240, 38857, 18849, 43666, 18849, 20375, 16843, 12466, 121, 25443, 110, 45035, 140, 117, 220, 141, 235, 30143, 16843, 4310...
1.576087
92
""" Library for Adaptive Design of Experiments. -- kandasamy@cs.cmu.edu """ from .exd.goal_oriented_exd import GoalOrientedExperimentDesigner from .exd.worker_manager import get_default_worker_manager from .policies.policy_utils import load_options_for_policy
[ 37811, 198, 220, 10074, 329, 30019, 425, 8495, 286, 8170, 6800, 13, 198, 220, 1377, 479, 392, 292, 14814, 31, 6359, 13, 11215, 84, 13, 15532, 198, 37811, 198, 198, 6738, 764, 1069, 67, 13, 35231, 62, 17107, 62, 1069, 67, 1330, 25376...
3.093023
86
import argparse import datetime import h5py import matplotlib.dates as mdates import matplotlib.pyplot as plt import numpy as np if __name__ == '__main__': _main()
[ 11748, 1822, 29572, 198, 11748, 4818, 8079, 198, 11748, 289, 20, 9078, 198, 11748, 2603, 29487, 8019, 13, 19581, 355, 285, 19581, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 11748, 299, 32152, 355, 45941, 628, 628...
2.836066
61
# This file is a part of WUnderground PWS Python API # Copyright (c) 2019 Marco Aceti <mail@marcoaceti.it> # See LICENSE file for more details about licensing and copying.
[ 2, 770, 2393, 318, 257, 636, 286, 370, 9203, 2833, 350, 19416, 11361, 7824, 198, 2, 15069, 357, 66, 8, 13130, 16556, 4013, 316, 72, 1279, 4529, 31, 3876, 1073, 23253, 72, 13, 270, 29, 198, 2, 4091, 38559, 24290, 2393, 329, 517, 33...
3.411765
51
from output_reader import Output_Reader from parslet import Parslet from report import Report from report import Plan import re
[ 6738, 5072, 62, 46862, 1330, 25235, 62, 33634, 198, 6738, 13544, 1616, 1330, 23042, 1616, 198, 6738, 989, 1330, 6358, 198, 6738, 989, 1330, 5224, 198, 11748, 302 ]
4.535714
28
# -*- coding: utf-8 -*- # Generated by Django 1.11.15 on 2019-01-29 21:10 from __future__ import unicode_literals from django.db import migrations, models
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 2980, 515, 416, 37770, 352, 13, 1157, 13, 1314, 319, 13130, 12, 486, 12, 1959, 2310, 25, 940, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, ...
2.754386
57
import sys import os import libsbml from tqdm import tqdm ''' Usage: annotate_links_from_mp.py <path_model-polisher_sbml-file> <path_input_sbml-file> <path_output_sbml-file> Extracts annotations form ModelPolisher file and adds it to previous file. ''' if __name__ == '__main__': main(sys.argv)
[ 11748, 25064, 198, 11748, 28686, 198, 11748, 9195, 36299, 4029, 198, 6738, 256, 80, 36020, 1330, 256, 80, 36020, 198, 198, 7061, 6, 198, 28350, 25, 24708, 378, 62, 28751, 62, 6738, 62, 3149, 13, 9078, 1279, 6978, 62, 19849, 12, 16104,...
2.657895
114
#! /usr/bin/env python3 """ http://oj.leetcode.com/problems/populating-next-right-pointers-in-each-node/ Since Apr-10-2014 18:33 """ # Definition for a binary tree node # @param root, a tree node # @return nothing if __name__ == '__main__': s = Solution() n1 = TreeNode(1) n2 = TreeNode(2) ...
[ 2, 0, 1220, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 37811, 198, 4023, 1378, 13210, 13, 293, 316, 8189, 13, 785, 14, 1676, 22143, 14, 12924, 8306, 12, 19545, 12, 3506, 12, 47809, 12, 259, 12, 27379, 12, 17440, 14, 198, 198...
2.09009
333
# 主函数 import os # 自写 import Tools # 设置需要爬取的页面 BASE_URL = 'http://www.9ku.com' CHILD_URLS = ['/douyin/bang.htm','/douyin/new.htm','/douyin/zhongwen.htm','/douyin/bgm.htm', '/laoge/500shou.htm','/laoge/80.htm','/laoge/70.htm', '/wangluo/zuixin.htm','/wangluo/haoting.htm'] SAVE_PATH = os.pat...
[ 2, 220, 10310, 119, 49035, 121, 46763, 108, 198, 198, 11748, 28686, 198, 2, 5525, 229, 103, 37863, 247, 198, 11748, 20003, 628, 198, 2, 5525, 106, 122, 163, 121, 106, 165, 250, 222, 17358, 223, 163, 230, 105, 20998, 244, 21410, 165,...
1.723312
459
# Generated by Django 3.0.3 on 2020-11-03 07:48 from django.db import migrations, models
[ 2, 2980, 515, 416, 37770, 513, 13, 15, 13, 18, 319, 12131, 12, 1157, 12, 3070, 8753, 25, 2780, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 628 ]
2.84375
32
import json import math import collections import sys scores = [] elements = [] end_res = {"files": []}
[ 11748, 33918, 198, 11748, 10688, 198, 11748, 17268, 198, 11748, 25064, 198, 198, 1416, 2850, 796, 17635, 198, 68, 3639, 796, 17635, 198, 437, 62, 411, 796, 19779, 16624, 1298, 17635, 92, 628, 628, 198 ]
3.114286
35
# -*- coding: utf-8 -*- from pony import orm import pony.orm.dbproviders.sqlite import datetime #orm.set_sql_debug(True) db = orm.Database() @db.on_connect(provider='sqlite') db.bind(provider='sqlite', filename='checkytdb.sqlite', create_db=True) db.generate_mapping(create_tables=True)
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 201, 198, 6738, 26902, 1330, 393, 76, 201, 198, 11748, 26902, 13, 579, 13, 9945, 15234, 4157, 13, 25410, 578, 201, 198, 11748, 4818, 8079, 201, 198, 2, 579, 13, 2617, 62, ...
2.26087
138
from unittest.mock import patch, MagicMock from dataclasses import dataclass @patch("flaskerize.generate._generate") @patch("flaskerize.generate._generate") @patch("flaskerize.generate._generate") @patch("flaskerize.generate._generate") @patch("flaskerize.generate._generate") @patch("flaskerize.generate._g...
[ 6738, 555, 715, 395, 13, 76, 735, 1330, 8529, 11, 6139, 44, 735, 198, 198, 6738, 4818, 330, 28958, 1330, 4818, 330, 31172, 628, 198, 31, 17147, 7203, 2704, 2093, 263, 1096, 13, 8612, 378, 13557, 8612, 378, 4943, 628, 198, 31, 17147,...
2.737705
122
import numpy as np from phi.flow import Scene from control.control_training import ControlTraining from control.pde.value import IncrementPDE # Data generation from control.sequences import StaggeredSequence if len(Scene.list('~/phi/data/value')) == 0: scene = Scene.create('~/phi/data/value') for frame in ...
[ 11748, 299, 32152, 355, 45941, 198, 198, 6738, 872, 72, 13, 11125, 1330, 28315, 198, 198, 6738, 1630, 13, 13716, 62, 34409, 1330, 6779, 44357, 198, 6738, 1630, 13, 79, 2934, 13, 8367, 1330, 10791, 434, 5760, 36, 628, 198, 2, 6060, 5...
2.159763
507
import threading from queue import Queue from spider import Spider from domain import * from general import * PROJECT_NAME = 'sebastianwalter' HOMEPAGE = 'http://sebastianwalter.org' DOMAIN_NAME = get_domain_name(HOMEPAGE) QUEUE_FILE = PROJECT_NAME + '/queue.txt' CRAWLED_FILE = PROJECT_NAME + '/crawled.txt' NUMBER_OF_...
[ 11748, 4704, 278, 198, 6738, 16834, 1330, 4670, 518, 198, 6738, 19230, 1330, 12648, 198, 6738, 7386, 1330, 1635, 198, 6738, 2276, 1330, 1635, 198, 198, 31190, 23680, 62, 20608, 796, 705, 325, 65, 459, 666, 16783, 353, 6, 198, 39069, 4...
3.167382
233
# MIDI input and output ports, on windows you'll have to # start them manually using LoopMIDI or another software MIDI_INPUT_PORT: str = "magenta_in" MIDI_OUTPUT_PORT: str = "magenta_out" # The server GUI for the app WS_SERVER_HOST: str = "127.0.0.1" WS_SERVER_PORT: int = 5000
[ 2, 33439, 5128, 290, 5072, 14090, 11, 319, 9168, 345, 1183, 423, 284, 198, 2, 923, 606, 14500, 1262, 26304, 44, 2389, 40, 393, 1194, 3788, 198, 44, 2389, 40, 62, 1268, 30076, 62, 15490, 25, 965, 796, 366, 19726, 29188, 62, 259, 1,...
2.682692
104
from direct.directnotify import DirectNotifyGlobal from . import CatalogItem from . import CatalogItemList from .CatalogFurnitureItem import CatalogFurnitureItem, nextAvailableCloset, getAllClosets, get50ItemCloset, getMaxClosets, get50ItemTrunk from .CatalogAnimatedFurnitureItem import CatalogAnimatedFurnitureItem fro...
[ 6738, 1277, 13, 12942, 1662, 1958, 1330, 4128, 3673, 1958, 22289, 198, 6738, 764, 1330, 44515, 7449, 198, 6738, 764, 1330, 44515, 7449, 8053, 198, 6738, 764, 49015, 37, 700, 8089, 7449, 1330, 44515, 37, 700, 8089, 7449, 11, 1306, 10493,...
2.651882
13,257
import numpy as np import pandas as pd import traceback from flask import Flask, request, jsonify, render_template import pickle app = Flask(__name__) model = pickle.load(open("model.pkl", "rb")) modelcol = pickle.load(open("modelcol.pkl", "rb")) @app.route('/') @app.route('/predict', methods = ["POST"]) if __name__ ...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 12854, 1891, 198, 6738, 42903, 1330, 46947, 11, 2581, 11, 33918, 1958, 11, 8543, 62, 28243, 198, 11748, 2298, 293, 198, 1324, 796, 46947, 7, 834, 3672, 8...
2.740458
131
#!/usr/bin/python # -*- coding: utf-8 -*- __author__ = 'liying'
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 628, 198, 834, 9800, 834, 796, 705, 4528, 1112, 6, 628 ]
2.09375
32
# File containing the driver workspace usecase. from typing import List from cabrenter.entities.cab import Cab from cabrenter.use_cases.driver_workspace_repo_interface import \ DriverWorkspaceRepoInterface
[ 2, 9220, 7268, 262, 4639, 44573, 779, 7442, 13, 198, 6738, 19720, 1330, 7343, 198, 198, 6738, 16212, 918, 353, 13, 298, 871, 13, 66, 397, 1330, 15976, 198, 6738, 16212, 918, 353, 13, 1904, 62, 33964, 13, 26230, 62, 5225, 10223, 62, ...
3.491803
61
#!/usr/bin/env python3 import uuid from pathlib import Path import cv2 import depthai as dai from collections import deque import numpy as np from common.camera_info import H_CR from common.config import NNConfig # Create pipeline pipeline = dai.Pipeline() # Define sources and outputs monoLeft = pipeline.create(...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 11748, 334, 27112, 198, 6738, 3108, 8019, 1330, 10644, 198, 198, 11748, 269, 85, 17, 198, 11748, 6795, 1872, 355, 288, 1872, 198, 6738, 17268, 1330, 390, 4188, 198, 198, 11748, 299...
2.500675
5,183
# -*- coding: utf-8 -*- import os from zhconv import convert_for_mw POETRY_DIRECTORY = './add_poetry/' if __name__ == "__main__": main()
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 28686, 198, 6738, 1976, 71, 42946, 1330, 10385, 62, 1640, 62, 76, 86, 198, 198, 16402, 2767, 18276, 62, 17931, 23988, 15513, 796, 705, 19571, 2860, 62, 7501, 1197...
2.212121
66
import random from enterprise import MontgomeryScott as Scotty scotty = Scotty() part_one() part_two()
[ 11748, 4738, 198, 6738, 13953, 1330, 21532, 19040, 355, 7130, 774, 198, 198, 1416, 313, 774, 796, 7130, 774, 3419, 628, 220, 220, 220, 220, 198, 3911, 62, 505, 3419, 198, 198, 3911, 62, 11545, 3419 ]
3.055556
36
import numpy as np import pandas as pd from sklearn.ensemble import BaggingClassifier, AdaBoostClassifier from sklearn.metrics import f1_score from sklearn.model_selection import train_test_split from sklearn.tree import DecisionTreeClassifier from IMLearn.metalearners import AdaBoost from IMLearn.learners.classifiers ...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 198, 6738, 1341, 35720, 13, 1072, 11306, 1330, 347, 16406, 9487, 7483, 11, 47395, 45686, 9487, 7483, 198, 6738, 1341, 35720, 13, 4164, 10466, 1330, 277, 16, 62, 26675,...
3.173077
156
from django.shortcuts import render from django.http import HttpResponse from scms import models # Create your views here.
[ 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 198, 6738, 629, 907, 1330, 4981, 198, 198, 2, 13610, 534, 5009, 994, 13, 198 ]
3.757576
33
# encoding=UTF-8 """convert-requirements-to-conda-yml.py""" import sys import argparse import pkg_resources import requests FEEDSTOCK_URL = 'https://github.com/conda-forge/{package}-feedstock' YML_TEMPLATE = """channels: - conda-forge - defaults dependencies: {conda_dependencies} {pip_dependencies} """ SCM_MAP = {...
[ 2, 21004, 28, 48504, 12, 23, 198, 37811, 1102, 1851, 12, 8897, 18883, 12, 1462, 12, 66, 13533, 12, 88, 4029, 13, 9078, 37811, 198, 198, 11748, 25064, 198, 11748, 1822, 29572, 198, 11748, 279, 10025, 62, 37540, 198, 198, 11748, 7007, ...
2.185495
1,434
from sqlalchemy import Column, UniqueConstraint from sqlalchemy import String, Integer, Text from authlib.oauth1 import ( ClientMixin, TemporaryCredentialMixin, TokenCredentialMixin, )
[ 6738, 44161, 282, 26599, 1330, 29201, 11, 30015, 3103, 2536, 2913, 198, 6738, 44161, 282, 26599, 1330, 10903, 11, 34142, 11, 8255, 198, 6738, 6284, 8019, 13, 12162, 1071, 16, 1330, 357, 198, 220, 220, 220, 20985, 35608, 259, 11, 198, ...
3
67
# Higher Class Language compiler for PYVM # transpiles a tiny language to ppvm for assembler # # By: Ari Stehney # import sys import os import time import crayons at_compiler_tags = dict() at_stack = dict() at_functions = dict() at_includes = dict() filename1 = sys.argv[1] filename2 = sys.argv[2] print(crayons.cya...
[ 2, 16038, 5016, 15417, 17050, 329, 350, 56, 15996, 198, 2, 1007, 79, 2915, 257, 7009, 3303, 284, 9788, 14761, 329, 11156, 1754, 198, 2, 198, 2, 2750, 25, 6069, 2441, 71, 1681, 198, 2, 198, 198, 11748, 25064, 198, 11748, 28686, 198, ...
2.472414
290
from multiselect_core import Multiselect fruits=["Apple","Pear","Apricot","Banana","Orange","Raspberry","Blueberry","Kiwi","Pineapple"] fruit_multiselect=[{"key":"Apple","value":False},{"key":"Pear","value":False},{"key":"Apricot","value":True},{"key":"Banana","value":False}, {"key":"Orange","value...
[ 6738, 1963, 786, 801, 62, 7295, 1330, 7854, 786, 801, 198, 198, 69, 50187, 28, 14692, 16108, 2430, 46262, 2430, 13680, 291, 313, 2430, 30457, 2271, 2430, 40141, 2430, 49, 17653, 2430, 14573, 8396, 2430, 42, 14246, 72, 2430, 47, 500, 1...
2.683417
796
import collections import random import game.content import gears import pbge from game.content import gharchitecture from game.content.ghplots import missionbuilder from game.ghdialogue import context from pbge.dialogue import Offer, ContextTag from pbge.plots import Plot from . import dd_customobjectives from game ...
[ 11748, 17268, 198, 11748, 4738, 198, 198, 11748, 983, 13, 11299, 198, 11748, 28713, 198, 11748, 279, 65, 469, 198, 6738, 983, 13, 11299, 1330, 24997, 998, 5712, 495, 198, 6738, 983, 13, 11299, 13, 456, 489, 1747, 1330, 4365, 38272, 19...
2.619643
1,120
from .gamedata import getTeams, getScores, adjustScores from .pwr import PWRsystems from .regression import Regression from .simulate import simulateBracket, simulateGame, simulateGamelog from .teams import Team, Teams from .tiebreak import getPlayoffSeeding from .util import playoff_game_ids from joblib import ...
[ 6738, 764, 70, 2434, 1045, 1330, 651, 6767, 4105, 11, 651, 3351, 2850, 11, 4532, 3351, 2850, 201, 198, 6738, 764, 79, 18351, 1330, 350, 18564, 10057, 82, 201, 198, 6738, 764, 2301, 2234, 1330, 3310, 2234, 201, 198, 6738, 764, 14323, ...
3.080882
136
''' Problem Tower of Hanoi: About: Tower of Hanoi is a mathematical puzzle where we have three rods and n disks. The objective of the puzzle is to move the entire stack to another rod, obeying the following simple rules: 1) Only one disk can be moved at a time. 2) Each move consists of taking the upper disk from one of...
[ 7061, 6, 20647, 8765, 286, 367, 5733, 72, 25, 198, 8585, 25, 8765, 286, 367, 5733, 72, 318, 257, 18069, 15027, 810, 356, 423, 1115, 32858, 290, 299, 32505, 13, 383, 9432, 286, 262, 15027, 318, 284, 1445, 262, 2104, 8931, 284, 1194, ...
3.328947
304
# uncompyle6 version 3.7.4 # Python bytecode 3.7 (3394) # Decompiled from: Python 3.7.9 (tags/v3.7.9:13c94747c7, Aug 17 2020, 18:58:18) [MSC v.1900 64 bit (AMD64)] # Embedded file name: T:\InGame\Gameplay\Scripts\Server\whims\whim_modifiers.py # Compiled at: 2020-10-08 02:43:22 # Size of source mod 2**32: 3151 bytes fr...
[ 2, 34318, 2349, 21, 2196, 513, 13, 22, 13, 19, 198, 2, 11361, 18022, 8189, 513, 13, 22, 357, 2091, 5824, 8, 198, 2, 4280, 3361, 3902, 422, 25, 11361, 513, 13, 22, 13, 24, 357, 31499, 14, 85, 18, 13, 22, 13, 24, 25, 1485, 66,...
2.864151
265
""" This example is largely adapted from https://github.com/pytorch/examples/blob/master/imagenet/main.py Before you can run this example, you will need to download the ImageNet dataset manually from the `official website <http://image-net.org/download>`_ and place it into a folder `path/to/imagenet`. Train on ImageN...
[ 37811, 198, 1212, 1672, 318, 5688, 16573, 422, 3740, 1378, 12567, 13, 785, 14, 9078, 13165, 354, 14, 1069, 12629, 14, 2436, 672, 14, 9866, 14, 320, 11286, 316, 14, 12417, 13, 9078, 198, 198, 8421, 345, 460, 1057, 428, 1672, 11, 345,...
3.362776
317
"""Backpropagation-like methods for interpretability Wrapper around: - (pytorch) Captum [1] - (keras) DeepExplain [2] References: [1] https://captum.ai/ [2] https://arxiv.org/abs/1711.06104 """ from captum.attr import IntegratedGradients, Saliency, DeepLift,\ DeepLiftShap, GradientShap...
[ 37811, 7282, 22930, 363, 341, 12, 2339, 5050, 329, 6179, 1799, 198, 198, 36918, 2848, 1088, 25, 198, 12, 357, 9078, 13165, 354, 8, 6790, 388, 685, 16, 60, 198, 12, 357, 6122, 292, 8, 10766, 18438, 391, 685, 17, 60, 198, 198, 19927...
2.289587
2,324
# coding: utf-8 """ Honeywell Home No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) # noqa: E501 The version of the OpenAPI document: 1.0.0 Generated by: https://openapi-generator.tech """ import pprint import re # noqa: F401 import six ...
[ 2, 19617, 25, 3384, 69, 12, 23, 198, 198, 37811, 198, 220, 220, 220, 21788, 4053, 5995, 628, 220, 220, 220, 1400, 6764, 2810, 357, 27568, 416, 4946, 15042, 35986, 3740, 1378, 12567, 13, 785, 14, 9654, 499, 270, 10141, 14, 9654, 1504...
2.375406
1,846
# (c) Copyright IBM Corp. 2010, 2018. All Rights Reserved. # -*- coding: utf-8 -*- # pragma pylint: disable=unused-argument, no-self-use, line-too-long """Function implementation test with: resilient-circuits selftest -l fn_digital_shadows_search """ import logging import json import requests from requests.auth imp...
[ 2, 357, 66, 8, 15069, 19764, 11421, 13, 3050, 11, 2864, 13, 1439, 6923, 33876, 13, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 23864, 2611, 279, 2645, 600, 25, 15560, 28, 403, 1484, 12, 49140, 11, 645,...
2.504785
836
import click from rezide.utils import interfaces from rezide.utils import sway @click.command()
[ 11748, 3904, 198, 198, 6738, 302, 89, 485, 13, 26791, 1330, 20314, 198, 6738, 302, 89, 485, 13, 26791, 1330, 20009, 628, 198, 198, 31, 12976, 13, 21812, 3419, 198 ]
3.333333
30
import unittest from click.testing import CliRunner import gksdud if __name__ == '__main__': unittest.main()
[ 11748, 555, 715, 395, 198, 6738, 3904, 13, 33407, 1330, 1012, 72, 49493, 198, 198, 11748, 308, 591, 67, 463, 628, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 555, 715, 395, 13, 12417, 3419...
2.659091
44
#! /usr/bin/env python2 # # This file is part of khmer, http://github.com/ged-lab/khmer/, and is # Copyright (C) Michigan State University, 2009-2013. It is licensed under # the three-clause BSD license; see doc/LICENSE.txt. # Contact: khmer-project@idyll.org # import sys MAX_SIZE = 50000 if __name__ == '__main__': ...
[ 2, 0, 1220, 14629, 14, 8800, 14, 24330, 21015, 17, 198, 2, 198, 2, 770, 2393, 318, 636, 286, 44081, 647, 11, 2638, 1378, 12567, 13, 785, 14, 2004, 12, 23912, 14, 14636, 647, 47454, 290, 318, 198, 2, 15069, 357, 34, 8, 7055, 1812...
2.241071
896
from collections import UserList from typing import * from .iterables import * from .math import * # (sample mean, sample standard deviation) @overload @overload def mean(X: list[int | float], weights: Optional[list[int | float]] = None): '''return the population mean = sample mean of X in O(n)''' if weights == ...
[ 6738, 17268, 1330, 11787, 8053, 198, 6738, 19720, 1330, 1635, 198, 6738, 764, 2676, 2977, 1330, 1635, 198, 6738, 764, 11018, 1330, 1635, 198, 198, 2, 357, 39873, 1612, 11, 6291, 3210, 28833, 8, 198, 31, 2502, 2220, 198, 198, 31, 2502,...
2.194742
2,054
from django.contrib import admin from .models import Post, Project, Author admin.site.register(Post) admin.site.register(Project) admin.site.register(Author)
[ 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 6738, 764, 27530, 1330, 2947, 11, 4935, 11, 6434, 198, 198, 28482, 13, 15654, 13, 30238, 7, 6307, 8, 198, 28482, 13, 15654, 13, 30238, 7, 16775, 8, 198, 28482, 13, 15654, 13, 3023...
3.382979
47
import json import os import subprocess import sys import time from shutil import copyfile from enum import Enum import boto3 import ray from ray.tune import run_experiments from .tf_serving_utils import export_tf_serving, natural_keys, change_permissions_recursive from .configuration_list import ConfigurationList fr...
[ 11748, 33918, 198, 11748, 28686, 198, 11748, 850, 14681, 198, 11748, 25064, 198, 11748, 640, 198, 6738, 4423, 346, 1330, 4866, 7753, 198, 6738, 33829, 1330, 2039, 388, 198, 198, 11748, 275, 2069, 18, 198, 198, 11748, 26842, 198, 6738, 2...
2.41619
2,273
# -*- coding: UTF-8 -*- logger.info("Loading 3 objects to table cal_dailyplannerrow...") # fields: id, seqno, designation, start_time, end_time loader.save(create_cal_dailyplannerrow(1,1,['AM', 'Vormittags', 'Avant-midi'],None,time(12,0,0))) loader.save(create_cal_dailyplannerrow(2,2,['PM', 'Nachmittags', 'Apr\xe8s-mid...
[ 2, 532, 9, 12, 19617, 25, 41002, 12, 23, 532, 9, 12, 198, 6404, 1362, 13, 10951, 7203, 19031, 513, 5563, 284, 3084, 2386, 62, 29468, 11578, 1008, 808, 9313, 8, 198, 2, 7032, 25, 4686, 11, 33756, 3919, 11, 22566, 11, 923, 62, 243...
2.405
200
import os from django.shortcuts import render from django.shortcuts import render, redirect, get_object_or_404, render_to_response from django.template import RequestContext from django.core.urlresolvers import reverse from django.contrib.auth.decorators import login_required, user_passes_test from django.contrib impo...
[ 11748, 28686, 198, 198, 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 198, 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 11, 18941, 11, 651, 62, 15252, 62, 273, 62, 26429, 11, 8543, 62, 1462, 62, 26209, 198, 6738, 42625, 14208, ...
3.577703
296
import click import recipes.sync_recipe_utils as sr import solvebio as sb __version__ = '1.0.0' @click.group() @click.option('--access-token', help='Manually provide a SolveBio Access Token') @click.option('--api-host', help='Override the default SolveBio API host') @click.option('--api-key', help='Manually provide ...
[ 11748, 3904, 198, 11748, 14296, 13, 27261, 62, 29102, 431, 62, 26791, 355, 19677, 198, 11748, 8494, 65, 952, 355, 264, 65, 198, 198, 834, 9641, 834, 796, 705, 16, 13, 15, 13, 15, 6, 628, 198, 31, 12976, 13, 8094, 3419, 198, 31, ...
2.859903
414
# Copyright (C) 2018 Garth N. Wells # # SPDX-License-Identifier: MIT """This module provides a model for a monitoring station, and tools for manipulating/modifying station data """ class MonitoringStation: """This class represents a river level monitoring station""" # Task 1F def typical_range_consisten...
[ 2, 15069, 357, 34, 8, 2864, 7164, 400, 399, 13, 18292, 198, 2, 198, 2, 30628, 55, 12, 34156, 12, 33234, 7483, 25, 17168, 198, 37811, 1212, 8265, 3769, 257, 2746, 329, 257, 9904, 4429, 11, 290, 4899, 198, 1640, 29349, 14, 4666, 403...
2.817185
547
import sys import os sys.path.append(os.path.dirname(os.path.dirname(os.path.realpath(__file__)))) import src.pattern.PatternBuilder as PB test_build3()
[ 11748, 25064, 198, 11748, 28686, 198, 17597, 13, 6978, 13, 33295, 7, 418, 13, 6978, 13, 15908, 3672, 7, 418, 13, 6978, 13, 15908, 3672, 7, 418, 13, 6978, 13, 5305, 6978, 7, 834, 7753, 834, 35514, 198, 198, 11748, 12351, 13, 33279, ...
2.785714
56