content
stringlengths
1
1.05M
input_ids
listlengths
1
883k
ratio_char_token
float64
1
22.9
token_count
int64
1
883k
import itertools import logging import math import random from collections import Counter from typing import Any, Dict, List, Optional, Set, Tuple, Union # mypy type checking from .cache import property_cache_forever, property_cache_once_per_frame from .data import ActionResult, Alert, Race, Result, Target, race_gas,...
[ 11748, 340, 861, 10141, 198, 11748, 18931, 198, 11748, 10688, 198, 11748, 4738, 198, 6738, 17268, 1330, 15034, 198, 6738, 19720, 1330, 4377, 11, 360, 713, 11, 7343, 11, 32233, 11, 5345, 11, 309, 29291, 11, 4479, 220, 1303, 616, 9078, ...
2.426134
5,510
# Copyright 2022 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). from __future__ import annotations from dataclasses import dataclass from enum import Enum from typing import Any, Iterable, cast from pants.core.util_rules.lockfile_metadata import ( ...
[ 2, 15069, 33160, 41689, 1628, 20420, 357, 3826, 27342, 9865, 3843, 20673, 13, 9132, 737, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 3826, 38559, 24290, 737, 198, 198, 6738, 11593, 37443, 834, 1330, 37647, 198, ...
3.264249
193
#!/usr/bin/env python3 import os import re cur_path = os.path.dirname(os.path.realpath(__file__)) opendbc_root = os.path.join(cur_path, '../') include_pattern = re.compile(r'CM_ "IMPORT (.*?)";') if __name__ == "__main__": create_all(opendbc_root)
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 11748, 28686, 198, 11748, 302, 198, 198, 22019, 62, 6978, 796, 28686, 13, 6978, 13, 15908, 3672, 7, 418, 13, 6978, 13, 5305, 6978, 7, 834, 7753, 834, 4008, 198, 404, 437, 15630, ...
2.383178
107
from django.contrib import admin from django.utils.safestring import mark_safe from customer.models import Owner, Dog, Breed, SubBreed admin.site.register(Dog, DogAdmin) admin.site.register(Owner, OwnerAdmin) admin.site.register(Breed, BreedAdmin) admin.site.register(SubBreed, SubBreedAdmin)
[ 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 6738, 42625, 14208, 13, 26791, 13, 49585, 395, 1806, 1330, 1317, 62, 21230, 198, 6738, 6491, 13, 27530, 1330, 23853, 11, 8532, 11, 45958, 11, 3834, 12679, 276, 628, 628, 198, 198, 2...
3.193548
93
from __future__ import absolute_import from redis import Redis from rq.decorators import job from kaneda.utils import get_backend backend = get_backend()
[ 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 198, 198, 6738, 2266, 271, 1330, 2297, 271, 198, 6738, 374, 80, 13, 12501, 273, 2024, 1330, 1693, 198, 198, 6738, 43998, 18082, 13, 26791, 1330, 651, 62, 1891, 437, 198, 198, 1891, 437, ...
3.22449
49
from dotenv import load_dotenv from PyPDF2 import PdfFileReader, PdfFileWriter import os import json if __name__ == "__main__": load_dotenv() ripper = CertRipper( start_page_index=os.getenv("START_PAGE_INDEX"), master_pdf_path=os.getenv("MASTER_PDF_PATH"), json_points_path=os.getenv(...
[ 6738, 16605, 24330, 1330, 3440, 62, 26518, 24330, 198, 6738, 9485, 20456, 17, 1330, 350, 7568, 8979, 33634, 11, 350, 7568, 8979, 34379, 198, 11748, 28686, 198, 11748, 33918, 628, 198, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 8...
2.240909
220
# # Licensed Materials - Property of IBM # # (c) Copyright IBM Corp. 2007-2008 # import unittest, sys import ibm_db import config from testfunctions import IbmDbTestFunctions #__END__ #__LUW_EXPECTED__ #False #int(0) #int(1) #False #False #False #int(1) #False #__ZOS_EXPECTED__ #False #int(0) #int(1) #False #False...
[ 2, 220, 198, 2, 220, 49962, 24310, 532, 14161, 286, 19764, 198, 2, 198, 2, 220, 357, 66, 8, 15069, 19764, 11421, 13, 4343, 12, 11528, 198, 2, 198, 198, 11748, 555, 715, 395, 11, 25064, 198, 11748, 24283, 76, 62, 9945, 198, 11748, ...
2.122881
236
from cms.api import get_page_draft from cms.toolbar_pool import toolbar_pool from cms.toolbar_base import CMSToolbar from cms.utils import get_cms_setting from cms.utils.permissions import has_page_change_permission from django.core.urlresolvers import reverse, NoReverseMatch from django.utils.translation import ugette...
[ 6738, 269, 907, 13, 15042, 1330, 651, 62, 7700, 62, 35679, 198, 6738, 269, 907, 13, 25981, 5657, 62, 7742, 1330, 50149, 62, 7742, 198, 6738, 269, 907, 13, 25981, 5657, 62, 8692, 1330, 16477, 2257, 970, 5657, 198, 6738, 269, 907, 13,...
2.971591
176
import math import torch import torch.nn as nn import torch.nn.functional as F # Temporarily leave PositionalEncoding module here. Will be moved somewhere else.
[ 11748, 10688, 198, 11748, 28034, 198, 11748, 28034, 13, 20471, 355, 299, 77, 198, 11748, 28034, 13, 20471, 13, 45124, 355, 376, 198, 198, 2, 5825, 1819, 3093, 2666, 18574, 1859, 27195, 7656, 8265, 994, 13, 2561, 307, 3888, 7382, 2073, ...
3.767442
43
main()
[ 12417, 3419 ]
3
2
from scrapper.playstation.spider import main
[ 6738, 19320, 2848, 13, 1759, 17529, 13, 2777, 1304, 1330, 1388 ]
4
11
import slackbot.bot import random answer = random.randint(1, 50) max = 50 def number(num): '''number Args: num (int): Returns: str: num answer : 'Too large' num answer : 'Too small' num answer : 'Correct!' : 'Can I kick you?.' 0 ...
[ 11748, 30740, 13645, 13, 13645, 198, 11748, 4738, 198, 198, 41484, 796, 4738, 13, 25192, 600, 7, 16, 11, 2026, 8, 198, 9806, 796, 2026, 198, 198, 4299, 1271, 7, 22510, 2599, 198, 220, 220, 220, 705, 7061, 17618, 220, 198, 220, 220, ...
2.101515
660
"""Code for checking and inferring types.""" import collections import logging import re import subprocess from typing import Any, Dict, Union from pytype import abstract from pytype import abstract_utils from pytype import convert_structural from pytype import debug from pytype import function from pytype import met...
[ 37811, 10669, 329, 10627, 290, 13249, 1806, 3858, 526, 15931, 198, 198, 11748, 17268, 198, 11748, 18931, 198, 11748, 302, 198, 11748, 850, 14681, 198, 6738, 19720, 1330, 4377, 11, 360, 713, 11, 4479, 198, 198, 6738, 12972, 4906, 1330, 1...
2.779675
2,401
#!/usr/bin/env python __author__ = "etseng@pacb.com" """ Given a pooled input GFF + demux CSV file, write out per-{barcode group} GFFs If input fasta/fastq is given, optionally also output per-{barcode group} FASTA/FASTQ """ import re from collections import defaultdict from csv import DictReader from typing import Op...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 834, 9800, 834, 796, 366, 1039, 1516, 31, 33587, 65, 13, 785, 1, 198, 198, 37811, 198, 15056, 257, 44762, 5128, 402, 5777, 1343, 1357, 2821, 44189, 2393, 11, 3551, 503, 583, 12, 90, ...
2.117742
1,240
import random import numpy as np import math from skimage.draw import line, line_aa, circle, set_color, circle_perimeter_aa from skimage.io import imsave from skimage.util import random_noise maxSlope = 10 # restrict the maximum slope of generated lines for stability minLength = 20 # restrict the minimum length of li...
[ 11748, 4738, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 10688, 198, 198, 6738, 1341, 9060, 13, 19334, 1330, 1627, 11, 1627, 62, 7252, 11, 9197, 11, 900, 62, 8043, 11, 9197, 62, 525, 16912, 62, 7252, 198, 6738, 1341, 9060, 13, 9...
3.772727
88
# -*- coding: utf-8 -*- """ Created on Wed Apr 1 17:14:19 2020 @author: Mitchell nesm_generator.py ~~~~~~~~~~~~~~~~~ This file serves as a script for using our pre-trained VAE model to generate brand new NES music soundtracks. NOTE - using the reduced model we only generate the first melodic voice for each track rat...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 41972, 319, 3300, 2758, 220, 352, 1596, 25, 1415, 25, 1129, 12131, 198, 198, 31, 9800, 25, 14526, 198, 198, 2516, 76, 62, 8612, 1352, 13, 9078, 198, 27156,...
3.262832
1,617
import logging import logging.handlers import os
[ 11748, 18931, 198, 11748, 18931, 13, 4993, 8116, 198, 11748, 28686, 198 ]
4.083333
12
#Author Theodosis Paidakis print("Hello World") hello_list = ["Hello World"] print(hello_list[0]) for i in hello_list: print(i)
[ 2, 13838, 383, 375, 5958, 47355, 27321, 198, 198, 4798, 7203, 15496, 2159, 4943, 198, 198, 31373, 62, 4868, 796, 14631, 15496, 2159, 8973, 198, 4798, 7, 31373, 62, 4868, 58, 15, 12962, 198, 1640, 1312, 287, 23748, 62, 4868, 25, 198, ...
2.714286
49
from collections import namedtuple from unittest.mock import MagicMock _fake_ext = namedtuple('_', ['qtype', 'kb_ident'])
[ 6738, 17268, 1330, 3706, 83, 29291, 220, 198, 6738, 555, 715, 395, 13, 76, 735, 1330, 6139, 44, 735, 628, 198, 62, 30706, 62, 2302, 796, 3706, 83, 29291, 10786, 62, 3256, 37250, 80, 4906, 3256, 705, 32812, 62, 738, 6, 12962, 220, ...
2.863636
44
from abc import ABCMeta, abstractmethod from typing import Tuple, Callable
[ 6738, 450, 66, 1330, 9738, 48526, 11, 12531, 24396, 198, 6738, 19720, 1330, 309, 29291, 11, 4889, 540, 628 ]
4
19
# Book04_1.py b1 = Book(); print(b1.category) b2 = b1; print(b2.category) print(Book.category) Book.category = '' print(b2.category); print(b1.category) ; print(Book.category) b2.category = 'IT' print(b2.category); print(b1.category) ; print(Book.category)
[ 2, 4897, 3023, 62, 16, 13, 9078, 198, 198, 65, 16, 796, 4897, 9783, 3601, 7, 65, 16, 13, 22872, 8, 198, 65, 17, 796, 275, 16, 26, 3601, 7, 65, 17, 13, 22872, 8, 198, 4798, 7, 10482, 13, 22872, 8, 198, 198, 10482, 13, 22872, ...
2.514563
103
# Copyright (C) 2015-2021 Virgil Security, Inc. # # All rights reserved. # # 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 copyright # notice, this li...
[ 2, 15069, 357, 34, 8, 1853, 12, 1238, 2481, 16310, 37718, 4765, 11, 3457, 13, 198, 2, 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, ...
3.334513
565
#!/usr/bin/env python # encoding: utf-8 from django.test import TestCase from zoo import models
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 21004, 25, 3384, 69, 12, 23, 628, 198, 6738, 42625, 14208, 13, 9288, 1330, 6208, 20448, 198, 198, 6738, 26626, 1330, 4981, 628 ]
3.030303
33
print('Digite seu nome completo: ') nome = input().strip().upper() print('Seu nome tem "Silva"?') print('SILVA' in nome)
[ 4798, 10786, 19511, 578, 384, 84, 299, 462, 1224, 1462, 25, 705, 8, 198, 198, 77, 462, 796, 5128, 22446, 36311, 22446, 45828, 3419, 198, 198, 4798, 10786, 4653, 84, 299, 462, 2169, 366, 15086, 6862, 1, 8348, 8, 198, 4798, 10786, 50,...
2.411765
51
dataset_type = 'STVQADATASET' data_root = '/home/datasets/mix_data/iMIX/' feature_path = 'data/datasets/stvqa/defaults/features/' ocr_feature_path = 'data/datasets/stvqa/defaults/ocr_features/' annotation_path = 'data/datasets/stvqa/defaults/annotations/' vocab_path = 'data/datasets/stvqa/defaults/extras/vocabs/' trai...
[ 19608, 292, 316, 62, 4906, 796, 705, 2257, 53, 48, 2885, 1404, 1921, 2767, 6, 198, 7890, 62, 15763, 796, 31051, 11195, 14, 19608, 292, 1039, 14, 19816, 62, 7890, 14, 72, 8895, 55, 14, 6, 198, 30053, 62, 6978, 796, 705, 7890, 14, ...
2.09375
1,568
# -*- coding: utf-8 -*- # Generated by Django 1.10 on 2016-09-27 13:17 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion import mezzanine.core.fields
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 2980, 515, 416, 37770, 352, 13, 940, 319, 1584, 12, 2931, 12, 1983, 1511, 25, 1558, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, 198, 6738,...
2.805195
77
#LineSensor test from gpiozero import LineSensor from time import sleep from signal import pause sensor = LineSensor(14) sensor.when_line = lineDetected sensor.when_no_line = noLineDetected pause() sensor.close()
[ 2, 13949, 47864, 1332, 198, 198, 6738, 27809, 952, 22570, 1330, 6910, 47864, 198, 6738, 640, 1330, 3993, 198, 6738, 6737, 1330, 14985, 628, 198, 82, 22854, 796, 6910, 47864, 7, 1415, 8, 198, 198, 82, 22854, 13, 12518, 62, 1370, 796, ...
3.084507
71
# # This file is part of LiteX-Boards. # # Copyright (c) 2021 Gwenhael Goavec-Merou <gwenhael.goavec-merou@trabucayre.com> # SPDX-License-Identifier: BSD-2-Clause from migen import * from litex.build.generic_platform import * from litex.build.gowin.platform import GowinPlatform from litex.build.openfpgaloader import ...
[ 2, 198, 2, 770, 2393, 318, 636, 286, 27395, 55, 12, 16635, 1371, 13, 198, 2, 198, 2, 15069, 357, 66, 8, 33448, 39661, 16550, 3010, 1514, 1015, 66, 12, 13102, 280, 1279, 70, 86, 16550, 3010, 13, 2188, 1015, 66, 12, 647, 280, 31, ...
2.284204
1,608
import numpy as np import copy import combo.misc import cPickle as pickle from results import history from .. import utility from ...variable import variable from ..call_simulator import call_simulator from ... import predictor from ...gp import predictor as gp_predictor from ...blm import predictor as blm_predictor im...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 4866, 198, 11748, 14831, 13, 44374, 198, 11748, 269, 31686, 293, 355, 2298, 293, 198, 6738, 2482, 1330, 2106, 198, 6738, 11485, 1330, 10361, 198, 6738, 2644, 45286, 1330, 7885, 198, 6738, 11485, ...
3.717172
99
_disable_linecache()
[ 198, 198, 62, 40223, 62, 1370, 23870, 3419, 198 ]
2.555556
9
import requests from bs4 import BeautifulSoup as bs import os #source url = '' # the source you want the bot take images from #down page page = requests.get(url) html = bs(page.text, 'html.parser') #locate image_loc = html.findAll('img') #create folder for located imgs if not os.path.exists('imgs'): os.makedirs(...
[ 11748, 7007, 198, 6738, 275, 82, 19, 1330, 23762, 50, 10486, 355, 275, 82, 198, 11748, 28686, 198, 198, 2, 10459, 198, 6371, 796, 10148, 1303, 262, 2723, 345, 765, 262, 10214, 1011, 4263, 422, 198, 198, 2, 2902, 2443, 220, 198, 7700...
2.492806
278
''' 1appium subproccess 1.1 1.2 2driver ''' from lib.tools import Tool import subprocess from lib.path import SYSTEMPATH, ERRORPATH import time from appium import webdriver import queue # python driver_queue = queue.Queue() if __name__ == '__main__': controller = Controller() controller.start_se...
[ 7061, 6, 198, 16, 1324, 1505, 198, 220, 220, 220, 850, 1676, 1591, 198, 220, 220, 220, 220, 198, 16, 13, 16, 198, 16, 13, 17, 198, 17, 26230, 198, 198, 7061, 6, 198, 198, 6738, 9195, 13, 31391, 1330, 16984, 198, 11748, 850, 1468...
2.847826
138
# -*- encoding: utf-8 -*- ''' @project : LeetCode @File : pondSizes.py @Contact : 9824373@qq.com @Desc : land0 [ [0,2,1,0], [0,1,0,1], [1,1,0,1], [0,1,0,1] ] [1,2,4] 0 < len(land) <= 1000 0 < len(land[i]) <= 1000 LeetCode https://le...
[ 2, 532, 9, 12, 21004, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 7061, 6, 198, 31, 16302, 1058, 220, 220, 1004, 316, 10669, 198, 31, 8979, 220, 220, 220, 1058, 220, 220, 16723, 50, 4340, 13, 9078, 198, 31, 17829, 1058, 220, 220, 9...
1.691466
457
# -*- coding: utf-8 -*- from decimal import Decimal, setcontext, ExtendedContext from geolucidate.links.google import google_maps_link from geolucidate.links.tools import MapLink from geolucidate.parser import parser_re setcontext(ExtendedContext) def _cleanup(parts): """ Normalize up the parts matched by :...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 32465, 1330, 4280, 4402, 11, 900, 22866, 11, 24204, 21947, 198, 198, 6738, 4903, 349, 1229, 20540, 13, 28751, 13, 13297, 1330, 23645, 62, 31803, 62, 8726, 198, 673...
2.347013
2,461
from setuptools import setup, find_packages setup( name='Pokedex', version='0.1', zip_safe=False, packages=find_packages(), package_data={ 'pokedex': ['data/csv/*.csv'] }, install_requires=[ 'SQLAlchemy>=1.0,<2.0', 'whoosh>=2.5,<2.7', 'markdown==2.4.1', ...
[ 6738, 900, 37623, 10141, 1330, 9058, 11, 1064, 62, 43789, 198, 198, 40406, 7, 198, 220, 220, 220, 1438, 11639, 47, 6545, 1069, 3256, 198, 220, 220, 220, 2196, 11639, 15, 13, 16, 3256, 198, 220, 220, 220, 19974, 62, 21230, 28, 25101,...
2.019774
354
# Copyright 2018 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, 2864, 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, ...
2.135734
3,610
import matplotlib.font_manager as fm import matplotlib.pyplot as plt import numpy as np font_location = './wordcloud_file/malgun.ttf' # For Windows font_name = fm.FontProperties(fname=font_location).get_name() plt.rc('font', family=font_name)
[ 11748, 2603, 29487, 8019, 13, 10331, 62, 37153, 355, 277, 76, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 11748, 299, 32152, 355, 45941, 198, 10331, 62, 24886, 796, 705, 19571, 4775, 17721, 62, 7753, 14, 7617, 7...
2.793103
87
from django.shortcuts import render from django.views.generic import TemplateView
[ 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 198, 6738, 42625, 14208, 13, 33571, 13, 41357, 1330, 37350, 7680 ]
4.263158
19
from django.shortcuts import render from .forms import * from django.shortcuts import redirect,get_object_or_404 from django.contrib.auth.decorators import login_required from . models import * from django.views import generic def myloc_details(request,myloc_id): activities=Activity.objects.filter(myloc=myloc_...
[ 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 198, 6738, 764, 23914, 1330, 1635, 198, 6738, 42625, 14208, 13, 19509, 23779, 1330, 18941, 11, 1136, 62, 15252, 62, 273, 62, 26429, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 13,...
2.875706
177
""" Day 1 Main Module """ from day01 import parse_input, part1, part2 if __name__ == "__main__": # trying out the new walrus[:=] oprtr in python if (part := int(input("Enter Part: "))) == 1: print(part1(parse_input("input.txt"))) elif part == 2: print(part2(parse_input("input.txt"))) e...
[ 37811, 198, 12393, 352, 8774, 19937, 198, 37811, 198, 198, 6738, 1110, 486, 1330, 21136, 62, 15414, 11, 636, 16, 11, 636, 17, 198, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 1303, 2111, 503, 26...
2.344156
154
""" Django settings for quiz_app project. Generated by 'django-admin startproject' using Django 2.1.2. For more information on this file, see https://docs.djangoproject.com/en/2.1/topics/settings/ For the full list of settings and their values, see https://docs.djangoproject.com/en/2.1/ref/settings/ """ SITE_ID = 1 ...
[ 37811, 198, 35, 73, 14208, 6460, 329, 38964, 62, 1324, 1628, 13, 198, 198, 8645, 515, 416, 705, 28241, 14208, 12, 28482, 923, 16302, 6, 1262, 37770, 362, 13, 16, 13, 17, 13, 198, 198, 1890, 517, 1321, 319, 428, 2393, 11, 766, 198,...
2.316509
1,902
import numpy as np import pickle from os.path import exists, realpath import sys import math from topple_data_loader import ToppleData, ToppleDataLoader import transforms3d if __name__=='__main__': # norm_info = ToppleNormalizationInfo() # norm_info.load_from('../../data/sim/normalization_info/cube_train.pkl'...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 2298, 293, 198, 6738, 28686, 13, 6978, 1330, 7160, 11, 1103, 6978, 198, 11748, 25064, 198, 11748, 10688, 198, 6738, 49377, 62, 7890, 62, 29356, 1330, 1675, 381, 293, 6601, 11, 1675, 381, 293, ...
2.232143
616
import numpy as np from operator import truediv
[ 11748, 299, 32152, 355, 45941, 201, 198, 6738, 10088, 1330, 491, 1739, 452, 201 ]
3.5
14
#!/usr/bin/env python ######################################################################################### # # Apply transformations. This function is a wrapper for sct_WarpImageMultiTransform # # --------------------------------------------------------------------------------------- # Copyright (c) 2014 Polytechn...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 29113, 29113, 14468, 7804, 2, 198, 2, 198, 2, 27967, 38226, 13, 770, 2163, 318, 257, 29908, 329, 264, 310, 62, 54, 5117, 5159, 29800, 41762, 198, 2, 198, 2, 16529, 19351, 6329, 198, ...
2.325481
2,080
# Copyright 2013-2014 MongoDB, Inc. # # 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 writin...
[ 2, 15069, 2211, 12, 4967, 42591, 11012, 11, 3457, 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, 1...
3.40856
257
import logging import sys from django.core.exceptions import ValidationError from django.db import models from django.db.models.fields.related import ForeignObject from django.utils.encoding import python_2_unicode_compatible try: from django.db.models.fields.related_descriptors import ForwardManyToOneDescriptor ...
[ 11748, 18931, 198, 11748, 25064, 198, 198, 6738, 42625, 14208, 13, 7295, 13, 1069, 11755, 1330, 3254, 24765, 12331, 198, 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 6738, 42625, 14208, 13, 9945, 13, 27530, 13, 25747, 13, 5363, 1330, ...
3.103175
378
# -*- coding: utf-8 -*- """ Modules for exposing functions that can be run as tasks. """ from __future__ import (absolute_import, division, print_function, unicode_literals)
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 5841, 5028, 329, 21294, 5499, 326, 460, 307, 1057, 355, 8861, 13, 198, 37811, 198, 6738, 11593, 37443, 834, 1330, 357, 48546, 62, 11748, 11, 7297, 11, 198, ...
2.538462
78
#-*- coding:utf-8 -*- # Part of Odoo. See LICENSE file for full copyright and licensing details. from odoo import api, fields, models, _ from odoo.exceptions import UserError from odoo.tools import float_compare, float_is_zero
[ 2, 12, 9, 12, 19617, 25, 40477, 12, 23, 532, 9, 12, 198, 2, 2142, 286, 10529, 2238, 13, 4091, 38559, 24290, 2393, 329, 1336, 6634, 290, 15665, 3307, 13, 198, 198, 6738, 16298, 2238, 1330, 40391, 11, 7032, 11, 4981, 11, 4808, 198, ...
3.194444
72
import matplotlib.pyplot as plt import matplotlib.gridspec as gridspec import sys import numpy as np from matplotlib.colors import LinearSegmentedColormap from matplotlib.colors import BoundaryNorm
[ 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 11748, 2603, 29487, 8019, 13, 2164, 2340, 43106, 355, 50000, 43106, 198, 11748, 25064, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 2603, 29487, 8019, 13, 4033, 669, 1330, ...
3.35
60
import logging import os import random from abc import ABC, abstractmethod from random import randint from time import sleep, strftime HOSTNAME = ['defence-first.rs', 'defence-first.de', 'defence-first.ru'] HOSTIP = ['78.218.236.218', '87.236.11.212', '54.147.165.86'] SOURCEIP = ['163.189.141.53', '204.164.10.7', '213...
[ 11748, 18931, 198, 11748, 28686, 198, 11748, 4738, 198, 6738, 450, 66, 1330, 9738, 11, 12531, 24396, 198, 6738, 4738, 1330, 43720, 600, 198, 6738, 640, 1330, 3993, 11, 965, 31387, 198, 198, 39, 10892, 20608, 796, 37250, 4299, 594, 12, ...
2.215606
487
from bayes_race.pp.pure_pursuit import purePursuit
[ 6738, 15489, 274, 62, 16740, 13, 381, 13, 37424, 62, 79, 1834, 5013, 1330, 5899, 47, 1834, 5013 ]
2.777778
18
from typing import Optional import numpy as np from . import Evaluator from ..state import VectorSpaceStateVar
[ 6738, 19720, 1330, 32233, 198, 11748, 299, 32152, 355, 45941, 198, 198, 6738, 764, 1330, 26439, 84, 1352, 198, 6738, 11485, 5219, 1330, 20650, 14106, 9012, 19852, 198 ]
4
28
from .knn_interpolate import knn_interpolate __all__ = [ 'knn_interpolate', ]
[ 6738, 764, 15418, 77, 62, 3849, 16104, 378, 1330, 638, 77, 62, 3849, 16104, 378, 198, 198, 834, 439, 834, 796, 685, 198, 220, 220, 220, 705, 15418, 77, 62, 3849, 16104, 378, 3256, 198, 60, 198 ]
2.243243
37
from bc4py_extension import PyAddress import hashlib def is_address(ck: PyAddress, hrp, ver): """check bech32 format and version""" try: if ck.hrp != hrp: return False if ck.version != ver: return False except ValueError: return False return True def g...
[ 6738, 47125, 19, 9078, 62, 2302, 3004, 1330, 9485, 20231, 198, 11748, 12234, 8019, 628, 198, 4299, 318, 62, 21975, 7, 694, 25, 9485, 20231, 11, 39436, 79, 11, 3326, 2599, 198, 220, 220, 220, 37227, 9122, 307, 354, 2624, 5794, 290, 2...
2.445483
321
"""``cubi-tk snappy kickoff``: kickoff SNAPPY pipeline.""" import argparse import os import subprocess import typing from logzero import logger from toposort import toposort from . import common from cubi_tk.exceptions import ParseOutputException def setup_argparse(parser: argparse.ArgumentParser) -> None: "...
[ 37811, 15506, 66, 29603, 12, 30488, 3013, 7774, 40532, 15506, 25, 40532, 11346, 24805, 56, 11523, 526, 15931, 198, 198, 11748, 1822, 29572, 198, 11748, 28686, 198, 11748, 850, 14681, 198, 11748, 19720, 198, 198, 6738, 2604, 22570, 1330, 4...
2.675287
348
from __future__ import absolute_import from functools import reduce from operator import mul try: from StringIO import StringIO except ImportError: # Python3 compatibility from io import StringIO import pytest from conftest import skipif_yask import numpy as np from devito import Grid, Function, TimeFun...
[ 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 198, 198, 6738, 1257, 310, 10141, 1330, 4646, 198, 6738, 10088, 1330, 35971, 198, 28311, 25, 198, 220, 220, 220, 422, 10903, 9399, 1330, 10903, 9399, 198, 16341, 17267, 12331, 25, 198, 220...
3.556522
115
from data.data_reader import BIZCARD_LABEL_MAP, BizcardDataParser import argparse from pathlib import Path import os import json import cv2 import numpy as np if __name__ == '__main__': parser = argparse.ArgumentParser() parser.add_argument('--img_dir', type=str) parser.add_argument('--gt_dir', type=str)...
[ 6738, 1366, 13, 7890, 62, 46862, 1330, 347, 14887, 34, 9795, 62, 48780, 3698, 62, 33767, 11, 347, 528, 9517, 6601, 46677, 198, 11748, 1822, 29572, 198, 6738, 3108, 8019, 1330, 10644, 198, 11748, 28686, 198, 11748, 33918, 198, 11748, 269...
2.372168
309
from pathlib import Path from typing import List, Optional from typer import Argument from deckz.cli import app from deckz.paths import Paths from deckz.running import run as running_run
[ 6738, 3108, 8019, 1330, 10644, 198, 6738, 19720, 1330, 7343, 11, 32233, 198, 198, 6738, 1259, 525, 1330, 45751, 198, 198, 6738, 6203, 89, 13, 44506, 1330, 598, 198, 6738, 6203, 89, 13, 6978, 82, 1330, 10644, 82, 198, 6738, 6203, 89, ...
3.72549
51
from django import template register = template.Library()
[ 6738, 42625, 14208, 1330, 11055, 198, 198, 30238, 796, 11055, 13, 23377, 3419, 628, 198 ]
4.066667
15
import asyncio import contextvars import aioredis import uvloop from aioredis import Redis from fastapi import FastAPI from starlette.middleware.base import BaseHTTPMiddleware from starlette.staticfiles import StaticFiles from RLog import rprint from routers import apirest, websockets REDIS_HOST = 'redis' REDIS_PORT =...
[ 11748, 30351, 952, 198, 11748, 4732, 85, 945, 198, 11748, 257, 72, 1850, 271, 198, 11748, 334, 85, 26268, 198, 6738, 257, 72, 1850, 271, 1330, 2297, 271, 198, 6738, 3049, 15042, 1330, 12549, 17614, 198, 6738, 3491, 21348, 13, 27171, 1...
2.767196
378
import argparse import autoencoder parser = argparse.ArgumentParser() subparsers = parser.add_subparsers(dest="action") encode_parser = subparsers.add_parser('encode') addTrainablesArg(encode_parser) encode_parser.add_argument('--input', dest='input', help='Input image file name', required=True) addExchangeArg(enc...
[ 11748, 1822, 29572, 198, 11748, 1960, 6571, 66, 12342, 628, 198, 198, 48610, 796, 1822, 29572, 13, 28100, 1713, 46677, 3419, 198, 198, 7266, 79, 945, 364, 796, 30751, 13, 2860, 62, 7266, 79, 945, 364, 7, 16520, 2625, 2673, 4943, 198, ...
2.806691
269
# -*- coding: utf-8; test-case-name: bridgedb.test.test_email_request; -*- #_____________________________________________________________________________ # # This file is part of BridgeDB, a Tor bridge distribution system. # # :authors: Nick Mathewson <nickm@torproject.org> # Isis Lovecruft <isis@torproject.o...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 26, 1332, 12, 7442, 12, 3672, 25, 38265, 2004, 65, 13, 9288, 13, 9288, 62, 12888, 62, 25927, 26, 532, 9, 12, 198, 2, 27193, 2602, 29343, 198, 2, 198, 2, 770, 2393, 318, 636, 286, 1...
2.82816
1,321
""" Module docstring """ def _impl(_ctx): """ Function docstring """ pass some_rule = rule( attrs = { "attr1": attr.int( default = 2, mandatory = False, ), "attr2": 5, }, implementation = _impl, )
[ 37811, 19937, 2205, 8841, 37227, 198, 198, 4299, 4808, 23928, 28264, 49464, 2599, 198, 220, 220, 220, 37227, 15553, 2205, 8841, 37227, 198, 220, 220, 220, 1208, 198, 198, 11246, 62, 25135, 796, 3896, 7, 198, 220, 220, 220, 708, 3808, ...
2.022727
132
from __future__ import print_function from connection import * from jinja2 import Environment, FileSystemLoader import webbrowser # self.entry_text(self.entry_name, result['firstName']+" "+result['lastName'] ) # self.entry_text(self.entry_EmpID, result['empID']) # self.entry_text(self.entry_EmpName, res...
[ 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 198, 6738, 4637, 1330, 1635, 198, 6738, 474, 259, 6592, 17, 1330, 9344, 11, 9220, 11964, 17401, 198, 11748, 3992, 40259, 198, 198, 2, 220, 220, 220, 220, 220, 197, 944, 13, 13000, 62, 5...
2.406814
499
# -*- coding: utf-8 -*- # # michael a.g. avzis # orthologue # (c) 1998-2021 all rights reserved # # superclass from .Schema import Schema # declaration # meta-methods def __init__(self, default=object, schema=Schema(), **kwds): # adjust the default; carefully, so we don't all end up using the sam...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 198, 2, 285, 40302, 257, 13, 70, 13, 1196, 89, 271, 198, 2, 29617, 39795, 198, 2, 357, 66, 8, 7795, 12, 1238, 2481, 477, 2489, 10395, 198, 2, 628, 198, 2, 220...
2.683007
306
# # Copyright The NOMAD Authors. # # This file is part of NOMAD. # See https://nomad-lab.eu for further info. # # 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/lic...
[ 2, 198, 2, 15069, 383, 399, 2662, 2885, 46665, 13, 198, 2, 198, 2, 770, 2393, 318, 636, 286, 399, 2662, 2885, 13, 198, 2, 4091, 3740, 1378, 26601, 324, 12, 23912, 13, 12496, 329, 2252, 7508, 13, 198, 2, 198, 2, 49962, 739, 262, ...
2.274259
3,442
# coding: utf-8 """ simcore-service-storage API API definition for simcore-service-storage service # noqa: E501 OpenAPI spec version: 0.1.0 Contact: support@simcore.io Generated by: https://openapi-generator.tech """ from __future__ import absolute_import import re # noqa: F401 # python 2 a...
[ 2, 19617, 25, 3384, 69, 12, 23, 198, 198, 37811, 198, 220, 220, 220, 985, 7295, 12, 15271, 12, 35350, 7824, 628, 220, 220, 220, 7824, 6770, 329, 985, 7295, 12, 15271, 12, 35350, 2139, 220, 1303, 645, 20402, 25, 412, 33548, 628, 22...
3.014085
142
# Generated by Django 3.2.7 on 2021-10-22 14:23 from django.db import migrations
[ 2, 2980, 515, 416, 37770, 513, 13, 17, 13, 22, 319, 33448, 12, 940, 12, 1828, 1478, 25, 1954, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 628 ]
2.766667
30
#!/usr/bin/env python """ Demos of encoding and decoding algorithms using populations of IAF neurons. """ # Copyright (c) 2009-2015, Lev Givon # All rights reserved. # Distributed under the terms of the BSD license: # http://www.opensource.org/licenses/bsd-license import sys import numpy as np # Set matplotlib back...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 37811, 198, 11522, 418, 286, 21004, 290, 39938, 16113, 1262, 9684, 286, 198, 3539, 37, 16890, 13, 198, 37811, 198, 198, 2, 15069, 357, 66, 8, 3717, 12, 4626, 11, 16042, 402, 452...
2.178652
1,780
"""func expr""" F = function( x,y ): return x+y def main(): TestError( F(1,2) == 3 )
[ 37811, 20786, 44052, 37811, 198, 198, 37, 796, 2163, 7, 2124, 11, 88, 15179, 198, 197, 7783, 2124, 10, 88, 198, 198, 4299, 1388, 33529, 198, 197, 14402, 12331, 7, 376, 7, 16, 11, 17, 8, 6624, 513, 1267, 628 ]
2.25
40
#coding:utf-8 from nadmin.sites import site from nadmin.views import BaseAdminPlugin, ListAdminView SORTBY_VAR = '_sort_by' site.register_plugin(SortablePlugin, ListAdminView)
[ 2, 66, 7656, 25, 40477, 12, 23, 198, 6738, 299, 28482, 13, 49315, 1330, 2524, 198, 6738, 299, 28482, 13, 33571, 1330, 7308, 46787, 37233, 11, 7343, 46787, 7680, 198, 198, 50, 9863, 17513, 62, 53, 1503, 796, 705, 62, 30619, 62, 1525,...
2.903226
62
import logging from config import ACCOUNTING_MAIL_RECIPIENT, LOG_LEVEL, REDIS_URL, TIMEZONE from datetime import datetime, timedelta from pytz import timezone import celery import redis from charges import amount_to_charge, charge, ChargeException from npsp import Opportunity from util import send_email zone = timez...
[ 11748, 18931, 198, 6738, 4566, 1330, 15859, 28270, 2751, 62, 5673, 4146, 62, 38827, 4061, 28495, 11, 41605, 62, 2538, 18697, 11, 23848, 1797, 62, 21886, 11, 20460, 57, 11651, 198, 6738, 4818, 8079, 1330, 4818, 8079, 11, 28805, 12514, 19...
3.154286
175
import operator import os from unittest.mock import patch import pytest import requests from rotkehlchen.chain.ethereum.manager import NodeName from rotkehlchen.constants.assets import A_BTC from rotkehlchen.tests.utils.blockchain import mock_etherscan_query from rotkehlchen.typing import SupportedBlockchain
[ 11748, 10088, 198, 11748, 28686, 198, 6738, 555, 715, 395, 13, 76, 735, 1330, 8529, 198, 198, 11748, 12972, 9288, 198, 11748, 7007, 198, 198, 6738, 5724, 365, 18519, 6607, 13, 7983, 13, 316, 1456, 388, 13, 37153, 1330, 19081, 5376, 19...
3.461538
91
#------------------------------------------------------------------------------- # Name: module1 # Purpose: # # Author: I am # # Created: 02/11/2017 # Copyright: (c) I am 2017 # Licence: <your licence> #------------------------------------------------------------------------------- if __name__ ==...
[ 2, 10097, 24305, 198, 2, 6530, 25, 220, 220, 220, 220, 220, 220, 220, 8265, 16, 198, 2, 32039, 25, 198, 2, 198, 2, 6434, 25, 220, 220, 220, 220, 220, 314, 716, 198, 2, 198, 2, 15622, 25, 220, 220, 220, 220, 7816, 14, 1157, 1...
3.583333
96
from flask import Flask from config import Config from sqlalchemy import MetaData from flask_sqlalchemy import SQLAlchemy from flask_migrate import Migrate from flask_login import LoginManager from flask_moment import Moment from flask_misaka import Misaka from flask_bootstrap import Bootstrap import os import logging ...
[ 6738, 42903, 1330, 46947, 198, 6738, 4566, 1330, 17056, 198, 6738, 44161, 282, 26599, 1330, 30277, 6601, 198, 6738, 42903, 62, 25410, 282, 26599, 1330, 16363, 2348, 26599, 198, 6738, 42903, 62, 76, 42175, 1330, 337, 42175, 198, 6738, 4290...
2.803175
315
import numpy as np import random from time import time, sleep import h5py import torch import torch.nn as nn import torch.optim as optimizer import glob import os #from scipy.stats import rankdata from lstm import Model, initialize from Optim import ScheduledOptim # import _pickle as cPickle # np.set_printoptions(t...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 4738, 198, 6738, 640, 1330, 640, 11, 3993, 198, 11748, 289, 20, 9078, 198, 11748, 28034, 198, 11748, 28034, 13, 20471, 355, 299, 77, 198, 11748, 28034, 13, 40085, 355, 6436, 7509, 198, 11748, ...
3.303922
102
from c_int import Int from casting import cast from globals_consts import NAMESPACE from temps import used_temps, get_temp, get_temp_func
[ 6738, 269, 62, 600, 1330, 2558, 198, 6738, 13092, 1330, 3350, 198, 6738, 15095, 874, 62, 1102, 6448, 1330, 399, 29559, 47, 11598, 198, 6738, 2169, 862, 1330, 973, 62, 11498, 862, 11, 651, 62, 29510, 11, 651, 62, 29510, 62, 20786, 19...
3.209302
43
#!/usr/bin/python from struct import * from getopt import * import sys import os import re if __name__ == "__main__": main()
[ 2, 48443, 14629, 14, 8800, 14, 29412, 201, 198, 6738, 2878, 1330, 1635, 201, 198, 6738, 651, 8738, 1330, 1635, 201, 198, 11748, 25064, 201, 198, 11748, 28686, 201, 198, 11748, 302, 201, 198, 201, 198, 361, 11593, 3672, 834, 6624, 366,...
2.566038
53
import os from pytest_mock import MockerFixture from robot.api import logger from Mainframe3270.x3270 import x3270
[ 11748, 28686, 198, 198, 6738, 12972, 9288, 62, 76, 735, 1330, 337, 12721, 37, 9602, 198, 6738, 9379, 13, 15042, 1330, 49706, 198, 198, 6738, 8774, 14535, 18, 20233, 13, 87, 18, 20233, 1330, 2124, 18, 20233, 628, 628 ]
3.076923
39
# -*- coding: utf-8 -*- from __future__ import print_function, division """ .. note:: These are the spectrophotometry functions for SPLAT """ # imports - internal import copy import os # imports - external import numpy from astropy import units as u # standard units from astropy import constants...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 11, 7297, 198, 198, 37811, 198, 492, 3465, 3712, 198, 220, 220, 220, 220, 220, 220, 220, 220, 2312, 389, 262, 5444, 1005...
2.247637
12,696
import datetime ONE_MINUTE = 60 ONE_HOUR = 3600 ONE_DAY = 24 * ONE_HOUR ONE_YEAR = 1 * 365 * ONE_DAY
[ 11748, 4818, 8079, 198, 198, 11651, 62, 23678, 37780, 796, 3126, 198, 11651, 62, 39, 11698, 796, 4570, 405, 198, 11651, 62, 26442, 796, 1987, 1635, 16329, 62, 39, 11698, 198, 11651, 62, 56, 17133, 796, 352, 1635, 21268, 1635, 16329, 6...
2.311111
45
""" Plot up surface or bottom (or any fixed level) errors from a profile object with no z_dim (vertical dimension). Provide an array of netcdf files and mess with the options to get a figure you like. You can define how many rows and columns the plot will have. This script will plot the provided list of netcdf datase...
[ 37811, 198, 43328, 510, 4417, 393, 4220, 357, 273, 597, 5969, 1241, 8, 8563, 422, 257, 7034, 2134, 198, 4480, 645, 1976, 62, 27740, 357, 1851, 605, 15793, 737, 44290, 281, 7177, 286, 2010, 66, 7568, 3696, 290, 220, 198, 37348, 351, ...
2.590217
1,840
from sklearn.feature_extraction.text import TfidfVectorizer def compute_tf_idf(corpus): """Computing term frequency (tf) - inverse document frequency (idf). :param corpus: List of documents. :returns: tf-idf of corpus. """ return TfidfVectorizer().fit_transform(corpus) if __name__ == '__main__': ...
[ 6738, 1341, 35720, 13, 30053, 62, 2302, 7861, 13, 5239, 1330, 309, 69, 312, 69, 38469, 7509, 198, 198, 4299, 24061, 62, 27110, 62, 312, 69, 7, 10215, 79, 385, 2599, 198, 220, 220, 220, 37227, 5377, 48074, 3381, 8373, 357, 27110, 8, ...
2.55102
196
#!/usr/bin/env python3 from __future__ import print_function import socket import threading try: import socketserver except ImportError: import SocketServer as socketserver import time import os import signal import sys import struct import errno from fprime.constants import DATA_ENCODING from optparse import...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 198, 11748, 17802, 198, 11748, 4704, 278, 198, 198, 28311, 25, 198, 220, 220, 220, 1330, 37037, 18497, 198, 16341, 17267, 12331, 25, ...
2.274903
1,546
import logging import sched import time ( MENU, EDIT_COIN_LIST, EDIT_USER_CONFIG, DELETE_DB, UPDATE_TG, UPDATE_BTB, PANIC_BUTTON, CUSTOM_SCRIPT, ) = range(8) BOUGHT, BUYING, SOLD, SELLING = range(4) logging.basicConfig( format="%(asctime)s - %(name)s - %(levelname)s - %(message)s"...
[ 11748, 18931, 198, 11748, 6038, 198, 11748, 640, 198, 198, 7, 198, 220, 220, 220, 41597, 52, 11, 198, 220, 220, 220, 48483, 62, 8220, 1268, 62, 45849, 11, 198, 220, 220, 220, 48483, 62, 29904, 62, 10943, 16254, 11, 198, 220, 220, ...
2.199029
206
import modutil mod, __getattr__ = modutil.lazy_import(__name__, ['tests.test_data.A', '.B', '.C as still_C'])
[ 11748, 953, 22602, 628, 198, 4666, 11, 11593, 1136, 35226, 834, 796, 953, 22602, 13, 75, 12582, 62, 11748, 7, 834, 3672, 834, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, ...
1.797619
84
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import os import sys import tqdm import torch import pickle import resource import numpy as np import matplotlib.pyplot as plt from args import parse_args from modelSummary import model_dict from pytorchtools import load_from_file from torch.utils.data import DataLoader ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 11748, 28686, 198, 11748, 25064, 198, 11748, 256, 80, 36020, 198, 11748, 28034, 198, 11748, 2298, 293, 198, 11...
1.670149
6,221
#!/usr/bin/env python """ <Program Name> test_util.py <Author> Konstantin Andrianov. <Started> February 1, 2013. <Copyright> See LICENSE for licensing information. <Purpose> Unit test for 'util.py' """ # Help with Python 3 compatibility, where the print statement is a function, an # implicit relative im...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 37811, 198, 27, 15167, 6530, 29, 198, 220, 1332, 62, 22602, 13, 9078, 198, 198, 27, 13838, 29, 198, 220, 17431, 18797, 259, 843, 4484, 709, 13, 198, 198, 27, 10434, 276, 29, 1...
3.157718
298
from django import forms
[ 198, 6738, 42625, 14208, 1330, 220, 5107 ]
3.714286
7
from functools import lru_cache from math import cos, sin import scipy from scipy.ndimage import affine_transform import numpy as np def rotation_axis_by_angle(data, angles=(90, 90, 90), times=(2, 2, 2)): """ Get true data matrix(Cartesian coordinates) from relative data matrix (Non-Cartesian coordinates)....
[ 6738, 1257, 310, 10141, 1330, 300, 622, 62, 23870, 198, 6738, 10688, 1330, 8615, 11, 7813, 198, 198, 11748, 629, 541, 88, 198, 198, 6738, 629, 541, 88, 13, 358, 9060, 1330, 1527, 500, 62, 35636, 198, 11748, 299, 32152, 355, 45941, 6...
2.35919
2,617
#!/usr/bin/env python import sys #lolafile = open("ex-small.graph", "r") source = 0 target = 0 lowlink = 0 trans = "bla" print("digraph {") with open(sys.argv[1]) as lolafile: for line in lolafile: if len(line) == 1: continue linelist = line.split(" ") if "STATE" in linelist: ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 11748, 25064, 198, 198, 2, 47288, 1878, 576, 796, 1280, 7203, 1069, 12, 17470, 13, 34960, 1600, 366, 81, 4943, 198, 198, 10459, 220, 796, 657, 198, 16793, 220, 796, 657, 198, 75...
2.15942
276
import re import urllib.parse from django.shortcuts import render, get_object_or_404 from django.http import HttpResponse, JsonResponse from django.core.paginator import Paginator, PageNotAnInteger, EmptyPage from .models import Definition RE_HANGUL = re.compile(r'[(]*[\uAC00-\uD7AF]+[\uAC00-\uD7AF (),;]*', re.IGNOR...
[ 11748, 302, 198, 11748, 2956, 297, 571, 13, 29572, 198, 198, 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 11, 651, 62, 15252, 62, 273, 62, 26429, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 11, 449, 1559, 31077, 1...
2.634921
126
import globals
[ 11748, 15095, 874, 628 ]
4
4
#!/usr/bin/env python from __future__ import print_function ''' 1\taaaa~^~bbbb~^~cccc 2\tdddd~^~EEEE~^~ffff ''' import sys ARR_DELIM = '~^~' for row in sys.stdin: row = row.strip() sent_id, lemmas = row.split('\t') lemmas = lemmas.split(ARR_DELIM) for lemma in lemmas: print('{}\t{}'.format(s...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 198, 198, 7061, 6, 198, 16, 59, 83, 24794, 93, 61, 93, 11848, 11848, 93, 61, 93, 535, 535, 198, 17, 59, 83, 1860, 1860, 93, 61, 93,...
2.011976
167
from django.urls import path from . import views urlpatterns = [ path('', views.SupplierList.as_view(), name='supplier_list'), path('view/<int:pk>', views.SupplierView.as_view(), name='supplier_view'), path('new', views.SupplierCreate.as_view(), name='supplier_new'), path('view/<int:pk>', views.Suppli...
[ 6738, 42625, 14208, 13, 6371, 82, 1330, 3108, 198, 198, 6738, 764, 1330, 5009, 198, 198, 6371, 33279, 82, 796, 685, 198, 220, 220, 220, 3108, 10786, 3256, 5009, 13, 15979, 2505, 8053, 13, 292, 62, 1177, 22784, 1438, 11639, 18608, 2505...
2.64
200
import yaml __config=None
[ 11748, 331, 43695, 628, 198, 834, 11250, 28, 14202, 198 ]
2.8
10
APP_PROFILE_DIRECTORY_NAME = 'lazies-cmd' DOSKEY_FILE_NAME = 'doskey.bat' AUTO_RUN_REGISTRY_NAME = 'AutoRun'
[ 24805, 62, 31190, 25664, 62, 17931, 23988, 15513, 62, 20608, 796, 705, 75, 1031, 444, 12, 28758, 6, 198, 35178, 20373, 62, 25664, 62, 20608, 796, 705, 37427, 2539, 13, 8664, 6, 198, 39371, 46, 62, 49, 4944, 62, 31553, 1797, 40405, 6...
2.18
50
#!/usr/bin/env python import os, sys from Bio import SeqIO if __name__ == "__main__": from argparse import ArgumentParser parser = ArgumentParser("Get sequences from a fasta file from a list") parser.add_argument("fasta_filename", help="Input fasta filename to extract sequences from") parser.add_argume...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 11748, 28686, 11, 25064, 198, 6738, 16024, 1330, 1001, 80, 9399, 198, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 422, 1822, 29572, 1330, 45751, 4...
3.18
150
import time import json import base64 import msgpack from schema import Schema, And, Optional from datetime import datetime from algosdk import mnemonic from algosdk.account import address_from_private_key from algosdk.error import * from algosdk.future.transaction import PaymentTxn from inequality_indexes import * fr...
[ 198, 11748, 640, 198, 11748, 33918, 198, 11748, 2779, 2414, 198, 11748, 31456, 8002, 198, 6738, 32815, 1330, 10011, 2611, 11, 843, 11, 32233, 198, 6738, 4818, 8079, 1330, 4818, 8079, 198, 6738, 435, 70, 418, 34388, 1330, 285, 77, 50016,...
2.733102
577
##### # # This class is part of the Programming the Internet of Things # project, and is available via the MIT License, which can be # found in the LICENSE file at the top level of this repository. # # Copyright (c) 2020 by Andrew D. King # import logging import unittest from programmingtheiot.cda.system.SystemMem...
[ 4242, 2, 198, 2, 220, 198, 2, 770, 1398, 318, 636, 286, 262, 30297, 262, 4455, 286, 11597, 198, 2, 1628, 11, 290, 318, 1695, 2884, 262, 17168, 13789, 11, 543, 460, 307, 198, 2, 1043, 287, 262, 38559, 24290, 2393, 379, 262, 1353, ...
3.25
124