content
stringlengths
1
1.04M
input_ids
listlengths
1
774k
ratio_char_token
float64
0.38
22.9
token_count
int64
1
774k
from sqlalchemy import String, Column, ARRAY, TEXT, DateTime from api.db.base_class import Base from fastapi import Depends from api.db.utils import get_db from sqlalchemy.orm import Session from sqlalchemy.dialects.postgresql import UUID
[ 6738, 44161, 282, 26599, 1330, 10903, 11, 29201, 11, 5923, 30631, 11, 40383, 11, 7536, 7575, 198, 6738, 40391, 13, 9945, 13, 8692, 62, 4871, 1330, 7308, 198, 6738, 3049, 15042, 1330, 2129, 2412, 198, 6738, 40391, 13, 9945, 13, 26791, ...
3.315068
73
import os import datasets import collections
[ 11748, 28686, 198, 11748, 40522, 198, 11748, 17268, 628, 198 ]
4.7
10
from lib import agent from lib import congaboard from lib import node # #tests # #start as player 1 with maxDepth of 3 player = agent.Agent(0, 0, 3) #opponent will play random moves as player 2 opponent = agent.Agent(1, 0, 0) #setup new Conga board board = congaboard.CongaBoard() MoveCount = [ 0, 0 ] #root stat...
[ 6738, 9195, 1330, 5797, 198, 6738, 9195, 1330, 369, 70, 397, 11953, 198, 6738, 9195, 1330, 10139, 198, 198, 2, 198, 2, 41989, 198, 2, 198, 198, 2, 9688, 355, 2137, 352, 351, 3509, 48791, 286, 513, 198, 7829, 796, 5797, 13, 36772, ...
2.985106
470
from .equals import equals from .private._curry2 import _curry2 from .private._helper import getAttribute from .private._isArray import _isArray from .private._isFunction import _isFunction lastIndexOf = _curry2(inner_lastIndexOf)
[ 6738, 764, 4853, 874, 1330, 21767, 198, 6738, 764, 19734, 13557, 66, 16682, 17, 1330, 4808, 66, 16682, 17, 198, 6738, 764, 19734, 13557, 2978, 525, 1330, 651, 33682, 198, 6738, 764, 19734, 13557, 271, 19182, 1330, 4808, 271, 19182, 198,...
3.342857
70
import six import json from abc import abstractproperty, abstractmethod from requests.structures import CaseInsensitiveDict class BaseDatabaseManager(object): '''A base class for database managers in the scrapi processing module Must handle setup, teardown, and multi-process initialization of database ...
[ 11748, 2237, 198, 11748, 33918, 198, 6738, 450, 66, 1330, 12531, 26745, 11, 12531, 24396, 198, 198, 6738, 7007, 13, 7249, 942, 1330, 8913, 20376, 18464, 35, 713, 628, 198, 198, 4871, 7308, 38105, 13511, 7, 15252, 2599, 198, 220, 220, ...
2.930743
592
#!/usr/bin/python3 #pylint: skip-file __author__ = 'Bartosz Kościów' from unittest.mock import MagicMock from nose.tools import assert_equal, assert_true, assert_false, assert_is_not_none from nose.tools import assert_raises from nose.tools import assert_not_in from node_listener.storage.storage import Storage from no...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 18, 198, 2, 79, 2645, 600, 25, 14267, 12, 7753, 198, 198, 834, 9800, 834, 796, 705, 33, 433, 418, 89, 17634, 129, 249, 979, 10205, 86, 6, 198, 6738, 555, 715, 395, 13, 76, 735, 1330, 6139, ...
3.131148
122
# <<BEGIN-copyright>> # Copyright 2021, Lawrence Livermore National Security, LLC. # See the top-level COPYRIGHT file for details. # # SPDX-License-Identifier: BSD-3-Clause # <<END-copyright>> """ This module defines classes for storing the elapsed time since fission. Each 'duration' instance has an associated time, ...
[ 2, 9959, 33, 43312, 12, 22163, 4766, 4211, 198, 2, 15069, 33448, 11, 13914, 45036, 3549, 2351, 4765, 11, 11419, 13, 198, 2, 4091, 262, 1353, 12, 5715, 27975, 38162, 9947, 2393, 329, 3307, 13, 198, 2, 220, 198, 2, 30628, 55, 12, 34...
3.757813
128
# -*- coding: utf-8 -*- """ The data is (should be) based on the lecture Energie und Klimasysteme II, Erneuerbare Energieerzeugung am Gebäude, FS 2019 """ from __future__ import print_function
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 464, 1366, 318, 357, 21754, 307, 8, 1912, 319, 262, 19143, 412, 1008, 22699, 3318, 509, 2475, 4107, 927, 68, 220, 2873, 11, 198, 9139, 710, 15573, 49382, 4...
2.746479
71
from django.apps import AppConfig
[ 6738, 42625, 14208, 13, 18211, 1330, 2034, 16934, 628 ]
3.888889
9
# Copyright (C) 2018 by eHealth Africa : http://www.eHealthAfrica.org # # See the NOTICE file distributed with this work for additional information # regarding copyright ownership. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with # the License. Y...
[ 2, 15069, 357, 34, 8, 2864, 416, 304, 18081, 5478, 1058, 2638, 1378, 2503, 13, 68, 18081, 17584, 30997, 13, 2398, 198, 2, 198, 2, 4091, 262, 28536, 2393, 9387, 351, 428, 670, 329, 3224, 1321, 198, 2, 5115, 6634, 9238, 13, 198, 2, ...
3.780488
246
import tensorflow as tf from ...neat import * from ...neat.commands import *
[ 11748, 11192, 273, 11125, 355, 48700, 198, 198, 6738, 2644, 710, 265, 1330, 1635, 198, 6738, 2644, 710, 265, 13, 9503, 1746, 1330, 1635, 628, 198 ]
3.076923
26
from .filedialogs import *
[ 6738, 764, 69, 3902, 498, 18463, 1330, 1635 ]
3.25
8
import datetime import logging import yaml from logging import Formatter, Handler import requests from dateutil import tz from pathlib import Path file_dir = Path(__file__).parent.resolve() file_name = file_dir/"values.yaml" if file_name.exists(): stream = open(file_name, 'r') values = yaml.load(stream, Load...
[ 11748, 4818, 8079, 198, 11748, 18931, 198, 11748, 331, 43695, 198, 6738, 18931, 1330, 5178, 1436, 11, 32412, 198, 198, 11748, 7007, 198, 6738, 3128, 22602, 1330, 256, 89, 198, 6738, 3108, 8019, 1330, 10644, 628, 198, 7753, 62, 15908, 79...
2.849711
173
""" Contains unit tests for spotify.py """ import os import tempfile import unittest from SwSpotify.spotify import song, artist, get_info_windows, get_info_web from SwSpotify import SpotifyNotRunning, SpotifyPaused from mock import patch import platform class LinuxTests(unittest.TestCase): """ Unit tests for ...
[ 37811, 198, 4264, 1299, 4326, 5254, 329, 4136, 1958, 13, 9078, 198, 37811, 198, 11748, 28686, 198, 11748, 20218, 7753, 198, 11748, 555, 715, 395, 198, 6738, 2451, 32565, 1958, 13, 20485, 1958, 1330, 3496, 11, 6802, 11, 651, 62, 10951, ...
2.468887
3,423
# -*- coding: utf-8 -*- """ @author: alexyang @contact: alex.yang0326@gmail.com @file: inference.py @time: 2018/4/12 15:04 @desc: """ import os import sys import pickle from gen_relclassify_data import read_data import tensorflow as tf os.environ['CUDA_VISIBLE_DEVICES'] = '0' def compute_accuracy(model_pat...
[ 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 37811, 198, 198, 31, 9800, 25, 257, 2588, 17859, 198, 198, 31, 32057, 25, 257, 2588, 13, 17859, 3070, 2075, 31, 14816, 13, 785, 198, 198, 31, 7753, 25, 322...
2.207773
669
# Generated by Django 3.2 on 2021-12-11 23:46 from django.db import migrations, models import django.db.models.deletion import group.models import uuid
[ 2, 2980, 515, 416, 37770, 513, 13, 17, 319, 33448, 12, 1065, 12, 1157, 2242, 25, 3510, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 198, 11748, 42625, 14208, 13, 9945, 13, 27530, 13, 2934, 1616, 295, 198, 1174...
3.019608
51
#!/usr/bin/env python # Copyright (c) 2017-present, Facebook, 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 a...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 2, 15069, 357, 66, 8, 2177, 12, 25579, 11, 3203, 11, 3457, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 3...
1.905024
3,822
from ebl.fragmentarium.application.annotations_schema import AnnotationsSchema from ebl.fragmentarium.domain.annotation import Annotations from ebl.transliteration.domain.museum_number import MuseumNumber from ebl.tests.factories.annotation import AnnotationsFactory COLLECTION = "annotations"
[ 6738, 304, 2436, 13, 8310, 363, 434, 17756, 13, 31438, 13, 34574, 602, 62, 15952, 2611, 1330, 47939, 27054, 2611, 198, 6738, 304, 2436, 13, 8310, 363, 434, 17756, 13, 27830, 13, 1236, 14221, 1330, 47939, 198, 6738, 304, 2436, 13, 7645...
3.638554
83
# Imports from flask import (Flask, render_template, request, redirect, send_file, flash, url_for) from functions import login_pass, getFernetObj, set_directories, getData, unset_directories, genPassword # Global variables user_downloaded_file = False dataBook = { "userinfo": "", "password...
[ 2, 1846, 3742, 198, 6738, 42903, 1330, 357, 7414, 2093, 11, 8543, 62, 28243, 11, 2581, 11, 18941, 11, 3758, 62, 7753, 11, 7644, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1...
2.919643
448
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ Created on Sun Aug 2 12:17:01 2020 @author: louis.cammarata """ # Imports import numpy as np import pandas as pd import networkx as nx import logging logger = logging.getLogger(__name__) import OmicsIntegrator as oi def import_virus_partners(virus_partners_file_na...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 37811, 198, 41972, 319, 3825, 2447, 220, 362, 1105, 25, 1558, 25, 486, 12131, 198, 198, 31, 9800, 25, 21081, 271,...
2.210127
5,273
""" Admin Site for accounts app. """ from django.contrib import admin from django.contrib.auth import get_user_model admin.site.register(get_user_model())
[ 37811, 198, 220, 220, 220, 32053, 14413, 329, 5504, 598, 13, 198, 37811, 198, 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 1330, 651, 62, 7220, 62, 19849, 198, 198, 28482, 13, 1565...
3.076923
52
""" Home-Monitor: AI system for the detection of anomalous and possibly harmful events for people. Written by Gabriel Rojas - 2019 (Change) Copyright (c) 2019 G0 S.A.S. (Change) See LICENSE file for details Class information: Template to get data from a device type CamController. """ import sys ...
[ 37811, 198, 16060, 12, 35479, 25, 220, 198, 220, 220, 220, 9552, 1080, 329, 262, 13326, 286, 26921, 516, 290, 5457, 13568, 2995, 329, 661, 13, 628, 220, 220, 220, 22503, 416, 17371, 5564, 28121, 532, 13130, 357, 19400, 8, 198, 220, ...
2.014597
5,001
""" Default settings for socket connections. """ from modules.formatter.modules.colors import (BLUE, CYAN, GREEN, MAGENTA, RED, YELLOW) # Maximum time for a connection attempt by a client, in seconds. ATTEMPT_TIME = 3 # Number of unaccepted connections that the system wi...
[ 37811, 198, 19463, 6460, 329, 17802, 8787, 13, 198, 37811, 198, 198, 6738, 13103, 13, 687, 1436, 13, 18170, 13, 4033, 669, 1330, 357, 9148, 8924, 11, 30440, 1565, 11, 47606, 11, 28263, 3525, 32, 11, 23848, 11, 198, 220, 220, 220, 22...
2.704
250
#import LoRaDuplexCallback #import LoRaPingPong #import LoRaSender #import LoRaReceiver import gc, os import _thread from machine import SPI, UART, Pin import network from time import sleep import config_lora from sx127x import SX127x from controller_esp32 import ESP32Controller from uPySensors.mpu9250 import MPU9250 f...
[ 2, 11748, 6706, 21762, 35, 929, 2588, 47258, 198, 2, 11748, 6706, 21762, 49806, 47, 506, 198, 2, 11748, 6706, 21762, 50, 2194, 198, 2, 11748, 6706, 21762, 3041, 39729, 198, 11748, 308, 66, 11, 28686, 198, 11748, 4808, 16663, 198, 6738...
2.124895
1,185
from .console import ProcessCommunicationEventHandler
[ 6738, 764, 41947, 1330, 10854, 30813, 3299, 9237, 25060, 198 ]
5.4
10
from boa3.interop.runtime import *
[ 6738, 1489, 64, 18, 13, 3849, 404, 13, 43282, 1330, 1635, 628 ]
3
12
from typing import Any, List import copy from attr.exceptions import FrozenInstanceError class HalfFrozenObject: """object which does not allow attributes to bet set without properly calling a setter"""
[ 6738, 19720, 1330, 4377, 11, 7343, 198, 11748, 4866, 198, 6738, 708, 81, 13, 1069, 11755, 1330, 23673, 33384, 12331, 628, 198, 4871, 13139, 37, 42005, 10267, 25, 198, 220, 220, 220, 37227, 15252, 543, 857, 407, 1249, 12608, 284, 731, ...
4.2
50
import logging import aiorun import yaml from pydantic import ValidationError from telethon import TelegramClient, errors from yaml import YAMLError from tgpy import Config, app from tgpy.builtin_functions import add_builtin_functions from tgpy.console import console from tgpy.handlers import add_handlers from tgpy.m...
[ 11748, 18931, 198, 198, 11748, 257, 1504, 403, 198, 11748, 331, 43695, 198, 6738, 279, 5173, 5109, 1330, 3254, 24765, 12331, 198, 6738, 5735, 400, 261, 1330, 50203, 11792, 11, 8563, 198, 6738, 331, 43695, 1330, 575, 2390, 2538, 81, 1472...
3.10828
157
import pytest @pytest.fixture def test_filter(klass, days_agos, AnalyzedAgileTicket): """filter_issues ignores issues completed before the specified range.""" issue_list_kwargs = [] for i in range(1, 3): kwargs = dict( key="TEST-{}".format(i), committed=dict(state="Commi...
[ 11748, 12972, 9288, 628, 198, 31, 9078, 9288, 13, 69, 9602, 628, 198, 198, 4299, 1332, 62, 24455, 7, 74, 31172, 11, 1528, 62, 48215, 11, 16213, 8863, 10262, 576, 51, 9715, 2599, 198, 220, 220, 220, 37227, 24455, 62, 37165, 24245, 24...
2.199297
853
from os.path import join, dirname from setuptools import setup, find_packages from cloudly import __title__, __version__, __author__, __email__, __license__ setup( name='cloudly', version=__version__, description=__title__, long_description=open(join(dirname(__file__), 'README.md')).read(), autho...
[ 6738, 28686, 13, 6978, 1330, 4654, 11, 26672, 3672, 198, 198, 6738, 900, 37623, 10141, 1330, 9058, 11, 1064, 62, 43789, 198, 198, 6738, 6279, 306, 1330, 11593, 7839, 834, 11, 11593, 9641, 834, 11, 11593, 9800, 834, 11, 11593, 12888, 8...
2.185083
362
import Config import Constant from Knight import Knight
[ 11748, 17056, 198, 11748, 20217, 198, 6738, 6700, 1330, 6700 ]
5.5
10
num = int(input("Digite um número!")) print("O número informado é ", num)
[ 22510, 796, 493, 7, 15414, 7203, 19511, 578, 23781, 299, 21356, 647, 78, 2474, 4008, 198, 4798, 7203, 46, 299, 21356, 647, 78, 4175, 4533, 38251, 33172, 997, 8 ]
2.517241
29
"""Test recursive synchronous fmap.""" import typing as t from picard.functor import fmap
[ 37811, 14402, 45115, 18305, 516, 277, 8899, 526, 15931, 198, 198, 11748, 19720, 355, 256, 198, 198, 6738, 8301, 446, 13, 12543, 2715, 1330, 277, 8899, 198 ]
3.407407
27
from django.apps import AppConfig
[ 6738, 42625, 14208, 13, 18211, 1330, 2034, 16934, 628 ]
3.888889
9
# Copyright (c) 2017 The WebRTC project authors. All Rights Reserved. # # Use of this source code is governed by a BSD-style license # that can be found in the LICENSE file in the root of the source # tree. An additional intellectual property rights grant can be found # in the file PATENTS. All contributing project au...
[ 2, 15069, 357, 66, 8, 2177, 383, 5313, 49, 4825, 1628, 7035, 13, 1439, 6923, 33876, 13, 198, 2, 198, 2, 5765, 286, 428, 2723, 2438, 318, 21825, 416, 257, 347, 10305, 12, 7635, 5964, 198, 2, 326, 460, 307, 1043, 287, 262, 38559, ...
2.88383
637
import pytest from ..vector_common import * def test_to_vector(): """ Tests the capability of converting tuples and lists to CadQuery Vectors. """ # Test a tuple v1 = (1, 1, 0) v2 = to_vector(v1) assert v2 == Vector(1, 1, 0) # Test a list v1 = [1, 1, 0] v2 = to_vector(v1)...
[ 11748, 12972, 9288, 198, 6738, 11485, 31364, 62, 11321, 1330, 1635, 628, 198, 4299, 1332, 62, 1462, 62, 31364, 33529, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 30307, 262, 12971, 286, 23202, 12777, 2374, 290, 8341, 198, 220, 220, ...
2.272917
960
from unittest import TestCase from cnfencoder import Parser
[ 6738, 555, 715, 395, 1330, 6208, 20448, 198, 198, 6738, 269, 77, 69, 12685, 12342, 1330, 23042, 263, 628 ]
3.263158
19
""" Helper script to create config files for BlenderProc. """ import os import yaml import random import numpy as np import binascii # these paths have to be manually set before creating a config BLENDERPROC_ROOT = '' # /path/to/BlenderProc SHAPENET_ROOT = '' # /path/to/ShapeNetCore.v2 SUNCG_ROOT = '' # /path/to/s...
[ 37811, 198, 47429, 4226, 284, 2251, 4566, 3696, 329, 1086, 2194, 2964, 66, 13, 198, 37811, 198, 198, 11748, 28686, 198, 11748, 331, 43695, 198, 11748, 4738, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 9874, 292, 979, 72, 198, 198, ...
2.648485
165
import matplotlib.pyplot as plt # import matplotlib import numpy as np # import numpy import tensorflow as tf #import numpy as np #trX = np.linspace(-1, 1, 101) #Create a linear space of 101 points between 1 and 1 #trY = 2 * trX + np.random.randn(*trX.shape) * 0.4 + 0.2 #Create The y function based on the x axis #plt....
[ 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 1303, 1330, 2603, 29487, 8019, 198, 11748, 299, 32152, 355, 45941, 1303, 1330, 299, 32152, 198, 11748, 11192, 273, 11125, 355, 48700, 198, 2, 11748, 299, 32152, 355, 45941, 198, 1...
2.413242
876
print(f(10))
[ 198, 198, 4798, 7, 69, 7, 940, 4008, 198 ]
1.666667
9
import asyncio from monitor import win as monitor import action import json import ticker import os os.add_dll_directory( 'C:\\Users\\jay\\Documents\\projects\\file-monitor\\env\\Lib\\site-packages\\pywin32_system32' ) def default_callback(entry): """Called by the monitor loop on a fil...
[ 11748, 30351, 952, 201, 198, 6738, 5671, 1330, 1592, 355, 5671, 201, 198, 201, 198, 11748, 2223, 201, 198, 201, 198, 11748, 33918, 201, 198, 11748, 4378, 263, 201, 198, 201, 198, 201, 198, 11748, 28686, 201, 198, 201, 198, 418, 13, ...
2.588235
272
import grpc from concurrent import futures import time import meter_pb2_grpc as pb2_grpc import meter_pb2 as pb2 from google.protobuf.json_format import MessageToDict from service import get_measurement import traceback if __name__ == '__main__': serve() # python3 -m grpc_tools.protoc --proto_path=. ./meter.p...
[ 11748, 1036, 14751, 198, 6738, 24580, 1330, 25650, 198, 11748, 640, 198, 11748, 16430, 62, 40842, 17, 62, 2164, 14751, 355, 279, 65, 17, 62, 2164, 14751, 198, 11748, 16430, 62, 40842, 17, 355, 279, 65, 17, 198, 6738, 23645, 13, 11235,...
2.834646
127
import tornado.web
[ 11748, 33718, 13, 12384, 628 ]
4
5
# void_test.py # Author: Thomas MINIER - MIT License 2017-2018 from database.datasets import Dataset from database.descriptors import VoidDescriptor, many_void from rdflib import Graph dataset = Dataset("tests/data/test_config.yaml")
[ 2, 7951, 62, 9288, 13, 9078, 198, 2, 6434, 25, 5658, 20625, 38311, 532, 17168, 13789, 2177, 12, 7908, 198, 6738, 6831, 13, 19608, 292, 1039, 1330, 16092, 292, 316, 198, 6738, 6831, 13, 20147, 1968, 669, 1330, 18331, 24564, 1968, 273, ...
3.077922
77
# Authors: Andreas Mueller # Manoj Kumar # License: BSD 3 clause import numpy as np from .validation import _deprecate_positional_args @_deprecate_positional_args def compute_class_weight(class_weight, *, classes, y): """Estimate class weights for unbalanced datasets. Parameters ...
[ 2, 46665, 25, 33728, 17768, 201, 198, 2, 220, 220, 220, 220, 220, 220, 220, 220, 220, 1869, 13210, 26105, 201, 198, 2, 13789, 25, 347, 10305, 513, 13444, 201, 198, 201, 198, 11748, 299, 32152, 355, 45941, 201, 198, 201, 198, 6738, ...
2.190858
3,369
import numpy as np import pandas as pd
[ 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 628 ]
3.076923
13
from flask import render_template import connexion from flask import Flask, request from flask_restx import Resource, Api from flask_cors import CORS, cross_origin from Runner import Runner; app = Flask(__name__) api = Api(app) runner = Runner() CORS(app, support_credentials=True) @cross_origin(supports_credentia...
[ 6738, 42903, 1330, 8543, 62, 28243, 198, 11748, 369, 12413, 295, 198, 198, 6738, 42903, 1330, 46947, 11, 2581, 198, 6738, 42903, 62, 2118, 87, 1330, 20857, 11, 5949, 72, 198, 6738, 42903, 62, 66, 669, 1330, 327, 20673, 11, 3272, 62, ...
2.714932
221
def project_2D_to_3D(x, y, focal_length, pixel_size_x, pixel_size_y, principal_point_x, principal_point_y, camera_monitor_distance): """ Projects 2D point on image coordinate system (ICS) to 3D point on camera coordinate syste...
[ 198, 198, 4299, 1628, 62, 17, 35, 62, 1462, 62, 18, 35, 7, 87, 11, 331, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 25397, 62, 13664, 11, 198, 220, 220, 220, 2...
2.407326
1,365
from django.contrib.auth.models import User from django.test import TestCase from django_dynamic_fixture import G from mock import Mock from tour.models import Tour from tour.api import TourApiView
[ 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 13, 27530, 1330, 11787, 198, 6738, 42625, 14208, 13, 9288, 1330, 6208, 20448, 198, 6738, 42625, 14208, 62, 67, 28995, 62, 69, 9602, 1330, 402, 198, 6738, 15290, 1330, 44123, 198, 6738, 4205,...
3.553571
56
# Import required libraries import pandas as pd from sklearn.datasets import load_iris from factor_analyzer import FactorAnalyzer import matplotlib.pyplot as plt import data_class as dc df = pd.DataFrame(pd.read_csv('res_SEM.csv')) df_phone = df.iloc[:,:12] df_QOL = df.iloc[:,12:] print('Phones:') phone_f...
[ 2, 17267, 2672, 12782, 201, 198, 11748, 19798, 292, 355, 279, 67, 201, 198, 6738, 1341, 35720, 13, 19608, 292, 1039, 1330, 3440, 62, 29616, 201, 198, 6738, 5766, 62, 38200, 9107, 1330, 27929, 37702, 9107, 201, 198, 11748, 2603, 29487, ...
1.923077
988
# -*- coding:utf-8 -*- # author:huawei from python2sky.context.span import Span
[ 2, 532, 9, 12, 19617, 25, 40477, 12, 23, 532, 9, 12, 198, 2, 1772, 171, 120, 248, 13415, 38247, 198, 6738, 21015, 17, 15688, 13, 22866, 13, 12626, 1330, 49101, 198 ]
2.5
32
# As TUPLAS são imutáveis, dentro do programa times = ('Palmeiras', 'Flamengo', 'São Paulo', 'Santos', 'Corinthians', 'Fluminense', 'Cruzeiro', 'Grêmio') a = (1, 2, 3, 4, 8) b = (5, 6, 7, 8) c = a + b print(c) # A ordem altera os fatores em tuplas c = b + a print(c) # A ordem altera os fatorem em tuplas pessoa = ('P...
[ 2, 1081, 309, 52, 6489, 1921, 264, 28749, 545, 315, 6557, 303, 271, 11, 18794, 305, 466, 1430, 64, 198, 22355, 796, 19203, 11531, 1326, 343, 292, 3256, 705, 37, 2543, 1516, 78, 3256, 705, 50, 28749, 34410, 3256, 705, 50, 415, 418, ...
2.31453
585
''' Linear regression with one variable, ridge regression (L2 regularisation), linear regression with stochastic gradient descent. Plotting. Bence Mélykúti 22/02/2018 ''' import numpy as np import csv import itertools import matplotlib.pyplot as plt from sklearn import linear_model csvfile = open('../machine-learnin...
[ 7061, 6, 198, 14993, 451, 20683, 351, 530, 7885, 11, 32525, 20683, 357, 43, 17, 3218, 5612, 828, 14174, 20683, 351, 3995, 354, 3477, 31312, 18598, 13, 28114, 889, 13, 198, 198, 33, 594, 43579, 306, 74, 21356, 20259, 198, 1828, 14, 2...
2.652464
1,197
# -*- coding: utf-8 -*- import requests import logging import sys from apiwrapper import APIWrapper API_URL = 'https://api.sandbox.amadeus.com/v1.2' log = configure_logger() STRICT, GRACEFUL, IGNORE = 'strict', 'graceful', 'ignore'
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 11748, 7007, 198, 11748, 18931, 198, 11748, 25064, 198, 198, 6738, 2471, 14246, 430, 2848, 1330, 7824, 36918, 2848, 198, 198, 17614, 62, 21886, 796, 705, 5450, 1378, ...
2.552083
96
#Testing ESRNN import runpy import os print('\n') print(10*'='+'TEST ESRNN'+10*'=') print('\n')
[ 2, 44154, 412, 12562, 6144, 198, 11748, 1057, 9078, 198, 11748, 28686, 198, 198, 4798, 10786, 59, 77, 11537, 198, 4798, 7, 940, 9, 6, 11639, 10, 6, 51, 6465, 412, 12562, 6144, 6, 10, 940, 9, 6, 28, 11537, 198, 4798, 10786, 59, 7...
2.061224
49
from rabbitai.security.manager import RabbitaiSecurityManager # noqa: F401
[ 6738, 22746, 1872, 13, 12961, 13, 37153, 1330, 25498, 1872, 24074, 13511, 220, 1303, 645, 20402, 25, 376, 21844, 198 ]
3.8
20
from django.contrib import admin from .models import Recipe, Tag, Image, Ingredient, IngredientAmount # Register your models here. # class RecipeAdmin(admin.ModelAdmin): # fieldsets = [ # (None, {'fields': ['question_text']}), # ('Date information', {'fields': ['pub_date'], 'classes...
[ 6738, 42625, 14208, 13, 3642, 822, 1330, 13169, 198, 6738, 764, 27530, 1330, 26694, 11, 17467, 11, 7412, 11, 17589, 445, 1153, 11, 17589, 445, 1153, 31264, 628, 198, 2, 17296, 534, 4981, 994, 13, 198, 198, 2, 1398, 26694, 46787, 7, ...
2.657407
216
""" Testing module for the generator and devices classes""" import pickle import numpy as np import pytest from c3.generator.devices import LO, AWG, Mixer, Response, DigitalToAnalog, VoltsToHertz from c3.generator.generator import Generator from c3.signal.gates import Instruction from c3.signal.pulse import Envelope, ...
[ 37811, 23983, 8265, 329, 262, 17301, 290, 4410, 6097, 37811, 198, 198, 11748, 2298, 293, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 12972, 9288, 198, 6738, 269, 18, 13, 8612, 1352, 13, 42034, 1330, 17579, 11, 14356, 38, 11, 15561, ...
1.928262
2,077
from django.conf import settings EMAIL_MGR_TEMPLATE_PATH = getattr(settings, "EMAIL_MGR_TEMPLATE_PATH", "emailmgr")
[ 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 198, 27630, 4146, 62, 44, 10761, 62, 51, 3620, 6489, 6158, 62, 34219, 796, 651, 35226, 7, 33692, 11, 366, 27630, 4146, 62, 44, 10761, 62, 51, 3620, 6489, 6158, 62, 34219, 1600, 366, 12...
2.489796
49
import pytest from tortoise import Tortoise from app.config import get_settings from app.models import User from app.security.auth import create_password_hash settings = get_settings() @pytest.mark.asyncio
[ 11748, 12972, 9288, 198, 6738, 7619, 25678, 1330, 28467, 25678, 198, 198, 6738, 598, 13, 11250, 1330, 651, 62, 33692, 198, 6738, 598, 13, 27530, 1330, 11787, 198, 6738, 598, 13, 12961, 13, 18439, 1330, 2251, 62, 28712, 62, 17831, 198, ...
3.5
60
import csv from datetime import datetime, timedelta, date from random import randint from fwt import app, db from fwt.models import WeightRecord import config if __name__ == "__main__": app.config.from_object('config.Config') with app.app_context(): db.create_all() fgfgd() app.run()
[ 11748, 269, 21370, 198, 6738, 4818, 8079, 1330, 4818, 8079, 11, 28805, 12514, 11, 3128, 198, 6738, 4738, 1330, 43720, 600, 198, 6738, 277, 46569, 1330, 598, 11, 20613, 198, 6738, 277, 46569, 13, 27530, 1330, 14331, 23739, 198, 11748, 45...
2.752212
113
import os import yaml import torch import math import cv2 def voltage2pixel(y, phi, low, high): """ Converts the measurement tensor / vector from voltage scale to pixel scale, so that the neural network can understand. y - measurement phi - block measurement matrix low - lowest voltage pixel ...
[ 11748, 28686, 198, 11748, 331, 43695, 198, 11748, 28034, 198, 11748, 10688, 198, 11748, 269, 85, 17, 628, 198, 4299, 15004, 17, 32515, 7, 88, 11, 872, 72, 11, 1877, 11, 1029, 2599, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 1482...
2.418675
332
from django.shortcuts import render from dev_config import TESTING import os from django.conf import settings from django.http import HttpResponse, Http404
[ 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 198, 6738, 1614, 62, 11250, 1330, 43001, 2751, 198, 11748, 28686, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 11, 367, 29281...
3.738095
42
# Generated by Django 3.1.4 on 2020-12-20 23:58 from django.db import migrations, models import django.db.models.deletion
[ 2, 2980, 515, 416, 37770, 513, 13, 16, 13, 19, 319, 12131, 12, 1065, 12, 1238, 2242, 25, 3365, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 198, 11748, 42625, 14208, 13, 9945, 13, 27530, 13, 2934, 1616, 295, ...
2.818182
44
# # Copyright (C) 2020-2021 Arm Limited or its affiliates and Contributors. All rights reserved. # SPDX-License-Identifier: Apache-2.0 # import pathlib from unittest import TestCase, mock from datetime import datetime from tempfile import TemporaryDirectory from continuous_delivery_scripts.utils.configuration import co...
[ 2, 198, 2, 15069, 357, 34, 8, 12131, 12, 1238, 2481, 7057, 15302, 393, 663, 29116, 290, 25767, 669, 13, 1439, 2489, 10395, 13, 198, 2, 30628, 55, 12, 34156, 12, 33234, 7483, 25, 24843, 12, 17, 13, 15, 198, 2, 198, 11748, 3108, 8...
3.478528
163
#!/usr/bin/env python #-*- coding:utf-8 -*- import re import urllib.request, urllib.error, urllib.parse STATUS_FALSE = 0 STATUS_TRUE = 1 STATUS_ERROR = 2 STATUS_CHECK = 3 STATUS_COOKIE = 4 __status_false = re.compile("2ch_X:false") __status_true = re.compile("(2ch_X:true|書きこみました)") __status_error = re.compile("(2ch_...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 12, 9, 12, 19617, 25, 40477, 12, 23, 532, 9, 12, 198, 198, 11748, 302, 198, 11748, 2956, 297, 571, 13, 25927, 11, 2956, 297, 571, 13, 18224, 11, 2956, 297, 571, 13, 29572, 198...
1.910345
870
from __future__ import print_function import os import sys import requests import toml from dcos import util
[ 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 198, 198, 11748, 28686, 198, 11748, 25064, 198, 198, 11748, 7007, 198, 11748, 284, 4029, 198, 198, 6738, 288, 6966, 1330, 7736, 628, 628, 198 ]
3.515152
33
"""Adapting original DGCNN implementation from: https://github.com/WangYueFt/dgcnn/blob/master/pytorch/model.py """ import torch import torch.nn as nn def knn(x, k): """ K-nearest neighbors :param x: :param k: :return: Note: Identical to original DGCNN implementation """ inner = -2 * torch...
[ 37811, 48003, 278, 2656, 360, 15916, 6144, 7822, 422, 25, 198, 5450, 1378, 12567, 13, 785, 14, 54, 648, 56, 518, 37, 83, 14, 67, 36484, 20471, 14, 2436, 672, 14, 9866, 14, 9078, 13165, 354, 14, 19849, 13, 9078, 198, 37811, 198, 11...
2.264286
1,260
# "Structural" generated this file from C:\dev\javascript\.packages\structural\test\test.h at Wed Aug 16 2017 10:18:06 GMT+0300 (FLE Daylight Time) from construct2 import * from functools import partial d = d_Struct('d', Struct("a", Embed(BYTE)), String("b", undefined, encoding="utf-8"), )
[ 2, 366, 44909, 1523, 1, 7560, 428, 2393, 422, 327, 7479, 7959, 59, 37495, 17405, 43789, 59, 7249, 1523, 59, 9288, 59, 9288, 13, 71, 379, 3300, 2447, 1467, 2177, 838, 25, 1507, 25, 3312, 16987, 10, 3070, 405, 357, 37, 2538, 47743, ...
2.941748
103
__author__ = "Trang Ha" import socket from _thread import * from main import Player import pickle import random server = "192.168.1.123" port = 5555 s = socket.socket(socket.AF_INET, socket.SOCK_STREAM) s.bind((server, port)) s.listen(2) print("Waiting for a connection, Server Started") # Set up random pictionary w...
[ 834, 9800, 834, 796, 366, 2898, 648, 9398, 1, 198, 198, 11748, 17802, 198, 6738, 4808, 16663, 1330, 1635, 198, 6738, 1388, 1330, 7853, 198, 11748, 2298, 293, 198, 11748, 4738, 198, 198, 15388, 796, 366, 17477, 13, 14656, 13, 16, 13, ...
2.802469
243
"""The xbox integration.""" import asyncio from dataclasses import dataclass from datetime import timedelta import logging from typing import Dict, Optional import voluptuous as vol from xbox.webapi.api.client import XboxLiveClient from xbox.webapi.api.provider.catalog.const import HOME_APP_IDS, SYSTEM_PFN_ID_MAP from...
[ 37811, 464, 2124, 3524, 11812, 526, 15931, 198, 11748, 30351, 952, 198, 6738, 4818, 330, 28958, 1330, 4818, 330, 31172, 198, 6738, 4818, 8079, 1330, 28805, 12514, 198, 11748, 18931, 198, 6738, 19720, 1330, 360, 713, 11, 32233, 198, 198, ...
2.114555
2,968
############################################################################### # Copyright (c) 2017, Lawrence Livermore National Security, LLC. # Produced at the Lawrence Livermore National Laboratory # Written by Francesco Di Natale, dinatale3@llnl.gov. # # LLNL-CODE-734340 # All rights reserved. # This file is part ...
[ 29113, 29113, 7804, 4242, 21017, 198, 2, 15069, 357, 66, 8, 2177, 11, 13914, 45036, 3549, 2351, 4765, 11, 11419, 13, 198, 2, 21522, 771, 379, 262, 13914, 45036, 3549, 2351, 18643, 198, 2, 22503, 416, 27025, 1073, 6031, 14393, 1000, 11...
3.5734
797
# Copyright (c) 2019 PaddlePaddle Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by app...
[ 2, 220, 220, 15069, 357, 66, 8, 13130, 350, 37382, 47, 37382, 46665, 13, 1439, 6923, 33876, 13, 198, 2, 198, 2, 49962, 739, 262, 24843, 13789, 11, 10628, 362, 13, 15, 357, 1169, 366, 34156, 15341, 198, 2, 345, 743, 407, 779, 428, ...
2.536657
1,023
import sys if __name__ == "__main__": sol()
[ 11748, 25064, 628, 628, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220, 220, 1540, 3419, 198 ]
2.363636
22
from django.shortcuts import get_object_or_404, render, HttpResponseRedirect from django.urls import reverse_lazy from django.contrib.auth.mixins import LoginRequiredMixin, UserPassesTestMixin from django.views.generic import ListView, DetailView, CreateView, UpdateView, DeleteView, RedirectView from .models import Not...
[ 6738, 42625, 14208, 13, 19509, 23779, 1330, 651, 62, 15252, 62, 273, 62, 26429, 11, 8543, 11, 367, 29281, 31077, 7738, 1060, 198, 6738, 42625, 14208, 13, 6371, 82, 1330, 9575, 62, 75, 12582, 198, 6738, 42625, 14208, 13, 3642, 822, 13,...
3.78
150
# proxy module from __future__ import absolute_import from mayavi.modules.api import *
[ 2, 15741, 8265, 198, 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 198, 6738, 743, 15820, 13, 18170, 13, 15042, 1330, 1635, 198 ]
3.782609
23
# -*- encoding: utf-8 -*- ''' @File : vqvae_tokenizer.py @Time : 2021/01/11 17:57:43 @Author : Ming Ding @Contact : dm18@mails.tsinghua.edu.cn ''' # here put the import lib import os import sys import math import random from tqdm import tqdm import numpy as np import torch import torch.nn.functional a...
[ 2, 532, 9, 12, 21004, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 7061, 6, 198, 31, 8979, 220, 220, 220, 1058, 220, 220, 410, 80, 33353, 62, 30001, 7509, 13, 9078, 198, 31, 7575, 220, 220, 220, 1058, 220, 220, 33448, 14, 486, 14, ...
2.654321
162
from typing import List from pyspark.sql import DataFrame from pyspark.sql import functions as F from pyspark.sql.window import Window from cishouseholds.weights.derive import assign_ethnicity_white from cishouseholds.weights.derive import assign_population_projections from cishouseholds.weights.derive import assign_...
[ 6738, 19720, 1330, 7343, 198, 198, 6738, 279, 893, 20928, 13, 25410, 1330, 6060, 19778, 198, 6738, 279, 893, 20928, 13, 25410, 1330, 5499, 355, 376, 198, 6738, 279, 893, 20928, 13, 25410, 13, 17497, 1330, 26580, 198, 198, 6738, 269, 6...
2.293553
2,606
# -*- coding: utf-8 -*- # @Time : 2020/2/4 12:05 下午 # @Author : 徐缘 # @FileName: 1.recall.py # @Software: PyCharm """ https://tensorflow.google.cn/api_docs/python/tf api文档 1、将数据以numpy.ndarray格式导入python 2、用keras.Sequential构建序贯的模型。(不同的任务,设置不同的模型) 3、设置优化函数,损失函数。 4、设置batch size和epoch并训练 5、save...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 2488, 7575, 1058, 12131, 14, 17, 14, 19, 1105, 25, 2713, 220, 10310, 233, 39355, 230, 198, 2, 2488, 13838, 1058, 10263, 122, 238, 163, 120, 246, 198, 2, 2488, 897...
1.718729
2,926
import sympy as sp import numpy as np from kaa.bundle import Bundle from kaa.model import Model
[ 11748, 10558, 88, 355, 599, 198, 11748, 299, 32152, 355, 45941, 198, 198, 6738, 479, 7252, 13, 65, 31249, 1330, 25282, 198, 6738, 479, 7252, 13, 19849, 1330, 9104, 198 ]
3.233333
30
#!/usr/bin/env python # -*- coding: utf-8 -*- # Copyright (C) 2013- Yan Shoshitaishvili aka. zardus # Ruoyu Wang aka. fish # Andrew Dutcher aka. rhelmot # Kevin Borgolte aka. cao # # This program is free software; you can redistribute it and/or modify # it un...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 2, 15069, 357, 34, 8, 2211, 12, 10642, 911, 3768, 5350, 680, 85, 2403, 22430, 13, 1976, 446, 385, 198, 2, 220,...
2.523754
1,726
from . import _StringSerializer from nanome.util import Logs, DirectoryEntry from nanome._internal._util._serializers import _TypeSerializer
[ 6738, 764, 1330, 4808, 10100, 32634, 7509, 198, 6738, 15709, 462, 13, 22602, 1330, 5972, 82, 11, 27387, 30150, 198, 198, 6738, 15709, 462, 13557, 32538, 13557, 22602, 13557, 46911, 11341, 1330, 4808, 6030, 32634, 7509, 628 ]
3.864865
37
from PySide2 import QtWidgets, QtCore, QtGui import os import maya.cmds as cmds import AniPorterLibrary reload(AniPorterLibrary) USERAPPDIR = cmds.internalVar(userAppDir=True) DIRECTORY = os.path.join(USERAPPDIR, 'AnimLib')
[ 6738, 9485, 24819, 17, 1330, 33734, 54, 312, 11407, 11, 33734, 14055, 11, 33734, 8205, 72, 201, 198, 11748, 28686, 201, 198, 11748, 743, 64, 13, 28758, 82, 355, 23991, 82, 201, 198, 201, 198, 11748, 1052, 72, 47, 4337, 23377, 201, 1...
2.39
100
#!/bin/env python3.9 """ cyclic backup creating a tar file """ import datetime import getopt import logging import os import re import sqlite3 import stat import sys import tarfile import time import traceback from builtins import bool import jinja2 import yaml blocked = set() config = { 'db': 'cycbackup.db', ...
[ 2, 48443, 8800, 14, 24330, 21015, 18, 13, 24, 198, 37811, 198, 15539, 291, 11559, 4441, 257, 13422, 2393, 198, 37811, 198, 11748, 4818, 8079, 198, 11748, 651, 8738, 198, 11748, 18931, 198, 11748, 28686, 198, 11748, 302, 198, 11748, 4416...
2.111482
4,790
from time import sleep import requests from parsel import Selector from tests.support.dtos import CurrentDestinationStatus
[ 6738, 640, 1330, 3993, 198, 198, 11748, 7007, 198, 198, 6738, 1582, 741, 1330, 9683, 273, 198, 6738, 5254, 13, 11284, 13, 28664, 418, 1330, 9236, 24159, 1883, 19580, 628 ]
4.2
30
import streamlit as st
[ 11748, 4269, 18250, 355, 336, 628, 198 ]
3.571429
7
from gym_vizdoom.envs.navigation_train_game import NavigationTrainGame from gym_vizdoom.envs.constants import MAX_STEP_EXPLORATION
[ 6738, 11550, 62, 85, 528, 67, 4207, 13, 268, 14259, 13, 28341, 7065, 62, 27432, 62, 6057, 1330, 42115, 44077, 8777, 198, 6738, 11550, 62, 85, 528, 67, 4207, 13, 268, 14259, 13, 9979, 1187, 1330, 25882, 62, 42135, 62, 6369, 6489, 158...
2.911111
45
# Copyright 2021, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # * Redistributions of source code must retain the above copyright # notice, this list of con...
[ 2, 15069, 33448, 11, 15127, 23929, 44680, 6234, 1222, 317, 5777, 4146, 40, 29462, 13, 1439, 2489, 10395, 13, 198, 2, 198, 2, 2297, 396, 3890, 290, 779, 287, 2723, 290, 13934, 5107, 11, 351, 393, 1231, 198, 2, 17613, 11, 389, 10431, ...
3.529167
480
from functions.wl import Wl from functions.statuses import HttpStatuses from functions.command_line import Color if __name__ == "__main__": while True: try: choice = input("1 - Wyszukaj po NIP.\n2 - Wyszukaj po REGON.\n\nTwój wybór:") choice = int(choice) if choice in [1...
[ 6738, 5499, 13, 40989, 1330, 370, 75, 198, 6738, 5499, 13, 14269, 2664, 1330, 367, 29281, 17126, 2664, 198, 6738, 5499, 13, 21812, 62, 1370, 1330, 5315, 198, 198, 361, 11593, 3672, 834, 6624, 366, 834, 12417, 834, 1298, 198, 220, 220,...
2.002016
496
''' Extractors that interact with the Indico API. ''' import logging import os from pliers.extractors.image import ImageExtractor from pliers.extractors.text import TextExtractor from pliers.extractors.base import Extractor, ExtractorResult from pliers.transformers import BatchTransformerMixin from pliers.transformers...
[ 7061, 6, 198, 11627, 974, 669, 326, 9427, 351, 262, 1423, 3713, 7824, 13, 198, 7061, 6, 198, 198, 11748, 18931, 198, 11748, 28686, 198, 6738, 458, 3183, 13, 2302, 974, 669, 13, 9060, 1330, 7412, 11627, 40450, 198, 6738, 458, 3183, 1...
2.940594
808
""" openconfig_if_types This module contains a set of interface type definitions that are used across OpenConfig models. These are generally physical or logical interfaces, distinct from hardware ports (which are described by the OpenConfig platform model). """ import sys from collections import OrderedDict from yd...
[ 37811, 1280, 11250, 62, 361, 62, 19199, 220, 198, 198, 1212, 8265, 4909, 257, 900, 286, 7071, 2099, 17336, 326, 198, 533, 973, 1973, 4946, 16934, 4981, 13, 2312, 389, 4143, 3518, 198, 273, 12219, 20314, 11, 7310, 422, 6890, 14090, 357...
2.581976
921
from django.contrib.auth import get_user_model from django.urls import reverse # GET /medicos/ SAMPLE_MEDIC_RESPONSE = [ { "id": 1, "crm": 3711, "nome": "Drauzio Varella", "especialidade": { "id": 2, "nome": "Pediatria" } }, { "id": 2,...
[ 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 1330, 651, 62, 7220, 62, 19849, 198, 6738, 42625, 14208, 13, 6371, 82, 1330, 9575, 198, 198, 2, 17151, 1220, 1150, 291, 418, 14, 198, 49302, 16437, 62, 30733, 2149, 62, 19535, 47, 1340, ...
1.625704
1,953
#!/usr/bin/env python3 # -*- coding: utf-8 -*- import tensorflow as tf import numpy if __name__ == "__main__": m = LanguageModel(is_training=True, keep_prob=1, n_gpu=2) cfg = tf.ConfigProto(allow_soft_placement=True) cfg.gpu_options.allow_growth = True sess = tf.Session(config=cfg) sess....
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 11748, 11192, 273, 11125, 355, 48700, 198, 11748, 299, 32152, 198, 198, 361, 11593, 3672, 834, 6624, 366, 834,...
1.651815
606
import logging from mqtt_panel.web.widget.gauge import Gauge
[ 11748, 18931, 198, 198, 6738, 285, 80, 926, 62, 35330, 13, 12384, 13, 42655, 13, 70, 559, 469, 1330, 35094, 469, 628 ]
2.863636
22
from rest_framework.permissions import IsAuthenticated from rest_framework.response import Response from rest_framework.views import APIView from apps.authentication.serializers import IsVerifiedSerializer
[ 6738, 1334, 62, 30604, 13, 525, 8481, 1330, 1148, 47649, 3474, 198, 6738, 1334, 62, 30604, 13, 26209, 1330, 18261, 198, 6738, 1334, 62, 30604, 13, 33571, 1330, 3486, 3824, 769, 198, 198, 6738, 6725, 13, 41299, 3299, 13, 46911, 11341, ...
4.333333
48
# Create your views here. from datetime import date from django.shortcuts import render, redirect from teachers.models import Teacher, TeacherInfo, TeacherQualification from .forms import AddTeacherForm # Index view # detail view # create view # delete teacher
[ 2, 13610, 534, 5009, 994, 13, 198, 6738, 4818, 8079, 1330, 3128, 198, 6738, 42625, 14208, 13, 19509, 23779, 1330, 8543, 11, 18941, 198, 6738, 7799, 13, 27530, 1330, 32019, 11, 32019, 12360, 11, 32019, 46181, 2649, 198, 6738, 764, 23914,...
4
68
# Colorful honeycombs import turtle from random import randint taylor = turtle.Turtle() taylor.speed(100) taylor.color(255) def hex(): """Draw one hex at current location""" taylor.pendown() taylor.color( randint(0,255),randint(0,255),randint(0,255) ) taylor.begin_fill() for i in range(6): ...
[ 2, 5315, 913, 12498, 785, 1443, 198, 198, 11748, 28699, 198, 6738, 4738, 1330, 43720, 600, 628, 198, 83, 7167, 796, 28699, 13, 51, 17964, 3419, 198, 83, 7167, 13, 12287, 7, 3064, 8, 198, 83, 7167, 13, 8043, 7, 13381, 8, 628, 198, ...
1.889849
463
import pytest from sphinx.application import Sphinx from sphinx import version_info @pytest.mark.sphinx("html", testroot="basic")
[ 11748, 12972, 9288, 198, 6738, 599, 20079, 87, 13, 31438, 1330, 45368, 28413, 198, 6738, 599, 20079, 87, 1330, 2196, 62, 10951, 628, 198, 31, 9078, 9288, 13, 4102, 13, 82, 746, 28413, 7203, 6494, 1600, 1332, 15763, 2625, 35487, 4943, ...
3.142857
42
""" Run this module to generate the dataset for testing, randomly. """ import numpy as np import copy import csv import os from datetime import datetime from dependencies import * from basics import * import random as rd from time import time from shutil import copy as shucopy __author__ = 'Duy Cao' __version__ = '20...
[ 37811, 5660, 428, 8265, 284, 7716, 262, 27039, 329, 4856, 11, 15456, 13, 37227, 198, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 4866, 198, 11748, 269, 21370, 198, 11748, 28686, 198, 6738, 4818, 8079, 1330, 4818, 8079, 198, 6738, 20...
2.396825
441
import requests from bs4 import BeautifulSoup url = "https://www.eventi.garr.it/it/ws19/programma/workshop" r = requests.get(url) # get the search url using requests soup = BeautifulSoup(r.content) # create a BeautifulSoup object 'soup' of the content # extract all the events in the workshop #'find_all' method is ...
[ 11748, 7007, 198, 6738, 275, 82, 19, 1330, 23762, 50, 10486, 198, 198, 6371, 796, 366, 5450, 1378, 2503, 13, 15596, 72, 13, 70, 3258, 13, 270, 14, 270, 14, 18504, 1129, 14, 23065, 2611, 14, 38067, 1, 198, 198, 81, 796, 7007, 13, ...
2.964467
197