content
stringlengths
1
1.04M
input_ids
listlengths
1
774k
ratio_char_token
float64
0.38
22.9
token_count
int64
1
774k
import pickle from firebase import firebase import pyautogui import time firebase = firebase.FirebaseApplication('https://sleep-tight-8a6df.firebaseio.com/', None) id2 = pickle.load(open("chrome","rb")) X = firebase.get('/sleep-tight-8a6df/Chrome/'+ str(id2) , 'CX' ) Y = firebase.get('/sleep-tight-8a6df/Chrome/'+ st...
[ 11748, 2298, 293, 198, 6738, 2046, 8692, 1330, 2046, 8692, 198, 11748, 12972, 2306, 519, 9019, 198, 11748, 640, 198, 198, 6495, 8692, 796, 2046, 8692, 13, 13543, 8692, 23416, 10786, 5450, 1378, 42832, 12, 33464, 12, 23, 64, 21, 7568, ...
2.461022
744
import pytest _EXPECTED = { "data": { "dog": { "name": "Dog", "nickname": "Doggo", "barkVolume": 2, "doesKnowCommand": True, "isHousetrained": False, "owner": {"name": "Hooman"}, } } } @pytest.mark.asyncio @pyte...
[ 11748, 12972, 9288, 628, 628, 628, 628, 628, 198, 198, 62, 49864, 9782, 1961, 796, 1391, 198, 220, 220, 220, 366, 7890, 1298, 1391, 198, 220, 220, 220, 220, 220, 220, 220, 366, 9703, 1298, 1391, 198, 220, 220, 220, 220, 220, 220, ...
1.488431
2,766
# Copyright (c) Microsoft Corporation. All Rights Reserved. # Licensed under the MIT license. See LICENSE file on the project webpage for details. """Setup for azure_media_services XBlock.""" import os from setuptools import setup def package_data(pkg, roots): """Generic function to find package_data. All ...
[ 2, 15069, 357, 66, 8, 5413, 10501, 13, 1439, 6923, 33876, 13, 198, 2, 49962, 739, 262, 17168, 5964, 13, 4091, 38559, 24290, 2393, 319, 262, 1628, 35699, 329, 3307, 13, 198, 198, 37811, 40786, 329, 35560, 495, 62, 11431, 62, 30416, 1...
2.432191
671
from biostuff import BlastLine, BlastFile some_attrs = ('qstart', 'qstop', 'sstart', 'sstop', 'pctid', 'score', 'query', 'subject')
[ 6738, 3182, 455, 1648, 1330, 20641, 13949, 11, 20641, 8979, 198, 198, 11246, 62, 1078, 3808, 796, 19203, 80, 9688, 3256, 705, 80, 11338, 3256, 705, 82, 9688, 3256, 705, 82, 11338, 3256, 705, 79, 310, 312, 3256, 705, 26675, 3256, 705, ...
2.409836
61
import pygame from pygame.sprite import Sprite # a class to represent a single enemy in the fleet # init the enemy and it's starting position # function to check if enemy is at edge of screen # enemy update function
[ 11748, 12972, 6057, 198, 6738, 12972, 6057, 13, 34975, 578, 1330, 33132, 198, 198, 2, 257, 1398, 284, 2380, 257, 2060, 4472, 287, 262, 11026, 628, 220, 220, 220, 1303, 2315, 262, 4472, 290, 340, 338, 3599, 2292, 628, 220, 220, 220, ...
3.714286
63
import copy import logging import re import uuid from django.conf import settings from raven import Client logger = logging.getLogger(__name__) REPORTS_BASE_URL = 'http://qa.orange.biolab.si/errors/{}' PYTHON_FOLDERS = [ "site-packages", "dist-packages", "Python34.lib", "anaconda3.lib", "lib.pyt...
[ 11748, 4866, 198, 11748, 18931, 198, 11748, 302, 198, 11748, 334, 27112, 198, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 37735, 1330, 20985, 198, 198, 6404, 1362, 796, 18931, 13, 1136, 11187, 1362, 7, 834, 3672, 834, 8, ...
1.953399
2,339
# Copyright 2006-2007 Virtutech AB import sim_commands sim_commands.new_pci_header_command('AM79C973', None) sim_commands.new_info_command('AM79C973', get_info) sim_commands.new_status_command('AM79C973', get_status)
[ 2, 15069, 4793, 12, 12726, 11285, 1133, 354, 9564, 198, 198, 11748, 985, 62, 9503, 1746, 198, 198, 14323, 62, 9503, 1746, 13, 3605, 62, 79, 979, 62, 25677, 62, 21812, 10786, 2390, 3720, 34, 24, 4790, 3256, 6045, 8, 198, 14323, 62, ...
2.576471
85
#!usr/bin/env python3 # -*- coding: utf-8 -*- """ pytest setup_module() and teardown_module() demo. Assumption: creating a user is a very resource-consuming process => Thus, we don't want to do user creation every time we run a test. """ __author__ = 'Ziang Lu' import pytest from pytest_for_python.src.codes import...
[ 2, 0, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 37811, 198, 9078, 9288, 9058, 62, 21412, 3419, 290, 573, 446, 593, 62, 21412, 3419, 13605, 13, 198, 198, 8021, ...
2.92126
127
#!/usr/bin/env python # -*- coding: utf-8 -*- import sys import os import socket import errno from getpass import getpass from optparse import OptionParser from sassh.connectionlib import Library, Connection from sassh.sshclient import SSHClient from paramiko import SSHException try: import pygtk pygtk.requir...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 11748, 25064, 198, 11748, 28686, 198, 11748, 17802, 198, 11748, 11454, 3919, 198, 6738, 651, 6603, 1330, 651, 6603, ...
2.024307
5,842
import asyncio import logging import os import json import etl.io_config.server_protocol as protocol alert_dns = '127.0.0.1' predictor_dns = '0.0.0.0' SRV_LOG_FMT = '%(asctime)s|%(name)s|%(process)s-%(thread)s|%(levelname)s|%(message)s' logging.basicConfig(level=logging.INFO, format=SRV_LOG_FMT) loop = asyncio.ge...
[ 11748, 30351, 952, 198, 11748, 18931, 198, 11748, 28686, 198, 11748, 33918, 198, 11748, 2123, 75, 13, 952, 62, 11250, 13, 15388, 62, 11235, 4668, 355, 8435, 198, 198, 44598, 62, 67, 5907, 796, 705, 16799, 13, 15, 13, 15, 13, 16, 6, ...
2.573477
279
# 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 # distributed under the...
[ 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, 7330, 257, 4866, 286, 262, 13789, 379, 198, 2,...
2.078603
5,814
from .cgevolver import CGEvolver from .eulerevolver import EulerEvolver from .rungekuttaevolver import RungeKuttaEvolver from .spintevolver import SpinTEvolver from .spinxferevolver import SpinXferEvolver from .uhh_thetaevolver import UHH_ThetaEvolver from .xf_thermheunevolver import Xf_ThermHeunEvolver from .xf_therms...
[ 6738, 764, 66, 469, 10396, 332, 1330, 327, 8264, 10396, 332, 198, 6738, 764, 68, 2261, 260, 10396, 332, 1330, 412, 18173, 36, 10396, 332, 198, 6738, 764, 5143, 469, 74, 315, 8326, 1990, 14375, 1330, 5660, 469, 42, 315, 8326, 36, 103...
2.652174
138
from django.conf import settings from django.http import HttpResponseForbidden target_methods = settings.METHOD_ORIGIN.keys() http_methods = ['CONNECT', 'DELETE', 'GET', 'HEAD', 'OPTIONS', 'POST', 'PUT']
[ 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 1890, 37978, 198, 198, 16793, 62, 24396, 82, 796, 6460, 13, 49273, 62, 1581, 3528, 1268, 13, 13083, 3419, 198, 198, 4023, 62, 24396, ...
2.971014
69
''' Crie um programa onde o usuário possa digitar sete valores numéricos e cadastre-os em uma lista única que mantenha separados os valores pares e ímpares. No final, mostre os valores pares e ímpares em ordem crescente.''' '''princ = [] impar= [] par= [] for c in range (0,7): n = int(input('Digite um número: ')) ...
[ 7061, 6, 327, 5034, 23781, 1430, 64, 319, 2934, 267, 514, 84, 6557, 27250, 1184, 64, 3100, 7940, 900, 68, 1188, 2850, 997, 2634, 1173, 418, 304, 20603, 459, 260, 12, 418, 198, 368, 334, 2611, 1351, 64, 6184, 118, 77, 3970, 8358, 2...
2.076063
447
import time from slackclient import SlackClient import common import config if __name__ == '__main__': conn = SlackConn(config.slack_token) conn.upload_img('/Users/omibot/data/omibot/sentry/Dienstag, 31. Oktober 2017 um 14:15:51/Image2.jpeg', '#allgemein')
[ 11748, 640, 198, 198, 6738, 30740, 16366, 1330, 36256, 11792, 198, 198, 11748, 2219, 198, 11748, 4566, 628, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 48260, 796, 36256, 37321, 7, 11250, 13, ...
2.596154
104
import os from datetime import datetime
[ 11748, 28686, 198, 6738, 4818, 8079, 1330, 4818, 8079, 628 ]
4.1
10
""" File: draw_line.py Name: Kevin Fang ------------------------- TODO: """ from campy.graphics.gobjects import GOval, GLine from campy.graphics.gwindow import GWindow from campy.gui.events.mouse import onmouseclicked # Assign window as constant to create canvas window = GWindow() SIZE = 10 # a, b ,c ,d a...
[ 37811, 201, 198, 8979, 25, 3197, 62, 1370, 13, 9078, 201, 198, 5376, 25, 7939, 24468, 201, 198, 22369, 12, 201, 198, 51, 3727, 46, 25, 201, 198, 37811, 201, 198, 6738, 1413, 88, 13, 70, 11549, 13, 70, 48205, 1330, 10351, 2100, 11,...
2.858238
261
from flask import get_flashed_messages from flask_login import current_user from app.auth.services.registration import ( AutoActivateUserPostProcessor, AutologinPostProcessor, SendActivationPostProcessor, ) from app.core.auth.activation import AccountActivator from app.utils.settings import app_config
[ 6738, 42903, 1330, 651, 62, 2704, 5263, 62, 37348, 1095, 198, 6738, 42903, 62, 38235, 1330, 1459, 62, 7220, 198, 198, 6738, 598, 13, 18439, 13, 30416, 13, 2301, 33397, 1330, 357, 198, 220, 220, 220, 11160, 25526, 378, 12982, 6307, 187...
3.393617
94
""" This function should return a string like "There are NUM planets in the solar system" where NUM is provided as an argument.""" # Should equal "There are 8 planets in the solar system" ss1 = solar_system(8) # Should equal "There are 9 planets in the solar system" ss2 = solar_system(9) """ This function should ret...
[ 37811, 770, 2163, 815, 1441, 257, 4731, 588, 198, 1, 1858, 389, 36871, 14705, 287, 262, 6591, 1080, 1, 198, 3003, 36871, 318, 2810, 355, 281, 4578, 526, 15931, 198, 198, 2, 10358, 4961, 366, 1858, 389, 807, 14705, 287, 262, 6591, 10...
3.176623
385
import logging import vlc import xml.etree.ElementTree as ET import os import sys import re from threading import Timer from time import sleep @vlc.CallbackDecorators.LogCb
[ 11748, 18931, 198, 11748, 410, 44601, 198, 11748, 35555, 13, 316, 631, 13, 20180, 27660, 355, 12152, 198, 11748, 28686, 198, 11748, 25064, 198, 11748, 302, 198, 6738, 4704, 278, 1330, 5045, 263, 198, 6738, 640, 1330, 3993, 628, 198, 31,...
3.320755
53
from django.contrib import admin from user import models # Register your models here. admin.site.register(models.User) admin.site.register(models.Staff) admin.site.register(models.CourseAdviser) admin.site.register(models.Student) admin.site.register(models.Biodata) admin.site.register(models.AcademicData) admin.sit...
[ 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 6738, 2836, 1330, 4981, 198, 198, 2, 17296, 534, 4981, 994, 13, 628, 198, 28482, 13, 15654, 13, 30238, 7, 27530, 13, 12982, 8, 198, 28482, 13, 15654, 13, 30238, 7, 27530, 13, 3144...
3.255639
133
line = input() sides = {} while line != "Lumpawaroo": if " | " in line: args = line.split(" | ") side = args[0] user = args[1] # TODO If you receive forceSide | forceUser, you should check if such forceUser already exists, and if not, add him/her to the corresponding side if...
[ 1370, 796, 5128, 3419, 198, 82, 1460, 796, 23884, 198, 198, 4514, 1627, 14512, 366, 43, 931, 707, 38049, 1298, 198, 220, 220, 220, 611, 366, 930, 366, 287, 1627, 25, 198, 220, 220, 220, 220, 220, 220, 220, 26498, 796, 1627, 13, 35...
2.065982
682
import requests import os url = 'http://admin:SuperAdminPasssword6742344234!!@localhost:8080/'#'http://admin:SuperAdminPasssword6742344234!!@a18e-2601-182-ce00-c860-3c42-c8b2-be91-176.ngrok.io/' #resp = requests.post(url, data={'newUser': True, 'username': 'new_user', 'password': 'test_pass'}) ## makefile : f...
[ 11748, 7007, 201, 198, 11748, 28686, 201, 198, 201, 198, 6371, 796, 705, 4023, 1378, 28482, 25, 12442, 46787, 14478, 30553, 3134, 43356, 2598, 24409, 3228, 31, 36750, 25, 1795, 1795, 14, 6, 2, 6, 4023, 1378, 28482, 25, 12442, 46787, 1...
2.630769
520
############################################## # Switching Linear Dynamical System # Code for both SLDS generative model as well # as variational inference code ############################################## import torch import torch.nn as nn import numpy as np import math from torch.autograd import Variable...
[ 29113, 7804, 4242, 2235, 198, 2, 220, 220, 220, 14645, 278, 44800, 14970, 605, 4482, 220, 198, 2, 220, 220, 220, 6127, 329, 1111, 12419, 5258, 1152, 876, 2746, 355, 880, 198, 2, 220, 220, 220, 355, 5553, 864, 32278, 2438, 198, 29113...
3.69281
153
import torch from torch import nn from houttuynia.nn import init __all__ = [ 'Conv1d', 'Conv2d', 'Conv3d', 'GramConv1', ]
[ 11748, 28034, 198, 6738, 28034, 1330, 299, 77, 198, 198, 6738, 289, 448, 28047, 2047, 544, 13, 20471, 1330, 2315, 198, 198, 834, 439, 834, 796, 685, 198, 220, 220, 220, 705, 3103, 85, 16, 67, 3256, 705, 3103, 85, 17, 67, 3256, 705...
2.163934
61
from enum import Enum from typing import Dict, List, Optional import click from pygments.lexers.shell import BashLexer from prompt_toolkit import prompt, print_formatted_text, PromptSession from prompt_toolkit.lexers import PygmentsLexer from prompt_toolkit.auto_suggest import AutoSuggestFromHistory from prompt_toolkit...
[ 6738, 33829, 1330, 2039, 388, 198, 6738, 19720, 1330, 360, 713, 11, 7343, 11, 32233, 198, 11748, 3904, 198, 6738, 12972, 11726, 13, 2588, 364, 13, 29149, 1330, 15743, 45117, 263, 198, 6738, 6152, 62, 25981, 15813, 1330, 6152, 11, 3601, ...
3.151163
258
# -------------- ##File path for the file file_path #Code starts here sample_message= str(read_file(file_path)) print(sample_message) # -------------- #Code starts here file_path_1 file_path_2 message_1=read_file(file_path_1) message_2=read_file(file_path_2) print("message1", message_1) ...
[ 2, 220, 26171, 198, 2235, 8979, 3108, 329, 262, 2393, 220, 201, 198, 7753, 62, 6978, 220, 201, 198, 201, 198, 2, 10669, 4940, 994, 201, 198, 201, 198, 201, 198, 39873, 62, 20500, 28, 965, 7, 961, 62, 7753, 7, 7753, 62, 6978, 400...
2.407066
651
"""Test string """ import ARgorithmToolkit algo = ARgorithmToolkit.StateSet() st = ARgorithmToolkit.String('st', algo, "Hello world! 1234") def test_body(): """Test string contents """ assert st.body == "Hello world! 1234" last_state = algo.states[-1] assert last_state.content["state_type"] == 'st...
[ 37811, 14402, 4731, 198, 37811, 198, 11748, 5923, 42289, 25391, 15813, 198, 198, 282, 2188, 796, 5923, 42289, 25391, 15813, 13, 9012, 7248, 3419, 198, 301, 796, 5923, 42289, 25391, 15813, 13, 10100, 10786, 301, 3256, 435, 2188, 11, 366, ...
2.549383
810
from logzero import logger import logzero import logging import glob import pandas as pd # Scrapy packages import scrapy import requests from scrapy.selector import Selector from TA_scrapy.items import ReviewRestoItem, RestoItem, UserItem from TA_scrapy.spiders import get_info # Chromedriver package and options from...
[ 198, 6738, 2604, 22570, 1330, 49706, 198, 11748, 2604, 22570, 198, 11748, 18931, 198, 11748, 15095, 198, 11748, 19798, 292, 355, 279, 67, 198, 198, 2, 1446, 2416, 88, 10392, 198, 11748, 15881, 88, 198, 11748, 7007, 198, 6738, 15881, 88,...
3.444444
171
# Copyright 2013 OpenStack Foundation # # 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 ...
[ 2, 15069, 2211, 4946, 25896, 5693, 198, 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, 26...
3.411215
214
"""测试场景组件的使用""" from manimlib.imports import * class Graph2DExample(GraphScene): """二维坐标图实例""" CONFIG = { "x_min": -1, "x_max": 6, "x_axis_width": 10, "x_axis_label": "time", #"x_label_color": RED, "y_min": -1, "y_max": 20, "y_axis_height": 8, ...
[ 37811, 38184, 233, 46237, 243, 28839, 118, 162, 247, 107, 163, 119, 226, 20015, 114, 21410, 45635, 18796, 101, 37811, 198, 198, 6738, 582, 320, 8019, 13, 320, 3742, 1330, 1635, 198, 198, 4871, 29681, 17, 35, 16281, 7, 37065, 36542, 25...
1.631579
589
# Copyright (c) 2020-2021 impersonator.org authors (Wen Liu and Zhixin Piao). All rights reserved. import cv2 import torch import numpy as np import math from operator import itemgetter from .dataset import normalize, pad_width def infer_fast_post_process(net_outputs, PoseClass): """ Args: net...
[ 2, 15069, 357, 66, 8, 12131, 12, 1238, 2481, 28671, 1352, 13, 2398, 7035, 357, 54, 268, 18258, 290, 10511, 844, 259, 350, 13481, 737, 1439, 2489, 10395, 13, 198, 198, 11748, 269, 85, 17, 198, 11748, 28034, 198, 11748, 299, 32152, 35...
2.222511
1,155
import numpy as np import pymc as pm from matplotlib import pyplot as plt challenger_data = np.genfromtxt("challenger_data.csv", skip_header=1, usecols=[1, 2], missing_values="NA", delimiter=",") # drop the NA values challenger_data = challenger_d...
[ 11748, 299, 32152, 355, 45941, 201, 198, 11748, 279, 4948, 66, 355, 9114, 201, 198, 6738, 2603, 29487, 8019, 1330, 12972, 29487, 355, 458, 83, 201, 198, 201, 198, 36747, 6540, 62, 7890, 796, 45941, 13, 5235, 6738, 14116, 7203, 36747, ...
2.380208
768
from tkinter import * window = Tk() window.geometry("600x500+30+20") window.title("Welcome to Python Programming") btn = Button(window, text = "Click to add name", fg ="blue") btn.place(x= 80, y= 100) lbl = Label(window, text = "Student Personal Information", fg = "Blue", bg = "orange") lbl.place(relx=.5, ...
[ 6738, 256, 74, 3849, 1330, 1635, 201, 198, 17497, 796, 309, 74, 3419, 201, 198, 201, 198, 17497, 13, 469, 15748, 7203, 8054, 87, 4059, 10, 1270, 10, 1238, 4943, 201, 198, 17497, 13, 7839, 7203, 14618, 284, 11361, 30297, 4943, 201, 1...
2.207516
612
from collections import defaultdict forward, reverse = build_mapping_from_input() # Part 1 print(len(can_contain('shiny gold'))) # Part 2 print(count_bags('shiny gold'))
[ 6738, 17268, 1330, 4277, 11600, 628, 198, 198, 11813, 11, 9575, 796, 1382, 62, 76, 5912, 62, 6738, 62, 15414, 3419, 628, 198, 2, 2142, 352, 628, 198, 4798, 7, 11925, 7, 5171, 62, 3642, 391, 10786, 1477, 3541, 3869, 6, 22305, 628, ...
2.967213
61
import itertools import numpy as np from draw import Draw from replay import Replay from config import WHITELIST class Comparer: """ A class for managing a set of replay comparisons. Attributes: List replays1: A list of Replay instances to compare against replays2. List replays2: A ...
[ 11748, 340, 861, 10141, 198, 198, 11748, 299, 32152, 355, 45941, 198, 198, 6738, 3197, 1330, 15315, 198, 6738, 24788, 1330, 23635, 198, 6738, 4566, 1330, 7655, 2043, 3698, 8808, 198, 198, 4871, 3082, 11258, 25, 198, 220, 220, 220, 37227...
2.50693
2,381
from setuptools import setup setup( name='proximal', version='0.1.7', packages=['proximal', 'proximal.prox_fns', 'proximal.lin_ops', 'proximal.algorithms', 'proximal.utils', 'proximal.halide', 'proximal.tests', ...
[ 6738, 900, 37623, 10141, 1330, 9058, 198, 198, 40406, 7, 198, 220, 220, 220, 1438, 11639, 1676, 87, 4402, 3256, 198, 220, 220, 220, 2196, 11639, 15, 13, 16, 13, 22, 3256, 198, 220, 220, 220, 10392, 28, 17816, 1676, 87, 4402, 3256, ...
1.690236
594
import math import numpy as np import subprocess import re import matplotlib.pyplot as plt from matplotlib.patches import Rectangle import astropy.units as units from astropy.cosmology import Planck15 as cosmo,z_at_value from matplotlib.backends.backend_pdf import PdfPages flare_dir="../flare" Ms=1.5e4*10**(np.a...
[ 11748, 10688, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 850, 14681, 198, 11748, 302, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 6738, 2603, 29487, 8019, 13, 8071, 2052, 1330, 48599, 9248, 198, 11748, 6468, ...
2.244681
282
""" Schema for event objects. """ from .common import sources, extras media_schema = { "description": ("This \"special\" schema is used in two places in the Event" " schema, on the top level and inside the agenda item. This is an" " optional component that may be omited...
[ 37811, 198, 220, 220, 220, 10011, 2611, 329, 1785, 5563, 13, 198, 37811, 198, 198, 6738, 764, 11321, 1330, 4237, 11, 33849, 198, 198, 11431, 62, 15952, 2611, 796, 1391, 198, 220, 220, 220, 366, 11213, 1298, 5855, 1212, 19990, 20887, 7...
1.660739
9,223
from django.contrib.auth import views as auth_views from django.views.generic.base import TemplateView from django.conf.urls import patterns, include, url from django.contrib import admin from django.conf.urls.static import static from django.conf import settings from django.views.generic import RedirectView from fileu...
[ 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 1330, 5009, 355, 6284, 62, 33571, 198, 6738, 42625, 14208, 13, 33571, 13, 41357, 13, 8692, 1330, 37350, 7680, 198, 6738, 42625, 14208, 13, 10414, 13, 6371, 82, 1330, 7572, 11, 2291, 11, 19...
2.670295
643
#!/usr/bin/env python3 # encoding: utf-8 """Choices are enumeration values you can choose, by selecting index number. It is a special TabStop, its content are taken literally, thus said, they will not be parsed recursively. """ from UltiSnips import vim_helper from UltiSnips.position import Position from UltiSnips.te...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 21004, 25, 3384, 69, 12, 23, 198, 198, 37811, 22164, 1063, 389, 27056, 341, 3815, 345, 460, 3853, 11, 416, 17246, 6376, 1271, 13, 198, 1026, 318, 257, 2041, 16904, 19485, 11, ...
3.27972
143
import pytest from mltk.utils.test_helper import run_model_operation, generate_run_model_params @pytest.mark.parametrize(*generate_run_model_params()) @pytest.mark.parametrize(*generate_run_model_params())
[ 198, 11748, 12972, 9288, 198, 6738, 285, 2528, 74, 13, 26791, 13, 9288, 62, 2978, 525, 1330, 1057, 62, 19849, 62, 27184, 11, 7716, 62, 5143, 62, 19849, 62, 37266, 628, 198, 31, 9078, 9288, 13, 4102, 13, 17143, 316, 380, 2736, 46491,...
2.824324
74
name = str(input('Type your name: ')).strip() print('Uppercase name: {}'.format(name.upper())) print('Lowercase name: {}'.format(name.lower())) print('Total letters: {}'.format(len(name) - name.count(' '))) #print('First name has {} letters. '.format(name.find(' '))) s = name.split() print('First name has {} letters.'....
[ 3672, 796, 965, 7, 15414, 10786, 6030, 534, 1438, 25, 705, 29720, 36311, 3419, 198, 4798, 10786, 52, 39921, 589, 1438, 25, 23884, 4458, 18982, 7, 3672, 13, 45828, 3419, 4008, 198, 4798, 10786, 31426, 7442, 1438, 25, 23884, 4458, 18982, ...
2.99115
113
#==================================================== # MODULES #==================================================== import pandas as pd import ROOT import matplotlib.pyplot as plt import numpy as np #==================================================== # DATA PREPARATION #==================================...
[ 2, 10052, 4770, 1421, 198, 2, 220, 220, 220, 220, 19164, 6239, 1546, 198, 2, 10052, 4770, 1421, 198, 11748, 19798, 292, 355, 279, 67, 220, 198, 11748, 15107, 2394, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 1...
2.422098
3,575
import unittest from katas.kyu_7.filter_list import filter_list
[ 11748, 555, 715, 395, 198, 198, 6738, 479, 265, 292, 13, 2584, 84, 62, 22, 13, 24455, 62, 4868, 1330, 8106, 62, 4868, 628 ]
2.75
24
#coding:utf-8 PURPLE = '\033[35m' RED = '\033[31m' CYAN = '\033[36m' OKBLUE = '\033[94m' OKGREEN = '\033[92m' WARNING = '\033[93m' FAIL = '\033[91m' ENDC = '\033[0m' import csv import sys import codecs from urllib.parse import urlparse #URL --> Domain from time import sleep dict_web_id = {} dict_url ...
[ 2, 66, 7656, 25, 40477, 12, 23, 198, 47, 4261, 16437, 220, 796, 705, 59, 44427, 58, 2327, 76, 6, 198, 22083, 220, 220, 220, 220, 796, 705, 59, 44427, 58, 3132, 76, 6, 198, 34, 56, 1565, 220, 220, 220, 796, 705, 59, 44427, 58, ...
2.242647
1,088
#personaldetails print("NAME:Wealth Okete \nE-MAIL: wealth.okete@gmail.com \nSLACK USERNAME: @Wealth \nBIOSTACK: Genomics \nTwitter Handle: @Wealty") print(hamming_distance('@Wealth','@Wealty'))
[ 2, 6259, 1940, 316, 1768, 201, 198, 4798, 7203, 20608, 25, 1135, 1094, 6762, 14471, 3467, 77, 36, 12, 5673, 4146, 25, 5129, 13, 482, 14471, 31, 14816, 13, 785, 3467, 77, 8634, 8120, 1294, 1137, 20608, 25, 2488, 1135, 1094, 3467, 77,...
2.5
80
conditional statement in python: this performs different computations or actions depending on whatever a specific boolean expression evaluaates to true or false. they are handled by if statements in python. from maths: equals: a==b not equals: a != b less than: a<b greater than: a>b greater than or equals to: a...
[ 17561, 1859, 2643, 287, 21015, 25, 201, 198, 5661, 17706, 1180, 2653, 602, 393, 4028, 6906, 319, 4232, 257, 2176, 25131, 5408, 5418, 6413, 689, 284, 2081, 393, 3991, 13, 201, 198, 9930, 389, 12118, 416, 611, 6299, 287, 21015, 13, 201,...
2.957328
539
""" sentry.event_manager ~~~~~~~~~~~~~~~~~~~~ :copyright: (c) 2010-2014 by the Sentry Team, see AUTHORS for more details. :license: BSD, see LICENSE for more details. """ from __future__ import absolute_import, print_function import logging import math import six from datetime import datetime, timedelta from collect...
[ 37811, 198, 82, 13000, 13, 15596, 62, 37153, 198, 27156, 8728, 198, 198, 25, 22163, 4766, 25, 357, 66, 8, 3050, 12, 4967, 416, 262, 11352, 563, 4816, 11, 766, 37195, 20673, 329, 517, 3307, 13, 198, 25, 43085, 25, 347, 10305, 11, 7...
3.366953
466
__author__ = "RADICAL-SAGA Development Team" __copyright__ = "Copyright 2013, RADICAL" __license__ = "MIT" import os import radical.utils as ru # ------------------------------------------------------------------------------ # import utils # ------------------------------------------------------------------...
[ 198, 834, 9800, 834, 220, 220, 220, 796, 366, 49, 2885, 20151, 12, 4090, 9273, 7712, 4816, 1, 198, 834, 22163, 4766, 834, 796, 366, 15269, 2211, 11, 33540, 20151, 1, 198, 834, 43085, 834, 220, 220, 796, 366, 36393, 1, 628, 198, 11...
3.413121
564
import json from .utils import Utils utils = Utils()
[ 11748, 33918, 198, 6738, 764, 26791, 1330, 7273, 4487, 198, 198, 26791, 796, 7273, 4487, 3419, 198 ]
3.176471
17
# -*- coding: utf-8 -*- if __name__ == '__main__': main()
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 628, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 1388, 3419, 198 ]
2
32
# -*- coding: utf-8 -*- from django.test.client import Client from networkapi.test.test_case import NetworkApiTestCase from networkapi.util.geral import mount_url
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 42625, 14208, 13, 9288, 13, 16366, 1330, 20985, 198, 198, 6738, 3127, 15042, 13, 9288, 13, 9288, 62, 7442, 1330, 7311, 32, 14415, 14402, 20448, 198, 6738, 3127, 15...
3.018182
55
## -*- coding: utf-8 -*- ## (C) 2018 Muthiah Annamalai, <ezhillang@gmail.com> import codecs import os from .resources import get_data_dir
[ 2235, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2235, 357, 34, 8, 2864, 337, 1071, 9520, 5506, 321, 282, 1872, 11, 1279, 8471, 12639, 648, 31, 14816, 13, 785, 29, 198, 198, 11748, 40481, 82, 198, 11748, 28686, 19...
2.545455
55
import os, sys from math import sqrt import numpy as np import torch import torch.nn as nn import torch.nn.functional as F from torch.distributions.laplace import Laplace from torch.distributions.normal import Normal from torch.optim import Adam from einops import rearrange, reduce, repeat from advbench import perturb...
[ 11748, 28686, 11, 25064, 198, 6738, 10688, 1330, 19862, 17034, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 28034, 198, 11748, 28034, 13, 20471, 355, 299, 77, 198, 11748, 28034, 13, 20471, 13, 45124, 355, 376, 198, 6738, 28034, 13, 1...
3.245033
151
#!/usr/bin/env python from __future__ import division, absolute_import, print_function import os import sys import argparse import redmapper if __name__ == '__main__': parser = argparse.ArgumentParser(description='Compute the zred background for all galaxies') parser.add_argument('-c', '--configfile', actio...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 6738, 11593, 37443, 834, 1330, 7297, 11, 4112, 62, 11748, 11, 3601, 62, 8818, 198, 198, 11748, 28686, 198, 11748, 25064, 198, 11748, 1822, 29572, 198, 11748, 2266, 76, 11463, 198, ...
2.823232
198
import socket import uuid from struct import pack
[ 11748, 17802, 198, 11748, 334, 27112, 198, 6738, 2878, 1330, 2353, 198 ]
4.166667
12
from setuptools import setup setup( name='pythonthegathering', packages=['pythonthegathering'], version='1.2.1', description='Replaces everything good and practical about Python with MTG!', author='Theo Hamilton/linky00', author_email='linky00@plotholestudios.com', url='https://github.com/l...
[ 6738, 900, 37623, 10141, 1330, 9058, 198, 198, 40406, 7, 198, 220, 220, 220, 1438, 11639, 79, 5272, 756, 258, 70, 25545, 3256, 198, 220, 220, 220, 10392, 28, 17816, 79, 5272, 756, 258, 70, 25545, 6, 4357, 198, 220, 220, 220, 2196, ...
2.568493
292
from . import common
[ 6738, 764, 1330, 2219, 628 ]
4.4
5
# -*- coding: utf-8 -*- def default_params(): ''' Description: It defines the default parameters of the program. Args: None Return: defaults_dict ''' defaults_dict = {} defaults_dict['program_name'] = 'MATSDP' defaults_dict['version'] = '0.2.4' de...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 201, 198, 4299, 4277, 62, 37266, 33529, 201, 198, 220, 220, 220, 705, 7061, 201, 198, 220, 220, 220, 12489, 25, 201, 198, 220, 220, 220, 220, 220, 220, 220, 632, 15738, 2...
2.319277
498
import scrapy
[ 11748, 15881, 88 ]
4.333333
3
#!/usr/bin/python # -*- coding: utf-8 -*- # ==================================================================== # @author: Joe Del Rocco # @since: 11/02/2017 # @summary: A module with angle and coordinate transformations. # @note: Parts of this file came from angle_utilities.py written by Dan Knowlton of PCG at Cornel...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 38093, 18604, 198, 2, 2488, 9800, 25, 5689, 4216, 13545, 1073, 198, 2, 2488, 20777, 25, 1367, 14, 2999, 14, 5539, 198, ...
3.747228
451
from .base import * import os MINIMUM_SAMPLE_SIZE = 3 TRANSCRIPT_PHRASE_POSITIVE_CONFIDENCE_LIMIT = .51 TRANSCRIPT_PHRASE_NEGATIVE_CONFIDENCE_LIMIT = -.51 TRANSCRIPT_PHRASE_CORRECTION_LOWER_LIMIT = .51 TRANSCRIPT_PHRASE_CORRECTION_UPPER_LIMIT = .66 INSTALLED_APPS += ('storages',) SECRET_KEY = os.environ['SECRET_KEY...
[ 6738, 764, 8692, 1330, 1635, 198, 11748, 28686, 198, 198, 23678, 3955, 5883, 62, 49302, 16437, 62, 33489, 796, 513, 198, 198, 5446, 1565, 6173, 46023, 62, 11909, 49, 11159, 62, 37997, 2043, 9306, 62, 10943, 37, 2389, 18310, 62, 43, 39...
1.954128
1,199
import urllib.request import os import pandas as pd import numpy as np from nltk.tokenize import RegexpTokenizer from nltk.stem.porter import PorterStemmer from nltk.corpus import stopwords df = pd.read_csv('../data/raw/movie_data.csv',encoding='utf-8') #print(df.head(3)) # init Objects tokenizer=RegexpTokenizer(r'\w...
[ 11748, 2956, 297, 571, 13, 25927, 198, 11748, 28686, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 299, 2528, 74, 13, 30001, 1096, 1330, 797, 25636, 79, 30642, 7509, 198, 6738, 299, 2528, 74, 13,...
2.633721
516
import numpy as np ######################################## # Jeong approximate functions ########################################
[ 11748, 299, 32152, 355, 45941, 198, 198, 29113, 7804, 198, 2, 220, 220, 220, 220, 3852, 506, 27665, 5499, 198, 29113, 7804, 628, 628 ]
5.791667
24
from rest_framework.decorators import api_view from fastrunner.utils import loader,newloader from rest_framework.response import Response from fastrunner.utils.parser import Format from fastrunner import models from django.conf import settings import os,time,sys from httprunner.utils import create_scaffold from fastrun...
[ 6738, 1334, 62, 30604, 13, 12501, 273, 2024, 1330, 40391, 62, 1177, 198, 6738, 3049, 16737, 13, 26791, 1330, 40213, 11, 3605, 29356, 198, 6738, 1334, 62, 30604, 13, 26209, 1330, 18261, 198, 6738, 3049, 16737, 13, 26791, 13, 48610, 1330,...
2.32344
2,965
from math import floor print(count_by([6.1,4.2,6.3], floor)) print(count_by(['one', 'two', 'three'], len))
[ 198, 6738, 10688, 1330, 4314, 198, 198, 4798, 7, 9127, 62, 1525, 26933, 21, 13, 16, 11, 19, 13, 17, 11, 21, 13, 18, 4357, 4314, 4008, 198, 4798, 7, 9127, 62, 1525, 7, 17816, 505, 3256, 705, 11545, 3256, 705, 15542, 6, 4357, 1889...
2.340426
47
from lifelines.datasets import load_rossi from lifelines import CoxPHFitter rossi_dataset = load_rossi() cph = CoxPHFitter() cph.fit(rossi_dataset, duration_col='week', event_col='arrest', show_progress=True) cph.print_summary() # access the results using cph.summary
[ 6738, 3868, 20655, 13, 19608, 292, 1039, 1330, 3440, 62, 1214, 72, 198, 6738, 3868, 20655, 1330, 18014, 11909, 37, 1967, 198, 198, 1214, 72, 62, 19608, 292, 316, 796, 3440, 62, 1214, 72, 3419, 198, 66, 746, 796, 18014, 11909, 37, 19...
2.842105
95
# ==================================================================== # 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 re...
[ 2, 38093, 18604, 198, 2, 220, 220, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 220, 220, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, 198, 2, 220, 220, 921,...
3.861789
246
import h5py import numpy as np # @staticmethod # def _preprocess_group_value(group): # data = group['data'][:] # labels = group['labels'][:] # result = [(data[i][np.newaxis], labels[i, 0]) for i in range(data.shape[0])] # return result # @staticmethod # def _preproces...
[ 11748, 289, 20, 9078, 198, 11748, 299, 32152, 355, 45941, 628, 628, 220, 220, 220, 1303, 2488, 12708, 24396, 198, 220, 220, 220, 1303, 825, 4808, 3866, 14681, 62, 8094, 62, 8367, 7, 8094, 2599, 198, 220, 220, 220, 1303, 220, 220, 22...
2.269231
208
import itertools import unittest from typing import List, Optional, Union, Tuple from . import children_entity_parser from .predicate import Predicate from ..most_general_unifier import MostGeneralUnifier class Clause(object): """ Class for keeping predicates together and some several multi-predicate suppor...
[ 11748, 340, 861, 10141, 198, 11748, 555, 715, 395, 198, 198, 6738, 19720, 1330, 7343, 11, 32233, 11, 4479, 11, 309, 29291, 198, 198, 6738, 764, 1330, 1751, 62, 26858, 62, 48610, 198, 6738, 764, 28764, 5344, 1330, 14322, 5344, 198, 673...
2.540541
2,442
import PySimpleGUI as sg import app_state as app import dashboard import backend import os from loguru import logger import traceback import arus
[ 11748, 9485, 26437, 40156, 355, 264, 70, 198, 11748, 598, 62, 5219, 355, 598, 198, 11748, 30415, 198, 11748, 30203, 198, 11748, 28686, 198, 6738, 2604, 14717, 1330, 49706, 198, 11748, 12854, 1891, 198, 11748, 610, 385, 628, 198 ]
3.794872
39
import time import timeit from handlerPdf import getPDFname, getLocalTime from pathlib import Path, PurePath
[ 11748, 640, 198, 11748, 640, 270, 198, 6738, 21360, 47, 7568, 1330, 651, 20456, 3672, 11, 651, 14565, 7575, 198, 6738, 3108, 8019, 1330, 10644, 11, 17129, 15235, 628, 628 ]
3.733333
30
import unittest import random import axelrod C, D = axelrod.Actions.C, axelrod.Actions.D
[ 11748, 555, 715, 395, 198, 11748, 4738, 198, 11748, 7877, 417, 14892, 198, 198, 34, 11, 360, 796, 7877, 417, 14892, 13, 32, 2733, 13, 34, 11, 7877, 417, 14892, 13, 32, 2733, 13, 35, 198 ]
2.5
36
import numpy as np import pytest import torch from supermariopy.ptutils import nn
[ 11748, 299, 32152, 355, 45941, 198, 11748, 12972, 9288, 198, 11748, 28034, 198, 6738, 2208, 76, 2743, 11081, 13, 457, 26791, 1330, 299, 77, 628, 628, 628, 628, 628, 628, 628, 628 ]
3.03125
32
from dimagi.ext.couchdbkit import DecimalProperty, Document, StringProperty from corehq.apps.cachehq.mixins import CachedCouchDocumentMixin TYPE_DOMAIN = 'domain' TYPE_PRODUCT = 'product' TYPE_SUPPLY_POINT_TYPE = 'supply-point-type' TYPE_SUPPLY_POINT = 'supply-point' class DefaultConsumption(CachedCouchDocumentMixi...
[ 6738, 5391, 18013, 13, 2302, 13, 66, 7673, 9945, 15813, 1330, 4280, 4402, 21746, 11, 16854, 11, 10903, 21746, 198, 198, 6738, 4755, 71, 80, 13, 18211, 13, 23870, 71, 80, 13, 19816, 1040, 1330, 327, 2317, 34, 7673, 24941, 35608, 259, ...
2.968872
257
# --- # jupyter: # jupytext: # formats: ipynb,py:percent # text_representation: # extension: .py # format_name: percent # format_version: '1.3' # jupytext_version: 1.13.7 # kernelspec: # display_name: Python [conda env:bandit_38] # language: python # name: conda-env-bandi...
[ 2, 11420, 198, 2, 474, 929, 88, 353, 25, 198, 2, 220, 220, 474, 929, 88, 5239, 25, 198, 2, 220, 220, 220, 220, 17519, 25, 20966, 2047, 65, 11, 9078, 25, 25067, 198, 2, 220, 220, 220, 220, 2420, 62, 15603, 341, 25, 198, 2, 22...
2.157093
4,265
import argparse import json import os import re import sys from configparser import ConfigParser from configparser import NoOptionError from configparser import NoSectionError from configparser import ParsingError from typing import Union, Dict from oelint_parser.cls_stash import Stash from oelint_parser.constants imp...
[ 11748, 1822, 29572, 198, 11748, 33918, 198, 11748, 28686, 198, 11748, 302, 198, 11748, 25064, 198, 6738, 4566, 48610, 1330, 17056, 46677, 198, 6738, 4566, 48610, 1330, 1400, 19722, 12331, 198, 6738, 4566, 48610, 1330, 1400, 16375, 12331, 19...
2.715517
464
#!/usr/bin/env python # -*- coding: utf-8 -*- """ String manipulate. """ # left strip assert " Hello ".lstrip() == "Hello " # right strip assert " Hello ".rstrip() == " Hello" # strip assert " Hello ".strip() == "Hello" # upper case assert "Hello".upper() == "HELLO" # lower case assert "Hello".lower() == ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 37811, 198, 10100, 18510, 13, 198, 37811, 198, 198, 2, 1364, 10283, 198, 30493, 366, 220, 18435, 220, 27071, 75, ...
2.677704
453
""" This file contains unittests for the api app. Use test_settings when running this: ./manage.py test --settings=dyanote.test_settings api This will use sqlite and other settings to make test execution faster. Command used to create test database. ./manage.py dumpdata --indent=4 --natural -e admin -e se...
[ 37811, 198, 1212, 2393, 4909, 555, 715, 3558, 329, 262, 40391, 598, 13, 198, 198, 11041, 1332, 62, 33692, 618, 2491, 428, 25, 198, 19571, 805, 496, 13, 9078, 1332, 1377, 33692, 28, 67, 4121, 1258, 13, 9288, 62, 33692, 40391, 198, 12...
2.965092
487
import pytest import shutil import tempfile import os import pipes import ujson as json CORPUS = { "docs": [ { "url": "http://www.douglasadams.com/", "content": """ <title>xxxxuniquecontent</title> """ }, { "url": "http://www.example.com/page1", ...
[ 11748, 12972, 9288, 198, 11748, 4423, 346, 198, 11748, 20218, 7753, 198, 11748, 28686, 198, 11748, 19860, 198, 11748, 334, 17752, 355, 33918, 198, 198, 44879, 47, 2937, 796, 1391, 198, 220, 220, 220, 366, 31628, 1298, 685, 198, 220, 220...
2.046296
216
import sys sys.path.insert(1,"../../../") import h2o from tests import pyunit_utils from h2o.estimators.glm import H2OGeneralizedLinearEstimator if __name__ == "__main__": pyunit_utils.standalone_test(glm_mean_residual_deviance) else: glm_mean_residual_deviance()
[ 11748, 25064, 198, 17597, 13, 6978, 13, 28463, 7, 16, 553, 40720, 40720, 40720, 4943, 198, 11748, 289, 17, 78, 198, 6738, 5254, 1330, 12972, 20850, 62, 26791, 198, 6738, 289, 17, 78, 13, 395, 320, 2024, 13, 4743, 76, 1330, 367, 17, ...
2.542056
107
from ScopeFoundry import HardwareComponent from ScopeFoundryHW.ni_daq.devices.NI_Daq import NI_DacTask
[ 6738, 41063, 21077, 563, 1330, 28715, 21950, 198, 6738, 41063, 21077, 563, 39, 54, 13, 8461, 62, 48539, 13, 42034, 13, 22125, 62, 26531, 80, 1330, 24947, 62, 35, 330, 25714 ]
3.290323
31
"""cli.alerter -- control alerter With ``alerter`` command you can control the :py:mod:`~elastico.alerter` module. For more help on a command, run:: elastico alerter <command> -h """ from .cli import command, opt, arg from ..alerter import Alerter from ..connection import elasticsearch from ..util import write_o...
[ 37811, 44506, 13, 36213, 353, 1377, 1630, 435, 263, 353, 198, 198, 3152, 7559, 36213, 353, 15506, 3141, 345, 460, 1630, 262, 1058, 9078, 25, 4666, 25, 63, 93, 417, 3477, 78, 13, 36213, 353, 63, 198, 21412, 13, 198, 198, 1890, 517, ...
2.677885
1,040
import time import uuid from ...config import AppConfig from ...middleware.interface import MiddlewareBase from ...session.interfaces import ISessionProvider from ...util import md5, b64
[ 11748, 640, 201, 198, 11748, 334, 27112, 201, 198, 201, 198, 6738, 2644, 11250, 1330, 2034, 16934, 201, 198, 6738, 2644, 27171, 1574, 13, 39994, 1330, 6046, 1574, 14881, 201, 198, 6738, 2644, 29891, 13, 3849, 32186, 1330, 3180, 2521, 29...
3.517857
56
LATESTMFILE = 'last_id.txt' LOGFILE = "twitterbot_log.txt" verbose = False twitterName = "ui_cer_bot" # Liste de terme qui servent pour répondre answers = ['ahah :)' , 'YO' , 'O_O', 'stoi' , 'TG' , 'MER IL ET FOU'] # Liste des terme qui servent a repondre "stoi xxxx" bad_words = {'boloss' : 'le boloss', 'boulette' :...
[ 171, 119, 123, 43, 1404, 6465, 44, 25664, 796, 705, 12957, 62, 312, 13, 14116, 6, 198, 25294, 25664, 796, 366, 6956, 13645, 62, 6404, 13, 14116, 1, 198, 19011, 577, 796, 10352, 198, 6956, 5376, 796, 366, 9019, 62, 2189, 62, 13645, ...
2.379747
395
from dsa.data_structures import LinkedList, ListNode l = [1, 2, 3] ll = LinkedList(l, doubly=False) mid_n = ll.head.next_node delete_middle_node(mid_n) str(ll)
[ 6738, 288, 11400, 13, 7890, 62, 7249, 942, 1330, 7502, 276, 8053, 11, 7343, 19667, 628, 198, 198, 75, 796, 685, 16, 11, 362, 11, 513, 60, 198, 297, 796, 7502, 276, 8053, 7, 75, 11, 3385, 306, 28, 25101, 8, 198, 13602, 62, 77, ...
2.328571
70
from django.db import models from django.db.models.deletion import CASCADE # Create your models here.
[ 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 6738, 42625, 14208, 13, 9945, 13, 27530, 13, 2934, 1616, 295, 1330, 35106, 34, 19266, 198, 198, 2, 13610, 534, 4981, 994, 13 ]
3.290323
31
#!/usr/bin/env python3 from collections import defaultdict if __name__ == '__main__': import argparse parser = argparse.ArgumentParser() parser.add_argument('csv', nargs='?', default=None, help='the CSV format callgraph to transform') args = parser.parse_args() import...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 6738, 17268, 1330, 4277, 11600, 628, 628, 628, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 1330, 1822, 29572, 198, 220, 220, 220, 30751,...
2.563536
181
#!/usr/bin/env python3 # Copyright 2021 Canonical Ltd. # See LICENSE file for licensing details. import logging from charms.operator_libs_linux.v0 import passwd from helpers import lines_in_file logger = logging.getLogger(__name__)
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 15069, 33448, 19507, 605, 12052, 13, 198, 2, 4091, 38559, 24290, 2393, 329, 15665, 3307, 13, 628, 198, 11748, 18931, 198, 198, 6738, 41700, 13, 46616, 62, 8019, 82, 62, 23289, ...
3.184211
76
# !/usr/bin/python3 import string import time import random import json import yaml import ssl import base64 import logging from logging.config import fileConfig import importlib import argparse import os import re from rich.logging import RichHandler from datetime import datetime import paho.mqtt.client as mqtt fr...
[ 2, 5145, 14, 14629, 14, 8800, 14, 29412, 18, 198, 198, 11748, 4731, 198, 11748, 640, 198, 11748, 4738, 198, 11748, 33918, 198, 11748, 331, 43695, 198, 11748, 264, 6649, 198, 11748, 2779, 2414, 198, 11748, 18931, 198, 6738, 18931, 13, ...
2.295628
1,830
# Author-Patrick Rainsberry # Description-Simplified Slicer for Fusion 360 # Importing sample Fusion Command # Could import multiple Command definitions here from .FusionSlicerLTCommand import FusionSlicerLTCommand, FusionSlicerLTCommand2 commands = [] command_definitions = [] # Define parameters for 1st command cmd...
[ 2, 6434, 12, 32718, 371, 1299, 8396, 198, 2, 12489, 12, 8890, 489, 1431, 311, 677, 263, 329, 21278, 11470, 198, 198, 2, 17267, 278, 6291, 21278, 9455, 198, 2, 10347, 1330, 3294, 9455, 17336, 994, 198, 6738, 764, 37, 4241, 50, 677, ...
2.864745
451
import subprocess import tempfile from pathlib import Path import requests from mutagen.easyid3 import EasyID3 from mutagen.id3 import APIC, ID3 from mutagen.mp3 import MP3 from pathvalidate import sanitize_filename from PyQt5.QtCore import QThread from vk_api.audio import VkAudio from entities.album import VkAlbum f...
[ 11748, 850, 14681, 198, 11748, 20218, 7753, 198, 6738, 3108, 8019, 1330, 10644, 198, 198, 11748, 7007, 198, 6738, 4517, 11286, 13, 38171, 312, 18, 1330, 16789, 2389, 18, 198, 6738, 4517, 11286, 13, 312, 18, 1330, 3486, 2149, 11, 4522, ...
3.325581
129
import h5py import math import time import numpy import sys from functools import reduce from keras.models import Sequential from keras.layers import GRU, LSTM, Dropout, Dense from keras.layers.wrappers import TimeDistributed from keras.callbacks import ModelCheckpoint from keras.utils import np_utils with open('./dat...
[ 11748, 289, 20, 9078, 198, 11748, 10688, 198, 11748, 640, 198, 11748, 299, 32152, 198, 11748, 25064, 198, 6738, 1257, 310, 10141, 1330, 4646, 198, 6738, 41927, 292, 13, 27530, 1330, 24604, 1843, 198, 6738, 41927, 292, 13, 75, 6962, 1330...
2.476839
734
# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other # Spack Project Developers. See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: (Apache-2.0 OR MIT) from spack.package import * class RClue(RPackage): """Cluster Ensembles.""" cran = "clue" version('0.3-61'...
[ 2, 15069, 2211, 12, 1238, 1828, 13914, 45036, 3549, 2351, 4765, 11, 11419, 290, 584, 198, 2, 1338, 441, 4935, 34152, 13, 4091, 262, 1353, 12, 5715, 27975, 38162, 9947, 2393, 329, 3307, 13, 198, 2, 198, 2, 30628, 55, 12, 34156, 12, ...
2.146739
368
print(min(a,b,c))
[ 4798, 7, 1084, 7, 64, 11, 65, 11, 66, 4008, 198 ]
1.636364
11
import nltk from nltk import tokenize from nltk.util import ngrams import os from vaderSentiment.vaderSentiment import SentimentIntensityAnalyzer from readability import Readability import collections from nltk.stem.porter import * from nltk import word_tokenize import string import pickle ### This File co...
[ 11748, 299, 2528, 74, 201, 198, 6738, 299, 2528, 74, 1330, 11241, 1096, 201, 198, 6738, 299, 2528, 74, 13, 22602, 1330, 299, 4546, 82, 201, 198, 11748, 28686, 201, 198, 6738, 410, 5067, 31837, 3681, 13, 85, 5067, 31837, 3681, 1330, ...
2.807229
166
#! /usr/bin/env python3 # -*- coding: utf-8 -*- # # Copyright 2017 Romain Boman # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # ...
[ 2, 0, 1220, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 198, 2, 220, 220, 15069, 2177, 3570, 391, 347, 5185, 198, 2, 198, 2, 220, 220, 49962, 739, 262, 24843, 1...
2.964674
368
import h5py import os
[ 11748, 289, 20, 9078, 198, 11748, 28686, 220, 198 ]
2.555556
9
import tensorflow as tf import numpy as np from sklearn.feature_extraction import text from sklearn import feature_selection from tensorflow.python.util import nest from autokeras import const from autokeras.hypermodel import hyper_block as hb_module class HyperPreprocessor(hb_module.HyperBlock): """Hyper prepro...
[ 11748, 11192, 273, 11125, 355, 48700, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 1341, 35720, 13, 30053, 62, 2302, 7861, 1330, 2420, 198, 6738, 1341, 35720, 1330, 3895, 62, 49283, 198, 6738, 11192, 273, 11125, 13, 29412, 13, 22602, ...
2.585405
1,850