content
stringlengths
1
1.04M
input_ids
listlengths
1
774k
ratio_char_token
float64
0.38
22.9
token_count
int64
1
774k
from datetime import datetime from num2words import num2words import gettext as gettext_module, locale, os __all__ = ('spoken_time', 'absolute_spoken_date', 'relative_spoken_date') # Reset locale for day & month names locale.setlocale( locale.LC_ALL, '') # Load translations for current locale _language, _encoding ...
[ 6738, 4818, 8079, 1330, 4818, 8079, 198, 6738, 997, 17, 10879, 1330, 997, 17, 10879, 198, 11748, 651, 5239, 355, 651, 5239, 62, 21412, 11, 36693, 11, 28686, 628, 198, 834, 439, 834, 796, 19203, 19842, 62, 2435, 3256, 705, 48546, 62, ...
2.402315
2,073
from redis import Redis import time from functools import update_wrapper from flask import request, g from flask import Flask, jsonify from models import Base, Item from sqlalchemy.ext.declarative import declarative_base from sqlalchemy.orm import relationship, sessionmaker from sqlalchemy import create_engine impo...
[ 6738, 2266, 271, 1330, 2297, 271, 198, 11748, 640, 198, 6738, 1257, 310, 10141, 1330, 4296, 62, 48553, 198, 6738, 42903, 1330, 2581, 11, 308, 198, 6738, 42903, 1330, 46947, 11, 33918, 1958, 220, 198, 6738, 4981, 1330, 7308, 11, 9097, ...
2.910569
246
from datetime import datetime, timedelta from flask import current_app from notifications_utils.timezones import convert_utc_to_bst from sqlalchemy import asc, desc, func from app import db from app.dao.dao_utils import autocommit from app.models import ( SMS_TYPE, FactBilling, ProviderDetails, Provid...
[ 6738, 4818, 8079, 1330, 4818, 8079, 11, 28805, 12514, 198, 198, 6738, 42903, 1330, 1459, 62, 1324, 198, 6738, 19605, 62, 26791, 13, 2435, 89, 1952, 1330, 10385, 62, 315, 66, 62, 1462, 62, 65, 301, 198, 6738, 44161, 282, 26599, 1330, ...
2.973016
1,260
#! /usr/bin/python3 from default_settings import default_settings from ultron_cli import UltronCLI if __name__ == '__main__': default_settings() try: UltronCLI().cmdloop() except KeyboardInterrupt: print("\nInterrupted by user.") print("Goodbye") exit(0)
[ 2, 0, 220, 1220, 14629, 14, 8800, 14, 29412, 18, 198, 6738, 4277, 62, 33692, 1330, 4277, 62, 33692, 198, 6738, 3789, 1313, 62, 44506, 1330, 46315, 5097, 40, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 22...
2.467213
122
import subprocess import schavott.gfatofasta import os import pyfasta
[ 11748, 850, 14681, 198, 11748, 5513, 615, 1252, 13, 70, 17359, 1659, 40197, 198, 11748, 28686, 198, 11748, 12972, 7217, 64, 198 ]
3.181818
22
from alien_functions import *
[ 6738, 8756, 62, 12543, 2733, 1330, 1635, 628, 628, 198 ]
3.4
10
from flask import Flask from flask.ext.login import current_user from flask.ext.security import Security, SQLAlchemyUserDatastore from flask_mail import Mail from flask_debugtoolbar import DebugToolbarExtension from werkzeug.contrib.fixers import ProxyFix from flask.ext.admin import Admin, AdminIndexView from flask.ext...
[ 6738, 42903, 1330, 46947, 198, 6738, 42903, 13, 2302, 13, 38235, 1330, 1459, 62, 7220, 198, 6738, 42903, 13, 2302, 13, 12961, 1330, 4765, 11, 16363, 2348, 26599, 12982, 27354, 459, 382, 198, 6738, 42903, 62, 4529, 1330, 11099, 198, 6738...
3.701087
184
known = set() unknown = set() for _ in range(int(input())): known.add(input().strip().lower()) for _ in range(int(input())): for word in input().strip().lower().split(): if word not in known: unknown.add(word) for word in unknown: print(word)
[ 4002, 796, 900, 3419, 198, 34680, 796, 900, 3419, 198, 198, 1640, 4808, 287, 2837, 7, 600, 7, 15414, 28955, 2599, 198, 220, 220, 220, 1900, 13, 2860, 7, 15414, 22446, 36311, 22446, 21037, 28955, 198, 198, 1640, 4808, 287, 2837, 7, 6...
2.541284
109
# # (c) Copyright 2016 Hewlett Packard Enterprise Development LP # (c) Copyright 2017 SUSE LLC # # 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 #...
[ 2, 198, 2, 357, 66, 8, 15069, 1584, 30446, 15503, 6400, 446, 14973, 7712, 18470, 198, 2, 357, 66, 8, 15069, 2177, 311, 19108, 11419, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 153...
3.931217
189
from cProfile import label import matplotlib.pyplot as plt import numpy as np from sklearn.decomposition import PCA from sklearn.manifold import TSNE import pickle import random from saxspy import debyeWaller as dwf from scipy.interpolate import CubicSpline from tqdm import tqdm import saxspy import umap if __name__ ...
[ 6738, 269, 37046, 1330, 6167, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 1341, 35720, 13, 12501, 296, 9150, 1330, 4217, 32, 198, 6738, 1341, 35720, 13, 805, 361, 727, 1...
2.224806
258
""" FactSet Ownership API FactSet’s Fund Ownership API gives access to both **Holdings** and **Holders** data.<p> Factset's Holdings endpoints gives access to all the underlying securities and their position detils held within a given fund. Fund Types supported include Open-End Mutual Funds, Closed-end Mutual ...
[ 37811, 198, 220, 220, 220, 19020, 7248, 33147, 1056, 7824, 628, 220, 220, 220, 19020, 7248, 447, 247, 82, 7557, 33147, 1056, 7824, 3607, 1895, 284, 1111, 12429, 26807, 654, 1174, 290, 12429, 26807, 364, 1174, 1366, 29847, 79, 29, 19020,...
3.063796
627
# -*- coding: utf-8 -*- # Copyright 2017 The Chromium OS Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. """Test common module.""" from __future__ import print_function from chromite.cros_bisect import common from chromite.lib import...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 15069, 2177, 383, 18255, 1505, 7294, 46665, 13, 1439, 2489, 10395, 13, 198, 2, 5765, 286, 428, 2723, 2438, 318, 21825, 416, 257, 347, 10305, 12, 7635, 5964, 326, 46...
2.648672
3,501
import yaml
[ 11748, 331, 43695, 628 ]
3.25
4
from .__funcs__ import tortuosity_geometric_2d
[ 6738, 764, 834, 12543, 6359, 834, 1330, 7619, 84, 16579, 62, 469, 16996, 62, 17, 67 ]
2.875
16
from datetime import date, datetime import pytz from tests.fixtures.simple import Schema from tests.fixtures.simple.schema import Item, Size
[ 6738, 4818, 8079, 1330, 3128, 11, 4818, 8079, 198, 198, 11748, 12972, 22877, 198, 198, 6738, 5254, 13, 69, 25506, 13, 36439, 1330, 10011, 2611, 198, 6738, 5254, 13, 69, 25506, 13, 36439, 13, 15952, 2611, 1330, 9097, 11, 12849, 628 ]
3.512195
41
#!/usr/bin/env python import logging import collections import traceback import Queue import threading # Inspired by: https://stackoverflow.com/questions/2829329
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 11748, 18931, 198, 11748, 17268, 198, 11748, 12854, 1891, 198, 11748, 4670, 518, 198, 11748, 4704, 278, 628, 198, 2, 45827, 416, 25, 3740, 1378, 25558, 2502, 11125, 13, 785, 14, 6...
3.458333
48
from contextlib import contextmanager import pytest from mando import Program program = Program('example.py', '1.0.10') program.option( "-f", "--foo", dest='foo', default='bar', completer=NoopCompleter, help="Real programmers don't comment their code. \ If it was hard to write, it should be hard ...
[ 6738, 4732, 8019, 1330, 4732, 37153, 198, 11748, 12972, 9288, 198, 6738, 6855, 78, 1330, 6118, 628, 198, 23065, 796, 6118, 10786, 20688, 13, 9078, 3256, 705, 16, 13, 15, 13, 940, 11537, 628, 198, 198, 23065, 13, 18076, 7, 198, 220, ...
2.324114
2,314
import collections # using the queue
[ 11748, 17268, 198, 220, 220, 220, 220, 198, 220, 220, 220, 1303, 1262, 262, 16834 ]
3
15
import contextlib import logging import os from urllib.error import URLError from urllib.parse import urlencode, urlparse # from django.contrib.auth import get_user_model from django.contrib.gis.db import models from django.core.exceptions import ObjectDoesNotExist from django.utils import timezone from girder_utils.f...
[ 11748, 4732, 8019, 198, 11748, 18931, 198, 11748, 28686, 198, 6738, 2956, 297, 571, 13, 18224, 1330, 37902, 2538, 81, 1472, 198, 6738, 2956, 297, 571, 13, 29572, 1330, 2956, 11925, 8189, 11, 19016, 29572, 198, 198, 2, 422, 42625, 14208,...
2.534877
3,369
"""Users forms.""" # Django from django import forms from django.contrib.auth.models import User from django.contrib.auth.forms import AuthenticationForm from django.contrib.auth import authenticate from django.contrib.auth.forms import UserCreationForm, AuthenticationForm from .models import *
[ 37811, 14490, 5107, 526, 15931, 198, 2, 37770, 198, 6738, 42625, 14208, 1330, 5107, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 13, 27530, 1330, 11787, 198, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 13, 23914, 1330, 4819...
3.679012
81
""" 猫眼电影影评,以复联4为例,先把时间节点都爬下来,再组合成url用线程池爬,这样效率更高 """ import arrow import requests import looter as lt from pprint import pprint from pathlib import Path from concurrent import futures domain = 'http://m.maoyan.com' movie_id = '248172' # 复仇者联盟4 total_timestamps = [] total_items = [] if __name__ == '__main__': ...
[ 37811, 198, 163, 234, 104, 40367, 120, 18796, 113, 37605, 109, 37605, 109, 46237, 226, 171, 120, 234, 20015, 98, 13783, 235, 164, 223, 242, 19, 10310, 118, 160, 122, 233, 171, 120, 234, 17739, 230, 162, 232, 232, 33768, 114, 29785, ...
1.936111
360
from ..app.security import create_access_token from ...utilities.utils import disable_logging from cobald.daemon.core.config import load from pathlib import Path from typing import List import logging import typer
[ 6738, 11485, 1324, 13, 12961, 1330, 2251, 62, 15526, 62, 30001, 198, 6738, 2644, 315, 2410, 13, 26791, 1330, 15560, 62, 6404, 2667, 198, 6738, 22843, 1940, 13, 6814, 7966, 13, 7295, 13, 11250, 1330, 3440, 198, 198, 6738, 3108, 8019, 1...
3.857143
56
# -*- coding: utf-8 -*- # Form implementation generated from reading ui file 'mainWindow.ui' # # Created by: PyQt5 UI code generator 5.15.4 # # WARNING: Any manual changes made to this file will be lost when pyuic5 is # run again. Do not edit this file unless you know what you are doing. from PyQt5 import...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 201, 198, 201, 198, 2, 5178, 7822, 7560, 422, 3555, 334, 72, 2393, 705, 12417, 27703, 13, 9019, 6, 201, 198, 2, 201, 198, 2, 15622, 416, 25, 9485, 48, 83, 20, 12454, 24...
2.804196
143
import numpy as np from sklearn.metrics.pairwise import manhattan_distances as dist
[ 11748, 299, 32152, 355, 45941, 201, 198, 6738, 1341, 35720, 13, 4164, 10466, 13, 24874, 3083, 1330, 582, 12904, 62, 17080, 1817, 355, 1233, 201, 198, 201, 198, 201, 198, 201, 198 ]
2.875
32
# Copyright 2011 David W. Hogg. # All rights reserved. # BUGS: # - Brittle code; must be run from directory client/examples; dies if APOD reformats urls or html. # - Runs client using os.system() instead of importing client and executing it; see if False block at end. from __future__ import print_function import re i...
[ 2, 15069, 2813, 3271, 370, 13, 367, 10332, 13, 198, 2, 1439, 2489, 10395, 13, 198, 198, 2, 347, 7340, 50, 25, 198, 2, 532, 1709, 1206, 2438, 26, 1276, 307, 1057, 422, 8619, 5456, 14, 1069, 12629, 26, 10564, 611, 3486, 3727, 4975, ...
2.216
875
#[port, char] nameDict = dict([(65, 'A'),(66, 'B'),(67, 'C'),(68, 'D'), (69, 'E'), (70, 'F'),(71, 'G'), (72, 'H'),(73, 'I'),(74, 'J'),(75, 'K'),(76, 'L'), (77, 'M'),(78, 'N'),(79, 'O'),(80, 'P'),(81, 'Q'),(82, 'R'),(83, 'S'),(84, 'T'),(85, 'U'),(86, 'V'),(87, 'W'),(88, 'X'),(89, 'Y'),(90, 'Z'), (97, 'a'),(98, 'b'),(99,...
[ 2, 58, 634, 11, 1149, 60, 198, 3672, 35, 713, 796, 8633, 26933, 7, 2996, 11, 705, 32, 33809, 7, 2791, 11, 705, 33, 33809, 7, 3134, 11, 705, 34, 33809, 7, 3104, 11, 705, 35, 33809, 357, 3388, 11, 705, 36, 33809, 357, 2154, 11, ...
1.88627
976
""" See README.md for help configuring and running this script. """ import os import sys import datetime from urllib.parse import urlparse import http.client import json import jwt from dotenv import load_dotenv ######## # KEY CONFIGURATION - Put your API Key info here # added on 2021-12-08 by shawn.becker@angel.com...
[ 37811, 198, 6214, 20832, 11682, 13, 9132, 329, 1037, 4566, 870, 290, 2491, 428, 4226, 13, 198, 37811, 198, 198, 11748, 28686, 198, 11748, 25064, 198, 11748, 4818, 8079, 198, 6738, 2956, 297, 571, 13, 29572, 1330, 19016, 29572, 198, 1174...
2.361936
2,459
from graphql import GraphQLError from shared.messages import UNKNOW_ERROR, TOO_MANY_REQUESTS, UNFOLLOW_SUCCESS, UNFOLLOW_ERROR, FOLLOW_SUCCESS, FOLLOW_ERROR from resolvers.types.user_info import UserInfo from resolvers.types.picture import Picture from resolvers.types.feed import Feed from storage.session import get_se...
[ 6738, 4823, 13976, 1330, 29681, 48, 2538, 81, 1472, 198, 6738, 4888, 13, 37348, 1095, 1330, 4725, 29132, 3913, 62, 24908, 11, 5390, 46, 62, 10725, 56, 62, 2200, 10917, 1546, 4694, 11, 4725, 6080, 44765, 62, 12564, 4093, 7597, 11, 4725...
3.140625
128
import importlib import traceback info = { "name": "reload", "type": 1, "description": "Reloads a command", "id": "reload", "options": [ { "name": "command", "description": "Command name", "type": 3, "required": True }, { ...
[ 11748, 1330, 8019, 198, 11748, 12854, 1891, 198, 198, 10951, 796, 1391, 198, 220, 220, 220, 366, 3672, 1298, 366, 260, 2220, 1600, 198, 220, 220, 220, 366, 4906, 1298, 352, 11, 198, 220, 220, 220, 366, 11213, 1298, 366, 6892, 1170, ...
1.911877
261
import time import pytest from tinkoff_voicekit_client import user_utils @pytest.mark.asyncio @pytest.mark.asyncio @pytest.mark.asyncio @pytest.mark.asyncio
[ 11748, 640, 198, 198, 11748, 12972, 9288, 198, 198, 6738, 44569, 2364, 62, 38888, 15813, 62, 16366, 1330, 2836, 62, 26791, 628, 198, 31, 9078, 9288, 13, 4102, 13, 292, 13361, 952, 628, 198, 31, 9078, 9288, 13, 4102, 13, 292, 13361, ...
2.530303
66
#!/usr/bin/python2 """ Statement: Let d(n) be defined as the sum of proper divisors of n (numbers less than n which divide evenly into n). If d(a) = b and d(b) = a, where a != b, then a and b are an amicable pair and each of a and b are called amicable numbers. For example, the proper divisors of 220 are 1, 2, 4, 5,...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 17, 198, 198, 37811, 198, 48682, 25, 198, 198, 5756, 288, 7, 77, 8, 307, 5447, 355, 262, 2160, 286, 1774, 2659, 271, 669, 286, 299, 198, 7, 77, 17024, 1342, 621, 299, 543, 14083, 21894, 656, ...
2.851852
216
from django.core.management.base import BaseCommand, CommandError from environments.dynamodb import DynamoIdentityWrapper
[ 6738, 42625, 14208, 13, 7295, 13, 27604, 13, 8692, 1330, 7308, 21575, 11, 9455, 12331, 198, 198, 6738, 12493, 13, 67, 4989, 375, 65, 1330, 41542, 7390, 26858, 36918, 2848, 628 ]
4
31
from extensions import db from app import app from models import User with app.app_context(): jon = User.query.filter_by(id=7).first() jon.balance += 1800_00 storage = User.query.filter_by(id=11).first() storage.balance -= 10000_00 alasdair = User.query.filter_by(id=10).first() alasdair.balan...
[ 6738, 18366, 1330, 20613, 198, 6738, 598, 1330, 598, 198, 6738, 4981, 1330, 11787, 198, 198, 4480, 598, 13, 1324, 62, 22866, 33529, 198, 220, 220, 220, 474, 261, 796, 11787, 13, 22766, 13, 24455, 62, 1525, 7, 312, 28, 22, 737, 11085...
2.691729
133
from .imports import * from .utils.core import * from .utils.extras import * # why is this different?
[ 6738, 764, 320, 3742, 1330, 1635, 198, 6738, 764, 26791, 13, 7295, 1330, 1635, 198, 6738, 764, 26791, 13, 2302, 8847, 1330, 1635, 628, 198, 198, 2, 1521, 318, 428, 1180, 30, 628 ]
3.212121
33
# -*- coding: utf-8 -*- """ @FileName: __init__.py @Time: 2020/7/18 11:10 @Author: zhaojm Module Description """
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 31, 8979, 5376, 25, 11593, 15003, 834, 13, 9078, 198, 31, 7575, 25, 12131, 14, 22, 14, 1507, 1367, 25, 940, 198, 31, 13838, 25, 1976, 3099, 13210, 76, 19...
2.166667
54
import os import sys from datetime import timedelta from typing import Callable, Optional from click import ( Choice, IntRange, argument, command, confirm, echo, group, option, ) from firebolt.common.exception import FireboltError from firebolt.model.engine import Engine from firebolt.s...
[ 11748, 28686, 198, 11748, 25064, 198, 6738, 4818, 8079, 1330, 28805, 12514, 198, 6738, 19720, 1330, 4889, 540, 11, 32233, 198, 198, 6738, 3904, 1330, 357, 198, 220, 220, 220, 18502, 11, 198, 220, 220, 220, 2558, 17257, 11, 198, 220, 2...
2.301568
8,867
import os from .remote import * # NOQA from .base import MEDIA_ROOT, BASE_DIR # NOQA DEBUG = False WAGTAIL_CACHE = False BASE_URL = "https://web.staging.nhsx-website.dalmatian.dxw.net" MIDDLEWARE += ["baipw.middleware.BasicAuthIPWhitelistMiddleware"] BASIC_AUTH_LOGIN = os.environ.get("BASIC_AUTH_LOGIN", "") BASIC_...
[ 11748, 28686, 198, 6738, 764, 47960, 1330, 1635, 220, 1303, 8005, 48, 32, 198, 6738, 764, 8692, 1330, 26112, 3539, 62, 13252, 2394, 11, 49688, 62, 34720, 220, 1303, 8005, 48, 32, 198, 198, 30531, 796, 10352, 198, 54, 4760, 5603, 4146,...
3.263158
361
from __future__ import annotations import time import typing from concurrent.futures import Future from functools import partial from uuid import uuid4 from gi.repository import Gio from gi.repository import GLib from gi.repository import KolibriDaemonDBus from kolibri_app.config import DAEMON_APPLICATION_ID from kol...
[ 6738, 11593, 37443, 834, 1330, 37647, 198, 198, 11748, 640, 198, 11748, 19720, 198, 6738, 24580, 13, 69, 315, 942, 1330, 10898, 198, 6738, 1257, 310, 10141, 1330, 13027, 198, 6738, 334, 27112, 1330, 334, 27112, 19, 198, 198, 6738, 308, ...
3.12766
282
# Copyright (c) 2014 Brocade Communications Systems, 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....
[ 2, 15069, 357, 66, 8, 1946, 2806, 46395, 14620, 11998, 11, 3457, 13, 198, 2, 1439, 6923, 33876, 13, 198, 2, 198, 2, 220, 220, 220, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 345, 743, 198,...
1.768778
12,754
import prody import numpy pdb_data = prody.parsePDB("../Models/prot_stretching/stretching_trajectory_offset_ligand.pdb") pdb_trajectory = prody.PDBEnsemble("iterposed_CA") # Write the initial coordsets prot = pdb_data.select("name CA") prody.writePDB("stretching_trajectory_offset_ligand.iterposed_all.pdb", prot) with...
[ 11748, 386, 9892, 198, 11748, 299, 32152, 198, 198, 79, 9945, 62, 7890, 796, 386, 9892, 13, 29572, 5760, 33, 7203, 40720, 5841, 1424, 14, 11235, 62, 301, 1186, 10813, 14, 301, 1186, 10813, 62, 9535, 752, 652, 62, 28968, 62, 4604, 39...
2.552916
463
import torch
[ 11748, 28034, 628 ]
4.666667
3
from . import fnoUtils as utils
[ 6738, 764, 1330, 277, 3919, 18274, 4487, 355, 3384, 4487 ]
3.1
10
# -*- coding: utf-8 -*- import datetime import django import os import sys # env sys.path.append('/usr/lib/python2.7/dist-packages/') sys.path.append('/usr/lib/python2.7/') sys.path.append('/usr/local/lib/python2.7/dist-packages/') sys.path.append('/data2/django_1.9/') sys.path.append('/data2/django_projects/') sys.pat...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 11748, 4818, 8079, 198, 11748, 42625, 14208, 198, 11748, 28686, 198, 11748, 25064, 198, 2, 17365, 198, 17597, 13, 6978, 13, 33295, 10786, 14, 14629, 14, 8019, 14, 29412, ...
2.260771
882
from unittest import TestCase from metabase.exceptions import AuthenticationError from metabase.metabase import Metabase from tests.helpers import IntegrationTestCase
[ 6738, 555, 715, 395, 1330, 6208, 20448, 198, 198, 6738, 1138, 5754, 13, 1069, 11755, 1330, 48191, 12331, 198, 6738, 1138, 5754, 13, 4164, 5754, 1330, 3395, 5754, 198, 6738, 5254, 13, 16794, 364, 1330, 38410, 14402, 20448, 628, 198 ]
4.25
40
""" Given two strings s and t which consist of only lowercase letters. String t is generated by random shuffling string s and then add one more letter at a random position. Find the letter that was added in t. Example: Input: s = "abcd" t = "abcde" Output: e Explanation: 'e' is the letter that was added. Your ru...
[ 37811, 198, 15056, 734, 13042, 264, 290, 256, 543, 3473, 286, 691, 2793, 7442, 7475, 13, 198, 198, 10100, 256, 318, 7560, 416, 4738, 32299, 1359, 4731, 264, 290, 788, 751, 530, 517, 3850, 379, 257, 4738, 2292, 13, 198, 198, 16742, 2...
3.315315
111
####################################################################### # Name: test_parser_params # Purpose: Test for parser parameters. # Author: Igor R. Dejanović <igor DOT dejanovic AT gmail DOT com> # Copyright: (c) 2014 Igor R. Dejanović <igor DOT dejanovic AT gmail DOT com> # License: MIT License ###############...
[ 29113, 29113, 4242, 21017, 198, 2, 6530, 25, 1332, 62, 48610, 62, 37266, 198, 2, 32039, 25, 6208, 329, 30751, 10007, 13, 198, 2, 6434, 25, 46157, 371, 13, 1024, 13881, 47297, 38325, 1279, 36274, 42743, 390, 13881, 17215, 5161, 308, 45...
2.833866
939
from dataclasses import dataclass from typing import Optional @dataclass
[ 6738, 4818, 330, 28958, 1330, 4818, 330, 31172, 198, 6738, 19720, 1330, 32233, 628, 198, 31, 19608, 330, 31172, 198 ]
3.75
20
import pytest from django.contrib.auth import get_user_model from rest_framework.test import APIClient @pytest.fixture(autouse=True) @pytest.fixture @pytest.fixture
[ 11748, 12972, 9288, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 1330, 651, 62, 7220, 62, 19849, 198, 6738, 1334, 62, 30604, 13, 9288, 1330, 3486, 2149, 75, 1153, 628, 198, 31, 9078, 9288, 13, 69, 9602, 7, 2306, 1076, 28, 1782...
2.803279
61
from __future__ import absolute_import import pytz from datetime import datetime from django.utils import timezone from mock import patch from sentry.testutils import AcceptanceTestCase, SnubaTestCase
[ 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 198, 198, 11748, 12972, 22877, 198, 198, 6738, 4818, 8079, 1330, 4818, 8079, 198, 6738, 42625, 14208, 13, 26791, 1330, 640, 11340, 198, 6738, 15290, 1330, 8529, 198, 198, 6738, 1908, 563, ...
3.796296
54
#1로 만들기 x=26 d = [0] * 30001 for i in range(2, x+1): d[i]=d[i-1]+1 if i%2 == 0: d[i]=min(d[i],d[i//2]+1) if i%3 == 0: d[i]=min(d[i],d[i//3]+1) if i%5 ==0: d[i]=min(d[i],d[i//5]+1) print(d[x])
[ 2, 16, 167, 94, 250, 31619, 100, 234, 167, 241, 97, 166, 116, 108, 198, 87, 28, 2075, 198, 198, 67, 796, 685, 15, 60, 1635, 5867, 486, 198, 198, 1640, 1312, 287, 2837, 7, 17, 11, 2124, 10, 16, 2599, 198, 220, 220, 220, 288, ...
1.335227
176
from . import server from . import client from . import model def serve(kelner_model, host="127.0.0.1", port=server.KELNER_PORT): """ Serves the loaded kelner_model """ k_server = server.KelnerServer(kelner_model) return k_server.serve_http(host, port)
[ 6738, 764, 1330, 4382, 198, 6738, 764, 1330, 5456, 198, 6738, 764, 1330, 2746, 628, 198, 4299, 4691, 7, 7750, 1008, 62, 19849, 11, 2583, 2625, 16799, 13, 15, 13, 15, 13, 16, 1600, 2493, 28, 15388, 13, 42, 3698, 21479, 62, 15490, 2...
2.59434
106
from setuptools import setup, find_packages setup(name='calltrak', version='1.0', py_modules = ['calltrak'], )
[ 6738, 900, 37623, 10141, 1330, 9058, 11, 1064, 62, 43789, 198, 198, 40406, 7, 3672, 11639, 13345, 44195, 3256, 198, 220, 220, 220, 220, 220, 2196, 11639, 16, 13, 15, 3256, 198, 220, 220, 220, 220, 220, 12972, 62, 18170, 796, 37250, ...
2.5625
48
import pandas as pd import torch from torch import nn from torch.utils.data import DataLoader from app.data_loading.bow_data_loading import BowMovieSentimentDataset from app.embeddings.bag_of_words import BagOfWords from app.models.bow_classifier import BowClassifier from app.preprocessing.preprocessor import Preproce...
[ 11748, 19798, 292, 355, 279, 67, 198, 11748, 28034, 198, 6738, 28034, 1330, 299, 77, 198, 6738, 28034, 13, 26791, 13, 7890, 1330, 6060, 17401, 198, 198, 6738, 598, 13, 7890, 62, 25138, 13, 8176, 62, 7890, 62, 25138, 1330, 9740, 25097,...
3.53271
107
# encoding: utf-8 import argparse import pathlib import matplotlib.pyplot as plt import pandas as pd from matplotlib import animation plt.rcParams['font.family'] = 'IPAPGothic' plt.rcParams['font.size'] = 11 plt.rcParams['xtick.direction'] = 'in' plt.rcParams['ytick.direction'] = 'in' plt.rcParams['xtick.top'] = Tru...
[ 2, 21004, 25, 3384, 69, 12, 23, 198, 198, 11748, 1822, 29572, 198, 11748, 3108, 8019, 198, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 11748, 19798, 292, 355, 279, 67, 198, 6738, 2603, 29487, 8019, 1330, 11034, ...
2.318493
292
""" repository.py Author: Joseph Maclean Arhin """ import os import click from jinja2 import Template from .utils import convert_to_camelcase, remove_suffix, add_to_init def create_repository(path, name, is_sql=True): """ This method creates a repository in the rootdir/repositories directory with the na...
[ 37811, 198, 260, 1930, 37765, 13, 9078, 198, 198, 13838, 25, 7212, 4100, 13087, 943, 20079, 198, 37811, 198, 11748, 28686, 198, 11748, 3904, 198, 6738, 474, 259, 6592, 17, 1330, 37350, 198, 198, 6738, 764, 26791, 1330, 10385, 62, 1462, ...
2.527607
652
import math from oh import ConfigDict
[ 11748, 10688, 198, 6738, 11752, 1330, 17056, 35, 713, 628, 628 ]
3.727273
11
""" Module with helpful functions for general use. """ # Core imports from datetime import date from re import sub as regex_sub from sys import stdout from sys import stderr # Project imports from . import constants def parse_date(date_string): """ Parses a date from a string in DD/MM/YYYY format. :para...
[ 37811, 198, 26796, 351, 7613, 5499, 329, 2276, 779, 13, 198, 37811, 198, 198, 2, 7231, 17944, 198, 6738, 4818, 8079, 1330, 3128, 198, 6738, 302, 1330, 850, 355, 40364, 62, 7266, 198, 6738, 25064, 1330, 14367, 448, 198, 6738, 25064, 13...
2.825527
854
from fastapi import APIRouter from application.controller import appointment as AppointmentController from application.models.schema import appointment as AppointmentSchema from application.models.schema.utils import SuccessResponse router = APIRouter(prefix='/appointments', tags=['appointments']) @router.post("/cr...
[ 6738, 3049, 15042, 1330, 3486, 4663, 39605, 198, 198, 6738, 3586, 13, 36500, 1330, 12557, 355, 2034, 49805, 22130, 198, 6738, 3586, 13, 27530, 13, 15952, 2611, 1330, 12557, 355, 2034, 49805, 27054, 2611, 198, 6738, 3586, 13, 27530, 13, ...
3.642276
123
"""changing module to not nullable Revision ID: 6079f2fae734 Revises: 6de7e8a83d66, 1db87855f77c Create Date: 2021-06-10 17:32:53.546706 """ from alembic import op import sqlalchemy as sa import rdr_service.model.utils from sqlalchemy.dialects import mysql from rdr_service.participant_enums import PhysicalMeasuremen...
[ 37811, 22954, 8265, 284, 407, 9242, 540, 198, 198, 18009, 1166, 4522, 25, 718, 2998, 24, 69, 17, 69, 3609, 22, 2682, 198, 18009, 2696, 25, 718, 2934, 22, 68, 23, 64, 5999, 67, 2791, 11, 352, 9945, 23, 3695, 2816, 69, 3324, 66, 1...
3.148936
376
import webbrowser from mplus.moduls.response import Selector from mplus.utils.data import search import re as _re def re(response, regex, replace_entities=False, flags=_re.S): """ @summary: 正则匹配 注意:网页源码<a class='page-numbers'... 会被处理成<a class="page-numbers" ; 写正则时要写<a class="(.*?)"。 但不会改非html...
[ 11748, 3992, 40259, 198, 6738, 285, 9541, 13, 4666, 5753, 13, 26209, 1330, 9683, 273, 198, 6738, 285, 9541, 13, 26791, 13, 7890, 1330, 2989, 198, 11748, 302, 355, 4808, 260, 628, 628, 628, 628, 628, 628, 628, 198, 4299, 302, 7, 2620...
1.381226
1,044
# factotum.py - Plan 9 factotum integration for Mercurial # # Copyright (C) 2012 Steven Stallion <sstallion@gmail.com> # # 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...
[ 2, 1109, 313, 388, 13, 9078, 532, 5224, 860, 1109, 313, 388, 11812, 329, 12185, 333, 498, 198, 2, 198, 2, 15069, 357, 34, 8, 2321, 8239, 35719, 295, 1279, 82, 32989, 295, 31, 14816, 13, 785, 29, 198, 2, 198, 2, 770, 1430, 318, ...
3.524927
682
#!/usr/bin/env python3 import os import cv2 import pickle import os.path as osp import utils aruco = cv2.aruco def pose_esitmation( frame, dictionary, marker_length, camera_matrix, dist_coeffs): """Estimates poses of detected markers in the frame.""" gray = cv2.cvtC...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 11748, 28686, 198, 11748, 269, 85, 17, 198, 11748, 2298, 293, 198, 11748, 28686, 13, 6978, 355, 267, 2777, 198, 198, 11748, 3384, 4487, 198, 198, 11493, 1073, 796, 269, 85, ...
2.058758
1,804
import frappe import os import json import sys # bench execute mfi_customization.mfi.patch.migrate_patch.get_custom_role_permission # bench execute mfi_customization.mfi.patch.migrate_patch.set_custom_role_permission
[ 11748, 5306, 27768, 198, 11748, 28686, 198, 11748, 33918, 198, 11748, 25064, 628, 198, 2, 220, 220, 7624, 12260, 285, 12463, 62, 23144, 1634, 13, 76, 12463, 13, 17147, 13, 76, 42175, 62, 17147, 13, 1136, 62, 23144, 62, 18090, 62, 525,...
3
75
# Copyright maintained by EleutherAI. Originally from https://github.com/EleutherAI/github-downloader import chardet import magic import lm_dataformat as lmd import os import random import sys import traceback import shutil import csv import json from multiprocessing import cpu_count, Pool from tqdm import tqdm import...
[ 2, 15069, 9456, 416, 15987, 12866, 20185, 13, 19486, 422, 3740, 1378, 12567, 13, 785, 14, 28827, 12866, 20185, 14, 12567, 12, 15002, 263, 198, 198, 11748, 442, 446, 316, 198, 11748, 5536, 198, 11748, 300, 76, 62, 7890, 18982, 355, 300...
2.105875
1,549
import unittest from selenium import webdriver from time import sleep if __name__ == '__main__': unittest.main(verbosity = 2)
[ 11748, 555, 715, 395, 198, 6738, 384, 11925, 1505, 1330, 3992, 26230, 198, 6738, 640, 1330, 3993, 628, 628, 628, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 555, 715, 395, 13, 12417, 7, 19011, ...
2.934783
46
from adaptivefiltering.pdal import * from adaptivefiltering.paths import get_temporary_filename from . import dataset, minimal_dataset import jsonschema import os import pyrsistent import pytest _pdal_filter_list = [ "filters.csf", "filters.elm", "filters.outlier", "filters.pmf", "filters.skewne...
[ 6738, 29605, 10379, 20212, 13, 30094, 282, 1330, 1635, 198, 6738, 29605, 10379, 20212, 13, 6978, 82, 1330, 651, 62, 11498, 5551, 62, 34345, 198, 198, 6738, 764, 1330, 27039, 11, 10926, 62, 19608, 292, 316, 198, 198, 11748, 44804, 684, ...
2.469072
194
# -*- coding: utf-8 -*- # Generated by Django 1.11.5 on 2017-10-07 14:31 from __future__ import unicode_literals from django.conf import settings from django.db import migrations, models import django.db.models.deletion import uuid
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 2980, 515, 416, 37770, 352, 13, 1157, 13, 20, 319, 2177, 12, 940, 12, 2998, 1478, 25, 3132, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, ...
2.888889
81
from urlparse import urljoin from django.conf import settings from django.contrib import admin from django import forms from django.db import models try: from funfactory.urlresolvers import reverse except ImportError: from django.core.urlresolvers import reverse from .models import (Badge, Award, Nomination...
[ 6738, 19016, 29572, 1330, 19016, 22179, 198, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 198, 6738, 42625, 14208, 1330, 5107, 198, 6738, 42625, 14208, 13, 9945, 1330, 4981, 198...
2.821918
438
import pytest import grappa from grappa.config import Config
[ 11748, 12972, 9288, 198, 11748, 21338, 64, 198, 6738, 21338, 64, 13, 11250, 1330, 17056, 628 ]
3.875
16
# Generated by Django 3.0.5 on 2020-05-20 13:05 import uuid import django.db.models.deletion from django.conf import settings from django.db import migrations, models
[ 2, 2980, 515, 416, 37770, 513, 13, 15, 13, 20, 319, 12131, 12, 2713, 12, 1238, 1511, 25, 2713, 198, 198, 11748, 334, 27112, 198, 198, 11748, 42625, 14208, 13, 9945, 13, 27530, 13, 2934, 1616, 295, 198, 6738, 42625, 14208, 13, 10414,...
2.982456
57
a = input('Digite Algo: ') print(f'O tipo primitivo desse valor é: ', type(a)) print(f'Só tem espaços? {a.isspace()} ') print(f'Isso é um numero? {a.isnumeric()} ') print(f'Isso é Alfabético? {a.isalpha()} ') print(f'Isso é Alfanumerico? {a.isnumeric()} ') print(f'Está em letras maiúsculas? {a.isupper()} ') print(f'E...
[ 64, 796, 5128, 10786, 19511, 578, 978, 2188, 25, 705, 8, 198, 4798, 7, 69, 6, 46, 8171, 78, 2684, 270, 23593, 748, 325, 1188, 273, 38251, 25, 46083, 2099, 7, 64, 4008, 198, 4798, 7, 69, 6, 50, 10205, 2169, 1658, 8957, 16175, 418...
2.097938
194
import tensorflow as tf from preppy import BibPreppy def expand(x): ''' Hack. Because padded_batch doesn't play nice with scalars, so we expand the scalar to a vector of length 1 :param x: :return: ''' x['length'] = tf.expand_dims(tf.convert_to_tensor(x['length']), 0) x['book_id'] = tf.ex...
[ 11748, 11192, 273, 11125, 355, 48700, 198, 198, 6738, 662, 14097, 1330, 43278, 6719, 14097, 628, 198, 4299, 4292, 7, 87, 2599, 198, 220, 220, 220, 705, 7061, 198, 220, 220, 220, 18281, 13, 4362, 44582, 62, 43501, 1595, 470, 711, 3621,...
2.846995
732
from .base_datatype_translator import BaseDatatypeTranslator class BooleanTranslator(BaseDatatypeTranslator): """A Translator class for converting fields into DynamoDB booleans For example:: translator = BooleanTranslator(Boolean()) translator.to_dynamodb(True) {'BOOL': True} ...
[ 6738, 764, 8692, 62, 19608, 265, 2981, 62, 7645, 41880, 1330, 7308, 27354, 265, 2981, 8291, 41880, 198, 198, 4871, 41146, 8291, 41880, 7, 14881, 27354, 265, 2981, 8291, 41880, 2599, 198, 220, 220, 220, 37227, 32, 3602, 41880, 1398, 329,...
2.587838
148
import numpy as np import random
[ 11748, 299, 32152, 355, 45941, 198, 11748, 4738, 198 ]
3.666667
9
import numpy as np import librosa import os import scipy import json with open('train-test.json') as fopen: wavs = json.load(fopen)['train'] if not os.path.exists('augment'): os.makedirs('augment') for no, wav in enumerate(wavs): try: root, ext = os.path.splitext(wav) if (no + 1) %...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 9195, 4951, 64, 198, 11748, 28686, 198, 11748, 629, 541, 88, 198, 11748, 33918, 628, 628, 628, 628, 198, 4480, 1280, 10786, 27432, 12, 9288, 13, 17752, 11537, 355, 277, 9654, 25, 198, 220, 22...
1.763366
1,010
# -------------------------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # Licensed under the MIT License. See License.txt in the project root for # license information. # # Code generated by Microsoft (R) AutoRest Code Generator. # Changes may cause incor...
[ 2, 16529, 35937, 198, 2, 15069, 357, 66, 8, 5413, 10501, 13, 1439, 2489, 10395, 13, 198, 2, 49962, 739, 262, 17168, 13789, 13, 4091, 13789, 13, 14116, 287, 262, 1628, 6808, 329, 198, 2, 5964, 1321, 13, 198, 2, 198, 2, 6127, 7560, ...
5.590909
88
# import necessary libraries import numpy as np import pandas as pd from scipy.signal import find_peaks import matplotlib.pyplot as plt import csv # global variable definition n=100 # number of sample points deg1 = 30 # polynomial order for fit xs=np.linspace(0,1,n) # spacing for data x= np.arange(0, n, 1) ...
[ 2, 1330, 3306, 12782, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 198, 6738, 629, 541, 88, 13, 12683, 282, 1330, 1064, 62, 431, 4730, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 1...
2.458706
1,005
import json import requests from lxml import html import redis from pymongo import MongoClient import datetime # 1.直接下载coursebook入库 # 2.直接下载coursebook reportmonkey入库 # 3.下载coursebook获取reportmonkey key然后下载coursebook reportmonkey入库 # TODO 三个解析器 # TODO 两个下载器 if __name__ == "__main__": coursebook_spider = CouseBo...
[ 11748, 33918, 198, 11748, 7007, 198, 6738, 300, 19875, 1330, 27711, 198, 11748, 2266, 271, 198, 6738, 279, 4948, 25162, 1330, 42591, 11792, 198, 11748, 4818, 8079, 628, 198, 2, 352, 13, 33566, 112, 162, 236, 98, 10310, 233, 164, 121, ...
1.972527
182
"""Top-level objects and functions offered by the Skyfield library. Importing this library is not always the fastest way to use a Skyfield feature, since importing this module involves importing almost the entirety of Skyfield and its dependencies, but is the most convenient way for most users to use Skyfield's main f...
[ 37811, 9126, 12, 5715, 5563, 290, 5499, 4438, 416, 262, 5274, 3245, 5888, 13, 198, 198, 20939, 278, 428, 5888, 318, 407, 1464, 262, 14162, 835, 284, 779, 257, 5274, 3245, 198, 30053, 11, 1201, 33332, 428, 8265, 9018, 33332, 2048, 262,...
2.9389
491
general_error = """ <html> <head> <style> body { height: 100%; width: 100%; background-color: #9E9E9E; } .box { border: 1px solid green ; background...
[ 24622, 62, 18224, 796, 37227, 198, 220, 220, 220, 1279, 6494, 29, 198, 220, 220, 220, 220, 220, 220, 220, 1279, 2256, 29, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1279, 7635, 29, 198, 220, 220, 220, 220, 220, ...
1.49635
411
#!/usr/bin/env python2.7 # coding=utf-8 # Copyright 2019 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). # Check that the ./pants.pex was built using the passed abi specification. from __future__ import absolute_import, division, print_function, unicod...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 17, 13, 22, 198, 2, 19617, 28, 40477, 12, 23, 198, 2, 15069, 13130, 41689, 1628, 20420, 357, 3826, 27342, 9865, 3843, 20673, 13, 9132, 737, 198, 2, 49962, 739, 262, 24843, 13789, 11, 1062...
2.954545
264
from solvers.ea_solver import EASolver from solvers.math import interpolate_signal, ls_fit from solvers.tests.base_test_case import BaseTestCase from solvers.tests.correction_models import linear_correction
[ 6738, 1540, 690, 13, 18213, 62, 82, 14375, 1330, 412, 1921, 14375, 198, 6738, 1540, 690, 13, 11018, 1330, 39555, 378, 62, 12683, 282, 11, 43979, 62, 11147, 198, 6738, 1540, 690, 13, 41989, 13, 8692, 62, 9288, 62, 7442, 1330, 7308, 1...
3.409836
61
from django.contrib.auth import get_user_model from django.contrib.auth.models import User from .models import Purchase from django.test import TestCase from django.urls import reverse
[ 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 1330, 651, 62, 7220, 62, 19849, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 13, 27530, 1330, 11787, 198, 6738, 764, 27530, 1330, 27637, 198, 6738, 42625, 14208, 13, 9288, 1330, 6208, ...
3.528302
53
##################################################################################### # MIT License # # # # Copyright (C) 2018 Charly Lamothe ...
[ 1303, 29113, 29113, 14468, 4242, 198, 1303, 17168, 13789, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 22...
2.006993
1,144
# -*- coding: utf-8 -*- from sqlalchemy import Boolean, Column, Date, func, Integer, select, String, Text, Unicode from sqlalchemy.dialects.postgresql import ARRAY from sqlalchemy.orm import column_property, relationship from .api_model import ApiModel from .base import Base from .bill_keyword import bill_keyword fro...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 6738, 44161, 282, 26599, 1330, 41146, 11, 29201, 11, 7536, 11, 25439, 11, 34142, 11, 2922, 11, 10903, 11, 8255, 11, 34371, 198, 6738, 44161, 282, 26599, 13, 38969, ...
2.432432
370
from django.urls import path from .views import ( StudentFeePaymentCreateView, StudentFeePaymentListView, StudentFeePaymentDetailView, StudentFeePaymentUpdateView, ) urlpatterns = [ path( 'add/', StudentFeePaymentCreateView.as_view(), name='StudentFeePayment_add'), path...
[ 6738, 42625, 14208, 13, 6371, 82, 1330, 3108, 198, 198, 6738, 764, 33571, 1330, 357, 198, 220, 220, 220, 13613, 37, 1453, 19197, 434, 16447, 7680, 11, 198, 220, 220, 220, 13613, 37, 1453, 19197, 434, 8053, 7680, 11, 198, 220, 220, 2...
2.162866
307
# Copyright (c) 2021 PaddlePaddle Authors. All Rights Reserved. # Copyright 2018 Google AI, Google Brain and the HuggingFace Inc. team. # # 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, 15069, 357, 66, 8, 33448, 350, 37382, 47, 37382, 46665, 13, 1439, 6923, 33876, 13, 198, 2, 15069, 2864, 3012, 9552, 11, 3012, 14842, 290, 262, 12905, 2667, 32388, 3457, 13, 1074, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789,...
2.096551
24,008
#!/usr/bin/env python3 import math from math import sin, cos, pi import rospy import tf from geometry_msgs.msg import Point, Pose, Quaternion, Twist, Vector3 from am_driver.msg import WheelEncoder if __name__ == '__main__': try: poseEncCheckRK4 = PoseEncCheckRK4() rospy.spin() #od...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 11748, 10688, 198, 6738, 10688, 1330, 7813, 11, 8615, 11, 31028, 198, 198, 11748, 686, 2777, 88, 198, 11748, 48700, 198, 6738, 22939, 62, 907, 14542, 13, 19662, 1330, 6252, 11...
2.425
160
# # For licensing see accompanying LICENSE file. # Copyright (C) 2022 Apple Inc. All Rights Reserved. # import os import importlib import argparse from utils import logger from utils.common_utils import check_frozen_norm_layer from utils.ddp_utils import is_master, is_start_rank_node from utils.download_utils import ...
[ 2, 198, 2, 1114, 15665, 766, 19249, 38559, 24290, 2393, 13, 198, 2, 15069, 357, 34, 8, 33160, 4196, 3457, 13, 1439, 6923, 33876, 13, 198, 2, 198, 198, 11748, 28686, 198, 11748, 1330, 8019, 198, 11748, 1822, 29572, 198, 198, 6738, 33...
2.66756
373
import cv2 import numpy as np if __name__ == '__main__': ex_1() ex_2() ex_3()
[ 11748, 269, 85, 17, 198, 11748, 299, 32152, 355, 45941, 628, 628, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 409, 62, 16, 3419, 198, 220, 220, 220, 409, 62, 17, 3419, 198, 220, 220, 220...
1.938776
49
#!/usr/bin/env python # -*- encoding: utf-8 -*- """ @Author : 王超逸 @File : graphgl_api.py @Time : 2021/2/25 14:15 @Desc : graphgl风格的api """ from model import * from graphene_model_base import BaseCURD, GraphQLViewSet, GrapheneModelObject from graphene import Int, String, Field, List, Schema s...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 21004, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 31, 13838, 220, 1058, 220, 220, 13328, 23329, 164, 41678, 34460, 116, 198, 31, 8979, 220, 220, 220, 1058, ...
2.343949
157
# -*- coding: utf-8 -*- # This code is part of Qiskit. # # (C) Copyright IBM 2017, 2021. # # This code is licensed under the Apache License, Version 2.0. You may # obtain a copy of this license in the LICENSE.txt file in the root directory # of this source tree or at http://www.apache.org/licenses/LICENSE-2.0. # # Any...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 2, 770, 2438, 318, 636, 286, 1195, 1984, 270, 13, 198, 2, 198, 2, 357, 34, 8, 15069, 19764, 2177, 11, 33448, 13, 198, 2, 198, 2, 770, 2438, 318, 11971, 739, ...
2.209342
13,552
from . import YESTERDAY, PST_TIMEZONE from bs4 import BeautifulSoup from datetime import datetime import re import requests
[ 6738, 764, 1330, 21560, 5781, 26442, 11, 28220, 62, 34694, 57, 11651, 198, 6738, 275, 82, 19, 1330, 23762, 50, 10486, 198, 6738, 4818, 8079, 1330, 4818, 8079, 198, 11748, 302, 198, 11748, 7007, 628, 628 ]
3.527778
36
from typing import Optional from .typing import EstimatorType from .typing import RandomStateType
[ 6738, 19720, 1330, 32233, 198, 198, 6738, 764, 774, 13886, 1330, 10062, 320, 1352, 6030, 198, 6738, 764, 774, 13886, 1330, 14534, 9012, 6030, 628, 628 ]
3.923077
26
import torch from rph import RandomProjectionHashModule if __name__ == '__main__': s1 = "AAATGCGGATGT" s2 = "TAATGCGGATGT" d = { "AA": 0, "AC": 1, "AT": 2, "AG": 3, "CA": 4, "CC": 5, "CT": 6, "CG": 7, "TA": 8, "TC": 9, ...
[ 11748, 28034, 198, 6738, 374, 746, 1330, 14534, 16775, 295, 26257, 26796, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 264, 16, 796, 366, 3838, 1404, 15916, 11190, 1404, 19555, 1, 198, 220, 2...
1.637555
458
""" kombu.transport =============== Built-in transports. :copyright: (c) 2009 - 2010 by Ask Solem. :license: BSD, see LICENSE for more details. """ import sys from kombu.utils import rpartition DEFAULT_TRANSPORT = "kombu.transport.pyamqplib.Transport" MISSING_LIB = """ The %(feature)s requires the %(lib)s mod...
[ 37811, 198, 74, 2381, 84, 13, 7645, 634, 198, 25609, 18604, 198, 198, 39582, 12, 259, 45245, 13, 198, 198, 25, 22163, 4766, 25, 357, 66, 8, 3717, 532, 3050, 416, 16981, 1406, 10671, 13, 198, 25, 43085, 25, 347, 10305, 11, 766, 385...
2.467919
639
# Code written by Rakesh C Jakati for the Motor Imagery tutorial from oscpy.server import OSCThreadServer from time import sleep from oscpy.client import OSCClient osc = OSCThreadServer() sock = osc.listen(address='127.0.0.1', port=9002, default=True) @osc.address(b'/neuropype') sleep(100)
[ 2, 6127, 3194, 416, 371, 1124, 71, 327, 25845, 7246, 329, 262, 12533, 39440, 1924, 11808, 198, 198, 6738, 267, 1416, 9078, 13, 15388, 1330, 440, 6173, 16818, 10697, 198, 6738, 640, 1330, 3993, 198, 6738, 267, 1416, 9078, 13, 16366, 13...
2.882353
102
# Copyright (c) 2016 Canonical 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 ...
[ 2, 15069, 357, 66, 8, 1584, 19507, 605, 12052, 198, 2, 198, 2, 220, 220, 220, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 345, 743, 198, 2, 220, 220, 220, 407, 779, 428, 2393, 2845, 287, ...
2.072365
2,211
import traceback try: import signals.sim_server as sim import signals.sentiment as sentiment import sys server = sim.SimServer('/home/ibraaaa/servers/1mon_preprocess/') result = server.query(sys.argv[1]) result = server.rank(result[0], result[1]) for r in result: sentimen...
[ 11748, 12854, 1891, 198, 28311, 25, 198, 220, 220, 220, 1330, 10425, 13, 14323, 62, 15388, 355, 985, 198, 220, 220, 220, 1330, 10425, 13, 34086, 3681, 355, 15598, 198, 220, 220, 220, 1330, 25064, 198, 220, 220, 220, 220, 198, 220, 2...
2.361345
238
__version_info__ = (0, 9, 34) __version__ = '.'.join(str(v) for v in __version_info__)
[ 834, 9641, 62, 10951, 834, 796, 357, 15, 11, 860, 11, 4974, 8, 198, 834, 9641, 834, 796, 705, 2637, 13, 22179, 7, 2536, 7, 85, 8, 329, 410, 287, 11593, 9641, 62, 10951, 834, 8, 198 ]
2.351351
37