content
stringlengths
1
1.04M
input_ids
listlengths
1
774k
ratio_char_token
float64
0.38
22.9
token_count
int64
1
774k
from regression_tests import * # https://github.com/avast-tl/retdec/issues/246 # Test for ordinals that are translated by YARA/pefile LUT. # https://github.com/avast-tl/retdec/issues/246 # Test for ordinals that are NOT translated by YARA/pefile LUT. # https://github.com/avast-tl/retdec/issues/121 # Test export ha...
[ 6738, 20683, 62, 41989, 1330, 1635, 628, 198, 2, 3740, 1378, 12567, 13, 785, 14, 615, 459, 12, 28781, 14, 1186, 12501, 14, 37165, 14, 26912, 198, 2, 6208, 329, 2760, 6897, 326, 389, 14251, 416, 575, 24401, 14, 431, 7753, 406, 3843, ...
3.016667
180
""" Jinja support adds the following abilities: 1. Adds a ``YamlFrontMatterLoader``, which searchs the beginning of the file for YAML between two lines of an equal number of three or more dashes. These lines are stripped off before rendering. 2. Jinja has nice support for displaying errors, but the YAML front m...
[ 37811, 198, 41, 259, 6592, 1104, 6673, 262, 1708, 7883, 25, 198, 198, 16, 13, 34333, 257, 7559, 56, 43695, 25886, 44, 1436, 17401, 15506, 11, 543, 2989, 82, 262, 3726, 286, 262, 2393, 329, 198, 220, 220, 575, 2390, 43, 1022, 734, ...
2.642431
1,843
import matplotlib.pyplot as plt from read_file import select_original_breakpoints from collections import defaultdict if __name__ == '__main__': N = 5 slopes, intervals = select_original_breakpoints(N, 'segm/segmented_curves_filtered.txt') slopes_hist = defaultdict(lambda: []) intervals_hist = defaul...
[ 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 6738, 1100, 62, 7753, 1330, 2922, 62, 14986, 62, 9032, 13033, 198, 6738, 17268, 1330, 4277, 11600, 628, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, ...
2.205882
442
# -*- coding:utf-8 -*- import base64 import numpy as np
[ 2, 532, 9, 12, 19617, 25, 40477, 12, 23, 532, 9, 12, 198, 11748, 2779, 2414, 198, 11748, 299, 32152, 355, 45941, 628, 198 ]
2.416667
24
# generated by appcreator import django_filters from django import forms from dal import autocomplete from vocabs.filters import generous_concept_filter from vocabs.models import SkosConcept from .models import ( NerDataSet, NerSample, Dataset, Example, ProdigyServer)
[ 2, 7560, 416, 598, 45382, 198, 11748, 42625, 14208, 62, 10379, 1010, 198, 6738, 42625, 14208, 1330, 5107, 198, 198, 6738, 288, 282, 1330, 1960, 42829, 6677, 198, 198, 6738, 12776, 8937, 13, 10379, 1010, 1330, 14431, 62, 43169, 62, 24455...
3.041667
96
import numpy as np from typing import Callable, Tuple, Union def assert_model_predictions_deviations( y_pred: float, y_pred_perturb: float, threshold: float = 0.01 ): """Check that model predictions does not deviate more than a given threshold.""" if abs(y_pred - y_pred_perturb) > threshold: retu...
[ 11748, 299, 32152, 355, 45941, 198, 6738, 19720, 1330, 4889, 540, 11, 309, 29291, 11, 4479, 628, 198, 198, 4299, 6818, 62, 19849, 62, 28764, 9278, 62, 7959, 40356, 7, 198, 220, 220, 220, 331, 62, 28764, 25, 12178, 11, 331, 62, 28764...
2.54307
2,554
import json import urllib.request from collections import defaultdict from datetime import datetime
[ 11748, 33918, 198, 11748, 2956, 297, 571, 13, 25927, 198, 6738, 17268, 1330, 4277, 11600, 198, 6738, 4818, 8079, 1330, 4818, 8079, 628, 198 ]
4.25
24
import requests import re import urllib from lxml import etree from bs4 import BeautifulSoup headers ={"User-Agent": "Mozilla/5.0 (iPhone; CPU iPhone OS 11_0 like Mac OS X) AppleWebKit/604.1.38 (KHTML, like Gecko) Version/11.0 Mobile/15A372 Safari/604.1","Referer": "http://fanyi.baidu.com/translate?aldtype=16047&quer...
[ 11748, 7007, 198, 11748, 302, 198, 11748, 2956, 297, 571, 198, 6738, 300, 19875, 1330, 220, 2123, 631, 198, 6738, 275, 82, 19, 1330, 23762, 50, 10486, 198, 198, 50145, 796, 4895, 12982, 12, 36772, 1298, 366, 44, 8590, 5049, 14, 20, ...
2.377551
392
import datetime as dt from typing import ClassVar, Optional, cast from cuenca_validations.types import SessionRequest, SessionType from pydantic import AnyUrl from pydantic.dataclasses import dataclass from .. import http from .base import Creatable, Queryable, Retrievable @dataclass
[ 11748, 4818, 8079, 355, 288, 83, 198, 6738, 19720, 1330, 5016, 19852, 11, 32233, 11, 3350, 198, 198, 6738, 18912, 268, 6888, 62, 12102, 602, 13, 19199, 1330, 23575, 18453, 11, 23575, 6030, 198, 6738, 279, 5173, 5109, 1330, 4377, 28165, ...
3.52439
82
# -*- coding: iso-8859-15 -*- # Copyright (c) 2014 The New York Times Company # # 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 re...
[ 2, 532, 9, 12, 19617, 25, 47279, 12, 3459, 3270, 12, 1314, 532, 9, 12, 198, 198, 2, 15069, 357, 66, 8, 1946, 383, 968, 1971, 3782, 5834, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34...
2.281768
2,172
import sys sys.path.append("../../external/CollMetric/") import numpy as np import tensorflow as tf import os from datetime import datetime from sampler import WarpSampler from CML_utils import Evaluator, Monitor, parse_args, dataset_to_uimatrix from CML import CML, optimize if __name__ == '__main__': args = pars...
[ 11748, 25064, 198, 17597, 13, 6978, 13, 33295, 7203, 40720, 40720, 22615, 14, 22667, 9171, 1173, 14, 4943, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 11192, 273, 11125, 355, 48700, 198, 11748, 28686, 198, 6738, 4818, 8079, 1330, 4818...
2.363284
1,291
import matplotlib.pyplot as plt x = [1,2,3] y = [1,2,1] yerrormin = [0.1,0.5,0.9] yerrormax = [0.2,0.4,0.6] xerror = 0.5 yerror = [yerrormin, yerrormax] plt.plot(x,y,'o') plt.errorbar(x,y,yerr=yerror, xerr=xerror, fmt='o', ecolor='black',elinewidth=2, capsize=5,capthick=2, barsabove=False, errorevery=1, lolims=False...
[ 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 198, 87, 796, 685, 16, 11, 17, 11, 18, 60, 198, 88, 796, 685, 16, 11, 17, 11, 16, 60, 198, 88, 8056, 579, 259, 796, 685, 15, 13, 16, 11, 15, 13, 20, 11, 15, 13,...
1.88785
214
""" Example of capturing the average image width VideoCaptureEX class. The averaged image can reduce random noise. """ import EasyPySpin import cv2 if __name__ == "__main__": main()
[ 37811, 198, 16281, 286, 21430, 262, 2811, 2939, 9647, 7623, 49630, 6369, 1398, 13, 198, 464, 16449, 2939, 460, 4646, 4738, 7838, 13, 198, 37811, 198, 11748, 16789, 20519, 4561, 259, 198, 11748, 269, 85, 17, 628, 198, 198, 361, 11593, ...
3.375
56
# 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 # d...
[ 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, 428, 2393, 2845, 287, 11846, 351, 262, 13789, 13, 921, 743, 7330, 198, 2, 220, 220, ...
2.585774
478
for i in range(2, 21): with open(f"tables/Multiplication_table_of_{i}.txt", 'w') as f: for j in range(1, 11): f.write(f"{i}X{j}={i*j}") if j!=10: f.write('\n')
[ 201, 198, 1640, 1312, 287, 2837, 7, 17, 11, 2310, 2599, 201, 198, 220, 220, 220, 351, 1280, 7, 69, 1, 83, 2977, 14, 15205, 24705, 3299, 62, 11487, 62, 1659, 23330, 72, 27422, 14116, 1600, 705, 86, 11537, 355, 277, 25, 201, 198, ...
1.605839
137
""" Module Name: ip_traffic.py Description: Module provides functionality to monitor IP traffic. Authors: Columbia University, the Internet Real-Time Lab (IRT Lab). 2018-2019. """ import random import db import utils from scapy.all import sniff from datetime import datetime def run_ip_traffic_monitor(d...
[ 37811, 198, 26796, 6530, 25, 198, 220, 20966, 62, 9535, 2108, 13, 9078, 628, 198, 11828, 25, 198, 220, 19937, 3769, 11244, 284, 5671, 6101, 4979, 13, 628, 198, 30515, 669, 25, 198, 220, 9309, 2059, 11, 262, 4455, 6416, 12, 7575, 349...
3.077236
738
""" iota-dust-manager A thread safe, stateless python package that manages your receiving dust address. """ __version__ = "0.1.5" __author__ = 'F-Node-Karlsruhe' import iota_client import threading IOTA_DUST = 1_000_000 IOTA_PER_DUST_TRANSACTION = 100_000 class DustManager: """Create a DustManager. :par...
[ 37811, 198, 72, 4265, 12, 48859, 12, 37153, 198, 198, 32, 4704, 3338, 11, 1181, 1203, 21015, 5301, 326, 15314, 534, 6464, 8977, 2209, 13, 198, 37811, 198, 198, 834, 9641, 834, 796, 366, 15, 13, 16, 13, 20, 1, 198, 834, 9800, 834, ...
2.300506
1,777
from django.db import models from hvad.models import TranslatableModel, TranslatedFields from django.utils.translation import ugettext_lazy as _
[ 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 6738, 289, 85, 324, 13, 27530, 1330, 3602, 49009, 17633, 11, 3602, 17249, 15878, 82, 198, 6738, 42625, 14208, 13, 26791, 13, 41519, 1330, 334, 1136, 5239, 62, 75, 12582, 355, 4808, 628, 1...
3.5
42
n,m,k=map(int,input().split()) a=min(m,k)+min(n-m,n-k) print(a)
[ 77, 11, 76, 11, 74, 28, 8899, 7, 600, 11, 15414, 22446, 35312, 28955, 198, 64, 28, 1084, 7, 76, 11, 74, 47762, 1084, 7, 77, 12, 76, 11, 77, 12, 74, 8, 198, 4798, 7, 64, 8 ]
1.657895
38
from wurst.transformations.geo import * import pytest @pytest.fixture(scope="function")
[ 6738, 266, 24962, 13, 35636, 602, 13, 469, 78, 1330, 1635, 198, 11748, 12972, 9288, 628, 198, 31, 9078, 9288, 13, 69, 9602, 7, 29982, 2625, 8818, 4943, 628, 628, 628, 628, 628, 628 ]
2.970588
34
# from.import invoice_report
[ 2, 422, 13, 11748, 45458, 62, 13116 ]
4
7
import numpy as np import pandas as pd def batch(l, b=1, n=None): """ Create batch from iterable. Parameters ---------- l : list list to create batches from b : int, optional, [default = 1] batch size n : int, optional, [default = None] if None: len(batches[-1]) < ...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 628, 198, 4299, 15458, 7, 75, 11, 275, 28, 16, 11, 299, 28, 14202, 2599, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 13610, 15458, 422, 11629, 540, 13, 628, 2...
2.249533
1,070
import logging from telegram import ReplyKeyboardMarkup, ReplyKeyboardRemove, KeyboardButton from autobot import AutoBotConstants from autobot.configuration import AutoBotConfig
[ 11748, 18931, 198, 198, 6738, 573, 30536, 1330, 14883, 9218, 3526, 9704, 929, 11, 14883, 9218, 3526, 27914, 11, 31973, 21864, 198, 198, 6738, 1960, 672, 313, 1330, 11160, 20630, 34184, 1187, 198, 6738, 1960, 672, 313, 13, 11250, 3924, 1...
4.068182
44
# coding: utf-8 # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License...
[ 2, 19617, 25, 3384, 69, 12, 23, 198, 198, 2, 49962, 284, 262, 24843, 10442, 5693, 357, 1921, 37, 8, 739, 530, 198, 2, 393, 517, 18920, 5964, 11704, 13, 220, 4091, 262, 28536, 2393, 198, 2, 9387, 351, 428, 670, 329, 3224, 1321, 1...
2.78306
2,987
''' Created on Oct 11, 2017 @author: William Tucker ''' import logging from django.conf import settings from django.contrib.auth import logout, login, get_user_model logger = logging.getLogger(__name__) class LoginMiddleware(): """ Middleware that checks for a valid login in the request and logs the ...
[ 7061, 6, 198, 41972, 319, 2556, 1367, 11, 2177, 198, 198, 31, 9800, 25, 3977, 25951, 198, 7061, 6, 198, 198, 11748, 18931, 198, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 1330, ...
3.082569
109
# coding: utf-8 from sqkb_api_testing.model.case.http_case import HttpCase from sqkb_api_testing.model.case.mysql_case import MySQLCase from sqkb_api_testing.model.case.rpc_case import RPCCase from sqkb_api_testing.model.case.wait_case import WaitCase
[ 2, 19617, 25, 3384, 69, 12, 23, 198, 198, 6738, 19862, 32812, 62, 15042, 62, 33407, 13, 19849, 13, 7442, 13, 4023, 62, 7442, 1330, 367, 29281, 20448, 198, 6738, 19862, 32812, 62, 15042, 62, 33407, 13, 19849, 13, 7442, 13, 28744, 139...
2.769231
91
import os import requests import shutil import tempfile from zipfile import ZipFile, ZIP_DEFLATED from flask import current_app name = 'JMeter' plugin_name = 'jmeter' plugin_type = 'radon.policies.testing.JMeterLoadTest' """ 'SimpleJMeterLoadTest': { 'type': 'radon.policies.testing.JMeterLoadTest', 'properti...
[ 11748, 28686, 198, 11748, 7007, 198, 11748, 4423, 346, 198, 11748, 20218, 7753, 198, 6738, 19974, 7753, 1330, 38636, 8979, 11, 42977, 62, 7206, 3697, 11617, 198, 198, 6738, 42903, 1330, 1459, 62, 1324, 198, 198, 3672, 796, 705, 50229, 2...
2.386454
251
# -- coding: utf-8 -- # xml解析 dom sax from xml.parsers.expat import ParserCreate from urllib import request xml = r'''<?xml version="1.0"?> <ol> <li><a href="/python">Python</a></li> <li><a href="/ruby">Ruby</a></li> </ol> ''' handler = DefaultSaxHandler() parser = ParserCreate() parser.StartElementHandler ...
[ 2, 1377, 19617, 25, 3384, 69, 12, 23, 1377, 198, 198, 2, 35555, 164, 100, 96, 162, 252, 238, 2401, 46909, 198, 198, 6738, 35555, 13, 79, 945, 364, 13, 1069, 8071, 1330, 23042, 263, 16447, 198, 6738, 2956, 297, 571, 1330, 2581, 198...
2.292994
314
'''this module acts as a driver for instrumentation definitions + application''' import logging FLASK_KEY = 'flask' DJANGO_KEY = 'django' GRPC_SERVER_KEY = 'grpc:server' GRPC_CLIENT_KEY = 'grpc:client' POSTGRESQL_KEY = 'postgresql' MYSQL_KEY = 'mysql' REQUESTS_KEY = 'requests' AIOHTTP_CLIENT_KEY = 'aiohttp:client' SU...
[ 7061, 6, 5661, 8265, 6529, 355, 257, 4639, 329, 8875, 341, 17336, 1343, 3586, 7061, 6, 198, 11748, 18931, 198, 198, 3697, 1921, 42, 62, 20373, 796, 705, 2704, 2093, 6, 198, 35028, 1565, 11230, 62, 20373, 796, 705, 28241, 14208, 6, 1...
2.566294
1,252
import json import os
[ 11748, 33918, 198, 11748, 28686, 628 ]
3.833333
6
from . import lstm, transformer
[ 6738, 764, 1330, 300, 301, 76, 11, 47385, 198 ]
3.555556
9
# -*- coding: utf-8 -*- ### BEGIN LICENSE # Copyright (C) 2010 Mads Chr. Olesen <mchro@cs.aau.dk> #This program is free software: you can redistribute it and/or modify it #under the terms of the GNU General Public License version 3, as published #by the Free Software Foundation. # #This program is distributed in the ...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 21017, 347, 43312, 38559, 24290, 198, 2, 15069, 357, 34, 8, 3050, 4627, 82, 49369, 13, 440, 829, 268, 1279, 76, 354, 305, 31, 6359, 13, 64, 559, 13, 34388, 29, 198, ...
2.968932
515
import PySimpleGUI as sg from alarmClock.clock import Clock from alarmClock.settings import dayList, hourList, minuteList, periodList, clocks def newAlarm(): '''Opens window to create a new alarm, and select days in which alarm plays.''' layout = [ [ sg.Combo(hourList, size=(3, 1), key="-H...
[ 11748, 9485, 26437, 40156, 355, 264, 70, 198, 6738, 10436, 44758, 13, 15750, 1330, 21328, 198, 6738, 10436, 44758, 13, 33692, 1330, 1110, 8053, 11, 1711, 8053, 11, 5664, 8053, 11, 2278, 8053, 11, 29906, 198, 198, 4299, 649, 2348, 1670, ...
1.974217
1,086
from bs4 import BeautifulSoup import requests import time if __name__ == "__main__": while True: find_jobs() time_wait = 10 time.sleep(time_wait*60) print(f"waiting {time_wait} minutes")
[ 6738, 275, 82, 19, 1330, 23762, 50, 10486, 198, 11748, 7007, 198, 11748, 640, 628, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 197, 4514, 6407, 25, 198, 197, 197, 19796, 62, 43863, 3419, 198, 197, 197, 2435, 6...
2.605263
76
from pinpayments.tests.models import * from pinpayments.tests.templatetags import *
[ 6738, 6757, 15577, 902, 13, 41989, 13, 27530, 1330, 1635, 198, 6738, 6757, 15577, 902, 13, 41989, 13, 11498, 489, 265, 316, 3775, 1330, 1635, 198 ]
3.230769
26
################################################## # Copyright (c) Xuanyi Dong [GitHub D-X-Y], 2021 # ################################################## from .yaml import load_yaml from .yaml import dump_yaml from .check import check_paper_and_correct_format from .check import check_and_sort_by_date
[ 29113, 14468, 2235, 198, 2, 15069, 357, 66, 8, 33591, 1092, 72, 28831, 685, 38, 270, 16066, 360, 12, 55, 12, 56, 4357, 33448, 1303, 198, 29113, 14468, 2235, 198, 6738, 764, 88, 43695, 1330, 3440, 62, 88, 43695, 198, 6738, 764, 88, ...
3.858974
78
from .io import * from .dataset import *
[ 6738, 764, 952, 1330, 1635, 198, 6738, 764, 19608, 292, 316, 1330, 1635 ]
3.076923
13
ORDER_SIDE_BUY = "BUY" ORDER_SIDE_SELL = "SELL" BITMEX_ORDER_SIDE_BUY = "Buy" BITMEX_ORDER_SIDE_SELL = "Sell"
[ 198, 198, 12532, 1137, 62, 50, 14114, 62, 19499, 56, 796, 366, 19499, 56, 1, 198, 12532, 1137, 62, 50, 14114, 62, 5188, 3069, 796, 366, 5188, 3069, 1, 198, 198, 26094, 44, 6369, 62, 12532, 1137, 62, 50, 14114, 62, 19499, 56, 796, ...
1.723077
65
# TODO: Display an image along with the top 5 classes
[ 2, 16926, 46, 25, 16531, 281, 2939, 1863, 351, 262, 1353, 642, 6097 ]
4.076923
13
from typing import List from fastapi import APIRouter from .tags import tags tags_router = APIRouter() @tags_router.get("/", response_model=List[str]) async def list_tags(): """ List of all tag slugs :return: List[str] """ return tags
[ 6738, 19720, 1330, 7343, 198, 6738, 3049, 15042, 1330, 3486, 4663, 39605, 198, 198, 6738, 764, 31499, 1330, 15940, 628, 198, 31499, 62, 472, 353, 796, 3486, 4663, 39605, 3419, 628, 198, 31, 31499, 62, 472, 353, 13, 1136, 7203, 14, 160...
2.708333
96
#!/usr/bin/env python3 import unittest from tconnectsync.parser.nightscout import NightscoutEntry, InvalidBolusTypeException if __name__ == '__main__': unittest.main()
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 11748, 555, 715, 395, 198, 6738, 256, 8443, 27261, 13, 48610, 13, 3847, 1416, 448, 1330, 5265, 1416, 448, 30150, 11, 17665, 33, 349, 385, 6030, 16922, 628, 198, 361, 11593, ...
2.9
60
import torch import torch.nn.functional as F from torch import nn from model import ResNeXt101
[ 11748, 28034, 198, 11748, 28034, 13, 20471, 13, 45124, 355, 376, 198, 6738, 28034, 1330, 299, 77, 198, 198, 6738, 2746, 1330, 1874, 8199, 55, 83, 8784, 628 ]
3.464286
28
import logging import torchvision from kerosene.config.parsers import YamlConfigurationParser from kerosene.config.trainers import RunConfiguration from kerosene.events import Event from kerosene.events.handlers.console import PrintTrainingStatus, PrintModelTrainersStatus from kerosene.events.handlers.visdom import Pl...
[ 11748, 18931, 198, 198, 11748, 28034, 10178, 198, 6738, 479, 27498, 1734, 13, 11250, 13, 79, 945, 364, 1330, 14063, 75, 38149, 46677, 198, 6738, 479, 27498, 1734, 13, 11250, 13, 27432, 364, 1330, 5660, 38149, 198, 6738, 479, 27498, 1734...
2.931359
743
# Copyright 2016 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or ...
[ 2, 15069, 1584, 3012, 3457, 13, 1439, 6923, 33876, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, ...
2.554928
1,948
#!/usr/bin/env python3
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 628 ]
2.4
10
# Copyright 2017 Google Inc. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or a...
[ 2, 15069, 2177, 3012, 3457, 13, 1439, 6923, 33876, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13789, ...
2.732433
12,509
#!/usr/bin/env python # encoding: utf-8 """ !----------------------------------------------------------------------- ! HDF5 and XDMF routines for creating output files for VisIt. !----------------------------------------------------------------------- """ import os,sys import h5py from numpy import * # Write a 2D HD...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 21004, 25, 3384, 69, 12, 23, 198, 198, 37811, 220, 198, 0, 10097, 26866, 198, 0, 5572, 37, 20, 290, 1395, 23127, 37, 31878, 329, 4441, 5072, 3696, 329, 6911, 1026, 13, 198, 0, ...
3.100917
218
# -*- coding: utf-8 -*- # Soft NMS for rotated rectangle, cpu implementation. # Author: Gongjie Zhang # GongjieZhang@ntu.edu.sg # or GongjieZhang007@gmail.com import numpy as np import cv2 def softnms_rotate_cpu(boxes, scores, iou_threshold, final_threshold=0.001): """ :param boxes: format [x_c, y_c, w, h, t...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 8297, 399, 5653, 329, 38375, 35991, 11, 42804, 7822, 13, 198, 2, 6434, 25, 47142, 73, 494, 19439, 220, 198, 2, 47142, 73, 494, 57, 33255, 31, 429, 84, 13, 15532, ...
1.957699
1,773
# -------------- #Header files import pandas as pd import numpy as np import matplotlib.pyplot as plt #path of the data file- path data = pd.read_csv(path) #Code starts here data['Gender'] = data['Gender'].replace('-','Agender') #print(data['Gender']) gender_count = data['Gender'].value_counts() #print(g...
[ 2, 220, 26171, 198, 2, 39681, 3696, 201, 198, 11748, 19798, 292, 355, 279, 67, 201, 198, 11748, 299, 32152, 355, 45941, 201, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 201, 198, 201, 198, 201, 198, 2, 6978, 286, ...
2.509868
912
import os from setuptools import setup here = os.path.abspath(os.path.dirname(__file__)) meta_info = {} with open(os.path.join(here, 'jsons', '_package_info.py'), 'r') as f: exec(f.read(), meta_info) with open('README.md', 'r') as f: long_description = f.read() setup( name=meta_info['__title__'], ve...
[ 11748, 28686, 198, 6738, 900, 37623, 10141, 1330, 9058, 628, 198, 1456, 796, 28686, 13, 6978, 13, 397, 2777, 776, 7, 418, 13, 6978, 13, 15908, 3672, 7, 834, 7753, 834, 4008, 198, 28961, 62, 10951, 796, 23884, 198, 4480, 1280, 7, 418...
2.201964
713
from .eLABJournalPager import *
[ 6738, 764, 68, 48780, 25296, 47, 3536, 1330, 1635, 198 ]
3.2
10
# Uses python3 import sys def sort_list(left, right): '''MergeSort(𝐴) returns a sorted array 𝐴 and the number of inversions in 𝐴.''' sort_a = list() count = 0 while left and right: first_l = left[0] first_r = right[0] if first_l <= first_r: sort_a.append(first_l...
[ 2, 36965, 21015, 18, 198, 11748, 25064, 198, 198, 4299, 3297, 62, 4868, 7, 9464, 11, 826, 2599, 198, 220, 220, 220, 705, 7061, 13102, 469, 42758, 7, 47728, 238, 112, 8, 5860, 257, 23243, 7177, 220, 47728, 238, 112, 290, 262, 1271, ...
2.092888
689
from __future__ import print_function, division from pdb import set_trace import pandas as pd from sklearn.model_selection import StratifiedKFold from sklearn.model_selection import LeaveOneOut from itertools import islice
[ 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 11, 7297, 201, 198, 201, 198, 6738, 279, 9945, 1330, 900, 62, 40546, 201, 198, 201, 198, 11748, 19798, 292, 355, 279, 67, 201, 198, 6738, 1341, 35720, 13, 19849, 62, 49283, 1330, 29186, ...
3.050633
79
import torch import argparse import os import logging import torch.nn as nn import torch.optim as optim import albumentations as A from albumentations.pytorch import ToTensorV2 from cnn.evaluate import evaluate, prettify_eval from cnn.dataset import Mit67Dataset import json from torch.utils.tensorboard import SummaryWr...
[ 11748, 28034, 198, 11748, 1822, 29572, 198, 11748, 28686, 198, 11748, 18931, 198, 11748, 28034, 13, 20471, 355, 299, 77, 198, 11748, 28034, 13, 40085, 355, 6436, 198, 11748, 435, 65, 1713, 602, 355, 317, 198, 6738, 435, 65, 1713, 602, ...
3.269504
141
# ------------------------------------------------------------------------------ # MIT License # # Copyright (c) 2019-2021 ThatRedKite # # 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 with...
[ 2, 16529, 26171, 198, 2, 220, 17168, 13789, 198, 2, 198, 2, 220, 15069, 357, 66, 8, 13130, 12, 1238, 2481, 1320, 7738, 42, 578, 198, 2, 198, 2, 220, 2448, 3411, 318, 29376, 7520, 11, 1479, 286, 3877, 11, 284, 597, 1048, 16727, 2...
2.922006
1,077
from .models import S3Parquetifier
[ 6738, 764, 27530, 1330, 311, 18, 10044, 21108, 7483, 198 ]
3.5
10
from pyspark import SparkContext, SparkConf from pyspark.sql import SQLContext from pyspark.sql.types import * from pyspark.sql.functions import udf from pyspark.sql.functions import col from pyspark.sql.types import StringType, DoubleType, IntegerType from abbreviations_dict import tofullname, toevent from operator im...
[ 6738, 279, 893, 20928, 1330, 17732, 21947, 11, 17732, 18546, 198, 6738, 279, 893, 20928, 13, 25410, 1330, 16363, 21947, 198, 6738, 279, 893, 20928, 13, 25410, 13, 19199, 1330, 1635, 198, 6738, 279, 893, 20928, 13, 25410, 13, 12543, 2733...
1.986376
1,835
SEND_MESSAGE_DATASET_TRAIN = [ { "query": "Text mom I love her", "actions": [ { "action": "SendMessage", "params": { "recipient": "mom", "body": "I love her", "application": "???" ...
[ 50, 10619, 62, 44, 1546, 4090, 8264, 62, 35, 1404, 1921, 2767, 62, 51, 3861, 1268, 796, 685, 198, 220, 220, 220, 1391, 198, 220, 220, 220, 220, 220, 220, 220, 366, 22766, 1298, 366, 8206, 1995, 314, 1842, 607, 1600, 198, 220, 220,...
1.802109
2,845
#!/usr/bin/env python ''' Use geomeTRIC library to optimize the molecular geometry. ''' from pyscf import gto, scf from pyscf.geomopt.geometric_solver import optimize mol = gto.M(atom='N 0 0 0; N 0 0 1.2', basis='ccpvdz') mf = scf.RHF(mol) # # geometry optimization for HF # mol_eq = optimize(mf) print(mol_eq.atom_c...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 7061, 6, 198, 11041, 4903, 462, 5446, 2149, 5888, 284, 27183, 262, 18955, 22939, 13, 198, 7061, 6, 198, 198, 6738, 279, 893, 12993, 1330, 308, 1462, 11, 629, 69, 198, 6738, 279,...
2.175385
325
# -*- coding: utf-8 -*- # # Copyright (C) 2010-2016 PPMessage. # Guijin Ding, dingguijin@gmail.com. # All rights reserved. # # core/utils/randomidenticon.py # import os import json import logging IDENTICON_PPMESSAGE_STORE = True _global_random_identicon_list = None if __name__ == "__main__": print(random_identi...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 198, 2, 15069, 357, 34, 8, 3050, 12, 5304, 350, 5868, 7589, 13, 198, 2, 1962, 2926, 259, 46980, 11, 44852, 5162, 2926, 259, 31, 14816, 13, 785, 13, 198, 2, 1439...
2.554745
137
var = "Good" show() print("outside function var1 is ", var1) print("var is ",var)
[ 7785, 796, 366, 10248, 1, 201, 198, 201, 198, 12860, 3419, 201, 198, 4798, 7203, 43435, 2163, 1401, 16, 318, 33172, 1401, 16, 8, 201, 198, 4798, 7203, 7785, 318, 33172, 7785, 8, 201, 198, 220, 220, 220, 220, 201, 198 ]
2.292683
41
"""Module that implements control service.""" from multiprocessing import Process import asyncio import json import zmq import zmq.asyncio from npc_engine import services from npc_engine.server.metadata_manager import MetadataManager from jsonrpc import JSONRPCResponseManager, Dispatcher from loguru import l...
[ 37811, 26796, 326, 23986, 1630, 2139, 526, 15931, 201, 198, 6738, 18540, 305, 919, 278, 1330, 10854, 201, 198, 11748, 30351, 952, 201, 198, 11748, 33918, 201, 198, 11748, 1976, 76, 80, 201, 198, 11748, 1976, 76, 80, 13, 292, 13361, 95...
2.211538
3,900
#!/usr/bin/env python """ Vagrant external inventory script. Automatically finds the IP of the booted vagrant vm(s), and returns it under the host group 'vagrant' Example Vagrant configuration using this script: config.vm.provision :ansible do |ansible| ansible.playbook = "./provision/your_playbook.yml" ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 37811, 198, 53, 363, 5250, 7097, 13184, 4226, 13, 17406, 4142, 7228, 262, 6101, 286, 262, 48696, 14334, 5250, 45887, 7, 82, 828, 290, 198, 7783, 82, 340, 739, 262, 2583, 1448, 705, 2...
2.960159
1,255
# Copyright (c) 2021 PaddlePaddle Authors. All Rights Reserved. # Copyright (c) 2020 TsinghuaAI Authors. # # 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...
[ 2, 15069, 357, 66, 8, 33448, 350, 37382, 47, 37382, 46665, 13, 1439, 6923, 33876, 13, 198, 2, 15069, 357, 66, 8, 12131, 309, 12215, 33061, 20185, 46665, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 35...
2.807554
556
""" DotKnot: software for RNA pseudoknot prediction Copyright (C) 2010-2011 Jana Sperschneider This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the L...
[ 37811, 201, 198, 220, 220, 220, 22875, 42, 1662, 25, 3788, 329, 25897, 25038, 482, 1662, 17724, 201, 198, 220, 220, 220, 15069, 357, 34, 8, 3050, 12, 9804, 449, 2271, 1338, 364, 354, 710, 1304, 197, 201, 198, 201, 198, 220, 220, 2...
1.930415
8,910
import re, os def do_get_light_config(value, TelegramResponder): """Light? - Gives you the possible light configurations""" for val in value.values(): if val.strip() == "Light?": if ( "433MHz_Transiever" in TelegramResponder.main.default_values_dict["setting...
[ 11748, 302, 11, 28686, 628, 198, 4299, 466, 62, 1136, 62, 2971, 62, 11250, 7, 8367, 11, 50203, 19309, 8623, 2599, 198, 220, 220, 220, 37227, 15047, 30, 532, 402, 1083, 345, 262, 1744, 1657, 25412, 37811, 198, 220, 220, 220, 329, 118...
1.758779
3,275
#------------------------------------------------------------------------------- # Name: Raspberry Pi Socket Client # Purpose: # # Author: Vaibhav # # Created: 20/08/2014 # Copyright: (c) Vaibhav 2014 # Licence: <your licence> #-------------------------------------------------------------...
[ 2, 10097, 24305, 201, 198, 2, 6530, 25, 220, 220, 220, 220, 220, 220, 220, 24244, 13993, 47068, 20985, 201, 198, 2, 32039, 25, 201, 198, 2, 201, 198, 2, 6434, 25, 220, 220, 220, 220, 220, 17668, 571, 71, 615, 201, 198, 2, 201, ...
2.817308
208
import copy import getpass import numpy as np import pickle import time import shutil import subprocess import os import random import sys from FGBconstants import * import game_engine, game_graphics, telegram_bot, report channel_name = '@FaedoGuerraBotChannel' print('Username UZ: ', end = '') username = input() pa...
[ 11748, 4866, 198, 11748, 651, 6603, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 2298, 293, 198, 11748, 640, 198, 11748, 4423, 346, 198, 11748, 850, 14681, 198, 11748, 28686, 198, 11748, 4738, 198, 11748, 25064, 198, 198, 6738, 376, ...
2.714567
508
__author__ = 'ziyan.yin' __version__ = '1.0.2'
[ 834, 9800, 834, 796, 705, 17027, 4121, 13, 88, 259, 6, 198, 834, 9641, 834, 796, 705, 16, 13, 15, 13, 17, 6, 198 ]
1.958333
24
import numpy as np import os from bfieldtools import kicad_io from bfieldtools.utils import load_example_mesh from .test_mesh_conductor import _fake_mesh_conductor, _fake_streamfunction import pytest
[ 11748, 299, 32152, 355, 45941, 198, 11748, 28686, 198, 6738, 275, 3245, 31391, 1330, 479, 291, 324, 62, 952, 198, 6738, 275, 3245, 31391, 13, 26791, 1330, 3440, 62, 20688, 62, 76, 5069, 198, 198, 6738, 764, 9288, 62, 76, 5069, 62, 1...
3.123077
65
"""Unsorted Table Map Implementation.""" from MapBase import MapBase class UnsortedTableMap(MapBase): """ Class that relies on storing key-value pairs in arbitrary order within a Python list. """ def __init__(self): """Initialize the unsorted list.""" self._table = [] def __getitem__(self, k):...
[ 37811, 3118, 82, 9741, 8655, 9347, 46333, 526, 15931, 198, 6738, 9347, 14881, 1330, 9347, 14881, 198, 198, 4871, 791, 82, 9741, 10962, 13912, 7, 13912, 14881, 2599, 198, 220, 37227, 198, 220, 5016, 326, 16507, 319, 23069, 1994, 12, 8367...
2.485643
801
# coding=utf8 import warnings import numpy as np class AbstractSVMKernel(object): ''' 核函数类的基类, 计算核函数与内积 ''' class LinearKernel(AbstractSVMKernel): ''' 线性核函数类 np.dot(xi.T, xj) ''' def __call__(self, xi, xj): ''' 线性核内积 np.dot(xi, xj.T) ...
[ 2, 19617, 28, 40477, 23, 201, 198, 11748, 14601, 201, 198, 11748, 299, 32152, 355, 45941, 201, 198, 201, 198, 4871, 27741, 50, 15996, 42, 7948, 7, 15252, 2599, 201, 198, 220, 220, 220, 705, 7061, 201, 198, 220, 220, 220, 10545, 254,...
1.474989
2,219
from datetime import datetime from blog import db
[ 6738, 4818, 8079, 1330, 4818, 8079, 198, 198, 6738, 4130, 1330, 20613, 628, 198 ]
3.785714
14
""" Module for managing the IRIS dataset """ import numpy as np from .Dataset import Dataset DATASET_SIZE = 15 class TwoByTwoLines(Dataset): """ This class manage the dataset , properties of the datasets are uniquely determined by the params dictionary It compares the parameters and complete t...
[ 37811, 198, 26796, 329, 11149, 262, 14826, 1797, 27039, 198, 37811, 198, 198, 11748, 299, 32152, 355, 45941, 198, 198, 6738, 764, 27354, 292, 316, 1330, 16092, 292, 316, 198, 198, 35, 1404, 1921, 2767, 62, 33489, 796, 1315, 628, 198, ...
2.525667
487
import atexit from IPython.display import display from ipywidgets.widgets import * from traitlets import Unicode, List, Bool, Int, Dict from qcodes.widgets import display_auto
[ 11748, 379, 37023, 198, 6738, 6101, 7535, 13, 13812, 1330, 3359, 198, 6738, 20966, 88, 28029, 11407, 13, 28029, 11407, 1330, 1635, 198, 6738, 1291, 2578, 912, 1330, 34371, 11, 7343, 11, 347, 970, 11, 2558, 11, 360, 713, 198, 198, 6738...
3.396226
53
N = int(input()) lang = set(input().split()) one = set(lang) alll = set(lang) for i in range(N - 1): lang = set(input().split()) one |= lang alll &= lang print(alll) print(one)
[ 45, 796, 493, 7, 15414, 28955, 198, 17204, 796, 900, 7, 15414, 22446, 35312, 28955, 198, 505, 796, 900, 7, 17204, 8, 198, 282, 297, 796, 900, 7, 17204, 8, 198, 1640, 1312, 287, 2837, 7, 45, 532, 352, 2599, 198, 220, 220, 220, 42...
2.333333
81
# -*- coding: utf-8 -*- # Copyright© 1986-2018 Altair Engineering Inc. """Module with the pkr environment""" import yaml from builtins import object from .utils import HashableDict, ensure_definition_matches, get_pkr_path, merge ENV_FOLDER = 'env' class Environment(object): """Class for loading and holding pk...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 15069, 16224, 12113, 12, 7908, 12344, 958, 14044, 3457, 13, 198, 198, 37811, 26796, 351, 262, 279, 38584, 2858, 37811, 198, 198, 11748, 331, 43695, 198, 6738, 3170, 1...
2.34647
1,827
# TODO: write proper tests if __name__ == "__main__": test_reconstruction()
[ 2, 16926, 46, 25, 3551, 1774, 5254, 628, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 628, 220, 220, 220, 1332, 62, 260, 9979, 2762, 3419, 198 ]
2.766667
30
from nose.tools import eq_ from pepdata.amino_acid_alphabet import ( canonical_amino_acids, canonical_amino_acid_letters, extended_amino_acids, extended_amino_acid_letters, )
[ 6738, 9686, 13, 31391, 1330, 37430, 62, 198, 6738, 279, 538, 7890, 13, 321, 2879, 62, 46309, 62, 17307, 8380, 1330, 357, 198, 220, 220, 220, 40091, 62, 321, 2879, 62, 330, 2340, 11, 198, 220, 220, 220, 40091, 62, 321, 2879, 62, 46...
2.546667
75
# -*- coding: utf-8 -*- """ tuesmon_ncurses.ui.views.projects ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ """ import functools import urwid from tuesmon_ncurses.ui.widgets import generic, projects from . import base from .backlog import ProjectBacklogSubView from .milestones import ProjectMilestoneSubView from .issues import...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 37811, 198, 83, 947, 2144, 62, 10782, 46998, 13, 9019, 13, 33571, 13, 42068, 198, 27156, 15116, 8728, 4907, 93, 198, 37811, 198, 198, 11748, 1257, 310, 10141, 198, ...
3.293103
116
MonoUpnpPackage ()
[ 198, 9069, 78, 4933, 37659, 27813, 7499, 198 ]
2.5
8
import ftplib
[ 11748, 10117, 489, 571, 198, 220, 220, 220, 220, 220, 220, 220, 220 ]
1.692308
13
# coding: UTF-8 from FreeCAD import Console, Placement, Rotation, Vector import Part import Sketcher from Legify.Common import *
[ 2, 19617, 25, 41002, 12, 23, 198, 198, 6738, 3232, 34, 2885, 1330, 24371, 11, 1345, 5592, 11, 371, 14221, 11, 20650, 198, 11748, 2142, 198, 11748, 3661, 316, 2044, 198, 6738, 3564, 1958, 13, 17227, 1330, 1635, 628 ]
3.358974
39
import time from poium.common import logging from poium.settings import Setting from poium.processing import processing, screenshots_name from poium.common.assert_des import insert_assert LOCATOR_LIST = [ "id", "name", "text", "nameContains", "label", "xpath", "labelContains", "classNa...
[ 11748, 640, 198, 6738, 745, 1505, 13, 11321, 1330, 18931, 198, 6738, 745, 1505, 13, 33692, 1330, 25700, 198, 6738, 745, 1505, 13, 36948, 1330, 7587, 11, 23322, 62, 3672, 198, 6738, 745, 1505, 13, 11321, 13, 30493, 62, 8906, 1330, 7550...
2.708955
134
import tensorflow as tf import numpy as np from zfit import ztypes from zfit_benchmark.timer import Timer import matplotlib.pyplot as plt import seaborn as sns import pandas as pd import inspect from decimal import Decimal from scipy.interpolate import UnivariateSpline from tf_kde.benchmark import distributions as ava...
[ 11748, 11192, 273, 11125, 355, 48700, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 1976, 11147, 1330, 1976, 19199, 198, 6738, 1976, 11147, 62, 26968, 4102, 13, 45016, 1330, 5045, 263, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355,...
2.774373
359
if __name__ == '__main__': print(MyClass.__dict__['var3']) clzz = MyClass() clzz.my_method()
[ 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 3601, 7, 3666, 9487, 13, 834, 11600, 834, 17816, 7785, 18, 6, 12962, 628, 220, 220, 220, 537, 3019, 796, 2011, 9487, 3419, 198, 220, 220, 220, 537, ...
2.14
50
from __future__ import absolute_import from changes.api.base import APIView from changes.models.node import Node
[ 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 198, 198, 6738, 2458, 13, 15042, 13, 8692, 1330, 3486, 3824, 769, 198, 6738, 2458, 13, 27530, 13, 17440, 1330, 19081, 628 ]
3.833333
30
import numpy as np from .single_vec_env import SingleVecEnv import gym.vector from gym.vector.utils import concatenate, iterate, create_empty_array from gym.spaces import Discrete @iterate.register(Discrete)
[ 11748, 299, 32152, 355, 45941, 198, 6738, 764, 29762, 62, 35138, 62, 24330, 1330, 14206, 53, 721, 4834, 85, 198, 11748, 11550, 13, 31364, 198, 6738, 11550, 13, 31364, 13, 26791, 1330, 1673, 36686, 378, 11, 11629, 378, 11, 2251, 62, 28...
3.212121
66
import os from collections import defaultdict full_names = { 'AR': 'Arabic', 'BG': 'Bulgarian', 'CH': 'Mandarin', 'CH_char': 'Mandarin', 'EN': 'English', 'WU': 'Cantonese', 'CR': 'Croatian', ...
[ 11748, 28686, 198, 6738, 17268, 1330, 4277, 11600, 198, 198, 12853, 62, 14933, 796, 1391, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 705, 1503, 10354, 705, 31602, 291, 3256, 198, 220, 220, 220, 2...
1.925908
6,141
# -*- coding: utf-8 -*- # --- # jupyter: # jupytext: # formats: ipynb,py,md # text_representation: # extension: .py # format_name: light # format_version: '1.5' # jupytext_version: 1.13.3 # kernelspec: # display_name: Python 3 (ipykernel) # language: python # name: python...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 11420, 198, 2, 474, 929, 88, 353, 25, 198, 2, 220, 220, 474, 929, 88, 5239, 25, 198, 2, 220, 220, 220, 220, 17519, 25, 20966, 2047, 65, 11, 9078, 11, 9132, 19...
2.574682
7,244
# Generate a graph with: # Vertices V = {"a", "b", "c", "d", "e"} # Edges E = {"ab", "ac", "bd", "cd", "de"} # Create the dictionary with graph elements graph_elements = { "a" : ["b","c"], "b" : ["a", "d"], "c" : ["a", "d"], "d" : ["e"], "e" : ["d"] ...
[ 2, 2980, 378, 257, 4823, 351, 25, 198, 2, 24417, 1063, 198, 53, 796, 19779, 64, 1600, 366, 65, 1600, 366, 66, 1600, 366, 67, 1600, 366, 68, 20662, 198, 2, 1717, 3212, 198, 36, 796, 19779, 397, 1600, 366, 330, 1600, 366, 17457, 1...
1.755486
319
import discord from discord.ext import commands import scrimdb as db import interactions
[ 11748, 36446, 198, 6738, 36446, 13, 2302, 1330, 9729, 198, 11748, 32157, 9945, 355, 20613, 198, 11748, 12213, 628, 198 ]
4.55
20
import sys import argparse import os import cv2 import glob import numpy as np import torch from PIL import Image import gc from torch.profiler import profile, record_function, ProfilerActivity import time sys.path.append('core') from core.raft import RAFT from core.utils import flow_viz from core.utils.utils impor...
[ 11748, 25064, 198, 198, 11748, 1822, 29572, 198, 11748, 28686, 198, 11748, 269, 85, 17, 198, 11748, 15095, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 28034, 198, 6738, 350, 4146, 1330, 7412, 198, 11748, 308, 66, 198, 6738, 28034, 1...
2.885593
472
import logging import shutil import os.path from jinja2 import Environment, PackageLoader from . import utils import ostester env = Environment(loader=PackageLoader('ostester', 'templates'), trim_blocks=True, lstrip_blocks=True) env.filters['header_to_function_name'] = utils.heade...
[ 11748, 18931, 198, 11748, 4423, 346, 198, 11748, 28686, 13, 6978, 198, 198, 6738, 474, 259, 6592, 17, 1330, 9344, 11, 15717, 17401, 198, 198, 6738, 764, 1330, 3384, 4487, 198, 11748, 23619, 7834, 198, 198, 24330, 796, 9344, 7, 29356, ...
2.607407
405
import numpy as np from extra_keras_metrics import (get_complete_binary_metrics, get_minimal_multiclass_metrics) from tensorflow.keras.layers import Dense from tensorflow.keras.models import Sequential def test_binary_model_run(): """Test that all metrics actually work when used w...
[ 11748, 299, 32152, 355, 45941, 198, 6738, 3131, 62, 6122, 292, 62, 4164, 10466, 1330, 357, 1136, 62, 20751, 62, 39491, 62, 4164, 10466, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, ...
2.282101
514
import datetime from Other.SharedResources import db, g_user
[ 11748, 4818, 8079, 201, 198, 6738, 3819, 13, 2484, 1144, 33236, 1330, 20613, 11, 308, 62, 7220, 201 ]
3.444444
18
__version__ = "1.0.1" from .dirty_mnist import *
[ 834, 9641, 834, 796, 366, 16, 13, 15, 13, 16, 1, 198, 198, 6738, 764, 49075, 62, 10295, 396, 1330, 1635, 628 ]
2.318182
22
import os import cv2 as cv import numpy as np if __name__ == "__main__": compute_finger('fingerprints/finger-0', 'fingerprints/clear.png', 'fingerprints/finger-0.npz')
[ 11748, 28686, 198, 198, 11748, 269, 85, 17, 355, 269, 85, 198, 11748, 299, 32152, 355, 45941, 628, 198, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 24061, 62, 35461, 10786, 35461, 17190, 14, 35461...
2.321429
84
import torch import torch.nn as nn
[ 11748, 28034, 198, 11748, 28034, 13, 20471, 355, 299, 77, 628 ]
3.272727
11
# Generated by Django 3.2.7 on 2021-09-17 02:10 import dashboard.models import django.core.validators from django.db import migrations, models
[ 2, 2980, 515, 416, 37770, 513, 13, 17, 13, 22, 319, 33448, 12, 2931, 12, 1558, 7816, 25, 940, 198, 198, 11748, 30415, 13, 27530, 198, 11748, 42625, 14208, 13, 7295, 13, 12102, 2024, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 60...
3.152174
46