content
stringlengths
1
1.04M
input_ids
listlengths
1
774k
ratio_char_token
float64
0.38
22.9
token_count
int64
1
774k
"""Tests for the vaillant HUB.""" import mock import pytest from pymultimatic.api import ApiError from homeassistant.components import vaillant from homeassistant.components.vaillant import DOMAIN from tests.components.vaillant import _setup, SystemManagerMock @pytest.fixture(autouse=True) def fixture_no_platform(m...
[ 37811, 51, 3558, 329, 262, 46935, 359, 415, 367, 10526, 526, 15931, 198, 198, 11748, 15290, 198, 11748, 12972, 9288, 198, 6738, 279, 4948, 586, 320, 1512, 13, 15042, 1330, 5949, 72, 12331, 198, 198, 6738, 1363, 562, 10167, 13, 5589, 3...
2.730088
452
import datetime from django.contrib import messages from django.shortcuts import redirect from django.utils import timezone from django.views.generic import CreateView, DetailView, FormView, UpdateView, View from django.views.generic.detail import SingleObjectMixin from website.apps.core.mixins import IsActiveObjectM...
[ 11748, 4818, 8079, 198, 198, 6738, 42625, 14208, 13, 3642, 822, 1330, 6218, 198, 6738, 42625, 14208, 13, 19509, 23779, 1330, 18941, 198, 6738, 42625, 14208, 13, 26791, 1330, 640, 11340, 198, 6738, 42625, 14208, 13, 33571, 13, 41357, 1330,...
3.531323
431
#!/usr/bin/env python # -*- Mode: Python; tab-width: 4; indent-tabs-mode: nil; -*- # vim:set ft=python ts=4 sw=4 sts=4 autoindent: """Main entry for the brat server, ensures integrity, handles dispatch and processes potential exceptions before returning them to be sent as responses. NOTE(S): * Defer imports until fa...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 10363, 25, 11361, 26, 7400, 12, 10394, 25, 604, 26, 33793, 12, 8658, 82, 12, 14171, 25, 18038, 26, 532, 9, 12, 198, 2, 43907, 25, 2617, 10117, 28, 29412, 40379, 28...
3.068085
470
"""A handler that sends mails.""" import smtplib import os.path from ConfigParser import RawConfigParser from email.mime.multipart import MIMEMultipart from email.mime.text import MIMEText # load config CFG_PATH = os.path.join( os.path.dirname(__file__), '..', '..', '..', 'notify.cfg') CONFIG = RawConfigParser()...
[ 37811, 32, 21360, 326, 12800, 285, 1768, 526, 15931, 198, 198, 11748, 895, 83, 489, 571, 198, 11748, 28686, 13, 6978, 198, 6738, 17056, 46677, 1330, 16089, 16934, 46677, 198, 198, 6738, 3053, 13, 76, 524, 13, 16680, 541, 433, 1330, 33...
2.363176
592
from pyspark.sql import Row from string import ascii_lowercase from splink.estimate import estimate_u_values from uuid import uuid4 from splink.case_statements import sql_gen_case_smnt_strict_equality_2 import pytest
[ 6738, 279, 893, 20928, 13, 25410, 1330, 11314, 198, 6738, 4731, 1330, 355, 979, 72, 62, 21037, 7442, 198, 198, 6738, 4328, 676, 13, 395, 1920, 1330, 8636, 62, 84, 62, 27160, 198, 6738, 334, 27112, 1330, 334, 27112, 19, 198, 6738, 43...
3.098592
71
""" Drop Path Hacked together by / Copyright 2020 Ross Wightman (https://github.com/rwightman) """ import jax.random as jr from objax import random from objax.typing import JaxArray def drop_path(x: JaxArray, drop_prob: float = 0., generator=random.DEFAULT_GENERATOR) -> JaxArray: """Drop paths (Stochastic Depth) ...
[ 37811, 14258, 10644, 198, 39, 6021, 1978, 416, 1220, 15069, 12131, 9847, 370, 432, 805, 357, 5450, 1378, 12567, 13, 785, 14, 31653, 432, 805, 8, 198, 37811, 198, 11748, 474, 897, 13, 25120, 355, 474, 81, 198, 6738, 26181, 897, 1330, ...
2.981481
378
""" Code to enable coverage of any external code called by the notebook. """ import os import coverage # Coverage setup/teardown code to run in kernel # Inspired by pytest-cov code. _python_setup = """\ import coverage __cov = coverage.Coverage( data_file=%r, source=%r, config_file=%r, auto_data=Tru...
[ 37811, 198, 10669, 284, 7139, 5197, 286, 597, 7097, 2438, 1444, 416, 262, 198, 11295, 2070, 13, 198, 37811, 198, 198, 11748, 28686, 198, 11748, 5197, 628, 198, 2, 33998, 9058, 14, 660, 446, 593, 2438, 284, 1057, 287, 9720, 198, 2, 4...
2.7182
2,445
from flask import request from flask_restful import Resource
[ 6738, 42903, 1330, 2581, 198, 6738, 42903, 62, 2118, 913, 1330, 20857, 628 ]
4.769231
13
import requests import json from blizzardapi import BlizzardApi f = open('utils/APIClient.json',) data = json.load(f) api_client = BlizzardApi(data['client_id'], data['client_secret']) for i in range(0,6): data = api_client.hearthstone.game_data.search_cards("eu","en_US", game_mode="battlegrounds", tier=i+1, p...
[ 11748, 7007, 198, 11748, 33918, 198, 6738, 698, 16191, 15042, 1330, 20206, 32, 14415, 198, 198, 69, 796, 1280, 10786, 26791, 14, 2969, 2149, 75, 1153, 13, 17752, 3256, 8, 198, 7890, 796, 33918, 13, 2220, 7, 69, 8, 198, 198, 15042, 6...
2.532164
171
import FWCore.ParameterSet.Config as cms from FastSimulation.Configuration.Geometries_cff import * import FastSimulation.SimplifiedGeometryPropagator.fastSimProducer_cff # Apply Tracker and Muon misalignment process.fastSimProducer.detectorDefinition.trackerAlignmentLabel = cms.untracked.string("") misalignedTracker...
[ 11748, 48849, 14055, 13, 36301, 7248, 13, 16934, 355, 269, 907, 198, 198, 6738, 12549, 8890, 1741, 13, 38149, 13, 10082, 908, 1678, 62, 66, 487, 1330, 1635, 198, 198, 11748, 12549, 8890, 1741, 13, 8890, 489, 1431, 10082, 15748, 24331, ...
3.429688
128
# -*- coding: utf-8 -*- # # This software may be modified and distributed under the terms # of the MIT license. See the LICENSE file for details. from collections import OrderedDict from difflib import unified_diff from os.path import splitext from pathlib import Path from mezzanine.pages.models import Page from me...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 198, 2, 770, 3788, 743, 307, 9518, 290, 9387, 739, 262, 2846, 198, 2, 286, 262, 17168, 5964, 13, 220, 4091, 262, 38559, 24290, 2393, 329, 3307, 13, 198, 198, 6738...
5.846154
156
import logging import webapp2 import config import re import json import models from google.appengine.api import mail ''' Base controller to deal with 500 errors ''' class base_page_controller(webapp2.RequestHandler): """ Base pag controller """ ''' Show the home page. ''' ''' Send the email ''' ''' Show the t...
[ 11748, 18931, 198, 11748, 3992, 1324, 17, 198, 11748, 4566, 198, 11748, 302, 198, 11748, 33918, 198, 11748, 4981, 198, 6738, 23645, 13, 1324, 18392, 13, 15042, 1330, 6920, 198, 198, 7061, 6, 198, 14881, 10444, 284, 1730, 351, 5323, 8563...
3.190909
110
#!/usr/bin/env python import argparse parser = argparse.ArgumentParser(description="Measure statistics across multiple chains.") parser.add_argument("--burn", type=int, default=0, help="How many samples to discard from the beginning of the chain for burn in.") parser.add_argument("--config", default="config.yaml", he...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 11748, 1822, 29572, 198, 198, 48610, 796, 1822, 29572, 13, 28100, 1713, 46677, 7, 11213, 2625, 47384, 7869, 1973, 3294, 14659, 19570, 198, 48610, 13, 2860, 62, 49140, 7203, 438, 108...
3
461
import pygame import game pygame.init() pygame.display.set_caption('R') clock = pygame.time.Clock() fps = 60 gameDisp = pygame.display.set_mode((800, 600), pygame.HWSURFACE|pygame.DOUBLEBUF|pygame.RESIZABLE) while True: for event in pygame.event.get(): if event.type == pygame.QUIT: quitfun...
[ 11748, 12972, 6057, 220, 198, 11748, 983, 198, 198, 9078, 6057, 13, 15003, 3419, 198, 198, 9078, 6057, 13, 13812, 13, 2617, 62, 6888, 1159, 10786, 49, 11537, 198, 15750, 796, 12972, 6057, 13, 2435, 13, 44758, 3419, 198, 29647, 796, 31...
2.318681
182
from flask_sqlalchemy import SQLAlchemy from .app import app db = SQLAlchemy(app) db_engine = db.engine db_connection = db_engine.connect()
[ 6738, 42903, 62, 25410, 282, 26599, 1330, 16363, 2348, 26599, 198, 198, 6738, 764, 1324, 1330, 598, 198, 198, 9945, 796, 16363, 2348, 26599, 7, 1324, 8, 198, 198, 9945, 62, 18392, 796, 20613, 13, 18392, 198, 9945, 62, 38659, 796, 2061...
2.979167
48
# -*- coding: utf-8 -*- # Generated by Django 1.11.13 on 2018-06-08 04:57 from __future__ import unicode_literals import django.core.validators 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, 1485, 319, 2864, 12, 3312, 12, 2919, 8702, 25, 3553, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198,...
2.833333
66
#!/usr/bin/env python from settings import * import numpy as np import struct
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 6738, 6460, 1330, 1635, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 2878, 198 ]
3.291667
24
""" Prepare MDS cluster for upgrade. """ import logging import time from tasks.cephfs.filesystem import Filesystem log = logging.getLogger(__name__) def task(ctx, config): """ Prepare MDS cluster for upgrade. This task reduces ranks to 1 and stops all standbys. """ if config is None: c...
[ 37811, 198, 37534, 533, 337, 5258, 13946, 329, 8515, 13, 198, 37811, 198, 198, 11748, 18931, 198, 11748, 640, 198, 198, 6738, 8861, 13, 344, 746, 9501, 13, 16624, 6781, 1330, 13283, 6781, 198, 198, 6404, 796, 18931, 13, 1136, 11187, 1...
2.419501
441
# -*- coding: utf-8 -*- """ Created on Thu May 21 15:21:59 2020 @author: Reuben """ import unittest import numpy as np import npsolve.soft_functions as soft
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 41972, 319, 26223, 1737, 2310, 1315, 25, 2481, 25, 3270, 12131, 198, 198, 31, 9800, 25, 797, 44636, 198, 37811, 628, 198, 11748, 555, 715, 395, 198, 11748, ...
1.596685
181
""" Pay to delegated puzzle or hidden puzzle In this puzzle program, the solution must choose either a hidden puzzle or a delegated puzzle on a given public key. The given public key is morphed by adding an offset from the hash of the hidden puzzle and itself, giving a new so-called "synthetic" public key which has t...
[ 37811, 198, 19197, 284, 49711, 15027, 393, 7104, 15027, 198, 198, 818, 428, 15027, 1430, 11, 262, 4610, 1276, 3853, 2035, 257, 7104, 15027, 393, 257, 198, 2934, 1455, 515, 15027, 319, 257, 1813, 1171, 1994, 13, 198, 198, 464, 1813, 11...
3.604207
1,046
from ..mapper import PropertyMapper, ApiInterfaceBase from ..mapper.types import Timestamp, AnyType __all__ = ['Surface', 'SurfaceInterface']
[ 6738, 11485, 76, 11463, 1330, 14161, 44, 11463, 11, 5949, 72, 39317, 14881, 198, 6738, 11485, 76, 11463, 13, 19199, 1330, 5045, 27823, 11, 4377, 6030, 198, 198, 834, 439, 834, 796, 37250, 14214, 2550, 3256, 705, 14214, 2550, 39317, 2052...
3.372093
43
from .board import Board
[ 6738, 764, 3526, 1330, 5926, 201, 198 ]
3.714286
7
#! /usr/bin/env python ###################### # quality_check.py ###################### # A program to loop through and inspect SWS results, plot the QA result from # Splitwavepy and print the measured SKS and SKKS splitting from Sheba # A measure of measure of data quality and discernable discrepancy between results i...
[ 2, 0, 1220, 14629, 14, 8800, 14, 24330, 21015, 198, 14468, 4242, 2235, 198, 2, 3081, 62, 9122, 13, 9078, 198, 14468, 4242, 2235, 198, 2, 317, 1430, 284, 9052, 832, 290, 10104, 12672, 50, 2482, 11, 7110, 262, 1195, 32, 1255, 422, 1...
3.466488
373
$NetBSD: patch-gyptest.py,v 1.4 2014/08/21 14:49:43 he Exp $ * Add NetBSD 5, 6 and 7 target --- gyptest.py.orig 2014-07-14 14:19:50.000000000 +0000 +++ gyptest.py + 'freebsd9': ['make'], + 'netbsd5': ['make'], + 'netbsd6': ['make'], + 'netbsd7': ['make'], 'openbsd5': ['make'], 'cy...
[ 3, 7934, 21800, 25, 8529, 12, 6022, 395, 13, 9078, 11, 85, 352, 13, 19, 1946, 14, 2919, 14, 2481, 1478, 25, 2920, 25, 3559, 339, 5518, 720, 198, 198, 9, 3060, 3433, 21800, 642, 11, 718, 290, 767, 2496, 198, 198, 6329, 21486, 457...
1.848039
204
""" Canvas fast grading script by makersmelx <makersmelx@gmail.com> """ import os dotenv_path = '.env'
[ 37811, 198, 6090, 11017, 3049, 43165, 4226, 198, 1525, 14429, 17694, 87, 1279, 6620, 17694, 87, 31, 14816, 13, 785, 29, 198, 37811, 198, 198, 11748, 28686, 198, 198, 26518, 24330, 62, 6978, 796, 45302, 24330, 6, 628 ]
2.789474
38
# (C) Copyright 2018, 2020 by Rocky Bernstein # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or (at your option) any later version. # # This program is...
[ 2, 357, 34, 8, 15069, 2864, 11, 12131, 416, 24534, 37584, 198, 2, 198, 2, 220, 770, 1430, 318, 1479, 3788, 26, 345, 460, 17678, 4163, 340, 290, 14, 273, 198, 2, 220, 13096, 340, 739, 262, 2846, 286, 262, 22961, 3611, 5094, 13789, ...
2.58473
1,074
''' Created on Jul 30, 2017 @author: Daniel Sela, Arnon Sela ''' def add_coords(coords, delta): ''' Adds (or substructs) number to (from) coords Args: coords: 235959.456 style coords delta: ss number to add (negative to sub) ''' temp = decim_2_sec(coords) temp += delta ret...
[ 7061, 6, 198, 41972, 319, 5979, 1542, 11, 2177, 198, 198, 31, 9800, 25, 7806, 311, 10304, 11, 943, 13159, 311, 10304, 198, 7061, 6, 628, 628, 198, 198, 4299, 751, 62, 1073, 3669, 7, 1073, 3669, 11, 25979, 2599, 198, 220, 220, 220,...
2.109244
476
# -*- coding: utf-8 -*- from __future__ import (absolute_import, division, print_function, unicode_literals) import json import os import socket import sys import snappy SERVER = "127.0.0.1" PORT = 6543 if __name__ == "__main__": ping()
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 11593, 37443, 834, 1330, 357, 48546, 62, 11748, 11, 7297, 11, 3601, 62, 8818, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 22...
2.336207
116
from __future__ import unicode_literals import datetime from django.utils import timezone from alexia.apps.billing.models import ( Authorization, Order, PermanentProduct, PriceGroup, ProductGroup, Purchase, TemporaryProduct, ) from alexia.apps.scheduling.models import Event from alexia.test import TestCase ...
[ 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, 198, 11748, 4818, 8079, 198, 198, 6738, 42625, 14208, 13, 26791, 1330, 640, 11340, 198, 198, 6738, 257, 2588, 544, 13, 18211, 13, 65, 4509, 13, 27530, 1330, 357, 198, 22...
3.490741
108
### clustering.py #Copyright 2005-2008 J. David Gladstone Institutes, San Francisco California #Author Nathan Salomonis - nsalomonis@gmail.com #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 ...
[ 21017, 32966, 1586, 13, 9078, 198, 2, 15269, 5075, 12, 11528, 449, 13, 3271, 28442, 6440, 33656, 11, 2986, 6033, 3442, 198, 2, 13838, 18106, 4849, 16698, 271, 532, 299, 21680, 16698, 271, 31, 14816, 13, 785, 198, 198, 2, 5990, 3411, ...
2.344879
18,015
# Copyright (c) Jeroen Van Steirteghem # See LICENSE from twisted.conch import avatar from twisted.conch.error import ValidPublicKey from twisted.conch.ssh import channel, factory, forwarding, keys from twisted.cred import checkers, credentials, portal from twisted.cred.error import UnauthorizedLogin from twisted.inte...
[ 2, 15069, 357, 66, 8, 449, 3529, 268, 6656, 2441, 343, 660, 70, 4411, 198, 2, 4091, 38559, 24290, 198, 198, 6738, 19074, 13, 1102, 354, 1330, 30919, 198, 6738, 19074, 13, 1102, 354, 13, 18224, 1330, 48951, 15202, 9218, 198, 6738, 19...
3.730769
130
import pytest import json @pytest.mark.usefixtures('cleanup_db') async def test_todo_api(app, test_cli): """ testing todo api """ # GET resp = await test_cli.get('/api/todo') assert resp.status == 200 resp_json = await resp.json() assert len(resp_json['todo_list']) == 0 # POST ...
[ 11748, 12972, 9288, 198, 11748, 33918, 628, 198, 31, 9078, 9288, 13, 4102, 13, 1904, 69, 25506, 10786, 27773, 929, 62, 9945, 11537, 198, 292, 13361, 825, 1332, 62, 83, 24313, 62, 15042, 7, 1324, 11, 1332, 62, 44506, 2599, 198, 220, ...
2.246696
454
import cv2 import tensorflow as tf
[ 11748, 269, 85, 17, 198, 11748, 11192, 273, 11125, 355, 48700, 628 ]
3
12
# -*- coding: utf-8 -*- ''' Cassandra cql returner test cases ''' # Import Python libs from __future__ import absolute_import # Import Salt Testing libs from tests.support.unit import TestCase, skipIf from tests.support.mock import patch, NO_MOCK, NO_MOCK_REASON from tests.support.mixins import LoaderModuleMockMixin ...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 7061, 6, 198, 43529, 15918, 269, 13976, 1441, 263, 1332, 2663, 198, 7061, 6, 198, 198, 2, 17267, 11361, 9195, 82, 198, 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, ...
2.340463
561
from typing import List
[ 6738, 19720, 1330, 7343, 628 ]
5
5
import json import listpad import numpy as np import qnd import qndex import tensorflow as tf def def_convert_json_example(): """Define json example converter. An example is the following. ```json [ { "word": "I", "label": 0 }, { "word": "am", "label": 0 }, { "word": "Bob...
[ 11748, 33918, 198, 198, 11748, 1351, 15636, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 10662, 358, 198, 11748, 10662, 358, 1069, 198, 11748, 11192, 273, 11125, 355, 48700, 628, 198, 4299, 825, 62, 1102, 1851, 62, 17752, 62, 20688, ...
2.29064
203
from swarm_controller.core import *
[ 6738, 30077, 62, 36500, 13, 7295, 1330, 1635 ]
4.375
8
import numpy as np import torch import torch.nn as nn import torch.optim as optim import torch.nn.functional as F import torch.autograd as autograd class RolloutStorage(): """ states: s s s s s s rewards: r r r r r actions: a a a a a masks: 1 1 1 1 1 0 returns: t ...
[ 11748, 299, 32152, 355, 45941, 198, 198, 11748, 28034, 198, 11748, 28034, 13, 20471, 355, 299, 77, 198, 11748, 28034, 13, 40085, 355, 6436, 198, 11748, 28034, 13, 20471, 13, 45124, 355, 376, 198, 11748, 28034, 13, 2306, 519, 6335, 355, ...
2.253333
150
import contextlib import logging import pathlib from io import StringIO import click import flake8.main.application import toml from ni_python_styleguide import _acknowledge_existing_errors def _get_application_import_names(pyproject): """Return the application package name the config.""" # Otherwise over...
[ 11748, 4732, 8019, 198, 11748, 18931, 198, 11748, 3108, 8019, 198, 6738, 33245, 1330, 10903, 9399, 198, 198, 11748, 3904, 198, 11748, 781, 539, 23, 13, 12417, 13, 31438, 198, 11748, 284, 4029, 198, 198, 6738, 37628, 62, 29412, 62, 34365...
2.479385
1,625
print_hello() print_hello() print_hello()
[ 4798, 62, 31373, 3419, 198, 4798, 62, 31373, 3419, 198, 4798, 62, 31373, 3419 ]
2.928571
14
# Copyright (c) 2018, NVIDIA CORPORATION. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by appli...
[ 2, 15069, 357, 66, 8, 2864, 11, 15127, 23929, 44680, 6234, 13, 220, 1439, 2489, 10395, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393,...
2.447222
3,600
from django.conf import settings from django.http import HttpResponse import logging from mapentity.views import (MapEntityLayer, MapEntityList, MapEntityJsonList, MapEntityFormat, MapEntityViewSet, MapEntityDetail, MapEntityDocument, MapEntityCreate, MapEntityUpdate, MapEntityDelete) fro...
[ 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 198, 198, 11748, 18931, 198, 6738, 3975, 26858, 13, 33571, 1330, 357, 13912, 32398, 49925, 11, 9347, 32398, 8053, 11, 9347, 32398, 41, ...
3.258065
279
# -*- coding: utf-8 -*- # Copyright 2021 Cohesity Inc. import cohesity_management_sdk.models.throttling_configuration class SourceThrottlingConfiguration(object): """Implementation of the 'SourceThrottlingConfiguration' model. Specifies the source side throttling configuration. Attributes: cpu_...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 15069, 33448, 1766, 956, 414, 3457, 13, 198, 198, 11748, 763, 956, 414, 62, 27604, 62, 21282, 74, 13, 27530, 13, 26110, 926, 1359, 62, 11250, 3924, 198, 198, 4871, ...
2.673784
843
# -*- coding: utf-8 -*- # Generated by Django 1.9.12 on 2017-01-16 06:37 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 2980, 515, 416, 37770, 352, 13, 24, 13, 1065, 319, 2177, 12, 486, 12, 1433, 9130, 25, 2718, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, ...
2.73913
69
# -*- coding: utf-8 -*- """ Created on Tue Dec 22 09:02:23 2015 @author: Avinash """ import numpy as np from numpy import * import numpy from math import * import ev_charge_schedule_modification1 as ev #import ev_charge_schedule.static as func1 #import ev_charge_schedule.dynamic as func2 import tim...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 201, 198, 37811, 201, 198, 41972, 319, 30030, 4280, 2534, 7769, 25, 2999, 25, 1954, 1853, 201, 198, 201, 198, 31, 9800, 25, 5184, 259, 1077, 201, 198, 37811, 201, 198, 201,...
1.402961
9,321
import json import requests j = json.load(open('voe_config.json')) js = json.dumps(j) requests.post('http://YOUR_DEVICE_IP:8585/set_voe_config', json={'config': js})
[ 11748, 33918, 198, 11748, 7007, 198, 198, 73, 796, 33918, 13, 2220, 7, 9654, 10786, 85, 2577, 62, 11250, 13, 17752, 6, 4008, 198, 8457, 796, 33918, 13, 67, 8142, 7, 73, 8, 198, 198, 8897, 3558, 13, 7353, 10786, 4023, 1378, 56, 116...
2.470588
68
# pptx-template - import csv to powerpoint template # coding=utf-8 import sys import codecs import logging import argparse import json import shutil import os import tempfile import openpyxl as xl from io import open, TextIOWrapper from pptx import Presentation from six import iteritems from itertools import islice ...
[ 2, 279, 457, 87, 12, 28243, 532, 1330, 269, 21370, 284, 1176, 4122, 11055, 198, 2, 19617, 28, 40477, 12, 23, 198, 198, 11748, 25064, 198, 11748, 40481, 82, 198, 11748, 18931, 198, 11748, 1822, 29572, 198, 11748, 33918, 198, 11748, 442...
2.82449
245
from email.mime.text import MIMEText import base64
[ 6738, 3053, 13, 76, 524, 13, 5239, 1330, 337, 3955, 2767, 2302, 198, 11748, 2779, 2414, 628, 628 ]
3
18
import datetime import geopandas as gpd import numpy as np import pandas as pd import pytest import trackintel as ti from geopandas.testing import assert_geodataframe_equal from pandas.testing import assert_frame_equal, assert_index_equal from shapely.geometry import Point from trackintel.analysis.location_identificat...
[ 11748, 4818, 8079, 198, 198, 11748, 30324, 392, 292, 355, 27809, 67, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 12972, 9288, 198, 11748, 2610, 48779, 355, 46668, 198, 6738, 30324, 392, 292, 13,...
2.255528
8,774
# Autogenerated constants for Power supply service from jacdac.constants import * from jacdac.system.constants import * JD_SERVICE_CLASS_POWER_SUPPLY = const(0x1f40375f) JD_POWER_SUPPLY_REG_ENABLED = const(JD_REG_INTENSITY) JD_POWER_SUPPLY_REG_OUTPUT_VOLTAGE = const(JD_REG_VALUE) JD_POWER_SUPPLY_REG_MINIMUM_VOLTAGE = c...
[ 2, 5231, 519, 877, 515, 38491, 329, 4333, 5127, 2139, 198, 6738, 474, 330, 67, 330, 13, 9979, 1187, 1330, 1635, 198, 6738, 474, 330, 67, 330, 13, 10057, 13, 9979, 1187, 1330, 1635, 198, 37882, 62, 35009, 27389, 62, 31631, 62, 47, ...
2.090909
297
import json import time import urllib from seeder import Seeder class PostCreationException(Exception): """Raised when the creation of a post fails""" pass
[ 11748, 33918, 198, 11748, 640, 198, 11748, 2956, 297, 571, 198, 198, 6738, 384, 5702, 1330, 1001, 5702, 628, 198, 4871, 2947, 12443, 341, 16922, 7, 16922, 2599, 198, 220, 220, 220, 37227, 21762, 1417, 618, 262, 6282, 286, 257, 1281, 1...
3.428571
49
#!/usr/bin/env python from itertools import combinations from sys import argv initial_set = set(argv[1:]) final_set = set() for i in range( len(initial_set) + 1 ): final_set |= set ( combinations( initial_set, i) ) set_printer("S",initial_set) set_printer("P(S)",final_set)
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 6738, 340, 861, 10141, 1330, 17790, 198, 6738, 25064, 1330, 1822, 85, 198, 198, 36733, 62, 2617, 796, 900, 7, 853, 85, 58, 16, 25, 12962, 198, 20311, 62, 2617, 796, 900, 3419, 628, ...
2.6
110
import pandas as pd if __name__ == "__main__": pre_crisis_years = list(range(2000, 2008)) crisis_years = list(range(2008, 2012)) post_crisis_years = list(range(2013, 2016)) df = get_divorce_data() pre_crisis_df = get_mariage_information(df, pre_crisis_years, "pre_crisis_years") crisis_df = g...
[ 11748, 19798, 292, 355, 279, 67, 628, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 662, 62, 66, 42841, 62, 19002, 796, 1351, 7, 9521, 7, 11024, 11, 3648, 4008, 198, 220, 220, 220, 4902, 62, 190...
2.358491
318
from django.apps import apps from django.shortcuts import get_object_or_404, redirect from django.contrib import messages from django.utils.translation import ugettext_lazy as _ from django.contrib.auth.decorators import login_required from wishlist.exceptions import ProductAlreadyAdded, ItemDoesNotExists @login_re...
[ 198, 6738, 42625, 14208, 13, 18211, 1330, 6725, 198, 6738, 42625, 14208, 13, 19509, 23779, 1330, 651, 62, 15252, 62, 273, 62, 26429, 11, 18941, 198, 6738, 42625, 14208, 13, 3642, 822, 1330, 6218, 198, 6738, 42625, 14208, 13, 26791, 13, ...
3.484848
99
import argparse import logging import os import tensorflow as tf from distutils.util import strtobool from multiprocessing import Pool from multiprocessing.pool import ThreadPool from generic.data_provider.iterator import Iterator from generic.tf_utils.evaluator import Evaluator, MultiGPUEvaluator from generic.tf_uti...
[ 11748, 1822, 29572, 198, 11748, 18931, 198, 11748, 28686, 198, 11748, 11192, 273, 11125, 355, 48700, 198, 6738, 1233, 26791, 13, 22602, 1330, 965, 83, 672, 970, 198, 198, 6738, 18540, 305, 919, 278, 1330, 19850, 198, 6738, 18540, 305, 9...
2.455052
3,949
import re from random import randint, choice from discord import Color, Embed from discord.ext.commands import Cog, Context, command import aiohttp from bot import constants from bot.bot import Bot from bot.converters import DiceThrow class Fun(Cog): """ A cog for built solely for fun """ roll_pat...
[ 11748, 302, 198, 6738, 4738, 1330, 43720, 600, 11, 3572, 198, 198, 6738, 36446, 1330, 5315, 11, 13302, 276, 198, 6738, 36446, 13, 2302, 13, 9503, 1746, 1330, 327, 519, 11, 30532, 11, 3141, 198, 198, 11748, 257, 952, 4023, 198, 198, ...
2.012987
2,618
from django.contrib.contenttypes.models import ContentType from django.db.models.signals import post_save from django.dispatch import receiver from bumblebee.activities.models import UserActivity from bumblebee.activities.utils import _create_activity from config.definitions import DEBUG from .models import Profile ...
[ 6738, 42625, 14208, 13, 3642, 822, 13, 11299, 19199, 13, 27530, 1330, 14041, 6030, 198, 6738, 42625, 14208, 13, 9945, 13, 27530, 13, 12683, 874, 1330, 1281, 62, 21928, 198, 6738, 42625, 14208, 13, 6381, 17147, 1330, 9733, 198, 198, 6738...
2.767606
284
import py4research.math.random as r # Generates an integer random number array i = r.generate_integer_random_number(low=0, high=100, size=10) print(f'Shape: {i.shape}') print(f'Value: {i}') # Generates a random gaussian number array g = r.generate_gaussian_random_number(mean=0.5, variance=1.0, size=10) print(f'Shape:...
[ 11748, 12972, 19, 34033, 13, 11018, 13, 25120, 355, 374, 198, 198, 2, 2980, 689, 281, 18253, 4738, 1271, 7177, 198, 72, 796, 374, 13, 8612, 378, 62, 41433, 62, 25120, 62, 17618, 7, 9319, 28, 15, 11, 1029, 28, 3064, 11, 2546, 28, ...
2.583942
137
"""A Python repr() syntax highlighter.""" from prompt_toolkit.styles import Style import pyparsing as pp from pyparsing import pyparsing_common as ppc from .repl import repl # pylint: disable=too-many-locals def parser_factory(styler): """Builds the repr() parser.""" squo = styler('class:string', "'") d...
[ 37811, 32, 11361, 41575, 3419, 15582, 1029, 75, 4799, 526, 15931, 198, 198, 6738, 6152, 62, 25981, 15813, 13, 47720, 1330, 17738, 198, 11748, 279, 4464, 945, 278, 355, 9788, 198, 6738, 279, 4464, 945, 278, 1330, 279, 4464, 945, 278, 6...
2.339
1,000
#!/usr/bin/env python # -*-coding:UTF-8 -* # # Olivier Locard import urllib
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 66, 7656, 25, 48504, 12, 23, 532, 9, 198, 2, 198, 2, 45674, 15181, 446, 198, 198, 11748, 2956, 297, 571, 628 ]
2.228571
35
from .tweerator import Tweerator
[ 6738, 764, 83, 732, 263, 1352, 1330, 24205, 263, 1352, 198 ]
3
11
from django.urls import path, include from rest_framework import routers from profiles_api import views router = routers.DefaultRouter() router.register('hello-viewset', views.HelloViewSet, base_name='hello-viewset') """ In the below registerwe need not assign the base name as we have defined it in the UserProfileV...
[ 6738, 42625, 14208, 13, 6371, 82, 1330, 3108, 11, 2291, 198, 198, 6738, 1334, 62, 30604, 1330, 41144, 198, 198, 6738, 16545, 62, 15042, 1330, 5009, 198, 198, 472, 353, 796, 41144, 13, 19463, 49, 39605, 3419, 198, 198, 472, 353, 13, ...
3.213333
225
"""Import custom utils packages """ from .captchahelper import preprocess from .ranked import rank5_accuracy __all__ = [ "preprocess", "rank5_accuracy", ]
[ 37811, 20939, 2183, 3384, 4487, 10392, 198, 37811, 198, 6738, 764, 27144, 11693, 2978, 525, 1330, 662, 14681, 198, 6738, 764, 28282, 1330, 4279, 20, 62, 4134, 23843, 628, 198, 834, 439, 834, 796, 685, 198, 220, 220, 220, 366, 3866, 14...
2.894737
57
"""Restrictions on on ontology classes.""" from enum import Enum import rdflib import logging from rdflib.term import BNode from osp.core.ontology.attribute import OntologyAttribute from osp.core.ontology.relationship import OntologyRelationship logger = logging.getLogger(__name__) class QUANTIFIER(Enum): """Th...
[ 37811, 19452, 2012, 507, 319, 319, 39585, 1435, 6097, 526, 15931, 198, 198, 6738, 33829, 1330, 2039, 388, 198, 11748, 374, 67, 2704, 571, 198, 11748, 18931, 198, 6738, 374, 67, 2704, 571, 13, 4354, 1330, 347, 19667, 198, 6738, 267, 27...
2.250684
2,557
# coding=utf-8 # Copyright 2018 The Google AI Language Team Authors and The HuggingFace Inc. team. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICEN...
[ 2, 19617, 28, 40477, 12, 23, 198, 2, 15069, 2864, 383, 3012, 9552, 15417, 4816, 46665, 290, 383, 12905, 2667, 32388, 3457, 13, 1074, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, ...
2.488716
2,570
# Copyright 2018 ICON 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 or agreed to in writi...
[ 2, 15069, 2864, 314, 10943, 5693, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, 198, 2, 921, 743,...
2.405764
2,637
#!/usr/bin/env python3 """ An example of testing the cache to prove that it's not making more requests than expected. """ import asyncio from contextlib import asynccontextmanager from logging import basicConfig, getLogger from unittest.mock import patch from aiohttp import ClientSession from aiohttp_client_cache imp...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 37811, 198, 2025, 1672, 286, 4856, 262, 12940, 284, 5879, 326, 340, 338, 407, 1642, 517, 7007, 621, 2938, 13, 198, 37811, 198, 11748, 30351, 952, 198, 6738, 4732, 8019, 1330, 355, ...
2.884404
545
#!/usr/bin/env python3 # ---------------------------------------------------------------------------- # Copyright (c) 2020--, Qiyun Zhu. # # Distributed under the terms of the Modified BSD License. # # The full license is in the file LICENSE, distributed with this software. # ------------------------------------------...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 2, 16529, 10541, 198, 2, 15069, 357, 66, 8, 12131, 438, 11, 1195, 7745, 403, 33144, 13, 198, 2, 198, 2, 4307, 6169, 739, 262, 2846, 286, 262, 40499, 347, 10305, 13789, 13,...
3.557692
208
# Testing command line interfaces is hard. But we'll try # At least we separated our actual program from the I/O part so that we # can test that import scispack from scispack.cli import cli_program
[ 2, 23983, 3141, 1627, 20314, 318, 1327, 13, 887, 356, 1183, 1949, 198, 2, 1629, 1551, 356, 11266, 674, 4036, 1430, 422, 262, 314, 14, 46, 636, 523, 326, 356, 198, 2, 460, 1332, 326, 198, 11748, 629, 271, 8002, 198, 6738, 629, 271,...
3.690909
55
from pyomo.environ import * infinity = float('inf') model = AbstractModel() #Players model.P = Set() #Expected Scoring model.S = Set() #value of each player model.v = Param(model.P, within=PositiveReals) #expected Positions for each player model.e = Param(model.P,model.S, within=NonNegativeReals) #Lower and uppe...
[ 198, 6738, 12972, 17902, 13, 268, 2268, 1330, 1635, 198, 10745, 6269, 796, 12178, 10786, 10745, 11537, 198, 198, 19849, 796, 27741, 17633, 3419, 198, 198, 2, 24860, 198, 19849, 13, 47, 796, 5345, 3419, 198, 198, 2, 3109, 7254, 1446, 3...
2.984416
385
class Config(object): """ Common configurations """ #Put any configurations here that are common a close all enviroment class DevelopmentConfig(Config): """ Development configurations """ DEBUG =True SQLALCHEMY_ECHO =True class ProductionConfig(Config): """ Production ...
[ 4871, 17056, 7, 15252, 2599, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 8070, 25412, 198, 220, 220, 220, 37227, 628, 198, 220, 220, 220, 1303, 11588, 597, 25412, 994, 326, 389, 220, 2219, 257, 1969, 477, 17365, 343, 296, 298, 19...
3.061224
147
import rospy from evdev import InputDevice, ecodes from lg_common.helpers import rewrite_message_to_dict, find_device from interactivespaces_msgs.msg import GenericMessage class DeviceReplay: """ Initialized with device name Needs a publisher to publish messages """ def __init__(self, publisher,...
[ 11748, 686, 2777, 88, 198, 198, 6738, 819, 7959, 1330, 23412, 24728, 11, 9940, 4147, 198, 6738, 300, 70, 62, 11321, 13, 16794, 364, 1330, 28183, 62, 20500, 62, 1462, 62, 11600, 11, 1064, 62, 25202, 198, 6738, 9427, 1083, 43076, 62, ...
2.511785
594
from pyspark import SparkConf from pyspark import SparkContext from pyspark.mllib.regression import LabeledPoint from pyspark.mllib.tree import DecisionTree conf = SparkConf() conf.setMaster('spark://HEAD_NODE_HOSTNAME:7077') conf.setAppName('spark-basic') sc = SparkContext(conf=conf) rdd = sc.parallelize(range(1000)...
[ 6738, 279, 893, 20928, 1330, 17732, 18546, 198, 6738, 279, 893, 20928, 1330, 17732, 21947, 198, 6738, 279, 893, 20928, 13, 76, 297, 571, 13, 2301, 2234, 1330, 3498, 18449, 12727, 198, 6738, 279, 893, 20928, 13, 76, 297, 571, 13, 21048...
2.334545
275
# coding=utf-8 # *** WARNING: this file was generated by the Pulumi SDK Generator. *** # *** Do not edit by hand unless you're certain you know what you are doing! *** from enum import Enum __all__ = [ 'ResourceDiscoveryMode', ] class ResourceDiscoveryMode(str, Enum): """ The way resources to remediate ...
[ 2, 19617, 28, 40477, 12, 23, 198, 2, 17202, 39410, 25, 428, 2393, 373, 7560, 416, 262, 21624, 12994, 26144, 35986, 13, 17202, 198, 2, 17202, 2141, 407, 4370, 416, 1021, 4556, 345, 821, 1728, 345, 760, 644, 345, 389, 1804, 0, 17202, ...
3.219626
214
# -*- 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 convert_to_basen(value, base): """Convert a base10 number to basen. >>> [convert_to_basen(i, 16) for i in range(1,16)] #doctest: +NORMALIZE_WHITESPACE ['1/16', '2/16', '3/16', '4/16', '5/16', '6/16', '7/16', '8/16', '9/16', 'a/16', 'b/16', 'c/16', 'd/16', 'e/16', 'f/16'] FUTURE: Binary may s...
[ 4299, 10385, 62, 1462, 62, 12093, 268, 7, 8367, 11, 2779, 2599, 198, 220, 220, 220, 37227, 3103, 1851, 257, 2779, 940, 1271, 284, 1615, 268, 13, 628, 220, 220, 220, 13163, 685, 1102, 1851, 62, 1462, 62, 12093, 268, 7, 72, 11, 1467...
2.112
375
from . import encoding_tester from . import html_compiler
[ 6738, 764, 1330, 21004, 62, 4879, 353, 198, 6738, 764, 1330, 27711, 62, 5589, 5329 ]
3.8
15
from mpmath import mp, mpf def remove_null_values(obj): """ Remove all null values from a dictionary :param obj: dictionary :return: filtered dictionary """ if not isinstance(obj, dict): return obj for k in list(obj.keys()): _obj = obj[k] if _obj is None: ...
[ 6738, 285, 4426, 776, 1330, 29034, 11, 29034, 69, 628, 628, 198, 4299, 4781, 62, 8423, 62, 27160, 7, 26801, 2599, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 17220, 477, 9242, 3815, 422, 257, 22155, 198, 220, 220, 220, 1058, 1714...
2.247911
359
import os import sys sys.path.append('modules/pytorch_mask_rcnn') import numpy as np import torch import matplotlib.pyplot as plt from torch.autograd import Variable from torch.autograd.gradcheck import zero_gradients from model import Dataset, unmold_image, MaskRCNN, compute_losses from visualize import display_inst...
[ 11748, 28686, 198, 11748, 25064, 198, 17597, 13, 6978, 13, 33295, 10786, 18170, 14, 9078, 13165, 354, 62, 27932, 62, 6015, 20471, 11537, 198, 198, 11748, 299, 32152, 355, 45941, 198, 198, 11748, 28034, 198, 11748, 2603, 29487, 8019, 13, ...
2.198893
3,434
# -*- coding: utf-8 -*- """Forms for medical history.""" from django import forms from django.conf import settings from django.core.validators import FileExtensionValidator from djtools.fields import BINARY_CHOICES SICKLE_CELL_RESULTS = ( ('Positive', 'Positive'), ('Negative', 'Negative'), ) DRUG_TEST_RESUL...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 37811, 8479, 82, 329, 3315, 2106, 526, 15931, 198, 198, 6738, 42625, 14208, 1330, 5107, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, ...
2.527872
1,184
# -*- coding: utf-8 -*- from __future__ import absolute_import from packtml.regression import SimpleLogisticRegression from sklearn.datasets import make_classification from sklearn.metrics import accuracy_score import numpy as np X, y = make_classification(n_samples=100, n_features=2, random_state=42, ...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 198, 198, 6738, 2353, 20369, 13, 2301, 2234, 1330, 17427, 11187, 2569, 8081, 2234, 198, 6738, 1341, 35720, 13, 19608, ...
2.289617
183
import pytest import datetime from pupa.scrape import Disclosure as ScrapeDisclosure
[ 11748, 12972, 9288, 198, 11748, 4818, 8079, 198, 6738, 15552, 64, 13, 1416, 13484, 1330, 41806, 355, 1446, 13484, 7279, 17966, 628, 628, 628, 628, 198 ]
3.576923
26
$NetBSD: patch-Lib_plistlib.py,v 1.1 2018/06/17 19:21:21 adam Exp $ Add ability to parse unsigned integers as externalized by NetBSD proplib(3). --- Lib/plistlib.py.orig 2014-12-10 15:59:39.000000000 +0000 +++ Lib/plistlib.py - self.addObject(int(self.getData())) + self.addObject(int(self.getData(), 0))...
[ 3, 7934, 21800, 25, 8529, 12, 25835, 62, 489, 396, 8019, 13, 9078, 11, 85, 352, 13, 16, 2864, 14, 3312, 14, 1558, 678, 25, 2481, 25, 2481, 23197, 5518, 720, 198, 198, 4550, 2694, 284, 21136, 22165, 37014, 355, 7097, 1143, 416, 343...
2.395522
134
from vyper.compiler import ( compile_codes, mk_full_signature, )
[ 6738, 410, 88, 525, 13, 5589, 5329, 1330, 357, 198, 220, 220, 220, 17632, 62, 40148, 11, 198, 220, 220, 220, 33480, 62, 12853, 62, 12683, 1300, 11, 198, 8, 628, 628, 198 ]
2.333333
33
from django.urls import path from . import views app_name='account' urlpatterns = [ path('login', views.login,name='login'), path('login/*/', views.login,name='login2'), path('register', views.register,name='register'), path('conact', views.conact,name='conact'), path('do_register',views.do_regist...
[ 6738, 42625, 14208, 13, 6371, 82, 1330, 3108, 198, 6738, 764, 1330, 5009, 198, 198, 1324, 62, 3672, 11639, 23317, 6, 198, 198, 6371, 33279, 82, 796, 685, 198, 220, 220, 220, 3108, 10786, 38235, 3256, 5009, 13, 38235, 11, 3672, 11639, ...
2.765734
286
example = """eedadn drvtee eandsr raavrd atevrs tsrnev sdttsa rasrtv nssdts ntnada svetve tesnvt vntsnd vrdear dvrsen enarar""" answer = { "a": "easter", "b": "advent" } do_day(test=False, day="a") do_day(test=False, day="b")
[ 20688, 796, 37227, 2308, 324, 77, 198, 7109, 85, 660, 68, 198, 68, 1746, 81, 198, 430, 615, 4372, 198, 378, 85, 3808, 198, 912, 81, 710, 85, 198, 21282, 83, 912, 64, 198, 8847, 81, 14981, 198, 77, 824, 67, 912, 198, 429, 77, 4...
1.825397
126
# # PySNMP MIB module INFORMANT-HW (http://snmplabs.com/pysmi) # ASN.1 source file:///Users/davwang4/Dev/mibs.snmplabs.com/asn1/INFORMANT-HW # Produced by pysmi-0.3.4 at Mon Apr 29 19:42:12 2019 # On host DAVWANG4-M-1475 platform Darwin version 18.5.0 by user davwang4 # Using Python version 3.7.3 (default, Mar 27 2019,...
[ 2, 198, 2, 9485, 15571, 7378, 337, 9865, 8265, 3268, 21389, 8643, 12, 39, 54, 357, 4023, 1378, 16184, 76, 489, 8937, 13, 785, 14, 79, 893, 11632, 8, 198, 2, 7054, 45, 13, 16, 2723, 2393, 1378, 14, 14490, 14, 67, 615, 47562, 19, ...
2.654843
233,236
#!/usr/bin/env python """ Single module to hold the high-level API """ import numpy as np from .cy_point_in_polygon import points_in_poly, points_in_polys, signed_area def polygon_inside(polygon_verts, trial_points): ''' Return a Boolean array the size of the trial point array True if point is inside ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 37811, 198, 28008, 8265, 284, 1745, 262, 1029, 12, 5715, 7824, 198, 37811, 198, 198, 11748, 299, 32152, 355, 45941, 198, 198, 6738, 764, 948, 62, 4122, 62, 259, 62, 35428, 14520, ...
2.444444
1,251
root_doc = 'equations' extensions = ['sphinx.ext.imgmath']
[ 15763, 62, 15390, 796, 705, 4853, 602, 6, 198, 2302, 5736, 796, 37250, 82, 746, 28413, 13, 2302, 13, 9600, 11018, 20520, 198 ]
2.565217
23
#!/usr/bin/env python3 # Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved. from idb.grpc.types import CompanionClient from idb.grpc.idb_pb2 import Location, SetLocationRequest
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 15069, 357, 66, 8, 3203, 11, 3457, 13, 290, 663, 29116, 13, 1439, 6923, 33876, 13, 628, 198, 6738, 4686, 65, 13, 2164, 14751, 13, 19199, 1330, 30653, 11792, 198, 6738, 4686, ...
3.316667
60
# vim: set fileencoding=utf-8 : import sys import os import shutil import tempfile import pytest import pyvips from helpers import \ JPEG_FILE, PNG_FILE, TIF_FILE, \ temp_filename, assert_almost_equal_objects, have, skip_if_no if __name__ == '__main__': pytest.main()
[ 2, 43907, 25, 900, 2393, 12685, 7656, 28, 40477, 12, 23, 1058, 198, 198, 11748, 25064, 198, 11748, 28686, 198, 11748, 4423, 346, 198, 11748, 20218, 7753, 198, 11748, 12972, 9288, 198, 198, 11748, 12972, 85, 2419, 198, 6738, 49385, 1330,...
2.704762
105
from bonsai.base.regtree import RegTree from sklearn.datasets import make_friedman1 from sklearn.model_selection import train_test_split import numpy as np import unittest from misc import apply_tree if __name__=="__main__": unittest.main()
[ 6738, 275, 684, 1872, 13, 8692, 13, 2301, 21048, 1330, 3310, 27660, 198, 6738, 1341, 35720, 13, 19608, 292, 1039, 1330, 787, 62, 25520, 805, 16, 198, 6738, 1341, 35720, 13, 19849, 62, 49283, 1330, 4512, 62, 9288, 62, 35312, 198, 11748...
3.074074
81
from numba import guvectorize import numpy as np @guvectorize(['void(int64[:,:], int64[:,:], int64[:,:])'], '(m,n),(n,p)->(m,p)') dim = 10 A = np.random.randint(dim, size=(dim, dim)) B = np.random.randint(dim, size=(dim, dim)) C = matmul(A, B) print("INPUT MATRIX A") print(":\n%s" % A) print("INPUT MA...
[ 6738, 997, 7012, 1330, 915, 31364, 1096, 198, 11748, 299, 32152, 355, 45941, 628, 198, 31, 5162, 31364, 1096, 7, 17816, 19382, 7, 600, 2414, 58, 45299, 25, 4357, 493, 2414, 58, 45299, 25, 4357, 493, 2414, 58, 45299, 25, 12962, 6, 43...
2.020305
197
import logging import math import torch.utils.model_zoo as model_zoo _logger = logging.getLogger(__name__)
[ 11748, 18931, 198, 11748, 10688, 198, 11748, 28034, 13, 26791, 13, 19849, 62, 89, 2238, 355, 2746, 62, 89, 2238, 628, 198, 62, 6404, 1362, 796, 18931, 13, 1136, 11187, 1362, 7, 834, 3672, 834, 8, 628 ]
2.972973
37
from collections import defaultdict #TODO: rename obj to something more descriptive #TODO: make test cases to test everything #######################################################################################################
[ 198, 6738, 17268, 1330, 4277, 11600, 198, 198, 2, 51, 3727, 46, 25, 36265, 26181, 284, 1223, 517, 35644, 198, 2, 51, 3727, 46, 25, 787, 1332, 2663, 284, 1332, 2279, 628, 628, 628, 198, 29113, 29113, 29113, 4242, 21017, 628, 628, 628...
5.651163
43
import discord from discord.ext import commands from console import Console console = Console(True)
[ 11748, 36446, 198, 6738, 36446, 13, 2302, 1330, 9729, 198, 6738, 8624, 1330, 24371, 198, 198, 41947, 796, 24371, 7, 17821, 8 ]
4.545455
22
class PurchaseOrder: """ Represents a Purchase Order. """ id = '' purchase_order_id = '' latest = False created_at = '' acknowledged_at = '' requested_delivery_from = '' requested_delivery_to = '' currency = '' gross_amount = 0.0 tax_amount = 0.0 total_amount = 0....
[ 4871, 27637, 18743, 25, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 1432, 6629, 257, 27637, 8284, 13, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 4686, 796, 10148, 198, 220, 220, 220, 5001, 62, 2875, 62, 312, 796, 10148, 198, ...
2.482399
767
# nlantau, 2020-11-09 print(evens_and_odds(1)) print(evens_and_odds(2)) print(evens_and_odds(3)) print(evens_and_odds(13))
[ 2, 299, 75, 415, 559, 11, 12131, 12, 1157, 12, 2931, 628, 198, 198, 4798, 7, 10197, 82, 62, 392, 62, 5088, 82, 7, 16, 4008, 198, 4798, 7, 10197, 82, 62, 392, 62, 5088, 82, 7, 17, 4008, 198, 4798, 7, 10197, 82, 62, 392, 62, ...
1.909091
66
import pytest from bg_atlasapi.bg_atlas import BrainGlobeAtlas import tempfile import shutil from pathlib import Path @pytest.fixture() @pytest.fixture() @pytest.fixture(scope="module")
[ 11748, 12972, 9288, 198, 6738, 275, 70, 62, 265, 21921, 15042, 13, 35904, 62, 265, 21921, 1330, 14842, 9861, 5910, 2953, 21921, 198, 11748, 20218, 7753, 198, 11748, 4423, 346, 198, 6738, 3108, 8019, 1330, 10644, 628, 198, 31, 9078, 9288...
2.811594
69
import distributions import math import numpy as np import os import projections import random import sys # Interface for models # ToImplement # Dumps the data into a file class Base(Model_Backbone): """ In this model, each forward step represe...
[ 11748, 24570, 201, 198, 11748, 10688, 201, 198, 11748, 299, 32152, 355, 45941, 201, 198, 11748, 28686, 201, 198, 11748, 19887, 201, 198, 11748, 4738, 201, 198, 11748, 25064, 201, 198, 201, 198, 201, 198, 2, 26491, 329, 4981, 201, 198, ...
2.682584
356