content
stringlengths
1
1.04M
input_ids
listlengths
1
774k
ratio_char_token
float64
0.38
22.9
token_count
int64
1
774k
from django.urls import path from . import views urlpatterns = [ path('', views.index, name="home"), path('all', views.index), path('create', views.create, name="create"), path('delete/<int:contact_id>', views.delete, name="delete"), path('edit/<int:contact_id>', views.edit, name="edit"), ]
[ 6738, 42625, 14208, 13, 6371, 82, 1330, 3108, 198, 6738, 764, 1330, 5009, 198, 198, 6371, 33279, 82, 796, 685, 198, 197, 6978, 10786, 3256, 5009, 13, 9630, 11, 1438, 2625, 11195, 12340, 198, 197, 6978, 10786, 439, 3256, 5009, 13, 9630...
2.883495
103
import numpy as np from scipy.optimize import fmin import math from scipy.optimize import minimize
[ 11748, 299, 32152, 355, 45941, 198, 6738, 629, 541, 88, 13, 40085, 1096, 1330, 277, 1084, 198, 11748, 10688, 198, 6738, 629, 541, 88, 13, 40085, 1096, 1330, 17775, 628, 628, 628, 628 ]
3.212121
33
""" Dummy source code to initialize repo""" from typing import Literal def dummy() -> Literal[True]: """Dummy function""" return True
[ 37811, 360, 13513, 2723, 2438, 284, 41216, 29924, 37811, 198, 198, 6738, 19720, 1330, 25659, 1691, 628, 198, 4299, 31548, 3419, 4613, 25659, 1691, 58, 17821, 5974, 198, 220, 220, 220, 37227, 35, 13513, 2163, 37811, 628, 220, 220, 220, 1...
3.395349
43
#!/usr/bin/env python3 # -*- coding: utf-8 -*-
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 201, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 201, 198, 201, 198, 201, 198 ]
1.766667
30
from launch import LaunchDescription from launch_ros.actions import Node
[ 6738, 4219, 1330, 21225, 11828, 198, 6738, 4219, 62, 4951, 13, 4658, 1330, 19081 ]
5.142857
14
""" Exports a no-op 'cython' namespace similar to https://github.com/cython/cython/blob/master/Cython/Shadow.py This allows to optionally compile @cython decorated functions (when cython is available at built time), or run the same code as pure-python, without runtime dependency on cython module. We only define the s...
[ 37811, 1475, 3742, 257, 645, 12, 404, 705, 948, 400, 261, 6, 25745, 2092, 284, 198, 5450, 1378, 12567, 13, 785, 14, 948, 400, 261, 14, 948, 400, 261, 14, 2436, 672, 14, 9866, 14, 34, 7535, 14, 27447, 13, 9078, 198, 198, 1212, 35...
3.052381
210
# Copyright 2014 The Swarming Authors. All rights reserved. # Use of this source code is governed by the Apache v2.0 license that can be # found in the LICENSE file. """Defines access groups.""" from components import auth from components import utils # Names of groups. # See https://code.google.com/p/swarming/wiki...
[ 2, 15069, 1946, 383, 2451, 18052, 46665, 13, 1439, 2489, 10395, 13, 198, 2, 5765, 286, 428, 2723, 2438, 318, 21825, 416, 262, 24843, 410, 17, 13, 15, 5964, 326, 460, 307, 198, 2, 1043, 287, 262, 38559, 24290, 2393, 13, 198, 198, 3...
2.989529
573
# Copyright (C) 2017 Open Information Security Foundation # # You can copy, redistribute or modify this Program under the terms of # the GNU General Public License version 2 as published by the Free # Software Foundation. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; wi...
[ 2, 15069, 357, 34, 8, 2177, 4946, 6188, 4765, 5693, 198, 2, 198, 2, 921, 460, 4866, 11, 17678, 4163, 393, 13096, 428, 6118, 739, 262, 2846, 286, 198, 2, 262, 22961, 3611, 5094, 13789, 2196, 362, 355, 3199, 416, 262, 3232, 198, 2, ...
3.953917
217
from django.contrib import admin from .models import Blog, Category, Tag, Comment # Register your models here. @admin.register(Blog) @admin.register(Category) @admin.register(Tag) @admin.register(Comment)
[ 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 6738, 764, 27530, 1330, 14001, 11, 21743, 11, 17467, 11, 18957, 198, 198, 2, 17296, 534, 4981, 994, 13, 198, 31, 28482, 13, 30238, 7, 42383, 8, 198, 198, 31, 28482, 13, 30238, 7, ...
3.3125
64
"""Test methods for `inout_core.py`. Can be run with: $ nosetests zcode/inout/tests/test_inout_core.py """ from __future__ import absolute_import, division, print_function, unicode_literals import os import warnings import shutil from numpy.testing import run_module_suite import numpy as np from nose.tools impor...
[ 37811, 14402, 5050, 329, 4600, 259, 448, 62, 7295, 13, 9078, 44646, 198, 198, 6090, 307, 1057, 351, 25, 198, 220, 220, 220, 720, 43630, 316, 3558, 1976, 8189, 14, 259, 448, 14, 41989, 14, 9288, 62, 259, 448, 62, 7295, 13, 9078, 19...
3.006536
153
name = input("Mame: ") print(f"Hello, {name}")
[ 3672, 796, 5128, 7203, 44, 480, 25, 366, 8, 198, 4798, 7, 69, 1, 15496, 11, 1391, 3672, 92, 4943 ]
2.3
20
"""Contains validators for task models.""" def task_instance_args_are_valid(instance, fill_missing_args=False): """Determines whether a task instance's arguments are valid. The arguments are valid if the instance's argument includes all of its task type's required arguments (but not necessarily the a...
[ 37811, 4264, 1299, 4938, 2024, 329, 4876, 4981, 526, 15931, 628, 198, 4299, 4876, 62, 39098, 62, 22046, 62, 533, 62, 12102, 7, 39098, 11, 6070, 62, 45688, 62, 22046, 28, 25101, 2599, 198, 220, 220, 220, 37227, 35, 13221, 274, 1771, ...
2.766194
988
#!/usr/bin/python # -*- coding: utf-8 -*- # Copyright (С) ABBYY (BIT Software), 1993 - 2019. All rights reserved. """ Различные метрики для keras подсчитываемые при обучении """ import functools import keras.backend as K import tensorflow as tf from semantic_segmentation.losses import get_losses @_metric_wrapper...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 15069, 357, 140, 94, 8, 9564, 17513, 56, 357, 26094, 10442, 828, 9656, 532, 13130, 13, 1439, 2489, 10395, 13, 198, 37811,...
1.968627
2,040
# -*- coding: utf-8 -*- """ Created on %(date)s @author: %(username)s """ import numpy as np import pandas as pd import matplotlib.pyplot as plt import seaborn as sns from sklearn import linear_model import statsmodels.api as sm from statsmodels.sandbox.regression.predstd import wls_prediction_std model_sm = 'sm' ...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 41972, 319, 4064, 7, 4475, 8, 82, 198, 198, 31, 9800, 25, 4064, 7, 29460, 8, 82, 198, 37811, 198, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 19798, ...
2.317181
227
#!/usr/bin/env python3.6 """Refactored utility functions.""" __author__ = "Richard Cosgrove" from collections import defaultdict import gzip from itertools import combinations from datetime import datetime, timedelta import json import os def export_compressed_json(dict_item, file_name): """Export gzip compress...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 13, 21, 198, 198, 37811, 8134, 529, 1850, 10361, 5499, 526, 15931, 198, 198, 834, 9800, 834, 796, 366, 22245, 10437, 27333, 303, 1, 198, 198, 6738, 17268, 1330, 4277, 11600, 198, 11748,...
2.458753
1,988
from django.contrib.auth import get_user_model from django.test import TestCase # Use the proper swappable User model User = get_user_model()
[ 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 1330, 651, 62, 7220, 62, 19849, 198, 6738, 42625, 14208, 13, 9288, 1330, 6208, 20448, 628, 198, 2, 5765, 262, 1774, 1509, 1324, 540, 11787, 2746, 198, 12982, 796, 651, 62, 7220, 62, 19849,...
3.295455
44
# Copyright 2016 Google Inc. 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 applicable law or ag...
[ 2, 15069, 1584, 3012, 3457, 13, 1439, 6923, 33876, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, ...
3.271589
799
#-*- coding: utf-8 -*- """ EOSS catalog system Custom logger Default configuration file within this directory is used to control logging behaviour; can be overwritten with LOGGING_CONF which points to local logging configuration """ __author__ = "Thilo Wehrmann, Steffen Gebhardt" __copyright__ = "Copyright 2016, E...
[ 2, 12, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 37811, 412, 18420, 18388, 1080, 198, 8562, 49706, 198, 15161, 8398, 2393, 1626, 428, 8619, 318, 973, 284, 1630, 18931, 9172, 26, 460, 307, 6993, 9108, 351, 41605, 38...
2.835148
643
# Copyright 2019 the ProGraML authors. # # Contact Chris Cummins <chrisc.101@gmail.com>. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # ...
[ 2, 15069, 13130, 262, 1041, 46971, 5805, 7035, 13, 198, 2, 198, 2, 14039, 5180, 30316, 1040, 1279, 354, 81, 2304, 13, 8784, 31, 14816, 13, 785, 28401, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 116...
2.8988
2,500
# A module inside the package print("Module: ", __name__)
[ 2, 317, 8265, 2641, 262, 5301, 198, 198, 4798, 7203, 26796, 25, 33172, 11593, 3672, 834, 8, 628 ]
3.333333
18
""" https://leetcode.com/problems/divisor-game/ Alice and Bob take turns playing a game, with Alice starting first. Initially, there is a number N on the chalkboard. On each player's turn, that player makes a move consisting of: Choosing any x with 0 < x < N and N % x == 0. Replacing the number N on the chalkboard w...
[ 37811, 198, 5450, 1378, 293, 316, 8189, 13, 785, 14, 1676, 22143, 14, 7146, 271, 273, 12, 6057, 14, 198, 44484, 290, 5811, 1011, 4962, 2712, 257, 983, 11, 351, 14862, 3599, 717, 13, 198, 198, 40443, 11, 612, 318, 257, 1271, 399, 3...
3.328947
228
import sys import traceback import numpy as np from evalml.automl.engine import EngineBase from evalml.exceptions import PipelineScoreError from evalml.model_family import ModelFamily from evalml.objectives.utils import get_objective from evalml.utils import get_logger logger = get_logger(__file__) class Sequentia...
[ 11748, 25064, 198, 11748, 12854, 1891, 198, 198, 11748, 299, 32152, 355, 45941, 198, 198, 6738, 5418, 4029, 13, 2306, 296, 75, 13, 18392, 1330, 7117, 14881, 198, 6738, 5418, 4029, 13, 1069, 11755, 1330, 37709, 26595, 12331, 198, 6738, 5...
2.240869
2,026
# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. # SPDX-License-Identifier: MIT-0 import csv import s3fs import os s3 = s3fs.S3FileSystem(anon=False) header = [ 'uuid', 'country', 'itemType', 'salesChannel', 'orderPriority', 'orderDate', 'region', 'shipDate' ]
[ 2, 15069, 6186, 13, 785, 11, 3457, 13, 393, 663, 29116, 13, 1439, 6923, 33876, 13, 198, 2, 30628, 55, 12, 34156, 12, 33234, 7483, 25, 17168, 12, 15, 198, 11748, 269, 21370, 198, 11748, 264, 18, 9501, 198, 11748, 28686, 198, 198, 8...
2.398496
133
# -*- coding: utf-8 -*- from numpy import pi from numpy import zeros from numpy import sin from numpy import cos from numpy import sqrt from numpy.random import random from numpy import float32 as npfloat from numpy import int32 as npint TWOPI = pi*2 PI = pi
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 628, 628, 198, 198, 6738, 299, 32152, 1330, 31028, 198, 6738, 299, 32152, 1330, 1976, 27498, 198, 6738, 299, 32152, 1330, 7813, 198, 6738, 299, 32152, 1330, 8615, 198, 6738, ...
2.934783
92
from logging import debug, exception from flask import Flask, request import os import asyncio import threading import ssl import aiohttp import nest_asyncio import json from openleadr.client import OpenADRClient from openleadr.utils import report_callback from openleadr.enums import MEASUREMENTS nest_asyncio.apply() ...
[ 6738, 18931, 1330, 14257, 11, 6631, 198, 6738, 42903, 1330, 46947, 11, 2581, 198, 11748, 28686, 198, 11748, 30351, 952, 198, 11748, 4704, 278, 198, 11748, 264, 6649, 198, 11748, 257, 952, 4023, 198, 11748, 16343, 62, 292, 13361, 952, 19...
2.729211
469
from __future__ import absolute_import # Copyright(c) Max Kolosov 2009 maxkolosov@inbox.ru # http://vosolok2008.narod.ru # BSD license __version__ = '0.1' __versionTime__ = '2009-11-15' __author__ = 'Max Kolosov <maxkolosov@inbox.ru>' __doc__ = ''' pybass_aac.py - is ctypes python module for BASS_AAC - exten...
[ 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 201, 198, 2, 15069, 7, 66, 8, 5436, 25910, 418, 709, 3717, 3509, 74, 349, 418, 709, 31, 259, 3524, 13, 622, 201, 198, 2, 2638, 1378, 85, 418, 349, 482, 11528, 13, 23955, 375, 13, 6...
2.442324
1,153
from collections import OrderedDict from django import http from django.db.models import Prefetch from django.db.transaction import non_atomic_requests from django.shortcuts import redirect from django.utils.cache import patch_cache_control from django.utils.decorators import method_decorator from django.views.decorat...
[ 6738, 17268, 1330, 14230, 1068, 35, 713, 198, 198, 6738, 42625, 14208, 1330, 2638, 198, 6738, 42625, 14208, 13, 9945, 13, 27530, 1330, 42195, 7569, 198, 6738, 42625, 14208, 13, 9945, 13, 7645, 2673, 1330, 1729, 62, 47116, 62, 8897, 3558...
2.933119
1,869
""" Created by Rohan Paleja on September 23, 2019 Nikolaidis et. al. benchmark """ import torch import torch.nn.functional as F # sys.path.insert(0, '/home/Anonymous/PycharmProjects/bayesian_prolo') import numpy as np import pickle from torch.autograd import Variable from utils.naive_utils import load_in_naive_data,...
[ 37811, 198, 41972, 416, 371, 22436, 21706, 6592, 319, 2693, 2242, 11, 13130, 198, 40979, 349, 1698, 271, 2123, 13, 435, 13, 18335, 198, 37811, 198, 198, 11748, 28034, 198, 11748, 28034, 13, 20471, 13, 45124, 355, 376, 198, 198, 2, 250...
2.114611
4,127
#!/usr/bin/env python3 import argparse import serial import time from time import sleep import datetime parser = argparse.ArgumentParser() parser.add_argument('port') args = parser.parse_args() sleep_time = 50 ser = serial.Serial(args.port, 9600) sleep(3) send('Button LCLICK', 0.1) try: ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 201, 198, 11748, 1822, 29572, 201, 198, 11748, 11389, 201, 198, 11748, 640, 201, 198, 6738, 640, 1330, 3993, 201, 198, 11748, 4818, 8079, 201, 198, 201, 198, 48610, 796, 1822, 29572, 13...
2.433526
173
import json import torch from torchvision import datasets, transforms from PIL import Image # Define function to read cat names # Define function to read data # Define processing testing image function def process_image(image): ''' Scales, crops, and normalizes a PIL image for a PyTorch model, returns an...
[ 11748, 33918, 198, 11748, 28034, 198, 6738, 28034, 10178, 1330, 40522, 11, 31408, 198, 6738, 350, 4146, 1330, 7412, 198, 198, 2, 2896, 500, 2163, 284, 1100, 3797, 3891, 198, 198, 2, 2896, 500, 2163, 284, 1100, 1366, 198, 198, 2, 2896,...
2.197789
814
# Copyright 2015 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
[ 2, 15069, 1853, 383, 309, 22854, 37535, 46665, 13, 1439, 6923, 33876, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, ...
3.776173
554
#!/usr/bin/env python # -*- coding: utf-8 -*- import os import numpy as np from gmprocess.core.streamcollection import StreamCollection from gmprocess.io.read import read_data from gmprocess.utils.test_utils import read_data_dir from gmprocess.waveform_processing.adjust_highpass_ridder import ridder_fchp from gmproces...
[ 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, 28686, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 308, 76, 14681, 13, 7295, 13, 5532, 43681, 1330, 1386...
2.743902
164
""" Import recipes from URLs to our database """ import re import json from txpx import background, EchoProcess from txpx.process import LineGlueProtocol from supperfeed.build import Recipe LineGlueProtocol.MAX_LENGTH=10000 class ImportProcess(EchoProcess): """ Import a recipe by loading the json data dump...
[ 37811, 198, 20939, 14296, 422, 32336, 284, 674, 6831, 198, 37811, 198, 11748, 302, 198, 11748, 33918, 198, 198, 6738, 27765, 8416, 1330, 4469, 11, 21455, 18709, 198, 6738, 27765, 8416, 13, 14681, 1330, 6910, 9861, 518, 19703, 4668, 198, ...
3.544554
101
from typing import List solution = Solution() print(solution.groupThePeople(groupSizes = [3,3,3,3,3,1,3]))
[ 6738, 19720, 1330, 7343, 628, 198, 82, 2122, 796, 28186, 3419, 198, 4798, 7, 82, 2122, 13, 8094, 464, 8061, 7, 8094, 50, 4340, 796, 685, 18, 11, 18, 11, 18, 11, 18, 11, 18, 11, 16, 11, 18, 60, 4008, 628 ]
2.619048
42
#! /usr/bin/python3 import sys import os sys.path.append('../') import numpy as np import matplotlib.pyplot as plt import imageio import matplotlib.cm as cm import time from netCDF4 import MFDataset import mesonh_probe as cdf """ test file for periodiccontainer and netcdfinterface types - arguments : mesonh (net...
[ 2, 0, 1220, 14629, 14, 8800, 14, 29412, 18, 198, 198, 11748, 25064, 198, 11748, 28686, 198, 17597, 13, 6978, 13, 33295, 10786, 40720, 11537, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, ...
2.217105
456
import responses @responses.activate
[ 11748, 9109, 628, 198, 31, 16733, 274, 13, 39022, 198 ]
3.9
10
# 请求成功 RESPONSE_OK = 200 # 请求所需的URL地址 URLS = { # 主机地址 "hostUrl": "https://m.r.umiaohealth.com/", # 获取疫苗接种列表地址;POST "vaccinationAddress": "/InstitutionMedicineStock/GetBykeyword_InstitutionMedicineStock", # 获取某个社区医院的某一天可预约的时间段 "hospitalTimeRange": "/Reservation/GetByWorkDate_Rsv_TimeRange", ...
[ 2, 5525, 107, 115, 162, 109, 224, 22755, 238, 27950, 253, 198, 19535, 47, 1340, 5188, 62, 11380, 796, 939, 198, 198, 2, 5525, 107, 115, 162, 109, 224, 33699, 222, 165, 250, 222, 21410, 21886, 28839, 108, 161, 251, 222, 198, 4261, ...
1.217656
657
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright (C) 2011 Radim Rehurek <radimrehurek@seznam.cz> # Licensed under the GNU LGPL v2.1 - http://www.gnu.org/licenses/lgpl.html """Scikit learn interface for :class:`~gensim.models.hdpmodel.HdpModel`. Follows scikit-learn API conventions to facilitate using gensim...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 198, 2, 15069, 357, 34, 8, 2813, 5325, 320, 797, 71, 495, 74, 1279, 6335, 320, 260, 71, 495, 74, 31, 325, 89, ...
2.231905
4,131
# 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 t...
[ 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 345, 743, 198, 2, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, 921, 743, 7330, 198, 2, 257, 4866, 286, 262, 13789, 379, 198, 2,...
2.236464
905
import discord import discord.utils from discord.ext import commands import requests import random client = discord.Client() SECRET_KEY="secretkey" BASE_URL="http://0.0.0.0:1234" @client.event @client.event client.run("")
[ 11748, 36446, 198, 11748, 36446, 13, 26791, 198, 6738, 36446, 13, 2302, 1330, 9729, 198, 11748, 7007, 198, 11748, 4738, 198, 198, 16366, 796, 36446, 13, 11792, 3419, 198, 198, 23683, 26087, 62, 20373, 2625, 21078, 2539, 1, 198, 33, 1115...
2.986842
76
from django.contrib.staticfiles.urls import staticfiles_urlpatterns from django.conf import settings from django.contrib import admin from django.urls import path, re_path from . import views # SSO urlpatterns = [ path('reports/', views.list_reports, name="django-pathfinder-statcrunch-list-reports"), ...
[ 6738, 42625, 14208, 13, 3642, 822, 13, 12708, 16624, 13, 6371, 82, 1330, 9037, 16624, 62, 6371, 33279, 82, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 6738, 42625, 14208, 13,...
2.645933
209
import fileinput nums = list(map(int, fileinput.input())) print(sum(inc for inc in gen()))
[ 11748, 2393, 15414, 198, 198, 77, 5700, 796, 1351, 7, 8899, 7, 600, 11, 2393, 15414, 13, 15414, 3419, 4008, 628, 198, 198, 4798, 7, 16345, 7, 1939, 329, 753, 287, 2429, 3419, 4008, 198 ]
2.714286
35
import connexion import six from openapi_server.models.runtime_error import RuntimeError # noqa: E501 from openapi_server.models.v1_health_check_service_health_check_response import V1HealthCheckServiceHealthCheckResponse # noqa: E501 from openapi_server import util def health_check_service_health_check(): # noqa...
[ 11748, 369, 12413, 295, 198, 11748, 2237, 198, 198, 6738, 1280, 15042, 62, 15388, 13, 27530, 13, 43282, 62, 18224, 1330, 43160, 12331, 220, 1303, 645, 20402, 25, 412, 33548, 198, 6738, 1280, 15042, 62, 15388, 13, 27530, 13, 85, 16, 62...
3.077419
155
class Model182: """Class to create Model 182 files""" declarant = None declared_registers = {}
[ 4871, 9104, 24294, 25, 198, 220, 220, 220, 37227, 9487, 284, 2251, 9104, 28581, 3696, 37811, 628, 220, 220, 220, 2377, 4741, 796, 6045, 198, 220, 220, 220, 6875, 62, 2301, 6223, 796, 23884, 198 ]
3.085714
35
""" Created on 12:39, June. 4th, 2021 Author: fassial Filename: VoltageJump.py """ import brainpy as bp __all__ = [ "VoltageJump", ]
[ 37811, 198, 41972, 319, 1105, 25, 2670, 11, 2795, 13, 604, 400, 11, 33448, 198, 13838, 25, 277, 562, 498, 198, 35063, 25, 45444, 36046, 13, 9078, 198, 37811, 198, 11748, 3632, 9078, 355, 275, 79, 198, 198, 834, 439, 834, 796, 685, ...
2.482143
56
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Sun May 10 10:31:44 2020 @author: alex """ import argparse from clodsa.utils.conf import Conf
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 41972, 319, 3825, 1737, 838, 838, 25, 3132, 25, 2598, 12131, 198, 198, 31, 9800, 25, 257, 2588, 198, ...
2.557377
61
#################################################################################### # BLACKMAMBA BY: LOSEYS (https://github.com/loseys) # # QT GUI INTERFACE BY: WANDERSON M.PIMENTA (https://github.com/Wanderson-Magalhaes) # ORIGINAL QT GUI: https://github.com/Wanderson-Magalhaes/Simple_PySide_Base ####################...
[ 29113, 29113, 14468, 4242, 198, 2, 31963, 44, 2390, 4339, 11050, 25, 406, 14058, 16309, 357, 5450, 1378, 12567, 13, 785, 14, 75, 577, 893, 8, 198, 2, 198, 2, 1195, 51, 25757, 23255, 49836, 11050, 25, 370, 6981, 29086, 337, 13, 47, ...
3.069388
245
from datetime import datetime from infrastructure.cqrs.decorators.requestclass import requestclass @requestclass
[ 6738, 4818, 8079, 1330, 4818, 8079, 198, 198, 6738, 6884, 13, 66, 80, 3808, 13, 12501, 273, 2024, 13, 25927, 4871, 1330, 2581, 4871, 628, 198, 31, 25927, 4871, 198 ]
3.866667
30
import sqlite3 # Connect to the sqlite3 file connection = sqlite3.connect("northwind_small.sqlite3") cursor = connection.cursor() # Queries # `expensive_items`: What are the ten most expensive items (per unit price) in the database? price_query = f""" SELECT UnitPrice, ProductName FROM product ...
[ 11748, 44161, 578, 18, 628, 198, 2, 8113, 284, 262, 44161, 578, 18, 2393, 198, 198, 38659, 796, 44161, 578, 18, 13, 8443, 7203, 43588, 7972, 62, 17470, 13, 25410, 578, 18, 4943, 198, 198, 66, 21471, 796, 4637, 13, 66, 21471, 3419, ...
2.412835
1,979
import torch import torch.nn as nn import torch.nn.functional as F import functools from .SurfaceClassifier import conv1_1, period_loss # from .DepthNormalizer import DepthNormalizer from ..net_util import * # from iPERCore.models.networks.criterions import VGGLoss from lib.model.Models import NestedUNet import numpy a...
[ 11748, 28034, 198, 11748, 28034, 13, 20471, 355, 299, 77, 198, 11748, 28034, 13, 20471, 13, 45124, 355, 376, 198, 11748, 1257, 310, 10141, 198, 6738, 764, 14214, 2550, 9487, 7483, 1330, 3063, 16, 62, 16, 11, 2278, 62, 22462, 198, 2, ...
2.209671
2,461
#!/usr/lib/python-exec/python2.7/python import os import sys os.chdir('C:/Users/Leleo/Documents/Active Cell Real Morphology/') from neuron import h from neuron import gui #%% import numpy as np import time import math import cPickle as pickle #%% sk = False if sk==True: from sklearn import decomposition f...
[ 2, 48443, 14629, 14, 8019, 14, 29412, 12, 18558, 14, 29412, 17, 13, 22, 14, 29412, 198, 11748, 28686, 198, 11748, 25064, 198, 418, 13, 354, 15908, 10786, 34, 14079, 14490, 14, 3123, 293, 78, 14, 38354, 14, 13739, 12440, 6416, 41170, ...
2.305906
1,981
from selenium import webdriver import time from datetime import date from selenium.webdriver.common.keys import Keys from scrape_table_all import scrape_table from return_dates import return_dates # Open the link PATH = "/Users/prajwalshrestha/Desktop/PythonApp/thesis/web-scrapers/sharesansar/chromedriver" browser = w...
[ 6738, 384, 11925, 1505, 1330, 3992, 26230, 198, 11748, 640, 198, 6738, 4818, 8079, 1330, 3128, 198, 6738, 384, 11925, 1505, 13, 12384, 26230, 13, 11321, 13, 13083, 1330, 26363, 198, 6738, 42778, 62, 11487, 62, 439, 1330, 42778, 62, 1148...
2.851016
443
import pytest import subprocess from io import BytesIO import json from werkzeug.wrappers import Response from elephant_vending_machine import elephant_vending_machine from subprocess import CompletedProcess, CalledProcessError @pytest.fixture
[ 11748, 12972, 9288, 198, 11748, 850, 14681, 198, 6738, 33245, 1330, 2750, 4879, 9399, 198, 11748, 33918, 198, 198, 6738, 266, 9587, 2736, 1018, 13, 29988, 11799, 1330, 18261, 198, 198, 6738, 20950, 62, 85, 1571, 62, 30243, 1330, 20950, ...
3.787879
66
from django.conf.urls import url from django.urls import path from . import views app_name = 'articles' urlpatterns = [ url(r'^$', views.homepage, name="list"), url(r'^about/$', views.about, name="about"), url(r'^contact/$', views.contact, name="contact"), url(r'^bolaka/$', views.bolaka, name="bolak...
[ 6738, 42625, 14208, 13, 10414, 13, 6371, 82, 1330, 19016, 198, 6738, 42625, 14208, 13, 6371, 82, 1330, 3108, 198, 198, 6738, 764, 1330, 5009, 198, 198, 1324, 62, 3672, 796, 705, 26845, 6, 628, 198, 6371, 33279, 82, 796, 685, 198, 22...
2.31328
881
"""Extensions for the ``maya.OpenMayaFX`` module."""
[ 37811, 11627, 5736, 329, 262, 7559, 11261, 64, 13, 11505, 6747, 64, 17213, 15506, 8265, 526, 15931, 198 ]
2.944444
18
# -*- coding: utf-8 -*- from __future__ import unicode_literals import uuid from django.db import 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, 11748, 334, 27112, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 4981, 628 ]
2.769231
39
from running_modes.configurations import GeneralConfigurationEnvelope from running_modes.constructors.base_running_mode import BaseRunningMode from running_modes.constructors.create_model_mode_constructor import CreateModelModeConstructor from running_modes.constructors.curriculum_learning_mode_constructor import Curri...
[ 6738, 2491, 62, 76, 4147, 13, 11250, 20074, 1330, 3611, 38149, 4834, 1091, 68, 198, 6738, 2491, 62, 76, 4147, 13, 41571, 669, 13, 8692, 62, 20270, 62, 14171, 1330, 7308, 28768, 19076, 198, 6738, 2491, 62, 76, 4147, 13, 41571, 669, 1...
4.026667
225
from ansible_collections.nhsd.apigee.plugins.module_utils import constants def org_from_env(environment) -> str: """Get nhsd apigee organization name from environment name.""" for org, envs in constants.APIGEE_ORG_TO_ENV.items(): if environment in envs: return org valid_envs = [] f...
[ 6738, 9093, 856, 62, 4033, 26448, 13, 77, 11994, 67, 13, 499, 328, 1453, 13, 37390, 13, 21412, 62, 26791, 1330, 38491, 628, 198, 4299, 8745, 62, 6738, 62, 24330, 7, 38986, 8, 4613, 965, 25, 198, 220, 220, 220, 37227, 3855, 299, 11...
2.668449
187
""" ``astyle`` provides classes for adding style (foreground and background color; bold; blink; etc.) to terminal and curses output. """ import sys, os try: import curses except ImportError: curses = None COLOR_BLACK = 0 COLOR_RED = 1 COLOR_GREEN = 2 COLOR_YELLOW = 3 COLOR_BLUE = 4 COLOR_MAGENT...
[ 37811, 198, 15506, 459, 2349, 15506, 3769, 6097, 329, 4375, 3918, 357, 754, 2833, 290, 4469, 3124, 26, 198, 36575, 26, 21019, 26, 3503, 2014, 284, 12094, 290, 43878, 5072, 13, 198, 37811, 628, 198, 11748, 25064, 11, 28686, 198, 198, 2...
2.162338
3,850
import pickle import robot_sim.robots.ur3_dual.ur3_dual as ur3d import rbt_con.force_control as ur3dx # import robot_con.ur.ur3_dual_x as ur3dx import visualization.panda.world as wd import modeling.geometric_model as gm import motion.optimization_based.incremental_nik as inik import numpy as np import modeling.collisi...
[ 11748, 2298, 293, 198, 11748, 9379, 62, 14323, 13, 22609, 1747, 13, 333, 18, 62, 646, 282, 13, 333, 18, 62, 646, 282, 355, 2956, 18, 67, 198, 11748, 374, 18347, 62, 1102, 13, 3174, 62, 13716, 355, 2956, 18, 34350, 198, 2, 1330, ...
2.299191
371
""" This module use SpiralArm superclass, with some modifications, to create 3-kpc arm. """ from shapely.geometry.polygon import Polygon from descartes import PolygonPatch from .spiral_parameters import Three_Kpc from . import spiral_property as spiral_eq from .spiral_arm_superclass import SpiralArm
[ 37811, 198, 1212, 8265, 779, 46727, 26560, 2208, 4871, 11, 351, 617, 19008, 11, 198, 284, 2251, 513, 12, 74, 14751, 3211, 13, 198, 37811, 198, 198, 6738, 5485, 306, 13, 469, 15748, 13, 35428, 14520, 1330, 12280, 14520, 198, 6738, 1715...
3.505747
87
'Code for scrapping RBI Data' from datetime import date from lxml import etree import logging from logging.config import fileConfig from scrappers.scrapping_utils import ScrappingUtils fileConfig('scrappers/logging_config.ini') logger = logging.getLogger() OUT_FOLDER = "rbi" if __name__ == '__main__': obj = RBIB...
[ 6, 10669, 329, 19320, 2105, 20948, 6060, 6, 198, 198, 6738, 4818, 8079, 1330, 3128, 198, 6738, 300, 19875, 1330, 2123, 631, 198, 11748, 18931, 198, 6738, 18931, 13, 11250, 1330, 2393, 16934, 198, 6738, 19320, 11799, 13, 1416, 430, 2105,...
2.477663
291
#!/usr/bin/python3 """ post email """ import urllib.request import urllib.parse import sys if __name__ == "__main__": value = {'email': sys.argv[2]} data = urllib.parse.urlencode(value) data = data.encode('utf-8') req = urllib.request.Request(sys.argv[1], data) with urllib.request.urlopen(req) as ...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 18, 198, 37811, 1281, 3053, 37227, 198, 11748, 2956, 297, 571, 13, 25927, 198, 11748, 2956, 297, 571, 13, 29572, 198, 11748, 25064, 628, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 129...
2.362573
171
# selection.py # since: 10/2018 # Developed by: Shehu Lab """Module for selecting next generation from current generation. This module provides methods to select next generation from current generation. Available Functions: - truncation: Selects next generation via elitism truncation selection. """ def truncation(...
[ 2, 6356, 13, 9078, 198, 2, 1201, 25, 838, 14, 7908, 198, 2, 6013, 276, 416, 25, 1375, 13415, 3498, 198, 198, 37811, 26796, 329, 17246, 1306, 5270, 422, 1459, 5270, 13, 198, 198, 1212, 8265, 3769, 5050, 284, 2922, 1306, 5270, 422, ...
3.034731
835
n = int(input('Digite um número: ')) if n % 2 == 0: print(f'O número {n} é par.') else: print(f'O número {n} é ímpar.')
[ 77, 796, 493, 7, 15414, 10786, 19511, 578, 23781, 299, 21356, 647, 78, 25, 705, 4008, 198, 361, 299, 4064, 362, 6624, 657, 25, 198, 220, 220, 220, 3601, 7, 69, 6, 46, 299, 21356, 647, 78, 1391, 77, 92, 38251, 1582, 2637, 8, 198,...
1.816901
71
import math def find_index(sorted_list, target): """Finds the index where the target value is expected in a sorted list.""" def binary_search(low_index, hi_index): """Searches for a value in a list, throwing away half each call""" # locate the middle index mid_index = math.ceil((low_i...
[ 11748, 10688, 628, 198, 4299, 1064, 62, 9630, 7, 82, 9741, 62, 4868, 11, 2496, 2599, 198, 220, 220, 220, 37227, 16742, 82, 262, 6376, 810, 262, 2496, 1988, 318, 2938, 287, 257, 23243, 1351, 526, 15931, 628, 220, 220, 220, 825, 13934...
2.280675
652
with open('input.txt') as file: total = 0 for line in file: inputs, outputs = parse_line(line) for code in outputs: if len(code) == 2 or len(code) == 3 or len(code) == 4 or len(code) == 7: total += 1 print(total)
[ 198, 4480, 1280, 10786, 15414, 13, 14116, 11537, 355, 2393, 25, 198, 220, 220, 220, 2472, 796, 657, 198, 220, 220, 220, 329, 1627, 287, 2393, 25, 198, 220, 220, 220, 220, 220, 220, 220, 17311, 11, 23862, 796, 21136, 62, 1370, 7, 1...
2.134921
126
import vcf import argparse from pyfaidx import Fasta from Bio import SeqIO from Bio.SeqRecord import SeqRecord from Bio.Seq import MutableSeq parser = argparse.ArgumentParser(description='Make fasta for each variant to align/augment.') parser.add_argument('-v', help='the input VCF file.', required=True) parser.add_arg...
[ 11748, 410, 12993, 198, 11748, 1822, 29572, 198, 6738, 12972, 69, 1698, 87, 1330, 12549, 64, 198, 6738, 16024, 1330, 1001, 80, 9399, 198, 6738, 16024, 13, 4653, 80, 23739, 1330, 1001, 80, 23739, 198, 6738, 16024, 13, 4653, 80, 1330, 1...
2.27657
828
""" Ethernet RMII Interface Copyright 2018-2019 Adam Greig Released under the MIT license; see LICENSE for details. """ from nmigen import Elaboratable, Module, Signal, Cat from .crc import CRC32 from .mac_address_match import MACAddressMatch class RMIIRx(Elaboratable): """ RMII receive module Receives...
[ 37811, 198, 36, 490, 3262, 29820, 3978, 26491, 198, 198, 15269, 2864, 12, 23344, 7244, 11955, 328, 198, 45037, 739, 262, 17168, 5964, 26, 766, 38559, 24290, 329, 3307, 13, 198, 37811, 198, 198, 6738, 28642, 9324, 1330, 2574, 4820, 21156...
2.585059
1,352
import discord from discord.ext import commands import random import sys sys.path.insert(1, '../functions') from functions.cmd_print import cmd_print
[ 11748, 36446, 198, 6738, 36446, 13, 2302, 1330, 9729, 198, 11748, 4738, 198, 11748, 25064, 198, 17597, 13, 6978, 13, 28463, 7, 16, 11, 705, 40720, 12543, 2733, 11537, 198, 6738, 5499, 13, 28758, 62, 4798, 1330, 23991, 62, 4798, 628, 1...
3.619048
42
sentences = [['a', 'b', 'c'], ['a', 'd','e']] default_val = '' entity_embeddings_dict = {} entity_embeddings_dict = {sentence[0]: doThis(sentence) + entity_embeddings_dict.get(sentence[0], default_val) \ for sentence in sentences } print(entity_embeddings_dict)
[ 34086, 3007, 796, 16410, 6, 64, 3256, 705, 65, 3256, 705, 66, 6, 4357, 37250, 64, 3256, 705, 67, 41707, 68, 6, 11907, 198, 198, 12286, 62, 2100, 796, 10148, 198, 26858, 62, 20521, 67, 654, 62, 11600, 796, 23884, 198, 26858, 62, 20...
2.646465
99
import dill as pickle import numpy as np from mpl_toolkits.mplot3d import Axes3D import matplotlib.pyplot as plt import grav_util_3 as gu import bead_util as bu import configuration as config import warnings warnings.filterwarnings("ignore") theory_data_dir = '/data/grav_sim_data/2um_spacing_data/' data_dirs =...
[ 11748, 288, 359, 355, 2298, 293, 198, 198, 11748, 299, 32152, 355, 45941, 198, 198, 6738, 285, 489, 62, 25981, 74, 896, 13, 76, 29487, 18, 67, 1330, 12176, 274, 18, 35, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, ...
1.836181
2,985
from ursina import * # Test Cube # Test button # update is run every frame # basic window app = Ursina() # basic cube cube = Entity(model='quad', color=color.orange, scale = (2,5), position = (5,1)) # quad with texture #sans_image = load_texture('Sans.png') #sans = Entity(model = 'quad', texture = sans_image) #...
[ 6738, 220, 1834, 1437, 1330, 1635, 198, 198, 2, 6208, 23315, 198, 198, 2, 6208, 4936, 628, 198, 2, 4296, 318, 1057, 790, 5739, 198, 198, 2, 4096, 4324, 198, 1324, 796, 37935, 1437, 3419, 198, 198, 2, 4096, 23441, 220, 198, 40296, ...
2.88172
186
import numpy as np from copy import copy, deepcopy from utils.rvs.utils import COMPARATOR_NEGATIONS def parse_value(value): ''' Attempts to interpret <value> as a number. ''' if isinstance(value, str): try: value = int(value) except ValueError: value = float(value) return value ...
[ 11748, 299, 32152, 355, 45941, 198, 6738, 4866, 1330, 4866, 11, 2769, 30073, 198, 6738, 3384, 4487, 13, 81, 14259, 13, 26791, 1330, 24301, 1503, 25633, 62, 45, 7156, 18421, 628, 628, 628, 628, 628, 628, 628, 628, 628, 628, 628, 628, ...
2.74359
117
from django import forms
[ 6738, 42625, 14208, 1330, 5107, 628, 198 ]
3.857143
7
# This code is part of Qiskit. # # (C) Copyright IBM 2018. # # This code is licensed under the Apache License, Version 2.0. You may # obtain a copy of this license in the LICENSE.txt file in the root directory # of this source tree or at http://www.apache.org/licenses/LICENSE-2.0. # # Any modifications or derivative wo...
[ 2, 770, 2438, 318, 636, 286, 1195, 1984, 270, 13, 198, 2, 198, 2, 357, 34, 8, 15069, 19764, 2864, 13, 198, 2, 198, 2, 770, 2438, 318, 11971, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 13, 921, 743, 198, 2, 7330, 257, 4866...
2.697561
615
# Generated by Django 3.1.2 on 2021-09-20 13:36 from django.db import migrations, models
[ 2, 2980, 515, 416, 37770, 513, 13, 16, 13, 17, 319, 33448, 12, 2931, 12, 1238, 1511, 25, 2623, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 628 ]
2.84375
32
#!/usr/bin/env python3 # Copyright <2019> <Chen Wang [https://chenwang.site], Carnegie Mellon University> # Redistribution and use in source and binary forms, with or without modification, are # permitted provided that the following conditions are met: # 1. Redistributions of source code must retain the above copyr...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 2, 15069, 1279, 23344, 29, 1279, 34, 831, 15233, 685, 5450, 1378, 6607, 47562, 13, 15654, 4357, 33976, 49808, 2059, 29, 198, 198, 2, 2297, 396, 3890, 290, 779, 287, 2723, 29...
2.901542
2,011
from .features import FeatureBinarizer, FeatureBinarizerFromTrees from .linear_regression import LinearRuleRegression from .logistic_regression import LogisticRuleRegression from .boolean_rule_cg import BooleanRuleCG from .GLRM import GLRMExplainer from .BRCG import BRCGExplainer
[ 6738, 764, 40890, 1330, 27018, 33, 22050, 7509, 11, 27018, 33, 22050, 7509, 4863, 51, 6037, 198, 6738, 764, 29127, 62, 2301, 2234, 1330, 44800, 31929, 8081, 2234, 198, 6738, 764, 6404, 2569, 62, 2301, 2234, 1330, 5972, 2569, 31929, 8081...
3.556962
79
import tkinter import time from . import render
[ 11748, 256, 74, 3849, 198, 11748, 640, 198, 6738, 764, 1330, 8543, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 628, 220, 220, 220, 220, 220, 2...
1.685185
54
from numpy import array import os import inspect import matplotlib.pyplot as plt def plot_learning_curve(title, computed_score, train_sizes, \ train_scores_mean, train_scores_std, test_scores_mean, \ test_scores_std): """Generate a plot of the test and training learning curves. Parameters -------...
[ 6738, 299, 32152, 1330, 7177, 198, 11748, 28686, 198, 11748, 10104, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 628, 198, 4299, 7110, 62, 40684, 62, 22019, 303, 7, 7839, 11, 29231, 62, 26675, 11, 4512, 62, 82, 4340, ...
2.565789
1,064
from .args import get_args from .config import get_config, get_connection_config, get_engine, get_meta from .query import query from .export import get_exporter def main(): """ Provides a CLI entrypoint to access a database and export a subset of its data in a specified format. """ args = get_args...
[ 6738, 764, 22046, 1330, 651, 62, 22046, 198, 6738, 764, 11250, 1330, 651, 62, 11250, 11, 651, 62, 38659, 62, 11250, 11, 651, 62, 18392, 11, 651, 62, 28961, 198, 6738, 764, 22766, 1330, 12405, 198, 6738, 764, 39344, 1330, 651, 62, 10...
3.088235
238
"""Circles URLs""" # Django from django.urls import path # Views from cride.circles.views import list_circles from cride.circles.views import create_circle urlpatterns = [ path ('circles/', list_circles), path ('circles/create/', create_circle), ]
[ 37811, 34, 343, 5427, 32336, 37811, 198, 198, 2, 37770, 198, 6738, 42625, 14208, 13, 6371, 82, 1330, 3108, 198, 198, 2, 29978, 198, 6738, 1067, 485, 13, 66, 343, 5427, 13, 33571, 1330, 1351, 62, 66, 343, 5427, 198, 6738, 1067, 485, ...
2.6875
96
__version__ = '1.5.4' __copyright__ = 'Copyright (c) 2018, Skioo SA' __licence__ = 'MIT' __URL__ = 'https://github.com/skioo/django-customer-billing'
[ 834, 9641, 834, 796, 705, 16, 13, 20, 13, 19, 6, 198, 834, 22163, 4766, 834, 796, 705, 15269, 357, 66, 8, 2864, 11, 3661, 952, 78, 14719, 6, 198, 834, 677, 594, 834, 796, 705, 36393, 6, 198, 834, 21886, 834, 796, 705, 5450, 13...
2.34375
64
# Copyright (c) 2013, Nathan Dunsworth - NFXPlugins # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # * Redistributions of source code must retain the above copyright # notice, this list...
[ 2, 15069, 357, 66, 8, 2211, 11, 18106, 5648, 30567, 532, 399, 17213, 23257, 1040, 198, 2, 1439, 2489, 10395, 13, 198, 2, 198, 2, 2297, 396, 3890, 290, 779, 287, 2723, 290, 13934, 5107, 11, 351, 393, 1231, 198, 2, 17613, 11, 389, ...
2.556234
8,838
import numpy as np
[ 11748, 299, 32152, 355, 45941, 628, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 198, 220, 220, 220, 220, 220, 220, 220, 220, 198, 220, 220, 220, 220 ]
1.333333
42
# Advent of Code 2018, Day 16 # (c) blu3r4y from collections import namedtuple from parse import parse OPERATIONS = ['addr', 'addi', 'mulr', 'muli', 'banr', 'bani', 'borr', 'bori', 'setr', 'seti', 'gtir', 'gtri', 'gtrr', 'eqir', 'eqri', 'eqrr'] Observation = namedtuple("Observation", ["instruction", "...
[ 2, 33732, 286, 6127, 2864, 11, 3596, 1467, 198, 2, 357, 66, 8, 48208, 18, 81, 19, 88, 198, 198, 6738, 17268, 1330, 3706, 83, 29291, 198, 198, 6738, 21136, 1330, 21136, 198, 198, 31054, 18421, 796, 37250, 29851, 3256, 705, 2860, 72, ...
2.40566
212
from keras.models import load_model import keras.preprocessing.text as kpt from keras.preprocessing.sequence import pad_sequences import sys import os import json import numpy as np from utils import ConfigurationManager, FileManager ## global dictionary global model dictionaryUrl = os.path.join(FileManager.getRoot...
[ 6738, 41927, 292, 13, 27530, 1330, 3440, 62, 19849, 198, 11748, 41927, 292, 13, 3866, 36948, 13, 5239, 355, 479, 457, 198, 6738, 41927, 292, 13, 3866, 36948, 13, 43167, 1330, 14841, 62, 3107, 3007, 198, 11748, 25064, 198, 11748, 28686, ...
3.139665
179
import pandas as pd from PIL import Image # www.pythonware.com/library/pil/handbook from PIL import ImageFont, ImageDraw, ImageEnhance from PIL import ImageFilter import os #import time import logging from Animate.Items import * from Animate.Properties import * from Animate.Constants import * LOG_FILENAME = '__log...
[ 11748, 19798, 292, 355, 279, 67, 198, 198, 6738, 350, 4146, 1330, 7412, 1303, 7324, 13, 29412, 1574, 13, 785, 14, 32016, 14, 79, 346, 14, 4993, 2070, 198, 6738, 350, 4146, 1330, 7412, 23252, 11, 7412, 25302, 11, 7412, 35476, 590, 19...
3.142857
126
import os def get_project_folder(): ''' Gives us the path to MGR-Project-Code from a list of allowed folders. :return: ''' PATH_ALTERNATIVES = ['/home/ekmek/Project II/MGR-Project-Code/', '/storage/brno2/home/previtus/MGR-Project-Code/', '/home/ekmek/Vitek/MGR-Project-Code/'] ABS_PATH_TO_PRJ = ...
[ 11748, 28686, 198, 198, 4299, 651, 62, 16302, 62, 43551, 33529, 198, 220, 220, 220, 705, 7061, 198, 220, 220, 220, 402, 1083, 514, 262, 3108, 284, 337, 10761, 12, 16775, 12, 10669, 422, 257, 1351, 286, 3142, 24512, 13, 198, 220, 220...
2.356808
1,065
# from sympy import * # Robot Chassis Parameters l = 370 #hip to hip length of the robot b = 210.1 #hip to hip breadth of the robot h = 44 #height of the robot ## Leg Type 1: Rear ''' Variable name convention as follows: The first number represents the length and the second number repre...
[ 2, 422, 10558, 88, 1330, 1635, 201, 198, 201, 198, 2, 16071, 609, 20297, 40117, 201, 198, 75, 796, 28687, 220, 220, 220, 220, 220, 220, 1303, 1056, 284, 10359, 4129, 286, 262, 9379, 201, 198, 65, 796, 20064, 13, 16, 220, 220, 220,...
2.758319
571
from math import floor, log10
[ 6738, 10688, 1330, 4314, 11, 2604, 940, 198 ]
3.75
8
import folium import csv from folium.plugins import MarkerCluster def main(): """ Creates a map of nodes with available SSH connection.\n :return: map_ssh.html file """ map_ssh = folium.Map(location=[45.523, -122.675], zoom_start=2) with open('lib/base_data.txt') as t...
[ 11748, 5955, 1505, 198, 11748, 269, 21370, 198, 6738, 5955, 1505, 13, 37390, 1330, 2940, 263, 2601, 5819, 628, 198, 4299, 1388, 33529, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 7921, 274, 257, 3975, 286, 13760, 351, 1695, 33825, ...
1.919571
373
#!/usr/bin/env python3 ans = 0 with open("input.txt") as f: for line in f: ans += 2 + line.count("\\") + line.count("\"") print(ans)
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 504, 796, 657, 198, 4480, 1280, 7203, 15414, 13, 14116, 4943, 355, 277, 25, 198, 220, 220, 220, 329, 1627, 287, 277, 25, 198, 220, 220, 220, 220, 220, 220, 220, 9093, 1585...
2.246154
65
""" Copyright (c) 2015 Marshall Farrier license http://opensource.org/licenses/MIT lib/ui/edit_menu.py Content for interactive editor """ from functools import partial from .obs_handlers import ObsHandlers from .menu import Menu from .spread_selector import SpreadSelector
[ 37811, 198, 15269, 357, 66, 8, 1853, 13606, 6755, 5277, 198, 43085, 2638, 1378, 44813, 1668, 13, 2398, 14, 677, 4541, 14, 36393, 198, 198, 8019, 14, 9019, 14, 19312, 62, 26272, 13, 9078, 198, 198, 19746, 329, 14333, 5464, 198, 37811, ...
3.4625
80
import numpy as np from uwb.generator import BlobGenerator from uwb.map import NoiseMapNormal
[ 11748, 299, 32152, 355, 45941, 198, 198, 6738, 334, 39346, 13, 8612, 1352, 1330, 1086, 672, 8645, 1352, 198, 6738, 334, 39346, 13, 8899, 1330, 30964, 13912, 26447, 628, 628 ]
3.266667
30
import sklearn from classifiers.classification_model import ClassificationModel
[ 11748, 1341, 35720, 201, 198, 201, 198, 6738, 1398, 13350, 13, 4871, 2649, 62, 19849, 1330, 40984, 17633, 201, 198, 201, 198 ]
3.909091
22
"""A helper for running inference callable multiple times, and ensemble the predictions with a simple majority vote. """ from typing import Callable from collections import Counter def majority_vote_ensemble(eval_func: Callable, num_runs: int): """ Args: eval_func: call without argument to get a pred...
[ 37811, 32, 31904, 329, 2491, 32278, 869, 540, 3294, 1661, 11, 290, 34549, 262, 198, 28764, 9278, 351, 257, 2829, 3741, 3015, 13, 198, 37811, 198, 198, 6738, 19720, 1330, 4889, 540, 198, 6738, 17268, 1330, 15034, 628, 198, 4299, 3741, ...
2.601485
404
import logging import os import shutil import subprocess import psutil from patroni.postgresql import Postgresql logger = logging.getLogger(__name__)
[ 11748, 18931, 198, 11748, 28686, 198, 11748, 4423, 346, 198, 11748, 850, 14681, 198, 11748, 26692, 22602, 198, 198, 6738, 19686, 72, 13, 7353, 34239, 13976, 1330, 2947, 34239, 13976, 198, 198, 6404, 1362, 796, 18931, 13, 1136, 11187, 1362...
3.276596
47
__all__ = ["tosca_parser", "tosca_rdcl_graph"]
[ 834, 439, 834, 796, 14631, 83, 418, 6888, 62, 48610, 1600, 366, 83, 418, 6888, 62, 4372, 565, 62, 34960, 8973 ]
2.190476
21