content
stringlengths
1
1.04M
input_ids
listlengths
1
774k
ratio_char_token
float64
0.38
22.9
token_count
int64
1
774k
from ksc.rewrites import RuleSet from ksc.rewrites_prelude import constant_folding_rules from ksc.parse_ks import parse_expr_string from ksc.type_propagate import type_propagate_decls
[ 6738, 479, 1416, 13, 1809, 23156, 1330, 14330, 7248, 198, 6738, 479, 1416, 13, 1809, 23156, 62, 79, 2411, 2507, 1330, 6937, 62, 11379, 278, 62, 38785, 198, 6738, 479, 1416, 13, 29572, 62, 591, 1330, 21136, 62, 31937, 62, 8841, 198, ...
3.1
60
import numpy as np import torch from .general import pol2cart
[ 11748, 299, 32152, 355, 45941, 198, 11748, 28034, 198, 198, 6738, 764, 24622, 1330, 755, 17, 26674, 628, 198 ]
3.421053
19
""" :mod:`torch.distributed.optim` exposes DistributedOptimizer, which takes a list of remote parameters (:class:`~torch.distributed.rpc.RRef`) and runs the optimizer locally on the workers where the parameters live. The distributed optimizer can use any of the local optimizer :ref:`optimizer-algorithms` to apply...
[ 37811, 201, 198, 25, 4666, 25, 63, 13165, 354, 13, 17080, 6169, 13, 40085, 63, 32142, 4307, 6169, 27871, 320, 7509, 11, 543, 2753, 257, 1351, 201, 198, 1659, 6569, 10007, 357, 25, 4871, 25, 63, 93, 13165, 354, 13, 17080, 6169, 13, ...
3.35
120
from pathlib import Path import os import pypandoc import settings
[ 6738, 3108, 8019, 1330, 10644, 198, 11748, 28686, 198, 11748, 279, 4464, 392, 420, 198, 11748, 6460, 628 ]
3.777778
18
import sys import os sys.path.append(os.getcwd()) import pyschedcl as fw import logging import argparse import json #import sys import time import datetime #import plotly.plotly as py from os import listdir from os.path import isfile, join import matplotlib.pyplot as plt import networkx as nx import csv import random i...
[ 11748, 25064, 198, 11748, 28686, 198, 17597, 13, 6978, 13, 33295, 7, 418, 13, 1136, 66, 16993, 28955, 198, 11748, 279, 893, 1740, 565, 355, 277, 86, 198, 11748, 18931, 198, 11748, 1822, 29572, 198, 11748, 33918, 198, 2, 11748, 25064, ...
1.899987
7,539
import time import traceback import pymysql.cursors import pymysql import queue import threading import logging from lrabbit_scrapy.common_utils.config_helper import get_mysql_config, get_config_path logger = logging.Logger(name="mysql connect") class GetConnectionFromPoolError(Exception): "...
[ 11748, 640, 201, 198, 11748, 12854, 1891, 201, 198, 11748, 279, 4948, 893, 13976, 13, 66, 1834, 669, 201, 198, 11748, 279, 4948, 893, 13976, 201, 198, 11748, 16834, 201, 198, 11748, 4704, 278, 201, 198, 11748, 18931, 201, 198, 6738, 3...
2.839744
156
import json import redis import xlwt from celery import uuid from celery_tasks import settings COLUMNS = ('Status', 'Result', 'Date done', 'Task UUID', 'Author', 'Name', 'Created date') FIRST_ROW = 0
[ 11748, 33918, 198, 11748, 2266, 271, 198, 11748, 2124, 75, 46569, 198, 198, 6738, 18725, 1924, 1330, 334, 27112, 198, 6738, 18725, 1924, 62, 83, 6791, 1330, 6460, 628, 198, 25154, 5883, 8035, 796, 19203, 19580, 3256, 705, 23004, 3256, 7...
2.7
80
# -*- coding: utf-8 -*- __author__ = 'luckydonald' from . import encoding from .utils import escape # validate_input from .exceptions import ArgumentParseError from os import path # file checking. import logging logger = logging.getLogger(__name__) class UnescapedUnicodeString(Argument): """ Used for unicodes s...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 834, 9800, 834, 796, 705, 46708, 5173, 261, 1940, 6, 198, 198, 6738, 764, 1330, 21004, 198, 6738, 764, 26791, 1330, 6654, 220, 1303, 26571, 62, 15414, 198, 6738, 764, ...
3.140244
164
import pytest from callbaker.functions import callback_from_info @pytest.mark.parametrize("data", [None, False, 234, "str"])
[ 11748, 12972, 9288, 198, 198, 6738, 869, 65, 3110, 13, 12543, 2733, 1330, 23838, 62, 6738, 62, 10951, 628, 198, 31, 9078, 9288, 13, 4102, 13, 17143, 316, 380, 2736, 7203, 7890, 1600, 685, 14202, 11, 10352, 11, 34323, 11, 366, 2536, ...
2.847826
46
import torch torch.manual_seed(10) torch.cuda.manual_seed_all(10) import torch.nn as nn import torch.autograd as autograd import sys sys.path.append("../") from extension.arap.cuda.arap import Arap from extension.grad_arap.cuda.arap import ArapGrad from RegArap import ARAP as ArapReg #from extension.isometric.cuda.iso...
[ 11748, 28034, 198, 13165, 354, 13, 805, 723, 62, 28826, 7, 940, 8, 198, 13165, 354, 13, 66, 15339, 13, 805, 723, 62, 28826, 62, 439, 7, 940, 8, 198, 11748, 28034, 13, 20471, 355, 299, 77, 198, 11748, 28034, 13, 2306, 519, 6335, ...
2.837662
308
from model import Student #this class stores every student in a list
[ 6738, 2746, 1330, 13613, 201, 198, 201, 198, 2, 5661, 1398, 7000, 790, 3710, 287, 257, 1351, 201, 198, 201, 198 ]
3.571429
21
"""The tests for the command line notification platform.""" from __future__ import annotations import os import subprocess import tempfile from typing import Any from unittest.mock import patch from homeassistant import setup from homeassistant.components.notify import DOMAIN from homeassistant.helpers.typing import ...
[ 37811, 464, 5254, 329, 262, 3141, 1627, 14483, 3859, 526, 15931, 198, 6738, 11593, 37443, 834, 1330, 37647, 198, 198, 11748, 28686, 198, 11748, 850, 14681, 198, 11748, 20218, 7753, 198, 6738, 19720, 1330, 4377, 198, 6738, 555, 715, 395, ...
2.451591
1,477
#! /usr/bin/env python3 # # 2019-06-15 # Colton Grainger # CC-0 Public Domain """ Assign UUIDs to all files (assumed to be pages) under the directory `import/data` in the rda-image-archive repo. """ # fakesection: to generate semi-sequential UUIDs import time from random import getrandbits from uuid import uuid1, ...
[ 2, 0, 1220, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 198, 2, 13130, 12, 3312, 12, 1314, 198, 2, 1623, 1122, 7037, 3889, 220, 198, 2, 12624, 12, 15, 5094, 20021, 198, 198, 37811, 198, 8021, 570, 471, 27586, 82, 284, 477, 36...
2.815018
546
"""Runs baseline algorithms over real-estate input matrix and generates images. source /home/calypso/work/research/current/denise/code_src/setup_env.sh export LD_PRELOAD=/usr/local/MATLAB/R2018b/sys/os/glnxa64/libstdc++.so.6.0.22 python3.6 run_realestate.py """ from absl import app from absl import flags import nump...
[ 37811, 10987, 82, 14805, 16113, 625, 1103, 12, 44146, 5128, 17593, 290, 18616, 4263, 13, 198, 198, 10459, 1220, 11195, 14, 66, 3400, 79, 568, 14, 1818, 14, 34033, 14, 14421, 14, 6559, 786, 14, 8189, 62, 10677, 14, 40406, 62, 24330, ...
2.268182
440
from sqlalchemy.engine.url import URL from rabbitai.db_engine_specs.trino import TrinoEngineSpec from tests.db_engine_specs.base_tests import TestDbEngineSpec
[ 6738, 44161, 282, 26599, 13, 18392, 13, 6371, 1330, 10289, 198, 198, 6738, 22746, 1872, 13, 9945, 62, 18392, 62, 4125, 6359, 13, 2213, 2879, 1330, 833, 2879, 13798, 22882, 198, 6738, 5254, 13, 9945, 62, 18392, 62, 4125, 6359, 13, 8692...
3.22
50
import json import logging from app.objects.secondclass.c_fact import Fact from app.objects.secondclass.c_relationship import Relationship from app.utility.base_parser import BaseParser
[ 11748, 33918, 201, 198, 11748, 18931, 201, 198, 201, 198, 6738, 598, 13, 48205, 13, 12227, 4871, 13, 66, 62, 22584, 1330, 19020, 201, 198, 6738, 598, 13, 48205, 13, 12227, 4871, 13, 66, 62, 39468, 1056, 1330, 39771, 201, 198, 6738, ...
3.421053
57
inputstatus = [ "Busy plotting Graphs", "Rendering Equation...", "Matplotlib is awesome!", "with Mathematics", "with Graphs", "with lines, parabolas and circles", "Hmmmm... what to plot today?", "Star me on GitHub pls! >github", "Do i make you feel like plotting some graphs?", ...
[ 15414, 13376, 796, 220, 220, 685, 198, 220, 220, 220, 366, 16286, 88, 29353, 29681, 82, 1600, 198, 220, 220, 220, 366, 49, 437, 1586, 7889, 341, 9313, 11, 198, 220, 220, 220, 366, 19044, 29487, 8019, 318, 7427, 40754, 198, 220, 220,...
3.003279
1,830
#!/usr/bin/env python # Copyright 2013 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 ...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 15069, 2211, 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, 7...
3.417197
314
import json from abc import ABC class JSONSerializable(ABC): """ Base class for when you want an object to be serializable in a json format. """ def __str__(self): """ Returns the json string representation of the object. :return: str """ return json.dumps(sel...
[ 11748, 33918, 198, 6738, 450, 66, 1330, 9738, 628, 198, 4871, 19449, 32634, 13821, 7, 24694, 2599, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 7308, 1398, 329, 618, 345, 765, 281, 2134, 284, 307, 11389, 13821, 287, 257, 33918, 5794...
2.638889
252
from django.contrib import admin from django.db.models import lookups import django.contrib.staticfiles from django.db.models.expressions import F, Value from django.utils.html import format_html from django.utils.http import urlencode from django.urls import reverse from django.db.models.aggregates import Count, Sum...
[ 198, 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 6738, 42625, 14208, 13, 9945, 13, 27530, 1330, 804, 4739, 198, 11748, 42625, 14208, 13, 3642, 822, 13, 12708, 16624, 220, 198, 6738, 42625, 14208, 13, 9945, 13, 27530, 13, 42712,...
3.248555
173
import sys class BaseDevice(object): """ micropython board interface This module provides a MpyDevice class to communicate with a micropython device. It allows to execute python code remote on the device. .. code-block:: python with MpyDevice('dev/tty.SLAB_USBtoUART') as dev: de...
[ 11748, 25064, 628, 198, 198, 4871, 7308, 24728, 7, 15252, 2599, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 12314, 1773, 7535, 3096, 7071, 628, 220, 220, 220, 770, 8265, 3769, 257, 337, 9078, 24728, 1398, 284, 10996, 351, 257, 1231...
2.51676
358
from .pybench import run_benchmark
[ 6738, 764, 9078, 26968, 1330, 1057, 62, 26968, 4102, 198 ]
3.5
10
""" A modules with application wide error handling logic. """ from dataclasses import dataclass import click from hopla.hoplalib.common import GlobalConstants class YouFoundABugRewardError(click.ClickException): """An exception that helps users submit a bug report. Devnote: This is a defensive programming t...
[ 37811, 198, 32, 13103, 351, 3586, 3094, 4049, 9041, 9156, 13, 198, 37811, 198, 6738, 4818, 330, 28958, 1330, 4818, 330, 31172, 198, 198, 11748, 3904, 198, 6738, 1725, 5031, 13, 8548, 75, 282, 571, 13, 11321, 1330, 8060, 34184, 1187, 6...
3.592593
135
import pandas as pd import os from qaPairsRelationClassification.utils.data_utils import shuffle, pad_sequences from qaPairsRelationClassification.DSSM import args import jieba import re from gensim.models import Word2Vec import numpy as np from qaPairsRelationClassification.DRCN import args from qaPairsRelationClassif...
[ 11748, 19798, 292, 355, 279, 67, 198, 11748, 28686, 198, 6738, 10662, 64, 47, 3468, 6892, 341, 9487, 2649, 13, 26791, 13, 7890, 62, 26791, 1330, 36273, 11, 14841, 62, 3107, 3007, 198, 6738, 10662, 64, 47, 3468, 6892, 341, 9487, 2649, ...
1.897311
409
import os import tensorflow as tf import source.layers as lay
[ 11748, 28686, 198, 11748, 11192, 273, 11125, 355, 48700, 198, 11748, 2723, 13, 75, 6962, 355, 3830, 198 ]
3.444444
18
import math import glob import serial import struct import time import sys import rospy from autoware_msgs.msg import NDTStat from geometry_msgs.msg import TwistStamped from std_msgs.msg import Float32 interfaces = {} target_velocity = 0.0 current_velocity = 0.0 steering_angle = 0.0 should_reverse = False current_thr...
[ 11748, 10688, 198, 11748, 15095, 198, 11748, 11389, 198, 11748, 2878, 198, 11748, 640, 198, 11748, 25064, 198, 198, 11748, 686, 2777, 88, 198, 6738, 1960, 322, 533, 62, 907, 14542, 13, 19662, 1330, 399, 24544, 17126, 198, 6738, 22939, 6...
2.607843
510
import matplotlib matplotlib.use("Agg") import sys import os import numpy as np import matplotlib.pylab as plt import seaborn as sns from pyhrt.utils import bh_predictions, tpr, fdr, pretty_str if __name__ == "__main__": main()
[ 11748, 2603, 29487, 8019, 198, 198, 6759, 29487, 8019, 13, 1904, 7203, 46384, 4943, 198, 11748, 25064, 198, 11748, 28686, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 2603, 29487, 8019, 13, 79, 2645, 397, 355, 458, 83, 198, 11748, 38...
2.655556
90
from collections import defaultdict if __name__ == "__main__": s = "ccacbaba" res = Solution().remove_duplicate_letters(s) print(res)
[ 6738, 17268, 1330, 4277, 11600, 628, 220, 220, 220, 220, 220, 220, 220, 220, 628, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 264, 796, 366, 535, 330, 65, 15498, 1, 198, 220, 220, 220, 581, 79...
2.453125
64
# -*- coding: utf-8 -*- # Generated by Django 1.9.4 on 2016-06-19 19:23 from __future__ import unicode_literals import datetime from django.db import migrations, models from django.utils.timezone import utc
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 2980, 515, 416, 37770, 352, 13, 24, 13, 19, 319, 1584, 12, 3312, 12, 1129, 678, 25, 1954, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, 19...
2.863014
73
""" This code will print out a greeting based on the time of day. """ # This function will print a greeting for the morning # This function will print a greeting for the afternoon # This function will print a greeting for the evening # Get input from the user and print matching greeting # I...
[ 37811, 201, 198, 1212, 2438, 481, 3601, 503, 257, 31933, 1912, 319, 262, 640, 286, 1110, 13, 201, 198, 37811, 201, 198, 201, 198, 2, 770, 2163, 481, 3601, 257, 31933, 329, 262, 3329, 201, 198, 220, 220, 220, 220, 201, 198, 2, 770,...
2.990783
217
import pandas as pd import numpy as np print("pandas version", pd.__version__) df = pd.DataFrame(np.random.random(size=(100, 5))) corr_mat = df.corr() mask = np.tril(np.ones_like(corr_mat, dtype=np.bool), k=-1) print(corr_mat.where(mask))
[ 11748, 19798, 292, 355, 279, 67, 198, 11748, 299, 32152, 355, 45941, 198, 198, 4798, 7203, 79, 392, 292, 2196, 1600, 279, 67, 13, 834, 9641, 834, 8, 198, 198, 7568, 796, 279, 67, 13, 6601, 19778, 7, 37659, 13, 25120, 13, 25120, 7,...
2.317308
104
from app import app from app.models.tables import User from flask import render_template, redirect, url_for from flask_login import login_required from sqlalchemy import desc @app.route('/scoreboard') @login_required @app.context_processor
[ 6738, 598, 1330, 598, 198, 6738, 598, 13, 27530, 13, 83, 2977, 1330, 11787, 198, 6738, 42903, 1330, 8543, 62, 28243, 11, 18941, 11, 19016, 62, 1640, 198, 6738, 42903, 62, 38235, 1330, 17594, 62, 35827, 198, 6738, 44161, 282, 26599, 13...
3.558824
68
import unittest import sme import os.path import numpy as np # root-mean-square of all elements
[ 11748, 555, 715, 395, 198, 11748, 895, 68, 198, 11748, 28686, 13, 6978, 198, 11748, 299, 32152, 355, 45941, 628, 198, 198, 2, 6808, 12, 32604, 12, 23415, 286, 477, 4847, 628 ]
3.125
32
import numpy as np from paddle import fluid from interaction.transformer import TransformerDecoder from interaction.trigger import TriggerController from perception.common.backbone import MobileNetV2
[ 11748, 299, 32152, 355, 45941, 198, 6738, 39517, 1330, 11711, 198, 198, 6738, 10375, 13, 7645, 16354, 1330, 3602, 16354, 10707, 12342, 198, 6738, 10375, 13, 46284, 1330, 24593, 22130, 198, 6738, 11202, 13, 11321, 13, 1891, 15992, 1330, 12...
4.590909
44
from collections import OrderedDict import torch if __name__ == '__main__': main()
[ 6738, 17268, 1330, 14230, 1068, 35, 713, 198, 198, 11748, 28034, 628, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 1388, 3419, 198 ]
2.935484
31
from django.test import TestCase from .maximalsequenceofconsecutiveones import solution
[ 6738, 42625, 14208, 13, 9288, 1330, 6208, 20448, 198, 6738, 764, 9806, 320, 2820, 421, 594, 1659, 1102, 4552, 425, 1952, 1330, 4610, 628 ]
3.708333
24
# The MIT License(MIT) # Copyright (c) 2013-2014 Matt Thomson # 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 limitation the rights # to use, copy, mo...
[ 2, 383, 17168, 13789, 7, 36393, 8, 198, 198, 2, 15069, 357, 66, 8, 2211, 12, 4967, 4705, 32425, 198, 198, 2, 2448, 3411, 318, 29376, 7520, 11, 1479, 286, 3877, 11, 284, 597, 1048, 16727, 257, 4866, 198, 2, 286, 428, 3788, 290, 3...
3.845029
342
import discord import os client = discord.Client() @client.event @client.event DISCORD_BOT_TOKEN = os.environ.get('DISCORD_BOT_TOKEN') client.run(DISCORD_BOT_TOKEN)
[ 11748, 36446, 198, 11748, 28686, 198, 198, 16366, 796, 36446, 13, 11792, 3419, 198, 198, 31, 16366, 13, 15596, 198, 198, 31, 16366, 13, 15596, 198, 198, 26288, 34, 12532, 62, 33, 2394, 62, 10468, 43959, 796, 28686, 13, 268, 2268, 13, ...
2.394366
71
import test_looper.server.rendering.Context as Context import test_looper.server.HtmlGeneration as HtmlGeneration import test_looper.server.rendering.TestGridRenderer as TestGridRenderer import test_looper.server.rendering.ComboContexts as ComboContexts import test_looper.server.rendering.TestSummaryRenderer as TestSum...
[ 11748, 1332, 62, 5439, 3575, 13, 15388, 13, 13287, 278, 13, 21947, 355, 30532, 198, 11748, 1332, 62, 5439, 3575, 13, 15388, 13, 39, 20369, 8645, 341, 355, 367, 20369, 8645, 341, 198, 11748, 1332, 62, 5439, 3575, 13, 15388, 13, 13287, ...
3.291339
127
import os import shutil from optparse import OptionParser def clear_pycache(folder, deep=True): ''' 列举目录下的目录 ''' result = [] dirname = os.path.abspath(folder) for i in os.listdir(dirname): path = os.path.abspath(dirname + '/' + i) if os.path.isdir(path): if i == '__p...
[ 11748, 28686, 198, 11748, 4423, 346, 198, 6738, 2172, 29572, 1330, 16018, 46677, 198, 198, 4299, 1598, 62, 9078, 23870, 7, 43551, 11, 2769, 28, 17821, 2599, 198, 220, 220, 220, 705, 7061, 198, 220, 220, 220, 10263, 230, 245, 10310, 12...
1.941989
362
import datetime import json import logging import webapp2 from google.appengine.api.app_identity import app_identity from src.commons.config.configuration import configuration from src.datastore_export.export_datastore_to_big_query_service import \ ExportDatastoreToBigQueryService app = webapp2.WSGIApplication...
[ 11748, 4818, 8079, 198, 11748, 33918, 198, 11748, 18931, 198, 198, 11748, 3992, 1324, 17, 198, 6738, 23645, 13, 1324, 18392, 13, 15042, 13, 1324, 62, 738, 414, 1330, 598, 62, 738, 414, 198, 198, 6738, 12351, 13, 9503, 684, 13, 11250, ...
2.847561
164
from datetime import datetime from app.db import db from app.custom_query_sets import SoftDeleteQuerySet from mongoengine import StringField, DateTimeField, EmailField, BooleanField from werkzeug.security import generate_password_hash, check_password_hash
[ 6738, 4818, 8079, 1330, 4818, 8079, 198, 6738, 598, 13, 9945, 1330, 20613, 198, 6738, 598, 13, 23144, 62, 22766, 62, 28709, 1330, 8297, 38727, 20746, 7248, 198, 6738, 285, 25162, 18392, 1330, 10903, 15878, 11, 7536, 7575, 15878, 11, 957...
3.893939
66
# 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...
2.1816
4,989
#!/usr/bin/env python # # Copyright (C) 2021 The Android Open Source Project # # 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 req...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 198, 2, 15069, 357, 34, 8, 33448, 383, 5565, 4946, 8090, 4935, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, ...
3.656
250
# Copyright (c) 2014 Lazy 8 Studios, LLC. # All rights reserved. from front.tests import base
[ 2, 15069, 357, 66, 8, 1946, 406, 12582, 807, 13799, 11, 11419, 13, 198, 2, 1439, 2489, 10395, 13, 198, 6738, 2166, 13, 41989, 1330, 2779, 198 ]
3.481481
27
from pathlib import Path from typing import Any, Generator, Optional, Tuple from cv2 import CAP_PROP_BUFFERSIZE, VideoCapture from numpy import ndarray from zoloto.marker_type import MarkerType from .base import BaseCamera from .mixins import IterableCameraMixin, VideoCaptureMixin, ViewableCameraMixin from .utils im...
[ 6738, 3108, 8019, 1330, 10644, 198, 6738, 19720, 1330, 4377, 11, 35986, 11, 32233, 11, 309, 29291, 198, 198, 6738, 269, 85, 17, 1330, 20176, 62, 4805, 3185, 62, 19499, 5777, 4877, 35400, 11, 7623, 49630, 198, 6738, 299, 32152, 1330, 2...
2.900293
341
# Copyright (c) 2019 Cloudify Platform Ltd. 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 ap...
[ 2, 15069, 357, 66, 8, 13130, 10130, 1958, 19193, 12052, 13, 1439, 2489, 10395, 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, ...
3.077647
425
from setuptools import find_packages from setuptools import setup setup( name='drift_analyzer', description='Data drift analyzer.', version='0.1', packages=find_packages(), install_requires=[ 'tensorflow-data-validation' ] )
[ 6738, 900, 37623, 10141, 1330, 1064, 62, 43789, 198, 6738, 900, 37623, 10141, 1330, 9058, 628, 198, 40406, 7, 198, 220, 220, 220, 1438, 11639, 7109, 2135, 62, 38200, 9107, 3256, 198, 220, 220, 220, 6764, 11639, 6601, 24260, 4284, 9107, ...
2.723404
94
"""Tests for the forms of the ``task_list`` app.""" from datetime import date from django.contrib.auth.models import User from django.contrib.contenttypes.models import ContentType from django.test import TestCase from django_libs.tests.factories import UserFactory from ..forms import ( TaskCreateForm, TaskD...
[ 37811, 51, 3558, 329, 262, 5107, 286, 262, 7559, 35943, 62, 4868, 15506, 598, 526, 15931, 198, 6738, 4818, 8079, 1330, 3128, 198, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 13, 27530, 1330, 11787, 198, 6738, 42625, 14208, 13, ...
3.22365
389
# Copyright European Organization for Nuclear Research (CERN) # # 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 # # Authors: # - Martin Barisits, <mar...
[ 2, 15069, 3427, 12275, 329, 19229, 4992, 357, 34, 28778, 8, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 921, 743, 407, 779, 428, 2393, 2845, 287, 11846, 351, 262, 13...
2.930502
259
# -*- coding: utf-8 -*- # Generated by Django 1.10.3 on 2017-09-01 23:45 from __future__ import unicode_literals from django.db import migrations
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 2980, 515, 416, 37770, 352, 13, 940, 13, 18, 319, 2177, 12, 2931, 12, 486, 2242, 25, 2231, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, 1...
2.690909
55
import sys from hypothesis import given from rene.exact import Contour from . import strategies @given(strategies.contours)
[ 11748, 25064, 198, 198, 6738, 14078, 1330, 1813, 198, 198, 6738, 302, 710, 13, 1069, 529, 1330, 2345, 454, 198, 6738, 764, 1330, 10064, 628, 198, 31, 35569, 7, 2536, 2397, 444, 13, 3642, 4662, 8, 198 ]
3.459459
37
from ast import literal_eval import numpy as np from .exceptions import InvalidArgument from .exceptions import InappropriateArgument from .exceptions import MethodNotImplementedError from anndata import AnnData from kneed import KneeLocator # the version for adata.uns['uncertain_subsets']
[ 6738, 6468, 1330, 18875, 62, 18206, 198, 198, 11748, 299, 32152, 355, 45941, 198, 198, 6738, 764, 1069, 11755, 1330, 17665, 28100, 1713, 198, 6738, 764, 1069, 11755, 1330, 554, 13335, 28100, 1713, 198, 6738, 764, 1069, 11755, 1330, 11789,...
3.505618
89
''' Web browser GUI-launched tasks run in a separate process. This module provides mechanisms for interacting withe the task running in another process, e.g., calling functions to start/stop the task, enabling/disabling decoder adaptation, etc. ''' import os import sys import time import xmlrpc.client import multipro...
[ 7061, 6, 198, 13908, 6444, 25757, 12, 38722, 1740, 8861, 1057, 287, 257, 4553, 1429, 13, 770, 8265, 3769, 220, 198, 1326, 3147, 6583, 329, 24986, 20868, 258, 262, 4876, 2491, 287, 1194, 1429, 11, 304, 13, 70, 1539, 198, 44714, 5499, ...
2.35919
4,641
import gym import numpy as np from keras.models import load_model from baselines.common.atari_wrappers import make_atari, wrap_deepmind from models.model_utils import get_extractor_model from models.neural_linear_wrapper import NeuralLinearWrapper
[ 11748, 11550, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 41927, 292, 13, 27530, 1330, 3440, 62, 19849, 198, 198, 6738, 1615, 20655, 13, 11321, 13, 35554, 62, 29988, 11799, 1330, 787, 62, 35554, 11, 14441, 62, 22089, 10155, 198, 6738...
3.549296
71
# -*- coding: utf-8 -*- import requests from requests.auth import HTTPDigestAuth from StringIO import StringIO import sys import re import math import json import os.path import time DIGEST_USER = "sp2lc" DIGEST_PASS = "********" PRACTICE_USER = "sp2lc" PRACTICE_PASS = "********"
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 7007, 198, 6738, 7007, 13, 18439, 1330, 7154, 51, 5760, 328, 395, 30515, 198, 6738, 10903, 9399, 1330, 10903, 9399, 198, 11748, 25064, 198, 11748, 302, 198, 11748, ...
2.784314
102
import streamlit as st import streamlit.components.v1 as components import pandas as pd import numpy as np import plotly.graph_objects as go import plotly.express as px from string import Template # =========================================================================== # GUARDINT asset URL and color scheme # ====...
[ 11748, 4269, 18250, 355, 336, 198, 11748, 4269, 18250, 13, 5589, 3906, 13, 85, 16, 355, 6805, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 7110, 306, 13, 34960, 62, 48205, 355, 467, 198, 11748,...
2.091963
61,525
from construct.core import * from construct.lib import * from os import urandom from time import time from pylurk.extensions.tls12_struct import TLS12Type, TLS12Status Extension = Struct( "designation" / Enum( Byte, lurk = 0, tls12 = 1 ), "version" / Switch( this.designation , ...
[ 6738, 5678, 13, 7295, 1330, 1635, 198, 6738, 5678, 13, 8019, 1330, 1635, 220, 198, 6738, 28686, 1330, 2956, 3749, 198, 6738, 640, 1330, 640, 628, 198, 6738, 279, 2645, 333, 74, 13, 2302, 5736, 13, 83, 7278, 1065, 62, 7249, 1330, 338...
2.100275
728
# Copyright 2018-2021 Xanadu Quantum Technologies Inc. # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # http://www.apache.org/licenses/LICENSE-2.0 # Unless required by applicable law or...
[ 2, 15069, 2864, 12, 1238, 2481, 47482, 324, 84, 29082, 21852, 3457, 13, 198, 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, ...
3.342071
763
import pygame
[ 11748, 12972, 6057, 628, 628 ]
3.4
5
#!/usr/bin/python # -*- coding: utf-8 -*- import gym import math import random import traceback import matplotlib.pyplot as plt import torch import torch.nn as nn import torch.nn.functional as F import torch.optim as optim from core.agent import Agent from core.memory import DQNMemory from core.config import device fro...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 11550, 198, 11748, 10688, 198, 11748, 4738, 198, 11748, 12854, 1891, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355,...
2.691814
623
from django.shortcuts import render from django.http import HttpResponse, Http404 from .models import Image import datetime as dt
[ 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 11, 367, 29281, 26429, 198, 6738, 764, 27530, 1330, 7412, 198, 11748, 4818, 8079, 355, 288, 83 ]
3.685714
35
import pandas as pd import numpy as np from bokeh.models import ColumnDataSource, Panel from bokeh.models.widgets import TableColumn, DataTable from bokeh.plotting import figure
[ 11748, 19798, 292, 355, 279, 67, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 1489, 365, 71, 13, 27530, 1330, 29201, 6601, 7416, 11, 18810, 198, 6738, 1489, 365, 71, 13, 27530, 13, 28029, 11407, 1330, 8655, 39470, 11, 6060, 10962, 1...
3.470588
51
"""输入多人身高,若输入空字符则停止,在得出平均值""" sum=0 sum1=0 while True: hight=input("请输入您的身高:") if hight==" ": break hight1=int(hight) sum+=hight1 sum1+=1 print(sum/sum1)
[ 37811, 164, 122, 241, 17739, 98, 13783, 248, 21689, 164, 118, 104, 165, 45865, 171, 120, 234, 164, 233, 98, 164, 122, 241, 17739, 98, 163, 102, 118, 27764, 245, 163, 105, 99, 26344, 247, 161, 223, 250, 29826, 95, 171, 120, 234, 28...
1.162338
154
import collections import logging import re import xml.etree.ElementTree import requests from manubot.util import get_manubot_user_agent def get_arxiv_csl_item(arxiv_id): """ Return csl_item item for an arXiv record. arxiv_id can be versioned, like `1512.00567v2`, or versionless, like `1512.00567`....
[ 11748, 17268, 198, 11748, 18931, 198, 11748, 302, 198, 11748, 35555, 13, 316, 631, 13, 20180, 27660, 198, 198, 11748, 7007, 198, 198, 6738, 582, 549, 313, 13, 22602, 1330, 651, 62, 805, 549, 313, 62, 7220, 62, 25781, 628, 198, 4299, ...
2.465686
1,224
from .config import CUDA from typing import Union import torch from torchvision import transforms from torchvision.utils import save_image from torch.autograd import Variable from PIL import Image class BaseProcessor: """ Handle preprocessing/postprocessing in accordance with model-zoo ImageNet subset ...
[ 6738, 764, 11250, 1330, 29369, 5631, 198, 198, 6738, 19720, 1330, 4479, 198, 198, 11748, 28034, 198, 6738, 28034, 10178, 1330, 31408, 198, 6738, 28034, 10178, 13, 26791, 1330, 3613, 62, 9060, 198, 6738, 28034, 13, 2306, 519, 6335, 1330, ...
2.477477
333
# -*- coding: utf-8 -*- from html_to_epub import * if __name__ == '__main__': main()
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 201, 198, 201, 198, 6738, 27711, 62, 1462, 62, 538, 549, 1330, 1635, 201, 198, 220, 220, 220, 220, 201, 198, 220, 220, 220, 220, 201, 198, 220, 220, 220, 220, 201, 198, ...
1.410256
117
# -*- coding: utf-8 -*- from functools import wraps from .exceptions import superuser_requred_forbid
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 1257, 310, 10141, 1330, 27521, 198, 6738, 764, 1069, 11755, 1330, 2208, 7220, 62, 8897, 445, 62, 1640, 14065, 628 ]
2.914286
35
######################################################################### #CSE574 | Project 3 | Part 3 #Description: To classify images by building convolutional neural network #using tensorflow ######################################################################### from cnn_lib import * import tensorflow as tf from...
[ 29113, 29113, 7804, 2, 198, 2, 34, 5188, 46900, 930, 4935, 513, 930, 2142, 513, 198, 2, 11828, 25, 1675, 36509, 4263, 416, 2615, 3063, 2122, 282, 17019, 3127, 198, 2, 3500, 11192, 273, 11125, 198, 29113, 29113, 7804, 2, 198, 198, 67...
2.801086
1,473
from . import gym_info from . import product_template from . import invoice
[ 6738, 764, 1330, 11550, 62, 10951, 198, 6738, 764, 1330, 1720, 62, 28243, 198, 6738, 764, 1330, 45458 ]
4.166667
18
from django.contrib import admin from .models import AuthLog admin.site.register(AuthLog,AuthLogAdmin)
[ 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 198, 6738, 764, 27530, 1330, 26828, 11187, 198, 198, 28482, 13, 15654, 13, 30238, 7, 30515, 11187, 11, 30515, 11187, 46787, 8, 198 ]
3.28125
32
from marshmallow import ( fields, post_load, Schema, validate, validates_schema, ValidationError, ) from .state import State
[ 6738, 22397, 42725, 1330, 357, 198, 220, 220, 220, 7032, 11, 198, 220, 220, 220, 1281, 62, 2220, 11, 198, 220, 220, 220, 10011, 2611, 11, 198, 220, 220, 220, 26571, 11, 198, 220, 220, 220, 4938, 689, 62, 15952, 2611, 11, 198, 220,...
2.508197
61
from __future__ import absolute_import, division, print_function __metaclass__ = type import os import sys import warnings import ansible.constants import ansible.errors import ansible.utils import pytest from pprint import pprint # The positive path test
[ 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 11, 7297, 11, 3601, 62, 8818, 198, 198, 834, 4164, 330, 31172, 834, 796, 2099, 198, 198, 11748, 28686, 198, 11748, 25064, 198, 11748, 14601, 198, 198, 11748, 9093, 856, 13, 9979, 1187, 1...
3.611111
72
from protorpc import messages class RidesCollection(messages.Message): """Collection of Rides""" items = messages.MessageField(Ride, 1, repeated=True) STORED_RIDES = RidesCollection(items=[]); class HitchhikesCollection(messages.Message): """Collection of Hitchhikes.""" items = messages.MessageField(Hitchhik...
[ 6738, 1237, 273, 14751, 1330, 6218, 198, 198, 4871, 371, 1460, 36307, 7, 37348, 1095, 13, 12837, 2599, 198, 220, 37227, 36307, 286, 371, 1460, 37811, 198, 220, 3709, 796, 6218, 13, 12837, 15878, 7, 49, 485, 11, 352, 11, 5100, 28, 17...
3.185484
124
#!/usr/bin/python3 import pytest from brownie import compile_source @pytest.fixture(scope="function", autouse=True) @pytest.fixture(scope="module") @pytest.fixture(scope="module") @pytest.fixture(scope="module") @pytest.fixture(scope="module")
[ 2, 48443, 14629, 14, 8800, 14, 29412, 18, 198, 198, 11748, 12972, 9288, 198, 6738, 7586, 494, 1330, 17632, 62, 10459, 628, 198, 31, 9078, 9288, 13, 69, 9602, 7, 29982, 2625, 8818, 1600, 1960, 1076, 28, 17821, 8, 628, 198, 31, 9078, ...
2.771739
92
# """ """ # end_pymotw_header from urllib.parse import unquote, unquote_plus print(unquote("http%3A//localhost%3A8080/%7Ehellmann/")) print(unquote_plus("http%3A%2F%2Flocalhost%3A8080%2F%7Ehellmann%2F"))
[ 2, 198, 37811, 198, 37811, 198, 198, 2, 886, 62, 79, 4948, 313, 86, 62, 25677, 198, 6738, 2956, 297, 571, 13, 29572, 1330, 555, 22708, 11, 555, 22708, 62, 9541, 198, 198, 4798, 7, 403, 22708, 7203, 4023, 4, 18, 32, 1003, 36750, ...
2.168421
95
# Copyright 2020 Tomas Brabec # # 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 writi...
[ 2, 15069, 12131, 42884, 1709, 397, 721, 198, 2, 220, 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...
2.606013
632
import six @six.add_metaclass(RegistryMeta)
[ 11748, 2237, 628, 198, 31, 19412, 13, 2860, 62, 4164, 330, 31172, 7, 8081, 4592, 48526, 8 ]
2.647059
17
import pytest from confluence_publish import cli, main DATADIR = __name__
[ 11748, 12972, 9288, 198, 6738, 1013, 23079, 62, 12984, 1836, 1330, 537, 72, 11, 1388, 198, 198, 35, 1404, 2885, 4663, 796, 11593, 3672, 834, 628, 198 ]
2.851852
27
import os from conftest import compile_mock_rt_graph from app import APP_ENV, seek_confirmation from app.retweet_graphs.bq_weekly_grapher import BigQueryWeeklyRetweetGrapher from app.botcode_v2.classifier import NetworkClassifier as BotClassifier, DRY_RUN if __name__ == "__main__": storage_service = BigQueryWeek...
[ 11748, 28686, 198, 198, 6738, 369, 701, 395, 1330, 17632, 62, 76, 735, 62, 17034, 62, 34960, 198, 6738, 598, 1330, 43504, 62, 1677, 53, 11, 5380, 62, 10414, 36241, 198, 6738, 598, 13, 1186, 7277, 62, 34960, 82, 13, 65, 80, 62, 452...
2.562368
946
''' The script to process wav file data from java Python version: 2.7.10 Author: Jinhua Wang License: MIT ''' ''' Squirrel Protocol: client (JAVA) send the file to server(python) for conversion (BASE64 Encoding) SEND\n LENGTH\n IN SAMPLE RATE\n IN NUM CHNNELS\n [DATA] server (python) send the converted file back t...
[ 7061, 6, 198, 464, 4226, 284, 1429, 266, 615, 2393, 1366, 422, 20129, 198, 37906, 2196, 25, 362, 13, 22, 13, 940, 198, 13838, 25, 17297, 33061, 15233, 220, 198, 34156, 25, 17168, 198, 7061, 6, 198, 198, 7061, 6, 198, 22266, 22793, ...
2.762295
488
import numpy as np from scipy.integrate import quad from scipy.special import legendre as P def b(r, K=1000, s=0.0033, **kwargs): """ The sigmoid spot profile. """ theta = np.linspace(0, np.pi, K) return 1 / (1 + np.exp((r - theta) / s)) - 1 def get_Bp(K=1000, lmax=5, eps=1e-9, sigma=15, **kwar...
[ 11748, 299, 32152, 355, 45941, 198, 6738, 629, 541, 88, 13, 18908, 4873, 1330, 15094, 198, 6738, 629, 541, 88, 13, 20887, 1330, 8177, 260, 355, 350, 628, 198, 4299, 275, 7, 81, 11, 509, 28, 12825, 11, 264, 28, 15, 13, 405, 2091, ...
2.214333
1,507
import argparse import sys from PIL import Image from pybraw import _pybraw, verify if __name__ == '__main__': main(sys.argv[1:])
[ 11748, 1822, 29572, 198, 11748, 25064, 198, 198, 6738, 350, 4146, 1330, 7412, 198, 6738, 12972, 65, 1831, 1330, 4808, 9078, 65, 1831, 11, 11767, 628, 628, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 2...
2.592593
54
#!/usr/bin/python3 import json import seaborn as sns from matplotlib import cm from matplotlib.colors import ListedColormap, LinearSegmentedColormap import matplotlib.colors as colors from scipy.stats import spearmanr import pylab import scipy.cluster.hierarchy as sch from scipy.stats import pearsonr, friedmanchisqu...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 18, 198, 198, 11748, 33918, 198, 11748, 384, 397, 1211, 355, 3013, 82, 198, 6738, 2603, 29487, 8019, 1330, 12067, 198, 6738, 2603, 29487, 8019, 13, 4033, 669, 1330, 406, 6347, 5216, 579, 499, 11, ...
3.077151
674
from flask import Flask from flask.ext.mongoengine import MongoEngine from flask_modus import Modus app = Flask(__name__) app.config["MONGODB_SETTINGS"] = {'DB': "test"} app.config["SECRET_KEY"] = "secretpassword" modus = Modus(app) db = MongoEngine(app) from app import views
[ 6738, 42903, 1330, 46947, 198, 6738, 42903, 13, 2302, 13, 76, 25162, 18392, 1330, 42591, 13798, 198, 6738, 42903, 62, 4666, 385, 1330, 3401, 385, 198, 1324, 796, 46947, 7, 834, 3672, 834, 8, 198, 1324, 13, 11250, 14692, 44, 18494, 372...
2.957447
94
""" @author Thomas Churchman Experiment start-up script """ from psychopy import logging from experimentHandler import * logging.console.setLevel(logging.DEBUG) eHandler = ExperimentHandler() eHandler.run()
[ 37811, 198, 31, 9800, 5658, 4564, 805, 198, 198, 20468, 3681, 923, 12, 929, 4226, 198, 37811, 198, 198, 6738, 3795, 11081, 1330, 18931, 198, 6738, 6306, 25060, 1330, 1635, 198, 198, 6404, 2667, 13, 41947, 13, 2617, 4971, 7, 6404, 2667...
3.559322
59
from .user import * from .registration import * from .email_handler import SendEmail
[ 6738, 764, 7220, 1330, 1635, 198, 6738, 764, 2301, 33397, 1330, 1635, 198, 6738, 764, 12888, 62, 30281, 1330, 16290, 15333 ]
4
21
# -*- coding: utf-8 -*- # 从html中提取正文, 文本密度提取算法 # update time: 20161014 import re import traceback from lxml import etree from scrapy import Selector # 移除HTML标签 # 移除空格 # 按行分割,并移除每行首尾的空格 # 获取1-blockwidth行中每行有多少字符 # 不知道干什么用的 if __name__ == '__main__': import XX.HTTP.RequestsHelper as cr...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 220, 20015, 236, 6494, 40792, 162, 237, 238, 20998, 244, 29826, 96, 23877, 229, 11, 10545, 244, 229, 17312, 105, 43380, 228, 41753, 99, 162, 237, 238, 20998, 244, 1...
1.660574
383
#!/usr/bin/env python3 """Move the TriFingerPro robot like a claw crane using the keyboard.""" import argparse import curses import os import sys import numpy as np from scipy.spatial.transform import Rotation from ament_index_python.packages import get_package_share_directory import trifinger_simulation import robo...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 37811, 21774, 262, 7563, 37, 3889, 2964, 9379, 588, 257, 26573, 41175, 1262, 262, 10586, 526, 15931, 198, 11748, 1822, 29572, 198, 11748, 43878, 198, 11748, 28686, 198, 11748, 25064, ...
3.265152
132
# from raven import Client """ 启动脚本 - backend/app/celery_worker_start.sh #linux # CELERY 4 celery worker -A app.celery_app.worker.example -l info -Q main-queue -c 1 # CELERY 5 celery -A app.celery_app.worker.example worker -l info -Q main-queue -c 1 #win # CELERY 4 celery worker -A...
[ 2, 422, 37735, 1330, 20985, 198, 37811, 198, 220, 220, 220, 10263, 238, 107, 27950, 101, 164, 226, 248, 17312, 105, 532, 30203, 14, 1324, 14, 7015, 88, 62, 28816, 62, 9688, 13, 1477, 198, 220, 220, 220, 1303, 23289, 198, 220, 220, ...
2.225275
364
import json from pathlib import Path import time from typing import Any, Dict, List from girder_client import GirderClient from girder_worker.utils import JobStatus import pytest localDataRoot = Path('tests/integration/data') """ Alice and Bobby have different types of data (images and video) Most tests run operatio...
[ 11748, 33918, 198, 6738, 3108, 8019, 1330, 10644, 198, 11748, 640, 198, 6738, 19720, 1330, 4377, 11, 360, 713, 11, 7343, 198, 198, 6738, 37370, 1082, 62, 16366, 1330, 23837, 1082, 11792, 198, 6738, 37370, 1082, 62, 28816, 13, 26791, 133...
1.700771
5,190
"""Module containing IssueTree, IssueNode classes for storing information about bugtracker issues.""" from collections import defaultdict from functools import partial class IssueNode: """Class IssueNode. issue_id - id of the bugtracker issue associated with the node store - dictionary for {user: ...
[ 37811, 26796, 7268, 18232, 27660, 11, 18232, 19667, 6097, 329, 23069, 1321, 546, 5434, 2213, 10735, 2428, 526, 15931, 198, 198, 6738, 17268, 1330, 4277, 11600, 198, 6738, 1257, 310, 10141, 1330, 13027, 628, 198, 4871, 18232, 19667, 25, 19...
2.332406
719
import peewee import sqlite3 file = 'paises.db' db = peewee.SqliteDatabase(file) if __name__ == '__main__': main()
[ 11748, 613, 413, 1453, 198, 11748, 44161, 578, 18, 198, 198, 7753, 796, 705, 8957, 2696, 13, 9945, 6, 198, 198, 9945, 796, 613, 413, 1453, 13, 50, 13976, 578, 38105, 7, 7753, 8, 628, 628, 198, 361, 11593, 3672, 834, 6624, 705, 834...
2.339623
53
import os from ArmMovementPredictionStudien.PREPROCESSING.smooth import smooth_data_utils directory = "../../DATA/1_interpolated/" for file in os.listdir(directory): smoothed_dataset = smooth_data_utils.generate_smooth_dataframe(file, directory, "savgol", window=13) new_filename = "../../DATA/2_smoothed/" + ...
[ 11748, 28686, 198, 198, 6738, 7057, 21774, 434, 39156, 2867, 13007, 2013, 13, 46437, 4805, 4503, 7597, 2751, 13, 5796, 5226, 1330, 7209, 62, 7890, 62, 26791, 198, 198, 34945, 796, 366, 40720, 40720, 26947, 14, 16, 62, 3849, 16104, 515, ...
2.697143
175
from copy import deepcopy from threading import Timer import matplotlib.pyplot as plt from afinn import Afinn from matplotlib.figure import Figure from src.real_time.base_backend import BackendInterface from src.real_time.text_input_backend import TextInputLoop from src.text.sentiment.sentiment_highlighting import se...
[ 6738, 4866, 1330, 2769, 30073, 198, 6738, 4704, 278, 1330, 5045, 263, 198, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 6738, 6580, 3732, 1330, 2483, 3732, 198, 6738, 2603, 29487, 8019, 13, 26875, 1330, 11291, 198,...
2.820175
228
"""Tests for NWChem functionality""" import numpy as np import pytest import qcelemental as qcel from qcelemental.testing import compare_values import qcengine as qcng from qcengine.testing import using # Molecule where autoz fails _auto_z_problem = xyz = """C 15.204188380000 -3.519180270000 -...
[ 37811, 51, 3558, 329, 21966, 41829, 11244, 37811, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 12972, 9288, 198, 11748, 10662, 344, 1732, 282, 355, 10662, 5276, 198, 6738, 10662, 344, 1732, 282, 13, 33407, 1330, 8996, 62, 27160, 198, ...
1.847729
3,369
from merc.lib.modules import Module class sbitbinaries(Module): """Description: Find all the suid/sgid binaries in the /system folder - uses method from http://hexesec.wordpress.com/2009/10/14/exploiting-suid-binaries/ Credit: Tyrone Erasmus - MWR Labs"""
[ 6738, 11991, 13, 8019, 13, 18170, 1330, 19937, 198, 198, 4871, 264, 2545, 8800, 3166, 7, 26796, 2599, 198, 220, 220, 220, 37227, 11828, 25, 9938, 477, 262, 424, 312, 14, 45213, 312, 38640, 287, 262, 1220, 10057, 9483, 532, 3544, 2446,...
3.170732
82
#!/usr/bin/env python __author__ = "XXX" __email__ = "XXX" import argparse import shutil import tensorflow as tf import wandb from datasets.implemented_datasets import * from evaluation.topk_evaluator import Evaluator from igccf_experiments.best_models import get_wandb_project_dict # Define static variables from mo...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 834, 9800, 834, 796, 366, 43145, 1, 198, 834, 12888, 834, 796, 366, 43145, 1, 198, 198, 11748, 1822, 29572, 198, 11748, 4423, 346, 198, 198, 11748, 11192, 273, 11125, 355, 48700, 198, ...
2.762712
1,239
from django.shortcuts import render, redirect, reverse from django.contrib import messages from django.contrib.auth.decorators import login_required from .forms import UserRegisterForm, UserUpdateForm, UserProfileUpdateForm @login_required
[ 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 11, 18941, 11, 9575, 198, 6738, 42625, 14208, 13, 3642, 822, 1330, 6218, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 13, 12501, 273, 2024, 1330, 17594, 62, 35827, 198, 6738, 764, ...
3.95082
61
from unittest.mock import patch, Mock import tests from timebomb.forms import CutForm @patch.object(CutForm, "__init__", return_value=None) @patch.object(CutForm, "__init__", return_value=None) @patch.object(CutForm, "__init__", return_value=None) @patch.object(CutForm, "__init__", return_value=None)
[ 6738, 555, 715, 395, 13, 76, 735, 1330, 8529, 11, 44123, 198, 198, 11748, 5254, 198, 6738, 640, 27657, 13, 23914, 1330, 9712, 8479, 628, 198, 31, 17147, 13, 15252, 7, 26254, 8479, 11, 366, 834, 15003, 834, 1600, 1441, 62, 8367, 28, ...
2.853211
109