content
stringlengths
1
1.05M
input_ids
listlengths
1
883k
ratio_char_token
float64
1
22.9
token_count
int64
1
883k
from .neural_network import Neural_network
[ 6738, 764, 710, 1523, 62, 27349, 1330, 47986, 62, 27349, 198 ]
3.909091
11
from django import forms from crispy_forms.helper import FormHelper from crispy_forms.layout import Submit from django.utils.translation import ugettext_lazy as _ from .models import Ride
[ 6738, 42625, 14208, 1330, 5107, 198, 6738, 42807, 62, 23914, 13, 2978, 525, 1330, 5178, 47429, 198, 6738, 42807, 62, 23914, 13, 39786, 1330, 39900, 198, 6738, 42625, 14208, 13, 26791, 13, 41519, 1330, 334, 1136, 5239, 62, 75, 12582, 355...
3.82
50
import asyncio from mlserver import MLModel from mlserver.codecs import NumpyCodec from mlserver.types import InferenceRequest, InferenceResponse
[ 11748, 30351, 952, 198, 198, 6738, 25962, 15388, 1330, 10373, 17633, 198, 198, 6738, 25962, 15388, 13, 19815, 721, 82, 1330, 399, 32152, 43806, 721, 198, 6738, 25962, 15388, 13, 19199, 1330, 554, 4288, 18453, 11, 554, 4288, 31077, 628, ...
3.658537
41
from time import time import torch import torch.nn as nn if __name__ == "__main__": #Depends on the Tokenizer input_vocab_size = 100 output_vocab_size = 200 #DEFAULT PerFORMERS PARAMETERS:- pad_idx = 0 embedding_out = 512 num_layers = 6 forward_expansion = 4 ...
[ 6738, 640, 1330, 640, 198, 11748, 28034, 220, 198, 11748, 28034, 13, 20471, 355, 299, 77, 220, 628, 628, 628, 628, 628, 628, 220, 220, 220, 220, 220, 220, 220, 220, 628, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, ...
2.122727
440
""" gtp_connection.py Module for playing games of Go using GoTextProtocol Parts of this code were originally based on the gtp module in the Deep-Go project by Isaac Henrion and Amos Storkey at the University of Edinburgh. """ import signal, os import traceback from sys import stdin, stdout, stderr from board_util im...
[ 37811, 198, 13655, 79, 62, 38659, 13, 9078, 198, 26796, 329, 2712, 1830, 286, 1514, 1262, 1514, 8206, 19703, 4668, 198, 198, 42670, 286, 428, 2438, 547, 6198, 1912, 319, 262, 308, 34788, 8265, 220, 198, 259, 262, 10766, 12, 5247, 1628...
2.414002
1,157
import weakref from .Cell import Cell def _set_observers(self): pass def __str__(self): return "Seamless SubCell: %s" % ".".join(self._path)
[ 11748, 4939, 5420, 198, 198, 6738, 764, 28780, 1330, 12440, 628, 220, 220, 220, 825, 4808, 2617, 62, 672, 2655, 690, 7, 944, 2599, 198, 220, 220, 220, 220, 220, 220, 220, 1208, 628, 220, 220, 220, 825, 11593, 2536, 834, 7, 944, 25...
2.27027
74
#!/usr/bin/env python # -*- coding: utf-8 -*- # The aim of this package is to : #- guarantee protected code execution is safe and *will* happen (eventually) #- report usage via colosstat # - recover when code fails ( possibly recording previous state, for example ) # one possibility is to implement another levelof ab...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 2, 383, 4031, 286, 428, 5301, 318, 284, 1058, 198, 2, 12, 9149, 6861, 2438, 9706, 318, 3338, 290, 1635, 10594, ...
3.881356
118
from frisky.events import MessageEvent from frisky.plugin import FriskyPlugin, PluginRepositoryMixin from frisky.responses import FriskyResponse
[ 6738, 1216, 34041, 13, 31534, 1330, 16000, 9237, 198, 6738, 1216, 34041, 13, 33803, 1330, 1305, 34041, 37233, 11, 42636, 6207, 13264, 35608, 259, 198, 6738, 1216, 34041, 13, 16733, 274, 1330, 1305, 34041, 31077, 628 ]
4.055556
36
# -*- coding: utf-8 -*- from PyQt5.QtWidgets import QGraphicsItem, QGraphicsRectItem, QGraphicsItemGroup from PyQt5.QtCore import pyqtSlot # end class def testItemChangeRegression(): """Make sure PyQt5 handles QGraphicsItem.itemChange correctly as there was a regression in PyQt5 v 5.6 that was fixed in v ...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 9485, 48, 83, 20, 13, 48, 83, 54, 312, 11407, 1330, 1195, 18172, 7449, 11, 1195, 18172, 45474, 7449, 11, 1195, 18172, 7449, 13247, 198, 6738, 9485, 48, 83, 20, ...
2.513514
296
# Copyright 2022 MosaicML. All Rights Reserved. from dataclasses import dataclass import yahp as hp from composer.models.model_hparams import ModelHparams
[ 2, 15069, 33160, 5826, 18452, 5805, 13, 1439, 6923, 33876, 13, 198, 198, 6738, 4818, 330, 28958, 1330, 4818, 330, 31172, 198, 198, 11748, 331, 993, 79, 355, 27673, 198, 198, 6738, 26777, 13, 27530, 13, 19849, 62, 71, 37266, 1330, 9104...
3.533333
45
from os.path import join from utils import getFileList
[ 6738, 28686, 13, 6978, 1330, 4654, 198, 6738, 3384, 4487, 1330, 651, 8979, 8053 ]
3.857143
14
''' Author: your name Date: 2021-06-18 10:13:00 LastEditTime: 2021-07-08 14:13:07 LastEditors: Please set LastEditors Description: In User Settings Edit FilePath: /genetic-drawing/main.py ''' import cv2 import os import time from IPython.display import clear_output from genetic_drawing import * gen = GeneticDrawing('0...
[ 7061, 6, 198, 13838, 25, 534, 1438, 198, 10430, 25, 33448, 12, 3312, 12, 1507, 838, 25, 1485, 25, 405, 198, 5956, 18378, 7575, 25, 33448, 12, 2998, 12, 2919, 1478, 25, 1485, 25, 2998, 198, 5956, 18378, 669, 25, 4222, 900, 4586, 18...
2.268975
751
import logging from typing import List, Union, Optional import torch import torch.nn import torch.nn.functional as F from tqdm import tqdm import flair.nn from flair.data import Dictionary, Sentence, Label from flair.datasets import SentenceDataset, DataLoader from flair.embeddings import TokenEmbeddings from flair....
[ 11748, 18931, 198, 198, 6738, 19720, 1330, 7343, 11, 4479, 11, 32233, 198, 198, 11748, 28034, 198, 11748, 28034, 13, 20471, 198, 11748, 28034, 13, 20471, 13, 45124, 355, 376, 198, 6738, 256, 80, 36020, 1330, 256, 80, 36020, 198, 198, ...
3.508929
112
import requests from bs4 import BeautifulSoup url = 'http://xiaohuar.com/' headers = { 'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.100 Safari/537.36'} spider_xiaohuar_content(url, headers)
[ 11748, 7007, 198, 6738, 275, 82, 19, 1330, 23762, 50, 10486, 198, 198, 6371, 796, 705, 4023, 1378, 36072, 1219, 84, 283, 13, 785, 14, 6, 198, 50145, 796, 1391, 198, 220, 220, 220, 705, 12982, 12, 36772, 10354, 705, 44, 8590, 5049, ...
2.448598
107
#csv import glob import pandas as pd import numpy as np io = glob.glob(r"*.csv") len_io=len(io) print('',len_io) prob_list=[] for i in range(len_io): sub_1 = pd.read_csv(io[i]) denominator=len(sub_1) for my_classes in ['healthy','multiple_diseases','rust','scab']: sub_label_1 = sub_...
[ 2, 40664, 201, 198, 11748, 15095, 201, 198, 11748, 19798, 292, 355, 279, 67, 201, 198, 11748, 299, 32152, 355, 45941, 201, 198, 201, 198, 952, 796, 15095, 13, 4743, 672, 7, 81, 1, 24620, 40664, 4943, 201, 198, 11925, 62, 952, 28, ...
2.025568
352
# Copyright 2016 NTT Data. # 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 app...
[ 2, 15069, 1584, 399, 15751, 6060, 13, 198, 2, 1439, 6923, 33876, 13, 198, 2, 198, 2, 220, 220, 220, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 345, 743, 198, 2, 220, 220, 220, 407, 779, ...
2.849793
1,205
news = ['klik untuk membaca', 'klik untuk maklumat']
[ 10827, 796, 37250, 41582, 1134, 1418, 2724, 1066, 65, 22260, 3256, 705, 41582, 1134, 1418, 2724, 285, 461, 75, 27798, 20520, 198 ]
2.409091
22
from sonosscripts import stop, play_pause, previous, next, change_bass, change_volume, mute_volume modules = { "stop": stop, "play_pause": play_pause, "previous": previous, "next": next, "change_bass": change_bass, "change_volume": change_volume, "mute_volume": mute_volume }
[ 198, 6738, 3367, 793, 6519, 82, 1330, 2245, 11, 711, 62, 32125, 11, 2180, 11, 1306, 11, 1487, 62, 42933, 11, 1487, 62, 29048, 11, 38723, 62, 29048, 198, 198, 18170, 796, 1391, 198, 220, 220, 220, 366, 11338, 1298, 2245, 11, 198, 2...
2.637931
116
""" Class SaleBot It is initialised by nlp model (bag-of-word, tf-idf, word2vec) It returns response with a question as the input """ from gensim.corpora import Dictionary #from gensim.models import FastText from gensim.models import Word2Vec , WordEmbeddingSimilarityIndex from gensim.similarities import SoftCo...
[ 37811, 201, 198, 9487, 16467, 20630, 201, 198, 1026, 318, 4238, 1417, 416, 299, 34431, 2746, 357, 21454, 12, 1659, 12, 4775, 11, 48700, 12, 312, 69, 11, 1573, 17, 35138, 8, 201, 198, 1026, 5860, 2882, 351, 257, 1808, 355, 262, 5128,...
2.983333
180
# -*- coding: utf-8 -*- """Demo123_Convolution_Visualization.ipynb # **Spit some [tensor] flow** We need to learn the intricacies of tensorflow to master deep learning `Let's get this over with` """ import numpy as np import pandas as pd import matplotlib.pyplot as plt import tensorflow as tf print(tf.__version__) ...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 11522, 78, 10163, 62, 3103, 85, 2122, 62, 36259, 1634, 13, 541, 2047, 65, 198, 2, 12429, 4561, 270, 617, 685, 83, 22854, 60, 5202, 1174, 198, 198, 1135, 761, ...
2.341929
1,047
import argparse as ap import hail from pprint import pprint import time from hail_scripts.v01.utils.vds_utils import write_vds p = ap.ArgumentParser(description="Convert a tsv table to a .vds") p.add_argument("-c", "--chrom-column", required=True) p.add_argument("-p", "--pos-column", required=True) p.add_argument("-r...
[ 11748, 1822, 29572, 355, 2471, 198, 11748, 32405, 198, 6738, 279, 4798, 1330, 279, 4798, 198, 11748, 640, 198, 198, 6738, 32405, 62, 46521, 13, 85, 486, 13, 26791, 13, 85, 9310, 62, 26791, 1330, 3551, 62, 85, 9310, 198, 198, 79, 796...
2.367412
626
#!/usr/bin/env python # Copyright (c) 2014, Stanford University # 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 list ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 15069, 357, 66, 8, 1946, 11, 13863, 2059, 198, 2, 1439, 2489, 10395, 13, 198, 2, 198, 2, 2297, 396, 3890, 290, 779, 287, 2723, 290, 13934, 5107, 11, 351, 393, 1231, 17613, 11, ...
3.034934
1,145
######################################################################################### # -*- coding: utf-8 -*- # # This file is part of the SKALogger project # # # ######################################################################################### """Contain the tests for the SKALogger.""" import re import py...
[ 29113, 29113, 14468, 7804, 2, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 198, 2, 770, 2393, 318, 636, 286, 262, 14277, 1847, 519, 1362, 1628, 198, 2, 198, 2, 198, 2, 198, 29113, 29113, 14468, 7804, 2,...
3.225256
293
#!/usr/bin/env python # -*- coding: utf-8 -*- import sys import re import urlparse if __name__ == "__main__": import argparse parser = argparse.ArgumentParser() buffer = [] buffer_url = None for line in sys.stdin: # line = line.decode("utf-8", "ignore") url = line.split("\t", 1)[...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 25064, 198, 11748, 302, 198, 11748, 19016, 29572, 628, 198, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 8...
2.122137
262
import pytest from graphviz import jupyter_integration
[ 11748, 12972, 9288, 198, 198, 6738, 4823, 85, 528, 1330, 474, 929, 88, 353, 62, 18908, 1358, 628, 628 ]
3.105263
19
import numpy as np if __name__ == '__main__': main()
[ 11748, 299, 32152, 355, 45941, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 1388, 3419, 198 ]
2.416667
24
import mountaincar as mc import numpy as np from collections import namedtuple from collections import defaultdict import matplotlib.pylab as plb import matplotlib.pyplot as plt from time import time State = namedtuple('State', ['x', 'v'])
[ 198, 11748, 8598, 7718, 355, 36650, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 17268, 1330, 3706, 83, 29291, 198, 6738, 17268, 1330, 4277, 11600, 198, 11748, 2603, 29487, 8019, 13, 79, 2645, 397, 355, 458, 65, 198, 11748, 2603, 2948...
3.442857
70
import matplotlib import matplotlib.pyplot as plt import numpy as np import pandas as pd """ The following functions are used to create an annotated heatmap and they were copied from: https://matplotlib.org/stable/gallery/images_contours_and_fields/image_annotated_heatmap.html#using-the-helper-function-code-style ""...
[ 11748, 2603, 29487, 8019, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 198, 198, 37811, 198, 383, 1708, 5499, 389, 973, 284, 2251, 281, 24708, ...
2.494015
1,838
# Copyright 2020 Huawei Technologies Co., Ltd # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to...
[ 2, 15069, 12131, 43208, 21852, 1766, 1539, 12052, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, 198...
4.128571
210
import logging import keyring SERVICE_NAME = "Orange3 - {}" log = logging.getLogger(__name__)
[ 11748, 18931, 198, 198, 11748, 1994, 1806, 198, 198, 35009, 27389, 62, 20608, 796, 366, 40141, 18, 532, 23884, 1, 198, 198, 6404, 796, 18931, 13, 1136, 11187, 1362, 7, 834, 3672, 834, 8, 628 ]
2.8
35
# -*- coding: utf-8 -*- # Copyright 2017-2019 ControlScan, Inc. # # This file is part of Cyphon Engine. # # Cyphon Engine is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, version 3 of the License. # # Cyphon En...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 15069, 2177, 12, 23344, 6779, 33351, 11, 3457, 13, 198, 2, 198, 2, 770, 2393, 318, 636, 286, 5934, 746, 261, 7117, 13, 198, 2, 198, 2, 5934, 746, 261, 7117, 318...
3.486301
292
import json import requests from collections import defaultdict from fuzzywuzzy import process from random import sample # Constants """ Constants for default responses that do not need any further computation. """ DEFAULT_STOP_RESPONSE = 'All right. See you next time!' DEFAULT_ERROR_MESSAGE = "I'm sorry. I don't kn...
[ 11748, 33918, 198, 11748, 7007, 198, 6738, 17268, 1330, 4277, 11600, 198, 6738, 34669, 86, 4715, 88, 1330, 1429, 198, 6738, 4738, 1330, 6291, 198, 198, 2, 4757, 1187, 628, 198, 37811, 198, 34184, 1187, 329, 4277, 9109, 326, 466, 407, ...
2.717623
1,498
import torch import numpy as np import logging, yaml, os, sys, argparse, time from tqdm import tqdm from collections import defaultdict from Logger import Logger import matplotlib matplotlib.use('agg') matplotlib.rcParams['agg.path.chunksize'] = 10000 import matplotlib.pyplot as plt from scipy.io import wavfile from ra...
[ 11748, 28034, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 18931, 11, 331, 43695, 11, 28686, 11, 25064, 11, 1822, 29572, 11, 640, 198, 6738, 256, 80, 36020, 1330, 256, 80, 36020, 198, 6738, 17268, 1330, 4277, 11600, 198, 6738, 5972, ...
2.629816
597
import logging import asyncio import aiohttp from .defaults import * from .app import App from .featured import FeaturedList log = logging.getLogger(__name__)
[ 11748, 18931, 198, 11748, 30351, 952, 198, 198, 11748, 257, 952, 4023, 628, 198, 6738, 764, 12286, 82, 1330, 1635, 198, 6738, 764, 1324, 1330, 2034, 198, 6738, 764, 69, 20980, 1330, 38188, 8053, 198, 198, 6404, 796, 18931, 13, 1136, 1...
3.346939
49
import sys import numpy as np import matplotlib.pyplot as plt f = open(sys.argv[1], 'r') lines = f.readlines() f.close() pop_size = int(lines.pop(0)) pops = [] for l in lines: if l[0] == '[': pops.append(l.strip()) for j in range(len(pops)): p = [] for n in pops[j][1:-1].split(','): p.a...
[ 11748, 25064, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 198, 69, 796, 1280, 7, 17597, 13, 853, 85, 58, 16, 4357, 705, 81, 11537, 198, 198, 6615, 796, 277, 13, 961, 6615, ...
1.882479
468
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ analyses for bVAE entanglement, etc """ import torch import sys sys.path.append("..") # Adds higher directory to python modules path. import matplotlib.pyplot as plt import numpy as np from data.dspritesb import dSpriteBackgroundDataset from torchvision import tran...
[ 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, 272, 43710, 329, 275, 11731, 36, 920, 648, 1732, 11, 3503, 198, 37811, 198, 198, 11748, 28034, 198, 1...
1.984098
3,773
##%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% ## Centering & Scaling ## %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% #%% Standard scaling import numpy as np from sklearn.preprocessing import StandardScaler X = np.array([[ 100...
[ 2235, 36917, 36917, 36917, 36917, 36917, 36917, 36917, 36917, 36917, 36917, 36917, 36917, 36917, 36917, 36917, 36917, 36917, 36917, 36917, 4, 201, 198, 2235, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, ...
2.573346
1,043
from pbtaskrunner import db from pbtaskrunner import app from datetime import datetime
[ 6738, 279, 18347, 2093, 16737, 1330, 20613, 198, 6738, 279, 18347, 2093, 16737, 1330, 598, 198, 198, 6738, 4818, 8079, 1330, 4818, 8079, 628, 628 ]
3.64
25
# -*- coding: utf-8 -*- from openerp.osv import fields, osv from openerp import tools
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 6738, 21996, 79, 13, 418, 85, 1330, 7032, 11, 267, 21370, 198, 6738, 21996, 79, 1330, 4899, 628 ]
2.666667
33
import app if __name__ == "__main__": app.daily_summary("data/Input.txt", "data/Output.csv")
[ 11748, 598, 198, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 598, 13, 29468, 62, 49736, 7203, 7890, 14, 20560, 13, 14116, 1600, 366, 7890, 14, 26410, 13, 40664, 4943 ]
2.621622
37
import urllib, re urllib._urlopener = FakeUseragentURLopener() download_pdf_regex = re.compile('.*<li class="pdf"><a class="sprite pdf-resource-sprite" href="([^"]*)" title="Download PDF.*') viewstate_regex = re.compile('.*<input type="hidden" name="__VIEWSTATE" id="__VIEWSTATE" value="([^"]*)" />.*') eventvalidation_...
[ 11748, 2956, 297, 571, 11, 302, 198, 333, 297, 571, 13557, 6371, 404, 877, 796, 33482, 12982, 25781, 21886, 404, 877, 3419, 198, 198, 15002, 62, 12315, 62, 260, 25636, 796, 302, 13, 5589, 576, 7, 4458, 9, 27, 4528, 1398, 2625, 12315...
2.160584
411
import os from flask import Flask from flask.ext.sqlalchemy import SQLAlchemy from flask.ext.login import LoginManager from flask.ext.openid import OpenID from config import basedir, ADMINS, MAIL_SERVER, MAIL_PORT, MAIL_USERNAME, MAIL_PASSWORD, MAIL_SECURE app = Flask(__name__) app.config.from_object('config') db = S...
[ 11748, 28686, 198, 6738, 42903, 1330, 46947, 198, 6738, 42903, 13, 2302, 13, 25410, 282, 26599, 1330, 16363, 2348, 26599, 198, 6738, 42903, 13, 2302, 13, 38235, 1330, 23093, 13511, 198, 6738, 42903, 13, 2302, 13, 9654, 312, 1330, 4946, ...
2.694444
540
# Generated by Django 3.0.8 on 2020-09-03 17:04 from django.db import migrations
[ 2, 2980, 515, 416, 37770, 513, 13, 15, 13, 23, 319, 12131, 12, 2931, 12, 3070, 1596, 25, 3023, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 628 ]
2.766667
30
from threading import Lock import discord from discord.ext import commands from loguru import logger from local_types import Snowflake from modules import is_bot_admin
[ 6738, 4704, 278, 1330, 13656, 198, 198, 11748, 36446, 198, 6738, 36446, 13, 2302, 1330, 9729, 198, 6738, 2604, 14717, 1330, 49706, 198, 198, 6738, 1957, 62, 19199, 1330, 7967, 47597, 198, 6738, 13103, 1330, 318, 62, 13645, 62, 28482, 62...
4.170732
41
import sys sys.path.append("./generated") sys.path.append("../../package/pywinrt/projection/pywinrt") import _winrt _winrt.init_apartment(_winrt.MTA)
[ 11748, 25064, 198, 17597, 13, 6978, 13, 33295, 7, 1911, 14, 27568, 4943, 198, 17597, 13, 6978, 13, 33295, 7203, 40720, 40720, 26495, 14, 9078, 5404, 17034, 14, 16302, 295, 14, 9078, 5404, 17034, 4943, 198, 198, 11748, 4808, 5404, 17034,...
2.603448
58
#!/usr/bin/env python import sys import subprocess import evalBedFile # Delly file format (when only del summaries in file - cat *.del.txt | grep Deletion) # The summary line contains the chromosome, the estimated start and end of the structural variant, # the size of the variant, the number of supporting pairs, the ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 11748, 25064, 198, 11748, 850, 14681, 198, 11748, 5418, 45896, 8979, 198, 198, 2, 360, 6148, 2393, 5794, 357, 12518, 691, 1619, 30114, 3166, 287, 2393, 532, 3797, 46866, 12381, 13, ...
2.340625
960
import ctypes import struct import time # # A small example how to use basic_dsp in a different language. # lib = ctypes.WinDLL('basic_dsp.dll') new64Proto = ctypes.WINFUNCTYPE ( ctypes.c_void_p, # Return type. ctypes.c_int, ctypes.c_int, ctypes.c_double, ctypes.c_ulong, ctypes.c_double) ne...
[ 11748, 269, 19199, 198, 11748, 2878, 198, 11748, 640, 198, 198, 2, 220, 198, 2, 317, 1402, 1672, 703, 284, 779, 4096, 62, 67, 2777, 287, 257, 1180, 3303, 13, 198, 2, 198, 198, 8019, 796, 269, 19199, 13, 16643, 35, 3069, 10786, 354...
2.368175
641
#!/usr/bin/env python # coding: utf-8 import pygame import operator from mino import * from random import * from pygame.locals import * from ui import * from screeninfo import get_monitors from pygame.surface import Surface import sys from function import * # screen_width = 0 screen_height = 0 for m in get_monitor...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 19617, 25, 3384, 69, 12, 23, 198, 198, 11748, 12972, 6057, 198, 11748, 10088, 198, 6738, 949, 78, 1330, 1635, 198, 6738, 4738, 1330, 1635, 198, 6738, 12972, 6057, 13, 17946, 874, ...
1.69866
25,453
""" Created on Sep 1, 2011 @author: guillaume """ from scipy import zeros from chemex.bases.two_states.fast import R_IXY, DR_IXY, DW, KAB, KBA def compute_liouvillians(pb=0.0, kex=0.0, dw=0.0, r_ixy=5.0, dr_ixy=0.0): """ Compute the exchange matrix (Liouvillian) The function a...
[ 37811, 198, 41972, 319, 8621, 352, 11, 2813, 198, 198, 31, 9800, 25, 915, 5049, 2454, 198, 37811, 198, 198, 6738, 629, 541, 88, 1330, 1976, 27498, 198, 198, 6738, 4607, 1069, 13, 65, 1386, 13, 11545, 62, 27219, 13, 7217, 1330, 371, ...
2.354443
979
import tempfile import shutil import os import pandas import numpy as np import datetime import pkg_resources from unittest import TestCase from dfs.nba.featurizers import feature_generators from dfs.nba.featurizers import fantasy_points_fzr, last5games_fzr, nf_stats_fzr, vegas_fzr, \ opp_ffpg_fzr, salary_fzr
[ 198, 11748, 20218, 7753, 198, 11748, 4423, 346, 198, 11748, 28686, 198, 11748, 19798, 292, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 4818, 8079, 198, 11748, 279, 10025, 62, 37540, 198, 6738, 555, 715, 395, 1330, 6208, 20448, 198, ...
2.698276
116
from blocksync._consts import ByteSizes from blocksync._status import Blocks
[ 6738, 7021, 13361, 13557, 1102, 6448, 1330, 30589, 50, 4340, 198, 6738, 7021, 13361, 13557, 13376, 1330, 35111, 628, 628 ]
4
20
#!/usr/bin/python3 import os
[ 2, 48443, 14629, 14, 8800, 14, 29412, 18, 198, 198, 11748, 28686, 198 ]
2.307692
13
# General Utility Libraries import sys import os import warnings # PyQt5, GUI Library from PyQt5 import QtCore, QtGui, QtWidgets # Serial and Midi Port Library import rtmidi import serial import serial.tools.list_ports # SKORE Library from lib_skore import read_config, update_config import globals #----------------...
[ 2, 3611, 34030, 46267, 198, 11748, 25064, 198, 11748, 28686, 198, 11748, 14601, 198, 198, 2, 9485, 48, 83, 20, 11, 25757, 10074, 198, 6738, 9485, 48, 83, 20, 1330, 33734, 14055, 11, 33734, 8205, 72, 11, 33734, 54, 312, 11407, 198, 1...
3.649718
177
import requests from .values import ROUTES from .values import LOCALES from .values import REGIONS from .values import ENDPOINTS
[ 11748, 7007, 198, 198, 6738, 764, 27160, 1330, 371, 12425, 1546, 198, 6738, 764, 27160, 1330, 37347, 1847, 1546, 198, 6738, 764, 27160, 1330, 23337, 11053, 198, 6738, 764, 27160, 1330, 12964, 6322, 46, 1268, 4694, 628, 628 ]
3.5
38
for i in range(30): print("a_", end="") print() for i in range(30): print("b_", end="") print() for i in range(30): print("c_", end="")
[ 1640, 1312, 287, 2837, 7, 1270, 2599, 198, 220, 220, 220, 3601, 7203, 64, 62, 1600, 886, 2625, 4943, 198, 4798, 3419, 198, 1640, 1312, 287, 2837, 7, 1270, 2599, 198, 220, 220, 220, 3601, 7203, 65, 62, 1600, 886, 2625, 4943, 198, 4...
2.185714
70
import os import pytest from typing import Any, Callable, Dict, List import LearnSubtitles as ls def prepare(language: str) -> List: """ Create LearnSubtitles objects for every subtitle in folder 'language' """ test_dir = "testfiles/" + language subs = [ ls.LearnSubtitles(os.path.abspath(os.path...
[ 11748, 28686, 198, 198, 11748, 12972, 9288, 198, 6738, 19720, 1330, 4377, 11, 4889, 540, 11, 360, 713, 11, 7343, 198, 198, 11748, 14365, 7004, 83, 30540, 355, 43979, 628, 198, 4299, 8335, 7, 16129, 25, 965, 8, 4613, 7343, 25, 198, 2...
2.770588
170
import pandas as pd import numpy as np from time import time import matplotlib.pyplot as plt from sklearn.ensemble import ExtraTreesClassifier train = pd.read_excel('stats.xls', sheet_name='train') test = pd.read_excel('stats.xls', sheet_name='test') array_train = train.values array_test = test.values X = array_trai...
[ 11748, 19798, 292, 355, 279, 67, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 640, 1330, 640, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 6738, 1341, 35720, 13, 1072, 11306, 1330, 17221, 51, 6037, 9487, 7483, ...
2.601273
943
#-*- coding: utf-8 -*- from logpot.admin.base import AuthenticateView from logpot.utils import ImageUtil from flask import flash, redirect from flask_admin import expose from flask_admin.contrib.fileadmin import FileAdmin from flask_admin.babel import gettext import os import os.path as op from operator import itemg...
[ 2, 12, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 6738, 2604, 13059, 13, 28482, 13, 8692, 1330, 31885, 5344, 7680, 198, 6738, 2604, 13059, 13, 26791, 1330, 7412, 18274, 346, 198, 198, 6738, 42903, 1330, 7644, 11, 18...
3.5
102
from .emailutil import *
[ 6738, 764, 12888, 22602, 1330, 1635 ]
4
6
from __future__ import annotations import multiprocessing import os import re import sys from concurrent.futures import ThreadPoolExecutor from dataclasses import dataclass, field from itertools import chain from pathlib import Path from urllib.parse import urlparse import click import requests from requests.models i...
[ 6738, 11593, 37443, 834, 1330, 37647, 198, 198, 11748, 18540, 305, 919, 278, 198, 11748, 28686, 198, 11748, 302, 198, 11748, 25064, 198, 6738, 24580, 13, 69, 315, 942, 1330, 14122, 27201, 23002, 38409, 198, 6738, 4818, 330, 28958, 1330, ...
2.985765
281
import os import time from hashlib import sha256 import requests from dotenv import load_dotenv from fastapi.security import OAuth2PasswordBearer BASE_DIR = os.path.dirname(os.path.abspath(__file__)) load_dotenv(os.path.join(BASE_DIR, "../.env")) oauth2_scheme = OAuth2PasswordBearer(tokenUrl="api/v1/activate-login-c...
[ 11748, 28686, 198, 11748, 640, 198, 6738, 12234, 8019, 1330, 427, 64, 11645, 198, 198, 11748, 7007, 198, 6738, 16605, 24330, 1330, 3440, 62, 26518, 24330, 198, 6738, 3049, 15042, 13, 12961, 1330, 440, 30515, 17, 35215, 3856, 11258, 198, ...
2.764706
119
"""Correlate based on geograpgic information.""" from alert_manager import AlertManager from utility import Utility
[ 37811, 10606, 2411, 378, 1912, 319, 4903, 7113, 70, 291, 1321, 526, 15931, 198, 198, 6738, 7995, 62, 37153, 1330, 23276, 13511, 198, 6738, 10361, 1330, 34030, 628 ]
4.214286
28
import numpy as np import matplotlib.pyplot as plt N =[20,40,50,75,100,150,200] scale = [0.0001, 0.001, 0.005, 0.01, 0.1, 1, 10] ...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 45, 796, 58, 1238, 11, 1821, 11, 1120, 11, 2425, 11, 3064, 11, 8628, 11, 2167, 60, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220,...
1.636451
1,037
#!/usr/bin/env python print("hey there, this is my first pip package")
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 4798, 7203, 20342, 612, 11, 428, 318, 616, 717, 7347, 5301, 4943, 198 ]
3.130435
23
from .django_q import AstToDjangoQVisitor from .django_q_ext import * from .shorthand import apply_odata_query
[ 6738, 764, 28241, 14208, 62, 80, 1330, 8304, 2514, 35, 73, 14208, 48, 15854, 2072, 198, 6738, 764, 28241, 14208, 62, 80, 62, 2302, 1330, 1635, 198, 6738, 764, 1477, 1506, 392, 1330, 4174, 62, 375, 1045, 62, 22766, 198 ]
2.775
40
# scrape articles from RAND site, see https://vashu11.livejournal.com/20523.html import re import requests from bs4 import BeautifulSoup import os content = ['https://www.rand.org/pubs/papers.html'] + ['https://www.rand.org/pubs/papers.{}.html'.format(i) for i in range(2, 108)] os.mkdir('pdfs') for page in content[11...
[ 2, 42778, 6685, 422, 46920, 2524, 11, 766, 3740, 1378, 85, 1077, 84, 1157, 13, 12583, 24891, 13, 785, 14, 21261, 1954, 13, 6494, 198, 11748, 302, 198, 11748, 7007, 198, 6738, 275, 82, 19, 1330, 23762, 50, 10486, 198, 11748, 28686, 1...
2.047962
417
from dbnd._core.commands.metrics import log_snowflake_table from dbnd_snowflake.snowflake_resources import log_snowflake_resource_usage __all__ = [ "log_snowflake_resource_usage", "log_snowflake_table", ]
[ 6738, 20613, 358, 13557, 7295, 13, 9503, 1746, 13, 4164, 10466, 1330, 2604, 62, 82, 2197, 47597, 62, 11487, 198, 6738, 20613, 358, 62, 82, 2197, 47597, 13, 82, 2197, 47597, 62, 37540, 1330, 2604, 62, 82, 2197, 47597, 62, 31092, 62, ...
2.654321
81
# A parser for multiple FINO2 .dat files in a directory. import os import pathlib import pandas as pd import numpy as np import glob import sys
[ 2, 317, 30751, 329, 3294, 33642, 46, 17, 764, 19608, 3696, 287, 257, 8619, 13, 198, 198, 11748, 28686, 198, 11748, 3108, 8019, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 15095, 198, 11748, 25...
3.395349
43
import subprocess as sp import os import time import platform from os.path import exists #colar vars permissions() getos() check_file() #dependencies
[ 11748, 850, 14681, 355, 599, 198, 11748, 28686, 198, 11748, 640, 198, 11748, 3859, 198, 6738, 28686, 13, 6978, 1330, 7160, 628, 198, 2, 4033, 283, 410, 945, 198, 198, 525, 8481, 3419, 198, 198, 1136, 418, 3419, 628, 198, 9122, 62, 7...
3.16
50
#! /usr/bin/env python ''' This script calculates total heterozygosity. #Example input: CHROM POS REF sample1 sample2 sample3 sample4 sample5 sample6 sample7 sample8 chr_1 1 A W N N A N N N N chr_1 2 C Y Y N C C N C N chr_1 3 C N C N C C C C C chr_1 4 ...
[ 2, 0, 1220, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 7061, 6, 198, 1212, 4226, 43707, 2472, 14445, 49834, 16579, 13, 198, 198, 2, 16281, 5128, 25, 198, 198, 3398, 33676, 220, 220, 28069, 4526, 37, 6291, 16, 6291, 17, 6291, 18, ...
2.210826
1,755
# -*- coding: utf-8 -*- """ Created on Wed Jun 27 17:24:58 2018 @author: Mauro """ #============================================================================== # Imports #============================================================================== import struct #=================================================...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 41972, 319, 3300, 7653, 2681, 1596, 25, 1731, 25, 3365, 2864, 198, 198, 31, 9800, 25, 28931, 305, 198, 37811, 198, 198, 2, 23926, 25609, 855, 198, 2, 1846,...
5.54386
171
#!/usr/bin/env python import pandas as pd from scipy import stats import numpy as np #import seaborn as sns #import matplotlib.pyplot as plt import math from Bio import SeqIO import io import re import pysam from functools import reduce import argparse import os parser = argparse.ArgumentParser() parser.add_argum...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 11748, 19798, 292, 355, 279, 67, 198, 6738, 629, 541, 88, 1330, 9756, 198, 11748, 299, 32152, 355, 45941, 198, 2, 11748, 384, 397, 1211, 355, 3013, 82, 198, 2, 11748, 2603, 2948...
2.876823
1,234
import datetime from django.contrib import admin from django.core.exceptions import ObjectDoesNotExist from django.db.models import Max from . import models, forms from address.biz import geocode from utils import common from utils.django_base import BaseAdmin # Register your models here. # @admin.registe...
[ 11748, 4818, 8079, 198, 198, 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 6738, 42625, 14208, 13, 7295, 13, 1069, 11755, 1330, 9515, 13921, 3673, 3109, 396, 198, 6738, 42625, 14208, 13, 9945, 13, 27530, 1330, 5436, 198, 198, 673...
3.362319
207
import matplotlib import matplotlib.pyplot as plt import numpy as np filenames=["euler.dat","rk4.dat","leapfrog.dat"] fig, axs = plt.subplots(nrows=3, ncols=3) ax=axs[0][0] ax.set_title('Euler') ax=axs[0][1] ax.set_title('RK4') ax=axs[0][2] ax.set_title('Leap_frog') for i in range(3): f=open(filenames[i],"r") s...
[ 11748, 2603, 29487, 8019, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 11748, 299, 32152, 355, 45941, 198, 10379, 268, 1047, 28, 14692, 68, 18173, 13, 19608, 2430, 81, 74, 19, 13, 19608, 2430, 293, 499, 49956, 13...
1.855769
520
import requests from bs4 import BeautifulSoup from time import sleep url = "http://zipnet.in/index.php?page=missing_person_search&criteria=browse_all&Page_No=1" r = requests.get(url) soup = BeautifulSoup(r.content, 'html.parser') all_tables = soup.findAll('table') for table in all_tables: print('--- table ---')...
[ 11748, 7007, 198, 6738, 275, 82, 19, 1330, 23762, 50, 10486, 198, 6738, 640, 1330, 3993, 198, 198, 6371, 796, 366, 4023, 1378, 13344, 3262, 13, 259, 14, 9630, 13, 10121, 30, 7700, 28, 45688, 62, 6259, 62, 12947, 5, 22213, 5142, 28, ...
2.315574
244
import mailpile.plugins from mailpile.commands import Command from mailpile.mailutils import Email, ExtractEmails from mailpile.util import * mailpile.plugins.register_command('C:', 'contact=', Contact) mailpile.plugins.register_command('_vcard', 'vcard=', VCard)
[ 11748, 6920, 79, 576, 13, 37390, 198, 6738, 6920, 79, 576, 13, 9503, 1746, 1330, 9455, 198, 6738, 6920, 79, 576, 13, 4529, 26791, 1330, 9570, 11, 29677, 10161, 1768, 198, 6738, 6920, 79, 576, 13, 22602, 1330, 1635, 628, 628, 198, 45...
3.021978
91
import numpy as np from pylab import * D = 10 acc1 = np.load('res/small/acc.npy').reshape(D, -1).mean(axis=0) loss1 = np.load('res/small/loss.npy').reshape(D, -1).mean(axis=0) acc2 = np.load('res/large/acc.npy').reshape(D, -1).mean(axis=0) loss2 = np.load('res/large/loss.npy').reshape(D, -1).mean(axis=0) cut = int(acc...
[ 11748, 299, 32152, 355, 45941, 198, 6738, 279, 2645, 397, 1330, 1635, 198, 198, 35, 796, 838, 198, 4134, 16, 796, 45941, 13, 2220, 10786, 411, 14, 17470, 14, 4134, 13, 77, 9078, 27691, 3447, 1758, 7, 35, 11, 532, 16, 737, 32604, 7...
2.165365
768
from flask_restful import reqparse parser = reqparse.RequestParser() parser.add_argument('email_address', help='field cannot be blank.')
[ 6738, 42903, 62, 2118, 913, 1330, 43089, 29572, 628, 198, 198, 48610, 796, 43089, 29572, 13, 18453, 46677, 3419, 198, 48610, 13, 2860, 62, 49140, 10786, 12888, 62, 21975, 3256, 1037, 11639, 3245, 2314, 307, 9178, 2637, 8, 198 ]
3.589744
39
""" A fake DB-API 2 driver. """ # DB names used to trigger certain behaviours. INVALID_DB = 'invalid-db' INVALID_CURSOR = 'invalid-cursor' HAPPY_OUT = 'happy-out' apilevel = '2.0' threadsafety = 2 paramstyle = 'qmark'
[ 37811, 198, 32, 8390, 20137, 12, 17614, 362, 4639, 13, 198, 37811, 198, 198, 2, 20137, 3891, 973, 284, 7616, 1728, 38975, 13, 198, 1268, 23428, 2389, 62, 11012, 796, 705, 259, 12102, 12, 9945, 6, 198, 1268, 23428, 2389, 62, 34, 4261...
2.427083
96
''' ================================================ ## VOICEBOOK REPOSITORY ## ================================================ repository name: voicebook repository version: 1.0 repository link: https://github.com/jim-schwoebel/voicebook author: Jim Schwoebel author contact: js@neur...
[ 7061, 6, 198, 10052, 4770, 220, 198, 2235, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 30578, 8476, 39453, 4526, 37997, 2043, 15513, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 22492, 220, 220, 220, 220, 220, ...
3.40122
820
from typing import List, Tuple, Union import pandas as pd import seaborn as sns from matplotlib import pyplot as plt from ..utils._checks import ( _check_participant, _check_participants, _check_type, ) from ..utils._docs import fill_doc def _check_scores_idx(scores: Union[int, list, tuple]) -> List[i...
[ 6738, 19720, 1330, 7343, 11, 309, 29291, 11, 4479, 198, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 384, 397, 1211, 355, 3013, 82, 198, 6738, 2603, 29487, 8019, 1330, 12972, 29487, 355, 458, 83, 198, 198, 6738, 11485, 26791, 135...
2.665428
269
# Generated by Django 3.1.6 on 2021-02-25 05:46 from django.conf import settings from django.db import migrations, models import django.db.models.deletion
[ 2, 2980, 515, 416, 37770, 513, 13, 16, 13, 21, 319, 33448, 12, 2999, 12, 1495, 8870, 25, 3510, 198, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 198, 11748, 42625, 14...
3.019231
52
#!/usr/bin/env python3 # -*- coding: utf-8 -*- # # This file is part of the minifold project. # https://github.com/nokia/minifold __author__ = "Marc-Olivier Buob" __maintainer__ = "Marc-Olivier Buob" __email__ = "marc-olivier.buob@nokia-bell-labs.com" __copyright__ = "Copyright (C) 2018, Nokia" __license__ ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 198, 2, 770, 2393, 318, 636, 286, 262, 949, 361, 727, 1628, 13, 198, 2, 3740, 1378, 12567, 13, 785, 14, 77...
2.107383
298
# -*- coding: utf-8 -*- # Generated by Django 1.11.7 on 2017-11-18 11:31 from __future__ import unicode_literals from django.db import migrations, models import django.db.models.deletion
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 2980, 515, 416, 37770, 352, 13, 1157, 13, 22, 319, 2177, 12, 1157, 12, 1507, 1367, 25, 3132, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, ...
2.73913
69
from bs4 import BeautifulSoup import re import urllib import pickle as pkl unclean_dat = pkl.load(open('omscs_website_data.p', 'rb')) clean_dat = {} for course_number in unclean_dat.keys(): curr_unclean_dat = unclean_dat[course_number] curr_clean_dat = {} for attribute in curr_unclean_dat.keys(): i...
[ 6738, 275, 82, 19, 1330, 23762, 50, 10486, 198, 11748, 302, 198, 11748, 2956, 297, 571, 198, 11748, 2298, 293, 355, 279, 41582, 198, 198, 403, 27773, 62, 19608, 796, 279, 41582, 13, 2220, 7, 9654, 10786, 296, 1416, 82, 62, 732, 1248...
1.897884
1,087
# 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,...
3.813333
150
from django.urls import path from .views import index, create, delete, update urlpatterns = [ path('', index, name='index'), path('create/', create, name='create'), path('delete/<int:pk>', delete, name='delete'), path('update/<int:pk>', update, name='update'), ]
[ 6738, 42625, 14208, 13, 6371, 82, 1330, 3108, 198, 198, 6738, 764, 33571, 1330, 6376, 11, 2251, 11, 12233, 11, 4296, 198, 198, 6371, 33279, 82, 796, 685, 198, 220, 220, 220, 3108, 10786, 3256, 6376, 11, 1438, 11639, 9630, 33809, 198, ...
2.8
100
""" Adapted from https://realpython.com/python-web-scraping-practical-introduction/ for the purpose of scraping https://publications.parliament.uk/pa/ld/ldjudgmt.HTML to create an expanded HOLJ+ corpus """ import requests from requests import get from requests.exceptions import RequestException from contextlib import ...
[ 37811, 198, 48003, 276, 422, 3740, 1378, 5305, 29412, 13, 785, 14, 29412, 12, 12384, 12, 1416, 2416, 278, 12, 29152, 605, 12, 27427, 596, 14, 198, 1640, 262, 4007, 286, 46743, 3740, 1378, 11377, 602, 13, 1845, 5130, 13, 2724, 14, 89...
3.022523
222
# #!/usr/bin/python import os import numpy as np import pandas as pd from keras.models import load_model from keras.models import Sequential from keras.utils import np_utils from keras.layers.core import Dense, Activation, Dropout from keras import optimizers from matplotlib import pyplot as plt print('Loading data...
[ 2, 1303, 48443, 14629, 14, 8800, 14, 29412, 198, 198, 11748, 28686, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 198, 198, 6738, 41927, 292, 13, 27530, 1330, 3440, 62, 19849, 198, 6738, 41927, 292, 13, 275...
2.653032
709
from socket import socket, gaierror, getservbyport, AF_INET, SOCK_STREAM, setdefaulttimeout from tqdm import tqdm from datetime import datetime if __name__ == '__main__': detect_port_services( ip=input('TARGET IP ADDRESS: '), range_start=int(input('START OF RANGE : ')), range_end=int(i...
[ 6738, 17802, 1330, 17802, 11, 31986, 959, 1472, 11, 3011, 712, 1525, 634, 11, 12341, 62, 1268, 2767, 11, 311, 11290, 62, 2257, 32235, 11, 900, 12286, 48678, 198, 6738, 256, 80, 36020, 1330, 256, 80, 36020, 198, 6738, 4818, 8079, 1330,...
2.421769
147
# -*- coding: utf-8 -*- import json from collections import OrderedDict from typing import List import dash_core_components as dcc import dash_html_components as html import dash_table import pandas as pd from dash import dash from dash.dependencies import Input, Output, State from zvdata import IntervalLevel from zv...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 33918, 198, 6738, 17268, 1330, 14230, 1068, 35, 713, 198, 6738, 19720, 1330, 7343, 198, 198, 11748, 14470, 62, 7295, 62, 5589, 3906, 355, 288, 535, 198, 11748, 14...
1.793252
3,260
import numpy as np
[ 11748, 299, 32152, 355, 45941, 628 ]
3.333333
6
from common_libs import * from cublas_functions import * linalg.init() # Matrix product, there is a batch equivalent for this function too # Make sure it has 2 dimensions (use reshape in the case is 1d) def cublas_matrix_product_gemm_non_batched(handle, a_gpu, b_gpu): """ :param handle: :param a_gpu: Be ca...
[ 6738, 2219, 62, 8019, 82, 1330, 1635, 198, 6738, 13617, 21921, 62, 12543, 2733, 1330, 1635, 198, 75, 1292, 70, 13, 15003, 3419, 198, 198, 2, 24936, 1720, 11, 612, 318, 257, 15458, 7548, 329, 428, 2163, 1165, 198, 2, 6889, 1654, 340,...
2.272727
484
import os from time import localtime, strftime pwd = os.curdir root_dir = pwd + './../' weights_path = '{}data/imagenet_models/VGG16.v2.caffemodel'.format(root_dir) cfg_path = '{}experiments/cfgs/mask_rcnn_alt_opt.yml'.format(root_dir) log_file="{}experiments/logs/mask_rcnn_alt_opt_{}".format(root_dir, strfti...
[ 11748, 28686, 201, 198, 6738, 640, 1330, 1957, 2435, 11, 965, 31387, 201, 198, 201, 198, 79, 16993, 796, 28686, 13, 66, 2799, 343, 201, 198, 15763, 62, 15908, 796, 279, 16993, 1343, 705, 19571, 40720, 6, 201, 198, 201, 198, 43775, 6...
2.272206
349
from direct.directnotify import DirectNotifyGlobal from direct.distributed import DistributedObject from toontown.ai import DistributedPhaseEventMgr
[ 6738, 1277, 13, 12942, 1662, 1958, 1330, 4128, 3673, 1958, 22289, 198, 6738, 1277, 13, 17080, 6169, 1330, 4307, 6169, 10267, 198, 6738, 284, 756, 593, 13, 1872, 1330, 4307, 6169, 35645, 9237, 44, 2164, 198 ]
4.138889
36
""" .. _ft_seeg_example: ========================================= Apply bipolar montage to depth electrodes ========================================= This scripts shows a very simple example on how to create an Interface wrapping a desired function of a Matlab toolbox (|FieldTrip|). .. |FieldTrip| raw:: html <a...
[ 37811, 198, 492, 4808, 701, 62, 325, 1533, 62, 20688, 25, 198, 198, 10052, 2559, 28, 198, 44836, 31170, 40689, 496, 284, 6795, 39780, 198, 10052, 2559, 28, 198, 1212, 14750, 2523, 257, 845, 2829, 1672, 319, 703, 284, 2251, 281, 26491,...
3
525
# Simple tree structure import numpy as np import math
[ 2, 17427, 5509, 4645, 198, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 10688 ]
3.928571
14
# -*- coding: utf-8 -*- """Console script for vibrant_frequencies.""" import logging import click from .prototype import visualize if __name__ == "__main__": main()
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 37811, 47581, 4226, 329, 21266, 62, 69, 8897, 3976, 526, 15931, 198, 11748, 18931, 198, 198, 11748, 3904, 198, 6738, 764, 38124, 1330, 38350, 628, 198, 198, 361, 11...
2.949153
59
from __future__ import annotations from typing import TYPE_CHECKING from .packet import ( ConnectionRequest, ConnectionRequestAccepted, NewIncomingConnection, OfflinePing, OfflinePong, OnlinePing, OnlinePong, OpenConnectionRequest1, OpenConnectionReply1, OpenConnectionRequest2, ...
[ 6738, 11593, 37443, 834, 1330, 37647, 198, 6738, 19720, 1330, 41876, 62, 50084, 2751, 198, 6738, 764, 8002, 316, 1330, 357, 198, 220, 220, 220, 26923, 18453, 11, 198, 220, 220, 220, 26923, 18453, 38855, 276, 11, 198, 220, 220, 220, 96...
3.167665
167
# This file is part of Pynguin. # # Pynguin is free software: you can redistribute it and/or modify # it under the terms of the GNU Lesser General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # Pynguin is distributed in the ho...
[ 2, 770, 2393, 318, 636, 286, 9485, 782, 48441, 13, 198, 2, 198, 2, 9485, 782, 48441, 318, 1479, 3788, 25, 345, 460, 17678, 4163, 340, 290, 14, 273, 13096, 198, 2, 340, 739, 262, 2846, 286, 262, 22961, 12892, 263, 3611, 5094, 13789...
3.589532
363