content
stringlengths
1
1.05M
input_ids
listlengths
1
883k
ratio_char_token
float64
1
22.9
token_count
int64
1
883k
#!/usr/bin/env python # -*- coding: utf-8 -*- """ @Time : 2021/2/26 12:07 @Author : hcai @Email : hua.cai@unidt.com """ import textembedding.get_embedding import textembedding.load_model name = "textbedding" # wv model # # #
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 37811, 198, 31, 7575, 220, 220, 220, 1058, 33448, 14, 17, 14, 2075, 1105, 25, 2998, 220, 198, 31, 13838, 220, ...
2.104348
115
# Import matplotlib.pyplot import matplotlib.pyplot as plt # Set start and end dates start = date(2016, 1, 1) end = date(2016, 12, 31) # Set the ticker and data_source ticker = 'FB' data_source = 'google' # Import the data using DataReader stock_prices = DataReader(ticker, data_source, start, end) # Plot Close stoc...
[ 2, 17267, 2603, 29487, 8019, 13, 9078, 29487, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 198, 2, 5345, 923, 290, 886, 9667, 198, 9688, 796, 3128, 7, 5304, 11, 352, 11, 352, 8, 198, 437, 796, 3128, 7, 5304, ...
2.789855
138
# !/usr/bin/env python # coding=utf8 import json import traceback from tornado.web import RequestHandler from pfrock.cli import logger from pfrock.core.constants import PFROCK_CONFIG_SERVER, PFROCK_CONFIG_ROUTER, PFROCK_CONFIG_PORT, ROUTER_METHOD, \ ROUTER_PATH, ROUTER_OPTIONS, ROUTER_HANDLER from pfrock.core.lib...
[ 2, 5145, 14, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 19617, 28, 40477, 23, 198, 11748, 33918, 198, 11748, 12854, 1891, 198, 198, 6738, 33718, 13, 12384, 1330, 19390, 25060, 198, 198, 6738, 279, 69, 10823, 13, 44506, 1330, 49706, 19...
2.697842
139
from typing import List, Union import torch from torch import nn from torch.nn import functional as F from src.modules.max_mahalanobis import MaxMahalanobis, GaussianResult from src.modules.normalize import Normalize from src.resnet.bottleneck_block_v2s3 import create_bottleneck_stage_v2s3 from src.resnet.shared impo...
[ 6738, 19720, 1330, 7343, 11, 4479, 198, 198, 11748, 28034, 198, 6738, 28034, 1330, 299, 77, 198, 6738, 28034, 13, 20471, 1330, 10345, 355, 376, 198, 198, 6738, 12351, 13, 18170, 13, 9806, 62, 76, 993, 25786, 672, 271, 1330, 5436, 4093...
3.284404
109
systemMenu = {"": 35, "": 45, "": 55, "": 20} menuList = [] while True: menuName = input("Please Enter Menu :") if(menuName.lower() == "exit"): break else: menuList.append([menuName, systemMenu[menuName]]) showBill()
[ 10057, 23381, 796, 19779, 1298, 3439, 11, 366, 1298, 4153, 11, 366, 1298, 5996, 11, 366, 1298, 1160, 92, 198, 26272, 8053, 796, 17635, 198, 198, 4514, 6407, 25, 198, 220, 6859, 5376, 796, 5128, 7203, 5492, 6062, 21860, 1058, 4943, 198...
2.617978
89
# -*- coding: utf-8 -*- import requests import os # 6000 is a large number to make sure we get all the components of a collection. Please do note that RISE also has a pagination feature, # which can be implemented by clients if they wish. per_page = 6000 # getting the list of collections that the user has access to: ...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 7007, 198, 11748, 28686, 198, 198, 2, 39064, 318, 257, 1588, 1271, 284, 787, 1654, 356, 651, 477, 262, 6805, 286, 257, 4947, 13, 4222, 466, 3465, 326, 371, 2435...
2.636147
841
# ___ ___ ___ _ _ # |_ _| _ \___| __(_)_ _ __| |___ _ _ # | || _/___| _|| | ' \/ _` / -_) '_| # |___|_| |_| |_|_||_\__,_\___|_| # Made by Robertas64 #Importing the module import os from time import * banner = """ ___ ___ ___ _ _ |_ _| _ \___| __(_)_ _ __| |_...
[ 2, 220, 220, 46444, 46444, 220, 220, 220, 220, 46444, 4808, 220, 220, 220, 220, 220, 220, 220, 220, 4808, 220, 220, 220, 220, 220, 220, 220, 220, 220, 198, 2, 930, 62, 4808, 91, 4808, 3467, 17569, 91, 11593, 28264, 8, 62, 4808, ...
1.832335
334
import pandas as pd import matplotlib.pyplot as plt
[ 11748, 19798, 292, 355, 279, 67, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 628, 198 ]
2.842105
19
import argparse import os import torch import torch.nn as nn import torch.optim as optim import argparse from torch.utils.data import DataLoader from torchvision import transforms from dataset.main import Flickr8kDataset from dataset.caps_collate import CapsCollate from dataset.download import DownloadDataset from mode...
[ 11748, 1822, 29572, 198, 11748, 28686, 198, 11748, 28034, 198, 11748, 28034, 13, 20471, 355, 299, 77, 198, 11748, 28034, 13, 40085, 355, 6436, 198, 11748, 1822, 29572, 198, 6738, 28034, 13, 26791, 13, 7890, 1330, 6060, 17401, 198, 6738, ...
3.230272
773
import unittest from unittest import TestCase from Implementations.FastIntegersFromGit import FastIntegersFromGit from Implementations.helpers.Helper import ListToPolynomial, toNumbers from Implementations.FasterSubsetSum.RandomizedBase import NearLinearBase from benchmarks.test_distributions import Distributions as d...
[ 11748, 555, 715, 395, 198, 6738, 555, 715, 395, 1330, 6208, 20448, 198, 198, 6738, 48282, 602, 13, 22968, 34500, 364, 4863, 38, 270, 1330, 12549, 34500, 364, 4863, 38, 270, 198, 6738, 48282, 602, 13, 16794, 364, 13, 47429, 1330, 7343,...
3.915663
83
# (set)------------------------ #------------------------------------------ # temp_set = {1,2,3} print(type(temp_set), temp_set) temp_list = [1,2,1,2,2,3,4,12,32] temp_set = set(temp_list) print(type(temp_set), temp_set) # print(100 in temp_set) for element in temp_set: print(element) # ...
[ 2, 220, 220, 220, 357, 2617, 8, 22369, 198, 2, 3880, 35937, 198, 220, 220, 220, 220, 1303, 220, 198, 29510, 62, 2617, 796, 1391, 16, 11, 17, 11, 18, 92, 198, 4798, 7, 4906, 7, 29510, 62, 2617, 828, 20218, 62, 2617, 8, 198, 295...
2.02682
261
from fabric.api import cd, run, settings, sudo configurations = { 'daily': { 'branch': 'master', 'ssl': False, }, 'dev': { 'branch': 'master', 'ssl': False, }, 'prod': { 'branch': 'prod', 'ssl': False, }, 'staging': { '...
[ 6738, 9664, 13, 15042, 1330, 22927, 11, 1057, 11, 6460, 11, 21061, 201, 198, 201, 198, 11250, 20074, 796, 1391, 201, 198, 220, 220, 220, 705, 29468, 10354, 1391, 201, 198, 220, 220, 220, 220, 220, 220, 220, 705, 1671, 3702, 10354, 7...
1.724444
225
""" Tree Sort . Binary Search Tree . Binary Search Tree . Root . . . Binary Search Tree . """ from __future__ import print_function """ Binary Search Tree inorder inorder . """ if __name__ == '__main__': try: raw_input # Python 2 ...
[ 37811, 198, 12200, 33947, 220, 764, 198, 220, 45755, 11140, 12200, 764, 198, 33, 3219, 11140, 12200, 220, 198, 220, 220, 220, 220, 220, 220, 764, 198, 220, 220, 220, 20410, 220, 764, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220,...
2.19697
264
# coding: utf-8 from __future__ import unicode_literals, absolute_import _NOTSET = type( b"NotSet", (object,), {"__repr__": lambda self: "<ValueNotSet>"} )()
[ 2, 19617, 25, 3384, 69, 12, 23, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 11, 4112, 62, 11748, 198, 198, 62, 11929, 28480, 796, 2099, 7, 198, 220, 220, 220, 275, 1, 3673, 7248, 1600, 198, 220, 220, 220, 357,...
2.442857
70
from typing import List import json import e2e.Libs.Ristretto.Ristretto as Ristretto from e2e.Libs.BLS import PrivateKey from e2e.Classes.Transactions.Transactions import Claim, Send, Transactions from e2e.Classes.Consensus.Verification import SignedVerification from e2e.Classes.Consensus.VerificationPacket import V...
[ 6738, 19720, 1330, 7343, 198, 11748, 33918, 198, 198, 11748, 304, 17, 68, 13, 25835, 82, 13, 49, 396, 11489, 78, 13, 49, 396, 11489, 78, 355, 371, 396, 11489, 78, 198, 6738, 304, 17, 68, 13, 25835, 82, 13, 33, 6561, 1330, 15348, ...
2.662566
1,138
#+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ # This is an EXUDYN example # # Details: Simulate Chain with 3D rigid bodies and SphericalJoint; # Also test MarkerNodePosition # # Author: Johannes Gerstmayr # Date: 2020-04-09 # # Copyright:This file is part of Exudyn. Exu...
[ 2, 44627, 44627, 44627, 44627, 25128, 14030, 10, 198, 2, 770, 318, 281, 7788, 8322, 40760, 1672, 198, 2, 198, 2, 14890, 25, 220, 3184, 5039, 21853, 351, 513, 35, 20831, 5920, 290, 1338, 37910, 41, 1563, 26, 198, 2, 220, 220, 220, ...
2.485394
2,054
import logging import sys import time from typing import List, Optional import uvicorn from fastapi import FastAPI from fastapi.exceptions import RequestValidationError from fastapi.responses import PlainTextResponse from sklearn.pipeline import Pipeline from src.entities import ( read_app_params, HeartDiseas...
[ 11748, 18931, 198, 11748, 25064, 198, 11748, 640, 198, 6738, 19720, 1330, 7343, 11, 32233, 198, 198, 11748, 334, 25531, 1211, 198, 6738, 3049, 15042, 1330, 12549, 17614, 198, 6738, 3049, 15042, 13, 1069, 11755, 1330, 19390, 7762, 24765, 1...
2.920886
316
import hashlib import hmac import json import datetime from abc import ABCMeta, abstractmethod from twisted.internet import protocol from mod_config.models import Rule, Actions from mod_honeypot.models import PiPotReport, Deployment from pipot.encryption import Encryption from pipot.notifications import Notification...
[ 11748, 12234, 8019, 198, 11748, 289, 20285, 198, 11748, 33918, 198, 198, 11748, 4818, 8079, 198, 6738, 450, 66, 1330, 9738, 48526, 11, 12531, 24396, 198, 198, 6738, 19074, 13, 37675, 1330, 8435, 198, 198, 6738, 953, 62, 11250, 13, 27530...
4.010753
93
from sys import modules from functools import wraps from jsonschema import validate from pyhttptest.constants import ( HTTP_METHOD_NAMES, JSON_FILE_EXTENSION, ) from pyhttptest.exceptions import ( FileExtensionError, HTTPMethodNotSupportedError ) from pyhttptest.http_schemas import ( # noqa get_s...
[ 6738, 25064, 1330, 13103, 198, 6738, 1257, 310, 10141, 1330, 27521, 198, 198, 6738, 44804, 684, 2395, 2611, 1330, 26571, 198, 198, 6738, 12972, 2804, 457, 395, 13, 9979, 1187, 1330, 357, 198, 220, 220, 220, 14626, 62, 49273, 62, 45, 2...
2.988558
874
from datetime import datetime import arrow import pytest from django.conf import settings from resources.models import Day, Period, Reservation, Resource, ResourceType, Unit TEST_PERFORMANCE = bool(getattr(settings, "TEST_PERFORMANCE", False))
[ 6738, 4818, 8079, 1330, 4818, 8079, 198, 198, 11748, 15452, 198, 11748, 12972, 9288, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 198, 6738, 4133, 13, 27530, 1330, 3596, 11, 18581, 11, 1874, 13208, 11, 20857, 11, 20857, 6030, 11...
3.458333
72
# Generated by Django 3.2.8 on 2021-10-12 22:34 from django.db import migrations, models
[ 2, 2980, 515, 416, 37770, 513, 13, 17, 13, 23, 319, 33448, 12, 940, 12, 1065, 2534, 25, 2682, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 628, 198 ]
2.787879
33
default_app_config = "wagtail_tag_manager.config.WagtailTagManagerConfig"
[ 12286, 62, 1324, 62, 11250, 796, 366, 86, 363, 13199, 62, 12985, 62, 37153, 13, 11250, 13, 54, 363, 13199, 24835, 13511, 16934, 1, 198 ]
2.96
25
# Copyright 2015 ETH Zurich # # 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, sof...
[ 2, 15069, 1853, 35920, 43412, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, 198, 2, 921, 743, 733...
2.910632
649
# -*- coding: utf-8 -*- # # Copyright 2021 Shuoyang Ding <shuoyangd@gmail.com> # Created on 2021-02-11 # # Distributed under terms of the MIT license. import argparse import logging import math import sys logging.basicConfig( format='%(asctime)s %(levelname)s: %(message)s', datefmt='%Y-%m-%d %H:%M:%S', level=log...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 198, 2, 15069, 220, 33448, 32344, 726, 648, 46980, 1279, 1477, 84, 726, 648, 67, 31, 14816, 13, 785, 29, 198, 2, 15622, 319, 33448, 12, 2999, 12, 1157, 198, 2, ...
2.729483
329
import collections from typing import List input = [1, 4, 2, 5, 3] print(validSubarrays(input))
[ 11748, 17268, 198, 6738, 19720, 1330, 7343, 628, 628, 628, 628, 628, 628, 628, 628, 628, 628, 628, 628, 198, 15414, 796, 685, 16, 11, 604, 11, 362, 11, 642, 11, 513, 60, 198, 4798, 7, 12102, 7004, 3258, 592, 7, 15414, 4008, 198 ]
2.727273
44
#!/usr/bin/env python3 # # Stolen almost verbatim from: # https://gitlab.cern.ch/lhcb-rta/pidcalib2/-/blob/master/src/pidcalib2/pklhisto2root.py ############################################################################### # (c) Copyright 2021 CERN for the benefit of the LHCb Collaboration # # ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 198, 2, 520, 8622, 2048, 3326, 8664, 320, 422, 25, 198, 2, 220, 220, 3740, 1378, 18300, 23912, 13, 30903, 13, 354, 14, 75, 71, 21101, 12, 81, 8326, 14, 35317, 9948, 571, 1...
2.162515
1,686
d1 = {"koe":4,"slang":0,"konijn":4,"zebra":4} d1["koe"] d2 = {"vis":0,"beer":4,"kip":2} d1.update(d2) print (d1)
[ 67, 16, 796, 19779, 74, 2577, 1298, 19, 553, 6649, 648, 1298, 15, 553, 74, 261, 48848, 1298, 19, 553, 89, 37052, 1298, 19, 92, 198, 67, 16, 14692, 74, 2577, 8973, 198, 67, 17, 796, 19779, 4703, 1298, 15, 553, 42428, 1298, 19, 55...
1.723077
65
from app.database import crud from fastapi import HTTPException, status
[ 6738, 598, 13, 48806, 1330, 1067, 463, 198, 6738, 3049, 15042, 1330, 14626, 16922, 11, 3722, 628, 628, 198 ]
4
19
""" This module represents the Consumer. Computer Systems Architecture Course Assignment 1 March 2020 """ from threading import Thread from time import sleep
[ 37811, 198, 1212, 8265, 6870, 262, 18110, 13, 198, 198, 34556, 11998, 29778, 20537, 198, 8021, 16747, 352, 198, 16192, 12131, 198, 37811, 198, 198, 6738, 4704, 278, 1330, 14122, 198, 6738, 640, 1330, 3993, 198 ]
4.444444
36
import torch.nn as nn import torch import numpy as np from torch.autograd import Variable
[ 11748, 28034, 13, 20471, 355, 299, 77, 198, 11748, 28034, 198, 11748, 299, 32152, 355, 45941, 198, 198, 6738, 28034, 13, 2306, 519, 6335, 1330, 35748, 628 ]
3.407407
27
""" transaction_set.py Defines the Enrollment 834 005010X220A1 transaction set model. """ from typing import List, Optional from linuxforhealth.x12.models import X12SegmentGroup from .loops import Footer, Header, Loop1000A, Loop1000B, Loop1000C, Loop2000 from pydantic import root_validator, Field from linuxforhealt...
[ 37811, 198, 7645, 2673, 62, 2617, 13, 9078, 198, 198, 7469, 1127, 262, 2039, 48108, 807, 2682, 3571, 20, 20943, 55, 17572, 32, 16, 8611, 900, 2746, 13, 198, 37811, 198, 198, 6738, 19720, 1330, 7343, 11, 32233, 198, 198, 6738, 32639, ...
3.285714
112
from utilities.getStore import getStore filePath = "./entities/bill/store.json" productFilePath = "./entities/product/store.json"
[ 6738, 20081, 13, 1136, 22658, 1330, 651, 22658, 198, 198, 7753, 15235, 796, 366, 19571, 298, 871, 14, 35546, 14, 8095, 13, 17752, 1, 198, 11167, 8979, 15235, 796, 366, 19571, 298, 871, 14, 11167, 14, 8095, 13, 17752, 1, 628 ]
3.219512
41
#discord.py from asyncio import sleep import discord client = discord.Client() #BOT # BOT client.run("***")
[ 2, 15410, 585, 13, 9078, 198, 6738, 30351, 952, 1330, 3993, 198, 11748, 36446, 198, 16366, 796, 36446, 13, 11792, 3419, 198, 2, 33, 2394, 198, 2, 347, 2394, 198, 16366, 13, 5143, 7203, 8162, 4943, 198 ]
2.918919
37
# Generated by Django 3.2.11 on 2022-01-08 03:50 from django.db import migrations, models import django.db.models.deletion
[ 2, 2980, 515, 416, 37770, 513, 13, 17, 13, 1157, 319, 33160, 12, 486, 12, 2919, 7643, 25, 1120, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 198, 11748, 42625, 14208, 13, 9945, 13, 27530, 13, 2934, 1616, 295, ...
2.840909
44
#!/usr/bin/python ########################################################################### # # Copyright 2019 Dell, 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....
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 29113, 29113, 7804, 21017, 198, 2, 198, 2, 15069, 13130, 23617, 11, 3457, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, ...
3.661972
284
import os import time exec_count = 100 cmds = [] cmds.append("tar -cPzf /opt/web.tar.gz /opt/web/ /opt/soft") cmds.append("rm -f /opt/web.tar.gz") for i in range(exec_count): for cmd in cmds: if os.system(cmd) != 0: break time.sleep(1)
[ 11748, 28686, 198, 11748, 640, 198, 18558, 62, 9127, 796, 1802, 198, 28758, 82, 796, 17635, 220, 198, 28758, 82, 13, 33295, 7203, 18870, 532, 66, 47, 89, 69, 1220, 8738, 14, 12384, 13, 18870, 13, 34586, 1220, 8738, 14, 12384, 14, 12...
2.061538
130
from .help import help_handler from .pre import pre_handler from .now import now_handler from .filter import filter_handler
[ 6738, 764, 16794, 1330, 1037, 62, 30281, 198, 6738, 764, 3866, 1330, 662, 62, 30281, 198, 6738, 764, 2197, 1330, 783, 62, 30281, 198, 6738, 764, 24455, 1330, 8106, 62, 30281 ]
3.967742
31
import utils.fileutils as futils inp = futils.read_list("../data/day6.txt") nums_dict = dict() group_size, res_count = 0, 0 for line in inp: if line == "": # res_count += len(nums_set) for k, v in nums_dict.items(): if v == group_size: res_count += 1 nums_dict = ...
[ 11748, 3384, 4487, 13, 7753, 26791, 355, 13294, 4487, 198, 198, 259, 79, 796, 13294, 4487, 13, 961, 62, 4868, 7203, 40720, 7890, 14, 820, 21, 13, 14116, 4943, 198, 77, 5700, 62, 11600, 796, 8633, 3419, 198, 8094, 62, 7857, 11, 581, ...
2.038596
285
from . import types from . import dep from . import RuntimeModel from . import Metadata def get_property(mod, property_name): """ Get a property model object by searching for property name :param mod: module on which to look for the property :param property_name: name of the property ...
[ 6738, 764, 1330, 3858, 198, 6738, 764, 1330, 1207, 198, 6738, 764, 1330, 43160, 17633, 198, 6738, 764, 1330, 3395, 14706, 628, 628, 628, 628, 628, 628, 628, 628, 628, 198, 198, 4299, 651, 62, 26745, 7, 4666, 11, 3119, 62, 3672, 2599...
2.745283
318
# -*- coding: utf-8 -*- # Generated by the protocol buffer compiler. DO NOT EDIT! # source: tests/schematics_proto3_tests.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) from google.protobuf.internal import enum_type_wrapper from google.protobuf import descriptor as _descri...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 2980, 515, 416, 262, 8435, 11876, 17050, 13, 220, 8410, 5626, 48483, 0, 198, 2, 2723, 25, 5254, 14, 1416, 10024, 873, 62, 1676, 1462, 18, 62, 41989, 13, 1676, 146...
2.408849
20,274
from rest_framework.serializers import ModelSerializer from accounts.models import Account
[ 6738, 1334, 62, 30604, 13, 46911, 11341, 1330, 9104, 32634, 7509, 198, 6738, 5504, 13, 27530, 1330, 10781, 198, 220, 198 ]
4.428571
21
# coding: utf-8 from __future__ import division from __future__ import print_function from __future__ import absolute_import from __future__ import unicode_literals import os import logging import datetime import numpy as np import pandas as pd import matplotlib.pyplot as plt import seaborn as sns from config impor...
[ 2, 19617, 25, 3384, 69, 12, 23, 198, 6738, 11593, 37443, 834, 1330, 7297, 198, 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 198, 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17...
3.324
250
# -*- coding: utf-8 -*- # Generated by Django 1.11 on 2018-09-21 17:17 from __future__ import unicode_literals import django.contrib.postgres.fields 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, 319, 2864, 12, 2931, 12, 2481, 1596, 25, 1558, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, 198, 1174...
2.848101
79
from .private.HMC804x import _RohdeSchwarzHMC804x from qcodes.utils.deprecate import deprecate_moved_to_qcd
[ 6738, 764, 19734, 13, 39, 9655, 36088, 87, 1330, 4808, 49, 1219, 2934, 14874, 5767, 89, 39, 9655, 36088, 87, 198, 6738, 10662, 40148, 13, 26791, 13, 10378, 8344, 378, 1330, 1207, 8344, 378, 62, 76, 2668, 62, 1462, 62, 80, 10210, 628...
2.534884
43
# Multiples -- Part I - Write code that prints all the odd numbers from 1 to 1000. Use the for loop and don't use a list to do this exercise for i in range(1, 1000, 2): print(i) # Multiples -- Part II - Create another program that prints all the multiples of 5 from 5 to 1,000,000 for m in range(5, 1000000, 5): ...
[ 2, 15237, 2374, 1377, 2142, 314, 532, 19430, 2438, 326, 20842, 477, 262, 5629, 3146, 422, 352, 284, 8576, 13, 5765, 262, 329, 9052, 290, 836, 470, 779, 257, 1351, 284, 466, 428, 5517, 198, 1640, 1312, 287, 2837, 7, 16, 11, 8576, 1...
2.738956
249
#!/usr/bin/env python3 """ Demo example to test CFG-VALSET ublox message - generation 9 @author: mgesteiro """ import sys import time from serial import Serial, SerialException, SerialTimeoutException from pyubx2 import ( UBXMessage, GET, SET, VALSET_RAM, UBXMessageError, UBXTypeError, UBXP...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 37811, 198, 11522, 78, 1672, 284, 1332, 18551, 38, 12, 53, 23333, 2767, 334, 2436, 1140, 3275, 532, 5270, 860, 198, 198, 31, 9800, 25, 285, 3495, 68, 7058, 198, 37811, 198, 11748...
2.082963
1,350
import pygame import time import sys, random pygame.init() yellow = (255, 255, 102) green = (0, 255, 0) black = (0,0,0) width = 1280 height = 720 gameDisplay = pygame.display.set_mode((width, height)) pygame.display.set_caption('Snake Game By Saswat Samal') clock = pygame.time.Clock() snake_block = 10 snak...
[ 11748, 12972, 6057, 198, 11748, 640, 198, 11748, 25064, 11, 4738, 198, 220, 198, 9078, 6057, 13, 15003, 3419, 198, 220, 198, 198, 36022, 796, 357, 13381, 11, 14280, 11, 15143, 8, 198, 14809, 796, 357, 15, 11, 14280, 11, 657, 8, 198,...
2.548571
175
import tensorflow as tf from tensorflow.examples.tutorials.mnist import input_data mnist = input_data.read_data_sets("MNIST_data/", one_hot = True) sess = tf.InteractiveSession() x = tf.placeholder(tf.float32, [None, 784]) W = tf.Variable(tf.zeros([784, 10])) b = tf.Variable(tf.zeros([10])) y = tf.nn.softmax(tf.matm...
[ 11748, 11192, 273, 11125, 355, 48700, 198, 6738, 11192, 273, 11125, 13, 1069, 12629, 13, 83, 44917, 82, 13, 10295, 396, 1330, 5128, 62, 7890, 198, 10295, 396, 796, 5128, 62, 7890, 13, 961, 62, 7890, 62, 28709, 7203, 39764, 8808, 62, ...
2.374026
385
# Generated by Django 2.2.20 on 2021-05-27 14:53 from django.db import migrations, models
[ 2, 2980, 515, 416, 37770, 362, 13, 17, 13, 1238, 319, 33448, 12, 2713, 12, 1983, 1478, 25, 4310, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 628 ]
2.875
32
# -*- coding: utf-8 -*- """ Solution to Project Euler problem X Author: Jaime Liew https://github.com/jaimeliew1/Project_Euler_Solutions """ import math isPoly = [isTri, isSqr, isPent, isHex,isHept,isOct] if __name__ == "__main__": print(run())
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 46344, 284, 4935, 412, 18173, 1917, 1395, 198, 198, 13838, 25, 38028, 406, 769, 198, 5450, 1378, 12567, 13, 785, 14, 73, 1385, 417, 769, 16, 14, 16775, 62,...
2.40566
106
from shop.models import Product from django.shortcuts import render_to_response from django.template import RequestContext
[ 6738, 6128, 13, 27530, 1330, 8721, 198, 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 62, 1462, 62, 26209, 198, 6738, 42625, 14208, 13, 28243, 1330, 19390, 21947, 628, 628, 628, 628 ]
4.0625
32
import numpy as np from qrogue.game.logic.actors import StateVector stv = StateVector([1 / np.sqrt(2), 0 + 0j, 0 + 0j, 1 / np.sqrt(2)]) #stv.extend(1) print(stv)
[ 11748, 299, 32152, 355, 45941, 198, 198, 6738, 10662, 3828, 518, 13, 6057, 13, 6404, 291, 13, 529, 669, 1330, 1812, 38469, 198, 198, 301, 85, 796, 1812, 38469, 26933, 16, 1220, 45941, 13, 31166, 17034, 7, 17, 828, 657, 1343, 657, 73...
2.173333
75
from rest_framework.views import APIView from rest_framework.response import Response from rest_framework import status from .models import Image, Comment, Like from .serializers import ImageSerializer, CommentSerializer, LikeSerializer
[ 6738, 1334, 62, 30604, 13, 33571, 1330, 3486, 3824, 769, 198, 6738, 1334, 62, 30604, 13, 26209, 1330, 18261, 198, 6738, 1334, 62, 30604, 1330, 3722, 198, 6738, 764, 27530, 1330, 7412, 11, 18957, 11, 4525, 198, 6738, 764, 46911, 11341, ...
3.833333
66
#!/usr/bin/env python """ Compute the comparison of the analytic and experimental PSD matrices. This will generate Figure 1. This is probably the only example that will run in a reasonable time without a GPU. For more details on the method see https://arxiv.org/abs/2106.13785. """ import numpy as np import matplotli...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 37811, 198, 7293, 1133, 262, 7208, 286, 262, 49166, 290, 11992, 6599, 35, 2603, 45977, 13, 198, 198, 1212, 481, 7716, 11291, 352, 13, 198, 1212, 318, 2192, 262, 691, 1672, 326, 481, ...
2.41092
1,740
# -*- coding: utf-8 -*- # Define your item pipelines here # # Don't forget to add your pipeline to the ITEM_PIPELINES setting # See: https://doc.scrapy.org/en/latest/topics/item-pipeline.html import pymysql
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 2, 2896, 500, 534, 2378, 31108, 994, 198, 2, 198, 2, 2094, 470, 6044, 284, 751, 534, 11523, 284, 262, 7283, 3620, 62, 47, 4061, 3698, 1268, 1546, 4634, 198, 2, ...
2.621951
82
"""mixin to add destinations to config attributes"""
[ 37811, 19816, 259, 284, 751, 23982, 284, 4566, 12608, 37811, 198 ]
4.818182
11
#!/usr/bin/env python3 """ Description: ------------ This Python script (assumes Python3) downloads boundary conditions files from AWS S3 to a target directory for the requested date range. Remarks: -------- (1) Jiawei Zhuang found that it is much faster to issue aws s3 cp commands from a bash script than...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 37811, 198, 11828, 25, 198, 10541, 198, 1212, 11361, 4226, 357, 562, 8139, 11361, 18, 8, 21333, 18645, 3403, 198, 16624, 422, 30865, 311, 18, 284, 257, 2496, 8619, 329, 262, ...
2.270368
2,774
from __future__ import absolute_import, unicode_literals # This will make sure the app is always imported when # Django starts so that shared_task will use this app. # import pymysql # # pymysql.install_as_MySQLdb()
[ 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 11, 28000, 1098, 62, 17201, 874, 198, 2, 770, 481, 787, 1654, 262, 598, 318, 1464, 17392, 618, 198, 2, 37770, 4940, 523, 326, 4888, 62, 35943, 481, 779, 428, 598, 13, 198, 2, 1330, 2...
3.323077
65
____notmain: BeginFunc 0 ; EndFunc ;
[ 1427, 1662, 12417, 25, 198, 197, 44140, 37, 19524, 657, 2162, 198, 197, 12915, 37, 19524, 2162, 198 ]
2.166667
18
""" Ejercicio para operacin entre currencies """ """ Representacin del currency""" # No me queda muy claro el uso de esta funcin, sirve para mostrar puntualmente qu? # def __repr__(self): # info = self.name # info2 = self.symbol # return info, info2 euro = Curency("Euro","EU","3.2")...
[ 37811, 198, 198, 36, 73, 2798, 46441, 31215, 1515, 330, 259, 920, 260, 19247, 198, 198, 37811, 628, 198, 37811, 10858, 330, 259, 1619, 7395, 37811, 628, 198, 2, 1400, 502, 627, 18082, 285, 4669, 10212, 78, 1288, 514, 78, 390, 1556, ...
2.385714
140
import os from IPython import get_ipython # need this fix first os.environ["LD_PRELOAD"] = "" os.system("apt remove libtcmalloc-minimal4") os.system("apt install libtcmalloc-minimal4") os.environ["LD_PRELOAD"] = "/usr/lib/x86_64-linux-gnu/libtcmalloc_minimal.so.4.3.0" os.system("dpkg -L libtcmalloc-minimal4") # then ...
[ 11748, 28686, 198, 6738, 6101, 7535, 1330, 651, 62, 541, 7535, 198, 198, 2, 761, 428, 4259, 717, 198, 418, 13, 268, 2268, 14692, 11163, 62, 47, 16448, 41048, 8973, 796, 13538, 198, 418, 13, 10057, 7203, 2373, 4781, 9195, 83, 11215, ...
2.466387
238
from django.db import models from django_countries.fields import CountryField from localflavor.us.models import USStateField from base.models import EONBaseModel
[ 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 6738, 42625, 14208, 62, 9127, 1678, 13, 25747, 1330, 12946, 15878, 198, 6738, 1179, 1604, 75, 5570, 13, 385, 13, 27530, 1330, 1294, 9012, 15878, 198, 198, 6738, 2779, 13, 27530, 1330, 412, ...
3.553191
47
#!/usr/bin/env python2.7 import sys reload(sys) sys.setdefaultencoding("utf-8") from flask import Flask, render_template, request, jsonify import argparse import datetime import os, sys import requests from socket import error as SocketError import errno import json import pika import uuid app = Flask(__name__) ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 17, 13, 22, 198, 198, 11748, 25064, 198, 260, 2220, 7, 17597, 8, 198, 17597, 13, 2617, 12286, 12685, 7656, 7203, 40477, 12, 23, 4943, 198, 6738, 42903, 1330, 46947, 11, 8543, 62, 28243, 1...
2.389058
658
import numpy as np from ComponentStructural import ComponentStructural from ..subsystems import SubsystemStructural
[ 198, 11748, 299, 32152, 355, 45941, 198, 6738, 35100, 44909, 1523, 1330, 35100, 44909, 1523, 198, 6738, 11485, 7266, 10057, 82, 1330, 3834, 10057, 44909, 1523, 198 ]
4.333333
27
from telegram.ext import Updater, CommandHandler, MessageHandler, Filters, ConversationHandler import logging from utils import TELEGRAM_TOKEN from handlers import start, ask_new_url, get_url, get_description, cancel from handlers import URL_URL, URL_DESCRIPTION logging.basicConfig(format='%(levelname)s - %(message)s...
[ 6738, 573, 30536, 13, 2302, 1330, 3205, 67, 729, 11, 9455, 25060, 11, 16000, 25060, 11, 7066, 1010, 11, 42427, 25060, 198, 11748, 18931, 198, 198, 6738, 3384, 4487, 1330, 13368, 2538, 10761, 2390, 62, 10468, 43959, 198, 6738, 32847, 133...
3.210938
128
#!/usr/bin/env python """ Simple surface plot example """ from gr import * from math import * x = [-2 + i * 0.5 for i in range(0, 29)] y = [-7 + i * 0.5 for i in range(0, 29)] z = list(range(0, 841)) for i in range(0, 29): for j in range(0, 29): r1 = sqrt((x[j] - 5)**2 + y[i]**2) r2 = sqrt((x[j] + 5)**2 +...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 37811, 198, 26437, 4417, 7110, 1672, 198, 37811, 198, 198, 6738, 1036, 1330, 1635, 220, 198, 6738, 10688, 1330, 1635, 198, 198, 87, 796, 25915, 17, 1343, 1312, 1635, 657, 13, 20, 329, ...
1.915718
439
# function that will be distributed # wrapper function, uses the dask client object
[ 2, 2163, 326, 481, 307, 9387, 628, 198, 2, 29908, 2163, 11, 3544, 262, 288, 2093, 5456, 2134, 198 ]
4.526316
19
"""Main functionalities.""" from .image.image import (Image, RawDataContainer) from .image.color_format import AVAILABLE_FORMATS from .parser.factory import ParserFactory import cv2 as cv import os
[ 37811, 13383, 10345, 871, 526, 15931, 198, 198, 6738, 764, 9060, 13, 9060, 1330, 357, 5159, 11, 16089, 6601, 29869, 8, 198, 6738, 764, 9060, 13, 8043, 62, 18982, 1330, 317, 11731, 4146, 17534, 62, 21389, 33586, 198, 6738, 764, 48610, ...
3.274194
62
"""demo URL Configuration The `urlpatterns` list routes URLs to views. For more information please see: https://docs.djangoproject.com/en/1.10/topics/http/urls/ Examples: Function views 1. Add an import: from my_app import views 2. Add a URL to urlpatterns: url(r'^$', views.home, name='home') Class-based...
[ 37811, 9536, 78, 10289, 28373, 198, 198, 464, 4600, 6371, 33279, 82, 63, 1351, 11926, 32336, 284, 5009, 13, 1114, 517, 1321, 3387, 766, 25, 198, 220, 220, 220, 3740, 1378, 31628, 13, 28241, 648, 404, 305, 752, 13, 785, 14, 268, 14, ...
2.715649
524
from django.urls import path from .views import teacherregister,studentregister,login_view,logout from . import views from .views import ( ClassroomCreateView,ClassroomListView,ClassroomDetailView,ClassroomUpdateView,ClassroomDeleteView, SubjectCreateView,SubjectListView,SubjectDetailView,SubjectUpdateView,SubjectDelet...
[ 6738, 42625, 14208, 13, 6371, 82, 1330, 3108, 198, 6738, 764, 33571, 1330, 4701, 30238, 11, 50139, 30238, 11, 38235, 62, 1177, 11, 6404, 448, 198, 6738, 764, 1330, 5009, 198, 6738, 764, 33571, 1330, 357, 198, 9487, 3823, 16447, 7680, ...
2.310963
1,505
#!/usr/bin/env python """ CLI tool to runs various tasks related to QA. """ import os import time from pathlib import Path import sys import traceback import json import yaml import uuid import datetime import click from .run import RunContext from .runners import runners, Job, JobGroup from .runners.lsf import LsfPr...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 37811, 198, 5097, 40, 2891, 284, 4539, 2972, 8861, 3519, 284, 1195, 32, 13, 198, 37811, 198, 11748, 28686, 198, 11748, 640, 198, 6738, 3108, 8019, 1330, 10644, 198, 11748, 25064, 198, ...
2.830817
1,921
# -*- coding: utf-8 -*- import threading import time import global_def as gd from db_reader import DbReaderDef, DbReaer from queue import Queue, Empty
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 4704, 278, 198, 11748, 640, 198, 11748, 3298, 62, 4299, 355, 308, 67, 198, 6738, 20613, 62, 46862, 1330, 360, 65, 33634, 7469, 11, 360, 65, 3041, 25534, 198, 67...
2.923077
52
import logging from rest_framework import mixins, generics, permissions, exceptions from django.conf import settings from django.utils import timezone from .serializers import CategorySerializer, TagSerializer, TodoSerializer from .models import Category, Tag, Todo logger = logging.getLogger(__name__)
[ 11748, 18931, 198, 198, 6738, 1334, 62, 30604, 1330, 5022, 1040, 11, 1152, 873, 11, 21627, 11, 13269, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, 26791, 1330, 640, 11340, 198, 198, 6738, 764, 46911, 1134...
3.738095
84
# coding=utf-8 # # This file is part of Hypothesis (https://github.com/DRMacIver/hypothesis) # # Most of this work is copyright (C) 2013-2015 David R. MacIver # (david@drmaciver.com), but it contains contributions by others. See # https://github.com/DRMacIver/hypothesis/blob/master/CONTRIBUTING.rst for a # full list of...
[ 2, 19617, 28, 40477, 12, 23, 198, 2, 198, 2, 770, 2393, 318, 636, 286, 21209, 313, 8497, 357, 5450, 1378, 12567, 13, 785, 14, 7707, 14155, 40, 332, 14, 36362, 313, 8497, 8, 198, 2, 198, 2, 4042, 286, 428, 670, 318, 6634, 357, ...
2.902497
2,523
""" Script to generate a security pipeline for PDF files. It does the following: - Adds specified meta-data - Encrypts file Run: python3 pipeline.py """ from PyPDF2 import PdfFileWriter, PdfFileReader from PyPDF2.generic import NameObject, createStringObject if __name__ == '__main__': # path for the file to ...
[ 37811, 198, 7391, 284, 7716, 257, 2324, 11523, 329, 12960, 3696, 13, 198, 1026, 857, 262, 1708, 25, 198, 12, 34333, 7368, 13634, 12, 7890, 198, 12, 14711, 6012, 82, 2393, 198, 198, 10987, 25, 198, 220, 220, 220, 21015, 18, 11523, 13...
2.491349
289
import glob from numpy.linalg import norm import numpy as np from copy import deepcopy as copy from MergeTrack.merge_functions import read_ann,read_props from MergeTrack.ReID_net_functions import ReID_net_init, add_ReID input_images = "DAVIS/val17/" input_proposals = "DAVIS/ReID_props/" first_frame_anns = "DAVIS/val1...
[ 11748, 15095, 198, 6738, 299, 32152, 13, 75, 1292, 70, 1330, 2593, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 4866, 1330, 2769, 30073, 355, 4866, 198, 198, 6738, 39407, 24802, 13, 647, 469, 62, 12543, 2733, 1330, 1100, 62, 1236, 1...
2.422655
821
import unittest import string_matching if __name__ == '__main__': unittest.main()
[ 11748, 555, 715, 395, 198, 11748, 4731, 62, 15699, 278, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 555, 715, 395, 13, 12417, 3419, 628 ]
2.666667
33
import numpy as np import pytest import molecool_test
[ 11748, 299, 32152, 355, 45941, 198, 11748, 12972, 9288, 198, 198, 11748, 9411, 24494, 62, 9288, 628, 628, 628, 198 ]
3.05
20
from unittest import TestCase from unittest.mock import patch, MagicMock, PropertyMock from basketball_reference_web_scraper.html import SearchPage, PlayerSearchResult
[ 6738, 555, 715, 395, 1330, 6208, 20448, 198, 6738, 555, 715, 395, 13, 76, 735, 1330, 8529, 11, 6139, 44, 735, 11, 14161, 44, 735, 198, 198, 6738, 9669, 62, 35790, 62, 12384, 62, 1416, 38545, 13, 6494, 1330, 11140, 9876, 11, 7853, ...
3.695652
46
## # This software was developed and / or modified by Raytheon Company, # pursuant to Contract DG133W-05-CQ-1067 with the US Government. # # U.S. EXPORT CONTROLLED TECHNICAL DATA # This software product contains export-restricted data whose # export/transfer/disclosure is restricted by U.S. law. Dissemination # to ...
[ 2235, 198, 2, 770, 3788, 373, 4166, 290, 1220, 393, 9518, 416, 7760, 1169, 261, 5834, 11, 198, 2, 12997, 284, 17453, 46133, 16945, 54, 12, 2713, 12, 34, 48, 12, 940, 3134, 351, 262, 1294, 5070, 13, 201, 198, 2, 220, 201, 198, 2,...
2.818975
917
from abc import ABC from typing import List from zeep import CachingClient, Client, Settings from .exceptions import APIError
[ 6738, 450, 66, 1330, 9738, 198, 6738, 19720, 1330, 7343, 198, 198, 6738, 41271, 538, 1330, 327, 8103, 11792, 11, 20985, 11, 16163, 198, 198, 6738, 764, 1069, 11755, 1330, 7824, 12331, 628, 628 ]
3.852941
34
# @Time: 2022/4/12 20:50 # @Author: chang liu # @Email: chang_liu_tamu@gmail.com # @File:4.4.Implementing_the_iterator_protocol.py ################ clean version ######################### # class Node: # def __init__(self, val): # self._value = val # self._children = [] # # def __repr__(self): ...
[ 2, 2488, 7575, 25, 33160, 14, 19, 14, 1065, 1160, 25, 1120, 198, 2, 2488, 13838, 25, 1488, 7649, 84, 198, 2, 2488, 15333, 25, 1488, 62, 4528, 84, 62, 83, 321, 84, 31, 14816, 13, 785, 198, 2, 2488, 8979, 25, 19, 13, 19, 13, 3...
2.260143
419
import tensorflow as tf import tensorflow_probability as tfp import numpy as np import pickle import random from utils import gauss_cross_entropy tfk = tfp.math.psd_kernels def forward_pass_FGPVAE_rotated_mnist(data_batch, beta, vae, GP, N_t, clipping_qs, bayes...
[ 11748, 11192, 273, 11125, 355, 48700, 201, 198, 11748, 11192, 273, 11125, 62, 1676, 65, 1799, 355, 256, 46428, 201, 198, 11748, 299, 32152, 355, 45941, 201, 198, 11748, 2298, 293, 201, 198, 11748, 4738, 201, 198, 201, 198, 6738, 3384, ...
1.760689
8,537
from abc import ABC, abstractmethod from argparse import Namespace, ArgumentParser from spotty.commands.writers.abstract_output_writrer import AbstractOutputWriter
[ 6738, 450, 66, 1330, 9738, 11, 12531, 24396, 198, 6738, 1822, 29572, 1330, 28531, 10223, 11, 45751, 46677, 198, 6738, 4136, 774, 13, 9503, 1746, 13, 34422, 13, 397, 8709, 62, 22915, 62, 8933, 11751, 1330, 27741, 26410, 34379, 628 ]
4.125
40
# -*- coding: utf-8 -*- # ------------------------------------------------------------------------------ # # Copyright 2018-2019 Fetch.AI Limited # # 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 ...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 16529, 26171, 198, 2, 198, 2, 220, 220, 15069, 2864, 12, 23344, 376, 7569, 13, 20185, 15302, 198, 2, 198, 2, 220, 220, 49962, 739, 262, 24843, 13789, 11, 10628, 3...
2.769482
2,451
import os.path import os from googleapiclient.discovery import build from google_auth_oauthlib.flow import InstalledAppFlow from google.auth.transport.requests import Request from google.oauth2.credentials import Credentials from datetime import datetime # If modifying these scopes, delete the file token.json. SCOPES ...
[ 11748, 28686, 13, 6978, 198, 11748, 28686, 198, 6738, 23645, 499, 291, 75, 1153, 13, 67, 40821, 1330, 1382, 198, 6738, 23645, 62, 18439, 62, 12162, 1071, 8019, 13, 11125, 1330, 2262, 4262, 4677, 37535, 198, 6738, 23645, 13, 18439, 13, ...
2.224971
2,587
from .QArithmetic import * from .qft import *
[ 6738, 764, 48, 3163, 29848, 1330, 1635, 198, 6738, 764, 80, 701, 1330, 1635, 198 ]
3.066667
15
"""Calculate conditional probability of a short interevent time being followed by another short interevent time, compared with the unconditional probability. This is used to test whether fault records have memory """ import os, sys from glob import glob import numpy as np import matplotlib.pyplot as plt from QuakeRat...
[ 37811, 9771, 3129, 378, 26340, 12867, 286, 257, 1790, 493, 567, 1151, 220, 198, 2435, 852, 3940, 416, 1194, 1790, 493, 567, 1151, 640, 11, 3688, 198, 4480, 262, 42423, 12867, 13, 198, 1212, 318, 973, 284, 1332, 1771, 8046, 4406, 423, ...
2.355416
1,117
import time #Controls functions for the delta sleep_time = 0.5
[ 11748, 640, 198, 2, 15988, 82, 5499, 329, 262, 25979, 198, 42832, 62, 2435, 796, 657, 13, 20, 198, 220, 220, 220, 220, 198 ]
2.833333
24
# From The School of AI's Move 37 Course https://www.theschool.ai/courses/move-37-course/ # Coding demo by Colin Skow # Forked from https://github.com/lazyprogrammer/machine_learning_examples/tree/master/rl # Credit goes to LazyProgrammer from __future__ import print_function, division from builtins import range # Note...
[ 2, 3574, 383, 3961, 286, 9552, 338, 10028, 5214, 20537, 3740, 1378, 2503, 13, 83, 956, 1251, 13, 1872, 14, 66, 39975, 14, 21084, 12, 2718, 12, 17319, 14, 198, 2, 327, 7656, 13605, 416, 18373, 3661, 322, 198, 2, 39812, 276, 422, 37...
3.243176
403
#!/usr/bin/env python # -*- coding: utf-8 -*- # # GTKcsvimport.py # # Copyright 2010-2015 Jose Riguera Lopez <jriguera@gmail.com> # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 198, 2, 220, 220, 220, 220, 220, 220, 7963, 42, 40664, 11748, 13, 9078, 198, 2, 198, 2, 220, 220, 15069, 3050, ...
2.711488
766
# -*- coding: utf-8 -*- # Max-Planck-Gesellschaft zur Frderung der Wissenschaften e.V. (MPG) is # holder of all proprietary rights on this computer program. # You can only use this computer program if you have closed # a license agreement with MPG or you get the right to use the computer # program from someone who is ...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 2, 5436, 12, 20854, 694, 12, 38, 274, 19187, 11693, 701, 1976, 333, 1305, 1082, 2150, 4587, 370, 747, 641, 11693, 14785, 304, 13, 53, 13, 357, 44, 6968, 8, 318,...
3.392713
247
from tensorflow.contrib.slim.python.slim.data import data_provider from tensorflow.contrib.slim.python.slim.data import parallel_reader
[ 6738, 11192, 273, 11125, 13, 3642, 822, 13, 82, 2475, 13, 29412, 13, 82, 2475, 13, 7890, 1330, 1366, 62, 15234, 1304, 198, 6738, 11192, 273, 11125, 13, 3642, 822, 13, 82, 2475, 13, 29412, 13, 82, 2475, 13, 7890, 1330, 10730, 62, 4...
3.044444
45
# -*- coding: UTF-8 -*- ####################################################################### # ---------------------------------------------------------------------------- # "THE BEER-WARE LICENSE" (Revision 42): # @tantrumdev wrote this file. As long as you retain this notice you # can do whatever you want wit...
[ 2, 532, 9, 12, 19617, 25, 41002, 12, 23, 532, 9, 12, 198, 29113, 29113, 4242, 21017, 198, 1303, 16529, 10541, 198, 1303, 366, 10970, 9348, 1137, 12, 33746, 38559, 24290, 1, 357, 18009, 1166, 5433, 2599, 198, 1303, 2488, 83, 415, 658...
4.118812
202
# import colorgram # # colors = colorgram.extract('image.jpg', 30) # rgb_colors = [] # for color in colors: # rgb_colors.append((color.rgb.r, color.rgb.g, color.rgb.b)) # # print(rgb_colors) from turtle import Turtle, Screen import random color_list = [(238, 251, 245), (250, 228, 15), (213, 12, 8), (199, 11, 36),...
[ 2, 1330, 951, 2398, 859, 198, 2, 198, 2, 7577, 796, 951, 2398, 859, 13, 2302, 974, 10786, 9060, 13, 9479, 3256, 1542, 8, 198, 2, 46140, 62, 4033, 669, 796, 17635, 198, 2, 329, 3124, 287, 7577, 25, 198, 2, 220, 220, 220, 220, 4...
2.075248
505
from django import forms from .models import UserAccount, JobPost, JobPostActivity, UserProfile
[ 6738, 42625, 14208, 1330, 5107, 198, 6738, 764, 27530, 1330, 11787, 30116, 11, 15768, 6307, 11, 15768, 6307, 16516, 11, 11787, 37046, 628, 628, 628, 628 ]
3.961538
26
#!/usr/bin/env python #_MIT License #_ #_Copyright (c) 2017 Dan Persons (dpersonsdev@gmail.com) #_ #_Permission is hereby granted, free of charge, to any person obtaining a copy #_of this software and associated documentation files (the "Software"), to deal #_in the Software without restriction, including without limi...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 2, 62, 36393, 13789, 198, 2, 62, 198, 2, 62, 15269, 357, 66, 8, 2177, 6035, 32884, 357, 67, 19276, 684, 7959, 31, 14816, 13, 785, 8, 198, 2, 62, 198, 2, 62, 5990, 3411, 31...
3.164557
632
# Generated by Django 3.2.7 on 2021-09-12 01:29 from django.db import migrations, models
[ 2, 2980, 515, 416, 37770, 513, 13, 17, 13, 22, 319, 33448, 12, 2931, 12, 1065, 5534, 25, 1959, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 628 ]
2.84375
32
# coding: utf-8 # # Copyright 2022 :Barry-Thomas-Paul: Moss # # 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 applicab...
[ 2, 19617, 25, 3384, 69, 12, 23, 198, 2, 198, 2, 15069, 33160, 1058, 33, 6532, 12, 22405, 12, 12041, 25, 19935, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 4943, 198, 2, 345, 743,...
3.428571
252
from pathlib import Path from unittest import mock import pytest from fab.build_config import AddFlags from fab.dep_tree import AnalysedFile from fab.steps.compile_fortran import CompileFortran # todo: we might have liked to reuse this from test_dep_tree from fab.util import CompiledFile
[ 6738, 3108, 8019, 1330, 10644, 198, 6738, 555, 715, 395, 1330, 15290, 198, 198, 11748, 12972, 9288, 198, 6738, 7843, 13, 11249, 62, 11250, 1330, 3060, 40053, 198, 198, 6738, 7843, 13, 10378, 62, 21048, 1330, 1052, 47557, 8979, 198, 6738...
3.488095
84