content
stringlengths
1
1.05M
input_ids
listlengths
1
883k
ratio_char_token
float64
1
22.9
token_count
int64
1
883k
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations import image_collection.models
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 4981, 11, 15720, 602, 198, 11748, 2939, 62, 43681, 13, 27530, 6...
3.136364
44
# Copying Holly Grimm's solution https://github.com/hollygrimm/cs294-homework/blob/master/hw1/bc.py # Copy and pasting and merging it into a copy of my behavior_cloner.py code. import argparse import pickle import os import sys import tensorflow.compat.v1 as tf import numpy as np from sklearn.model_selection import tr...
[ 2, 6955, 1112, 7764, 27145, 338, 4610, 3740, 1378, 12567, 13, 785, 14, 71, 5098, 2164, 8608, 14, 6359, 27696, 12, 26452, 6433, 14, 2436, 672, 14, 9866, 14, 36599, 16, 14, 15630, 13, 9078, 198, 2, 17393, 290, 1613, 278, 290, 35981, ...
2.325048
1,569
from __future__ import print_function import argparse import torch import torch.utils.data from torch import nn, optim from torch.nn import functional as F from torchvision import datasets, transforms from torchvision.utils import save_image import numpy as np parser = argparse.ArgumentParser(description='VAE MNIST ...
[ 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 198, 11748, 1822, 29572, 198, 11748, 28034, 198, 11748, 28034, 13, 26791, 13, 7890, 198, 6738, 28034, 1330, 299, 77, 11, 6436, 198, 6738, 28034, 13, 20471, 1330, 10345, 355, 376, 198, 6738,...
2.369738
879
# Author: Gheorghe Postelnicu from datetime import date import pandas as pd from io import BytesIO from urllib.request import urlopen
[ 2, 6434, 25, 402, 258, 2398, 258, 2947, 417, 6988, 84, 198, 6738, 4818, 8079, 1330, 3128, 198, 11748, 19798, 292, 355, 279, 67, 198, 6738, 33245, 1330, 2750, 4879, 9399, 198, 6738, 2956, 297, 571, 13, 25927, 1330, 19016, 9654, 628 ]
3.214286
42
from django.db import migrations, models
[ 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 628 ]
3.818182
11
""" Definition of the :class:`PersonNameTestCase` class. """ from dicom_parser.data_elements.person_name import PersonName from tests.test_data_element import DataElementTestCase
[ 37811, 198, 36621, 286, 262, 1058, 4871, 25, 63, 15439, 5376, 14402, 20448, 63, 1398, 13, 198, 37811, 198, 6738, 288, 291, 296, 62, 48610, 13, 7890, 62, 68, 3639, 13, 6259, 62, 3672, 1330, 7755, 5376, 198, 6738, 5254, 13, 9288, 62, ...
3.461538
52
"""Fixtures for models module.""" from physalia.models import Measurement import numpy def create_measurement(use_case='login', app_pkg='com.package', duration=2, energy_consumption=30): """Fake data for measurement.""" return Measurement( ...
[ 37811, 37, 25506, 329, 4981, 8265, 526, 15931, 198, 198, 6738, 2281, 9752, 13, 27530, 1330, 24291, 434, 198, 11748, 299, 32152, 628, 198, 4299, 2251, 62, 1326, 5015, 434, 7, 1904, 62, 7442, 11639, 38235, 3256, 198, 220, 220, 220, 220,...
1.930012
843
import tensorflow as tf from config import config from utils.utils import * import logging from DL_Models.tf_models.ConvNet import ConvNet
[ 11748, 11192, 273, 11125, 355, 48700, 198, 6738, 4566, 1330, 4566, 198, 6738, 3384, 4487, 13, 26791, 1330, 1635, 198, 11748, 18931, 198, 6738, 23641, 62, 5841, 1424, 13, 27110, 62, 27530, 13, 3103, 85, 7934, 1330, 34872, 7934, 198 ]
3.475
40
from __future__ import print_function from __future__ import absolute_import from __future__ import division import scriptcontext as sc import compas_rhino from compas_3gs.rhino import SettingsForm from compas_3gs.rhino import ForceVolMeshObject from compas_3gs.rhino import FormNetworkObject __commandname__ = "TGS...
[ 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 198, 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 198, 6738, 11593, 37443, 834, 1330, 7297, 198, 198, 11748, 4226, 22866, 355, 629, 198, 198, 11748, 552, 292, 62, 17179, 2879, 198, 198, ...
4.189394
132
import setuptools with open("README.md", "r") as fh: long_description = fh.read() setuptools.setup( name="xdcc", version="0.0.3", author="Thiago T. P. Silva", author_email="thiagoteodoro501@gmail.com", description="A simple XDCC downloader written in python3", long_description=long_descrip...
[ 11748, 900, 37623, 10141, 198, 198, 4480, 1280, 7203, 15675, 11682, 13, 9132, 1600, 366, 81, 4943, 355, 277, 71, 25, 198, 220, 220, 220, 890, 62, 11213, 796, 277, 71, 13, 961, 3419, 198, 198, 2617, 37623, 10141, 13, 40406, 7, 198, ...
2.543689
309
"""Modified code from https://developers.google.com/optimization/routing/tsp#or-tools """ # Copyright Matthew Mack (c) 2020 under CC-BY 4.0: https://creativecommons.org/licenses/by/4.0/ from __future__ import print_function import math from ortools.constraint_solver import routing_enums_pb2 from ortools.constraint_sol...
[ 37811, 5841, 1431, 2438, 422, 3740, 1378, 16244, 364, 13, 13297, 13, 785, 14, 40085, 1634, 14, 81, 13660, 14, 912, 79, 2, 273, 12, 31391, 37227, 198, 2, 15069, 9308, 16640, 357, 66, 8, 12131, 739, 12624, 12, 17513, 604, 13, 15, 25...
2.601425
2,386
import pytest import payload as pl from .fixtures import Fixtures
[ 11748, 12972, 9288, 198, 198, 11748, 21437, 355, 458, 198, 198, 6738, 764, 69, 25506, 1330, 376, 25506, 628, 198 ]
3.5
20
import numpy as np from pydrake.all import *
[ 11748, 299, 32152, 355, 45941, 198, 6738, 279, 5173, 33788, 13, 439, 1330, 1635, 198 ]
3
15
import os import shadercompiler
[ 198, 11748, 28686, 198, 11748, 33030, 5589, 5329, 628 ]
3.777778
9
# Generated by Django 2.2.13 on 2021-01-22 17:41 from django.db import migrations, models import django.db.models.deletion import django.utils.timezone
[ 2, 2980, 515, 416, 37770, 362, 13, 17, 13, 1485, 319, 33448, 12, 486, 12, 1828, 1596, 25, 3901, 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.90566
53
import urllib.request import cv2 import numpy as np import time URL = "http://192.168.1.3:8080/shot.jpg" while True: img_arr = np.array(bytearray(urllib.request.urlopen(URL).read()),dtype=np.uint8) img = cv2.imdecode(img_arr,-1) cv2.imshow('IPWebcam',img) q = cv2.waitKey(1) if q == ord("q"...
[ 11748, 2956, 297, 571, 13, 25927, 201, 198, 11748, 269, 85, 17, 201, 198, 11748, 299, 32152, 355, 45941, 201, 198, 11748, 640, 201, 198, 21886, 796, 366, 4023, 1378, 17477, 13, 14656, 13, 16, 13, 18, 25, 1795, 1795, 14, 9442, 13, ...
1.984043
188
import sys import time import arcpy import traceback import GeneralizeDEM if __name__ == '__main__': # SET PARAMETERS HERE # -------------------------------------------------------------------- demdataset = 'X:/Work/Scripts & Tools/MY/DEMGEN/mistral' marine = 'X:/Work/Scripts & Tools/MY/DEMGEN/DEMGENE...
[ 11748, 25064, 198, 11748, 640, 198, 11748, 10389, 9078, 198, 11748, 12854, 1891, 198, 11748, 3611, 1096, 39429, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 628, 220, 220, 220, 1303, 25823, 29463, 2390, 2767, 4877, ...
2.202368
929
#! /usr/bin/python3 # -*- coding: utf-8 -*- # # json_python_read.py # # Jul/25/2014 # # --------------------------------------------------------------------- import sys sys.path.append ("/var/www/data_base/common/python_common") # from file_io import file_to_str_proc # # --------------------------------------------...
[ 2, 0, 1220, 14629, 14, 8800, 14, 29412, 18, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 198, 2, 197, 17752, 62, 29412, 62, 961, 13, 9078, 198, 2, 198, 2, 197, 197, 197, 197, 197, 16980, 14, 1495, 1...
3.269006
171
# -*- coding: utf-8 -*- from __future__ import unicode_literals from django.db import models, migrations
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 6738, 11593, 37443, 834, 1330, 28000, 1098, 62, 17201, 874, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 4981, 11, 15720, 602, 628 ]
2.891892
37
from math import radians, cos, sin, asin, sqrt, floor, pow import math lat1 = 11.00461011 lon1 = 76.95691543 lat2 = 11.0070471 lon2 = 76.96110704 lon1 = radians(lon1) lon2 = radians(lon2) lat1 = radians(lat1) lat2 = radians(lat2) # Haversine formula dlon = lon2 - lon1 dlat = lat2 - lat1 a = sin(...
[ 6738, 10688, 1330, 2511, 1547, 11, 8615, 11, 7813, 11, 355, 259, 11, 19862, 17034, 11, 4314, 11, 7182, 198, 11748, 10688, 628, 198, 15460, 16, 796, 1367, 13, 405, 3510, 8784, 16, 220, 220, 220, 220, 198, 14995, 16, 796, 8684, 13, ...
2.093878
245
from slixmpp.exceptions import XMPPError from ..conf import settings mechanisms = {} def get_sasl_by_name(name): return mechanisms.get(name, None)
[ 6738, 1017, 844, 76, 381, 13, 1069, 11755, 1330, 1395, 7378, 47, 12331, 198, 6738, 11485, 10414, 1330, 6460, 198, 198, 1326, 3147, 6583, 796, 23884, 198, 198, 4299, 651, 62, 82, 292, 75, 62, 1525, 62, 3672, 7, 3672, 2599, 198, 220, ...
2.781818
55
from django.http import HttpResponse
[ 6738, 42625, 14208, 13, 4023, 1330, 367, 29281, 31077, 628 ]
3.8
10
""" Sprite Rotation With A Tank. Vehicles or tower defense turrets can have parts that can rotate toward targets. These parts are usually represented with separate sprites drawn relative to attachment points on the main body. Because these sprites are usually asymmetrical, we have to rotate them around their attachme...
[ 37811, 198, 38454, 578, 371, 14221, 2080, 317, 15447, 13, 198, 198, 37870, 2983, 393, 10580, 3761, 41104, 460, 423, 3354, 198, 5562, 460, 23064, 3812, 6670, 13, 198, 4711, 3354, 389, 3221, 7997, 351, 4553, 42866, 198, 41549, 3585, 284, ...
3.52809
356
import datetime import requests import requests_cache from rest_framework import status from rest_framework.decorators import api_view from rest_framework.response import Response from api.commonresponses import DOWNSTREAM_ERROR_RESPONSE from api.modules.github import constants from api.modules.github.github_response...
[ 11748, 4818, 8079, 198, 198, 11748, 7007, 198, 11748, 7007, 62, 23870, 198, 6738, 1334, 62, 30604, 1330, 3722, 198, 6738, 1334, 62, 30604, 13, 12501, 273, 2024, 1330, 40391, 62, 1177, 198, 6738, 1334, 62, 30604, 13, 26209, 1330, 18261, ...
3.767241
116
import os # import pygame from mutagen.mp3 import MP3 import time from classuiui import MyFrame1 import wx # import thread import threading import multiprocessing from playsound import playsound from test001 import MyFrame1 # file="cd&&cd music&&cd&&StarSky.mp3" # os.system(file) # pygame.mixer.init() # audio = MP3("...
[ 11748, 28686, 198, 2, 1330, 12972, 6057, 198, 6738, 4517, 11286, 13, 3149, 18, 1330, 4904, 18, 198, 11748, 640, 198, 6738, 1398, 9019, 9019, 1330, 2011, 19778, 16, 198, 11748, 266, 87, 198, 2, 1330, 4704, 198, 11748, 4704, 278, 198, ...
2.596639
357
import mmcv import os import numpy as np from mmcv.runner import load_checkpoint from mmdet.models import build_detector from mmdet.apis import init_detector, inference_detector import torch # device = torch.device("cpu") # os.environ["CUDA_VISIBLE_DEVICES"]="" # import pdb; pdb.set_trace() config_file = '../configs/...
[ 11748, 8085, 33967, 198, 11748, 28686, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 8085, 33967, 13, 16737, 1330, 3440, 62, 9122, 4122, 198, 6738, 8085, 15255, 13, 27530, 1330, 1382, 62, 15255, 9250, 198, 6738, 8085, 15255, 13, 499, 2...
2.588816
304
#!/usr/bin/env python3 # file://mkpy3_finder_chart_survey_fits_image_get_v1.py # Kenneth Mighell # SETI Institute # ============================================================================= def mkpy3_finder_chart_survey_fits_image_get_v1( ra_deg=None, dec_deg=None, radius_arcmin=None, survey=No...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 2, 2393, 1378, 28015, 9078, 18, 62, 22805, 62, 40926, 62, 11793, 3304, 62, 21013, 62, 9060, 62, 1136, 62, 85, 16, 13, 9078, 198, 198, 2, 23632, 24488, 12758, 198, 2, 25823...
2.496131
1,163
""" marathontcp.py Author: Steven Gantz Date: 11/22/2016 These two classes are used as custom TCP Servers and its accompanying handler that defines each request. These class are what forward the data from the preset /metrics endpoints in the scaled marathon instances directly to the TCP servers running from this appli...
[ 37811, 198, 3876, 776, 756, 13155, 13, 9078, 198, 13838, 25, 8239, 402, 46269, 198, 10430, 25, 1367, 14, 1828, 14, 5304, 198, 198, 4711, 734, 6097, 389, 973, 355, 2183, 23633, 2930, 690, 290, 663, 19249, 198, 30281, 326, 15738, 1123, ...
4.114583
96
import pytest import io import random from copy import deepcopy from horcrux import io as hio from horcrux.hrcx_pb2 import StreamBlock from horcrux.sss import Share, Point def test_init_horcrux(): h = hio.Horcrux(io.BytesIO()) def test_horcrux__write_bytes(hx): hx._write_bytes(b'123') assert hx.str...
[ 11748, 12972, 9288, 198, 198, 11748, 33245, 198, 11748, 4738, 198, 6738, 4866, 1330, 2769, 30073, 198, 198, 6738, 3076, 32838, 87, 1330, 33245, 355, 289, 952, 198, 6738, 3076, 32838, 87, 13, 71, 6015, 87, 62, 40842, 17, 1330, 13860, 1...
2.03367
2,079
#!/usr/bin/env python3 """ A Pandoc filter to create non-code diffs. `add` and `rm` are the classes that can be added to a `Div` or a `Span`. `add` colors the text green, and `rm` colors the text red. For HTML, `add` also underlines the text, and `rm` also strikes out the text. # Example ## `Div` Unchanged portion...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 37811, 198, 32, 16492, 420, 8106, 284, 2251, 1729, 12, 8189, 814, 82, 13, 4600, 2860, 63, 290, 4600, 26224, 63, 389, 262, 6097, 326, 198, 5171, 307, 2087, 284, 257, 4600, ...
2.620192
208
from __future__ import absolute_import, unicode_literals
[ 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 11, 28000, 1098, 62, 17201, 874, 628, 628, 198 ]
3.588235
17
""" Displays anatomical data from the mesoscope """ from skimage.io import imread from napari import Viewer, gui_qt stack = imread('data/mesoscope/anatomical/volume_zoomed.tif') with gui_qt(): # create an empty viewer viewer = Viewer() # add the image layer = viewer.add_image(stack, name='stack', c...
[ 37811, 198, 7279, 26024, 48631, 1366, 422, 262, 18842, 40326, 198, 37811, 198, 198, 6738, 1341, 9060, 13, 952, 1330, 545, 961, 198, 6738, 25422, 2743, 1330, 3582, 263, 11, 11774, 62, 39568, 198, 198, 25558, 796, 545, 961, 10786, 7890, ...
2.788321
137
from .. import utils from ..config import table paper = Paper()
[ 6738, 11485, 1330, 3384, 4487, 198, 6738, 11485, 11250, 1330, 3084, 628, 198, 20189, 796, 14962, 3419, 198 ]
3.666667
18
import discord from discord.ext import commands from utils.database import sqlite, create_tables
[ 11748, 36446, 198, 6738, 36446, 13, 2302, 1330, 9729, 198, 6738, 3384, 4487, 13, 48806, 1330, 44161, 578, 11, 2251, 62, 83, 2977, 628, 628, 220, 220, 198 ]
3.678571
28
# coding: utf-8 # In[2]: import pandas as pd import numpy as np import h5py # In[24]: input_step_size = 50 output_size = 30 sliding_window = False file_name= 'bitcoin2012_2017_50_30_prediction.h5' # In[19]: df = pd.read_csv('data/bitstampUSD_1-min_data_2012-01-01_to_2017-05-31.csv').dropna().tail(1000000) ...
[ 198, 2, 19617, 25, 3384, 69, 12, 23, 198, 198, 2, 554, 58, 17, 5974, 628, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 289, 20, 9078, 628, 198, 2, 554, 58, 1731, 5974, 628, 198, 15414, 62...
2.378187
706
import requests if __name__ == '__main__': main()
[ 11748, 7007, 628, 198, 198, 361, 11593, 3672, 834, 6624, 705, 834, 12417, 834, 10354, 198, 220, 220, 220, 1388, 3419, 198 ]
2.590909
22
# Generated by Django 3.1.12 on 2021-09-18 12:55 from django.db import migrations
[ 2, 2980, 515, 416, 37770, 513, 13, 16, 13, 1065, 319, 33448, 12, 2931, 12, 1507, 1105, 25, 2816, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 628 ]
2.8
30
#!/usr/bin/python import requests import json import random from sets import Set # # Creates client-side connectivity json # # # Creates line-side connectivity json # # # Obtains TAPI context through restconf # # # Check if the node is transponder. # True - transponder # False - OLS # # # Parse src and dst ...
[ 2, 48443, 14629, 14, 8800, 14, 29412, 198, 198, 11748, 7007, 198, 11748, 33918, 198, 11748, 4738, 198, 6738, 5621, 1330, 5345, 628, 198, 2, 198, 2, 7921, 274, 5456, 12, 1589, 19843, 33918, 198, 2, 628, 198, 2, 198, 2, 7921, 274, 1...
3.318182
462
""" The outfile structure is the following: diameter density birth lifetime is_captured stuck_to_geometry theta (blank line) Re Ur (blank line) n_trajectory x1 y1 up1 vp1 Uf1 Vf1 gradpx1 gradpy1 ap_x1 ap_y1 af_x1 af_y1 x2 y2 up2 vp2 Uf2 Vf2 gradpx2 gradpy2 ap_x2 ap_y2 af_x2 af_y2 ... xNt yNt upNt vpNt UfNt VfNt gradpx...
[ 37811, 198, 464, 503, 7753, 4645, 318, 262, 1708, 25, 198, 198, 67, 13173, 12109, 198, 24280, 10869, 198, 271, 62, 27144, 1522, 7819, 62, 1462, 62, 469, 15748, 262, 8326, 198, 7, 27190, 1627, 8, 198, 3041, 8799, 198, 7, 27190, 1627,...
2.511962
209
########## 1.2.3. Formulao matemtica de reduo de dimensionalidade LDA ########## # Primeiro note que K significa que \mu_k so vetores em \mathcal{R}^d, e eles esto em um subespao afim H de dimenso no mximo K - 1 (2 pontos esto em uma linha, 3 pontos esto em um plano, etc.) ). # Como mencionado acima, podemos...
[ 7804, 2235, 352, 13, 17, 13, 18, 13, 19639, 78, 2603, 368, 83, 3970, 390, 2027, 78, 390, 38517, 312, 671, 406, 5631, 1303, 7804, 2, 628, 198, 220, 220, 220, 1303, 5537, 7058, 3465, 8358, 509, 2216, 64, 8358, 3467, 30300, 62, 74, ...
2.813406
552
"""A collection of cards.""" import random from csrv.model import cards from csrv.model.cards import card_info # This import is just to pull in all the card definitions import csrv.model.cards.corp import csrv.model.cards.runner
[ 37811, 32, 4947, 286, 4116, 526, 15931, 198, 198, 11748, 4738, 198, 6738, 269, 27891, 85, 13, 19849, 1330, 4116, 198, 6738, 269, 27891, 85, 13, 19849, 13, 27761, 1330, 2657, 62, 10951, 198, 198, 2, 770, 1330, 318, 655, 284, 2834, 28...
3.236111
72
ans = True while ans: print(""" 1.Add a Student 2.Delete a Student 3.Look Up Student Record 4.Exit/Quit """) ans = input("What would you like to do? ") if ans == "1": print("\nStudent Added") elif ans == "2": print("\n Student Deleted") elif ans == "3": pr...
[ 504, 796, 6407, 198, 4514, 9093, 25, 198, 220, 220, 220, 3601, 7203, 15931, 198, 220, 220, 220, 352, 13, 4550, 257, 13613, 198, 220, 220, 220, 362, 13, 38727, 257, 13613, 198, 220, 220, 220, 513, 13, 8567, 3205, 13613, 13266, 198, ...
2.213953
215
from __future__ import print_function, division import sys sys.dont_write_bytecode = True from lib import *
[ 6738, 11593, 37443, 834, 1330, 3601, 62, 8818, 11, 7297, 198, 11748, 25064, 198, 17597, 13, 67, 756, 62, 13564, 62, 26327, 8189, 796, 6407, 198, 198, 6738, 9195, 1330, 1635, 198, 220, 220, 220, 220, 198 ]
3.081081
37
from setuptools import setup import pyhap.const as pyhap_const PROJECT_NAME = 'HAP-python' URL = 'https://github.com/ikalchev/{}'.format(PROJECT_NAME) PROJECT_URLS = { 'Bug Reports': '{}/issues'.format(URL), 'Documentation': 'http://hap-python.readthedocs.io/en/latest/', 'Source': '{}/tree/master'.format...
[ 6738, 900, 37623, 10141, 1330, 9058, 198, 198, 11748, 12972, 45897, 13, 9979, 355, 12972, 45897, 62, 9979, 628, 198, 31190, 23680, 62, 20608, 796, 705, 39, 2969, 12, 29412, 6, 198, 21886, 796, 705, 5450, 1378, 12567, 13, 785, 14, 1134...
2.322785
316
#!/usr/bin/env python # -*- coding: utf-8 -*- """ Scrape the MMWR morbidity tables at http://wonder.cdc.gov/mmwr/mmwrmorb.asp. No processing is done; we simply save the files for potential offline processing. """ # Copyright (c) Los Alamos National Security, LLC and others. from __future__ import print_function, d...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 198, 37811, 198, 197, 3351, 13484, 262, 337, 14326, 49, 34813, 414, 8893, 379, 2638, 1378, 86, 8623, 13, 10210, 66, 1...
2.459048
525
import json import logging import os import traceback from boto3.dynamodb.conditions import Attr, Key import storage from util import lambda_result logger = logging.getLogger('cluster_status') if os.environ.get('DEBUG'): logger.setLevel(logging.DEBUG) def set_cluster_status(event, context): """Set the sta...
[ 11748, 33918, 198, 11748, 18931, 198, 11748, 28686, 198, 11748, 12854, 1891, 198, 198, 6738, 275, 2069, 18, 13, 67, 4989, 375, 65, 13, 17561, 1756, 1330, 3460, 81, 11, 7383, 198, 198, 11748, 6143, 198, 6738, 7736, 1330, 37456, 62, 202...
2.408492
2,732
""" This module implements utilities for labels """ # Copyright (C) 2021-2022 Intel Corporation # SPDX-License-Identifier: Apache-2.0 # from typing import List, Optional from ote_sdk.entities.label import LabelEntity from ote_sdk.entities.label_schema import LabelSchemaEntity from ote_sdk.entities.scored_label impor...
[ 37811, 198, 1212, 8265, 23986, 20081, 329, 14722, 198, 37811, 198, 198, 2, 15069, 357, 34, 8, 33448, 12, 1238, 1828, 8180, 10501, 198, 2, 30628, 55, 12, 34156, 12, 33234, 7483, 25, 24843, 12, 17, 13, 15, 198, 2, 198, 198, 6738, 19...
2.657588
514
import unittest from typing import List from dsa.lib.math.nums.three_sum import ThreeSum
[ 11748, 555, 715, 395, 198, 6738, 19720, 1330, 7343, 198, 198, 6738, 288, 11400, 13, 8019, 13, 11018, 13, 77, 5700, 13, 15542, 62, 16345, 1330, 7683, 13065, 628 ]
3.137931
29
""" Contains functions for plot spectrum action """ import mne import numpy as np import matplotlib.pyplot as plt from meggie.utilities.plotting import color_cycle from meggie.utilities.plotting import create_channel_average_plot from meggie.utilities.channels import average_to_channel_groups from meggie.utilities.c...
[ 37811, 49850, 5499, 329, 7110, 10958, 2223, 198, 37811, 198, 198, 11748, 285, 710, 198, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 198, 6738, 502, 23571, 13, 315, 2410, 13, 2...
2.198394
1,744
from .base_runner import BaseRunner from .gym_runner import GymRunner
[ 6738, 764, 8692, 62, 16737, 1330, 7308, 49493, 198, 6738, 764, 1360, 76, 62, 16737, 1330, 31187, 49493, 198 ]
3.684211
19
""" DataGenerator for CyclesPS Dataset This file use substantial portion of code from the original CNN-PS repository https://github.com/satoshi-ikehata/CNN-PS/ """ import numpy as np import cv2 import os import gc from data.datagenerator import DataGenerator from data.utils import rotate_images from misc.projections ...
[ 37811, 198, 6601, 8645, 1352, 329, 5934, 5427, 3705, 16092, 292, 316, 198, 1212, 2393, 779, 8904, 6903, 286, 2438, 422, 262, 2656, 8100, 12, 3705, 16099, 3740, 1378, 12567, 13, 785, 14, 49720, 13704, 12, 522, 71, 1045, 14, 18474, 12, ...
3.4375
112
import os def new_func(path, prev): """ pathprev 1000, 1001, 1002, 1003, ... :return: """ response = {'code': 1000, 'data': None} try: if not os.path.exists(path): raise ExistsError() if not prev: raise KeyInvalidE...
[ 11748, 28686, 198, 198, 4299, 649, 62, 20786, 7, 6978, 11, 8654, 2599, 198, 220, 220, 220, 37227, 198, 220, 220, 220, 3108, 47050, 198, 220, 220, 220, 220, 220, 220, 220, 8576, 11, 198, 220, 220, 220, 220, 220, 220, 220, 1802, 16,...
2.020262
839
import re for _ in range(0, int(input())): matches = re.findall(r'(#(?:[\da-f]{3}){1,2})(?!\w)(?=.*;)', input(), re.IGNORECASE) if matches: print(*matches, sep='\n')
[ 11748, 302, 198, 198, 1640, 4808, 287, 2837, 7, 15, 11, 493, 7, 15414, 28955, 2599, 198, 220, 220, 220, 7466, 796, 302, 13, 19796, 439, 7, 81, 6, 7, 2, 7, 27514, 58, 59, 6814, 12, 69, 60, 90, 18, 92, 19953, 16, 11, 17, 92, ...
1.967742
93
from talon import Context, Module from .user_settings import get_list_from_csv mod = Module() ctx = Context() mod.list("vocabulary", desc="additional vocabulary words") # Default words that will need to be capitalized (particularly under w2l). # NB. These defaults and those later in this file are ONLY used when # a...
[ 6738, 3305, 261, 1330, 30532, 11, 19937, 198, 6738, 764, 7220, 62, 33692, 1330, 651, 62, 4868, 62, 6738, 62, 40664, 198, 198, 4666, 796, 19937, 3419, 198, 49464, 796, 30532, 3419, 198, 198, 4666, 13, 4868, 7203, 18893, 22528, 1600, 17...
2.645759
1,674
import json from bson import ObjectId from datetime import datetime, date
[ 11748, 33918, 198, 6738, 275, 1559, 1330, 9515, 7390, 198, 6738, 4818, 8079, 1330, 4818, 8079, 11, 3128, 628, 198 ]
3.8
20
# Reraising last exception with raise w/o args try: f() print("FAIL") raise SystemExit except ValueError as e: pass # Can reraise only in except block try: raise print("FAIL") raise SystemExit except RuntimeError: print("PASS")
[ 2, 371, 8607, 1710, 938, 6631, 351, 5298, 266, 14, 78, 26498, 198, 198, 28311, 25, 198, 220, 220, 220, 277, 3419, 198, 220, 220, 220, 3601, 7203, 7708, 4146, 4943, 198, 220, 220, 220, 5298, 4482, 30337, 198, 16341, 11052, 12331, 355...
2.683673
98
import re
[ 11748, 302, 628, 198 ]
3
4
# coding=utf-8 from datetime import datetime, timedelta import dateutil.parser import pytz import urllib TZ = pytz.timezone('Europe/Kiev')
[ 2, 19617, 28, 40477, 12, 23, 198, 6738, 4818, 8079, 1330, 4818, 8079, 11, 28805, 12514, 198, 11748, 3128, 22602, 13, 48610, 198, 11748, 12972, 22877, 198, 11748, 2956, 297, 571, 198, 198, 51, 57, 796, 12972, 22877, 13, 2435, 11340, 10...
2.238636
88
#!/usr/bin/env python3 """ Show split layout indicator Usage: ./tiling-indicator.py Suppoused to be used inside waybar or polybar. Config example: Waybar: "custom/ws": { "exec": "python -u $HOME/.config/sway/scripts/tiling-indicator-2.py 2> /dev/null } Polybar: [module/layout] type = custom/script exec...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 18, 198, 198, 37811, 5438, 6626, 12461, 16916, 198, 198, 28350, 25, 198, 220, 220, 220, 24457, 83, 4386, 12, 521, 26407, 13, 9078, 198, 198, 15979, 29997, 284, 307, 973, 2641, 835, 5657, ...
2.203866
569
from typing import Optional import discord import asyncpg from discord.ext import commands from .utils.pagination import create_paginated_embed
[ 6738, 19720, 1330, 32233, 198, 198, 11748, 36446, 198, 11748, 30351, 6024, 198, 6738, 36446, 13, 2302, 1330, 9729, 198, 198, 6738, 764, 26791, 13, 79, 363, 1883, 1330, 2251, 62, 79, 363, 3898, 62, 20521 ]
4.027778
36
import sys import mapping.organization as org import mapping.contact as contact import mapping.worship as worship import mapping.central as central import mapping.national as national import mapping.codelist as codelist import mapping.vocabulary as vocab import mapping.location as location import mapping.local_admin_...
[ 11748, 25064, 198, 198, 11748, 16855, 13, 9971, 1634, 355, 8745, 198, 11748, 16855, 13, 32057, 355, 2800, 198, 11748, 16855, 13, 86, 11094, 355, 11892, 198, 11748, 16855, 13, 31463, 355, 4318, 198, 11748, 16855, 13, 14648, 355, 2260, 19...
3.610687
131
import numpy as np import os import matplotlib.pyplot as plt from print_values import * from plot_data_all_phonemes import * from plot_data import * # File that contains the data data_npy_file = 'data/PB_data.npy' # Loading data from .npy file data = np.load(data_npy_file, allow_pickle=True) data = np.ndarray.tolist(...
[ 11748, 299, 32152, 355, 45941, 198, 11748, 28686, 198, 11748, 2603, 29487, 8019, 13, 9078, 29487, 355, 458, 83, 198, 6738, 3601, 62, 27160, 1330, 1635, 198, 6738, 7110, 62, 7890, 62, 439, 62, 746, 261, 368, 274, 1330, 1635, 198, 6738,...
2.920124
964
# Generated by Django 2.2.6 on 2020-04-03 20:55 from django.db import migrations
[ 2, 2980, 515, 416, 37770, 362, 13, 17, 13, 21, 319, 12131, 12, 3023, 12, 3070, 1160, 25, 2816, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 628 ]
2.766667
30
import curses from contextlib import contextmanager from time import sleep from typing import List, Tuple, TYPE_CHECKING from .actions import Action from .properties import Property if TYPE_CHECKING: from .object import Object
[ 11748, 43878, 198, 6738, 4732, 8019, 1330, 4732, 37153, 198, 6738, 640, 1330, 3993, 198, 6738, 19720, 1330, 7343, 11, 309, 29291, 11, 41876, 62, 50084, 2751, 198, 198, 6738, 764, 4658, 1330, 7561, 198, 6738, 764, 48310, 1330, 14161, 198...
4.034483
58
import factory from projects.tests.factories.project import ProjectFactory
[ 11748, 8860, 198, 198, 6738, 4493, 13, 41989, 13, 22584, 1749, 13, 16302, 1330, 4935, 22810, 628 ]
4.529412
17
DATASET_LIST = [ { "name": "tree_equity_score", "module_dir": "tree_equity_score", "class_name": "TreeEquityScoreETL", }, { "name": "census_acs", "module_dir": "census_acs", "class_name": "CensusACSETL", }, { "name": "ejscreen", "module...
[ 35, 1404, 1921, 2767, 62, 45849, 796, 685, 198, 220, 220, 220, 1391, 198, 220, 220, 220, 220, 220, 220, 220, 366, 3672, 1298, 366, 21048, 62, 4853, 414, 62, 26675, 1600, 198, 220, 220, 220, 220, 220, 220, 220, 366, 21412, 62, 1590...
1.88806
536
from .group import Group from .star import (STAR_PARAMETERS_NAMES, GalacticDiskType, Star)
[ 6738, 764, 8094, 1330, 4912, 198, 6738, 764, 7364, 1330, 357, 46678, 62, 27082, 2390, 2767, 4877, 62, 45, 29559, 11, 198, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 220, 23509, 40961, 6030, ...
1.954545
66
# Generated by Django 3.0.8 on 2020-10-24 01:39 from django.db import migrations, models
[ 2, 2980, 515, 416, 37770, 513, 13, 15, 13, 23, 319, 12131, 12, 940, 12, 1731, 5534, 25, 2670, 198, 198, 6738, 42625, 14208, 13, 9945, 1330, 15720, 602, 11, 4981, 628 ]
2.84375
32
from e2e import DockerTest
[ 6738, 304, 17, 68, 1330, 25716, 14402, 628 ]
3.5
8
import numpy as np import pandas as pd import h5py # docker run -it kagglegym # python # >>> import kagglegym # >>> kagglegym.test() train = pd.read_hdf("../data/train.h5")
[ 11748, 299, 32152, 355, 45941, 198, 11748, 19798, 292, 355, 279, 67, 198, 11748, 289, 20, 9078, 198, 198, 2, 36253, 1057, 532, 270, 479, 9460, 293, 1360, 76, 198, 2, 21015, 198, 2, 13163, 1330, 479, 9460, 293, 1360, 76, 198, 2, 13...
2.39726
73
# 50. Write a Python program to print without newline or space. # Question: # Input: # Output: # Solution: https://www.w3resource.com/python-exercises/python-basic-exercise-50.php # Ideas: """ 1. Badly phrased qquestion. Question should be using for loop to generate 10 off "*" and print them in one line. """ # St...
[ 2, 2026, 13, 19430, 257, 11361, 1430, 284, 3601, 1231, 649, 1370, 393, 2272, 13, 198, 2, 18233, 25, 220, 198, 2, 23412, 25, 220, 198, 2, 25235, 25, 198, 2, 28186, 25, 3740, 1378, 2503, 13, 86, 18, 31092, 13, 785, 14, 29412, 12, ...
2.711656
163
from django.db import models import django_filters from django_filters.rest_framework import FilterSet REGISTERED_SERVICES = ['PACS']
[ 198, 6738, 42625, 14208, 13, 9945, 1330, 4981, 198, 11748, 42625, 14208, 62, 10379, 1010, 198, 6738, 42625, 14208, 62, 10379, 1010, 13, 2118, 62, 30604, 1330, 25853, 7248, 628, 198, 31553, 41517, 1961, 62, 35009, 53, 34444, 796, 37250, ...
3.111111
45
#!/usr/bin/env python """ """ from xml.etree.ElementTree import Element import xml.etree.ElementTree as etree import xml.dom.minidom import re import sys import getopt import os from time import gmtime, strftime from nipype import config, logging from nighres.lesion_tool.lesion_pipeline import Lesion_extractor i...
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 37811, 198, 37811, 198, 198, 6738, 35555, 13, 316, 631, 13, 20180, 27660, 1330, 11703, 198, 11748, 35555, 13, 316, 631, 13, 20180, 27660, 355, 2123, 631, 198, 11748, 35555, 13, 3438, 1...
2.820313
128
# ********************************************************************** # Copyright (C) 2020 Johns Hopkins University Applied Physics Laboratory # # All Rights Reserved. # For any other permission, please contact the Legal Office at JHU/APL. # # Licensed under the Apache License, Version 2.0 (the "License"); # y...
[ 2, 220, 41906, 17174, 2466, 1174, 198, 2, 220, 15069, 357, 34, 8, 12131, 25824, 21183, 2059, 27684, 23123, 18643, 198, 2, 198, 2, 220, 1439, 6923, 33876, 13, 198, 2, 220, 1114, 597, 584, 7170, 11, 3387, 2800, 262, 16027, 4452, 379, ...
3.98722
313
# Constants DEFAULT_TITLE = 'Khan Academy' HOME_DOMAIN = 'www.khanacademy.org'
[ 2, 4757, 1187, 198, 198, 7206, 38865, 62, 49560, 2538, 796, 705, 42, 7637, 8581, 6, 198, 39069, 62, 39170, 29833, 796, 705, 2503, 13, 74, 7637, 330, 324, 3065, 13, 2398, 6, 198 ]
2.352941
34
# ------------------------------------------------------------------------------ # Copyright (c) Abdurasul Rakhimov 24.2.2021. # ------------------------------------------------------------------------------ import numpy as np from overrides import overrides
[ 2, 16529, 26171, 198, 2, 220, 15069, 357, 66, 8, 17870, 17786, 377, 371, 11322, 44273, 1987, 13, 17, 13, 1238, 2481, 13, 198, 2, 16529, 26171, 198, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 23170, 1460, 1330, 23170, 1460, 628, ...
6.116279
43
# Generated by configen, do not edit. # See https://github.com/facebookresearch/hydra/tree/master/tools/configen # fmt: off # isort:skip_file # flake8: noqa from dataclasses import dataclass from typing import * from omegaconf import MISSING
[ 2, 2980, 515, 416, 4566, 268, 11, 466, 407, 4370, 13, 198, 2, 4091, 3740, 1378, 12567, 13, 785, 14, 19024, 34033, 14, 15511, 430, 14, 21048, 14, 9866, 14, 31391, 14, 11250, 268, 198, 2, 46996, 25, 572, 198, 2, 318, 419, 25, 4826...
3.024691
81
import time import numpy as np from freenect import sync_get_depth as get_depth, sync_get_video as get_video
[ 11748, 640, 201, 198, 11748, 299, 32152, 355, 45941, 201, 198, 6738, 277, 1361, 478, 1330, 17510, 62, 1136, 62, 18053, 355, 651, 62, 18053, 11, 17510, 62, 1136, 62, 15588, 355, 651, 62, 15588, 201 ]
3.083333
36
#!/usr/bin/env python import flask import requests import lxml.html import logging app = flask.Flask(__name__) LOGGER = logging.getLogger(__name__) HN_BASE_URL = 'https://news.ycombinator.com/' if __name__ == '__main__': logging.basicConfig(level='INFO') app.run(host='0.0.0.0')
[ 2, 48443, 14629, 14, 8800, 14, 24330, 21015, 198, 198, 11748, 42903, 198, 11748, 7007, 198, 11748, 300, 19875, 13, 6494, 198, 11748, 18931, 198, 198, 1324, 796, 42903, 13, 7414, 2093, 7, 834, 3672, 834, 8, 198, 25294, 30373, 796, 1893...
2.487179
117
# Functions for project: NormativeNeuroDev_Longitudinal # Linden Parkes, 2019 # lindenmp@seas.upenn.edu from IPython.display import clear_output import numpy as np import scipy as sp from scipy import stats import pandas as pd from statsmodels.stats import multitest
[ 2, 40480, 329, 1628, 25, 11220, 876, 8199, 1434, 13603, 62, 14617, 29121, 198, 2, 9329, 268, 3250, 274, 11, 13130, 198, 2, 300, 521, 268, 3149, 31, 325, 292, 13, 929, 1697, 13, 15532, 198, 198, 6738, 6101, 7535, 13, 13812, 1330, 1...
3.134831
89
from sympy.functions import sqrt, sign, root from sympy.core import S, Wild, sympify, Mul, Add, Expr from sympy.core.function import expand_multinomial, expand_mul from sympy.core.symbol import Dummy from sympy.polys import Poly, PolynomialError from sympy.core.function import count_ops def is_sqrt(expr): """Retu...
[ 6738, 10558, 88, 13, 12543, 2733, 1330, 19862, 17034, 11, 1051, 11, 6808, 198, 6738, 10558, 88, 13, 7295, 1330, 311, 11, 6183, 11, 10558, 1958, 11, 17996, 11, 3060, 11, 1475, 1050, 198, 6738, 10558, 88, 13, 7295, 13, 8818, 1330, 429...
1.956462
8,016
import datetime import os import shutil from django.conf import settings from django.contrib.auth import get_user_model from django.core.cache import cache from django.db import transaction, IntegrityError from django.db.models import Q, F from django.http import FileResponse from django.utils.encoding import escape_u...
[ 11748, 4818, 8079, 198, 11748, 28686, 198, 11748, 4423, 346, 198, 198, 6738, 42625, 14208, 13, 10414, 1330, 6460, 198, 6738, 42625, 14208, 13, 3642, 822, 13, 18439, 1330, 651, 62, 7220, 62, 19849, 198, 6738, 42625, 14208, 13, 7295, 13, ...
3.574359
390
#!/bin/env python3 import sys import argparse import configparser import docx from docx import Document from docx.shared import Pt, Inches from docx.enum.dml import MSO_THEME_COLOR_INDEX from docx.enum.section import WD_ORIENT, WD_SECTION from datetime import datetime from mediumroast.api.high_level import Auth as au...
[ 2, 48443, 8800, 14, 24330, 21015, 18, 198, 198, 11748, 25064, 198, 11748, 1822, 29572, 198, 11748, 4566, 48610, 198, 11748, 2205, 87, 198, 198, 6738, 2205, 87, 1330, 16854, 198, 6738, 2205, 87, 13, 28710, 1330, 34352, 11, 554, 2052, 1...
2.482715
1,591
import pprint import logging import datetime from selenium import webdriver import hubcheck.conf # block websites that make linkcheck slow # these are usually blocked by the workspace firewall # mozillalabs comes from using a nightly version of firefox browser # many of the others are from login authentication site...
[ 11748, 279, 4798, 198, 11748, 18931, 198, 11748, 4818, 8079, 198, 198, 6738, 384, 11925, 1505, 1330, 3992, 26230, 198, 198, 11748, 12575, 9122, 13, 10414, 628, 198, 2, 2512, 9293, 326, 787, 2792, 9122, 3105, 198, 2, 777, 389, 3221, 10...
1.47276
7,856
from topdown import * from caty.jsontools import stdjson from caty.jsontools import xjson from caty.jsontools.selector import stm as default_factory from caty.core.spectypes import UNDEFINED from caty.core.language import name_token
[ 198, 6738, 1353, 2902, 1330, 1635, 198, 6738, 3797, 88, 13, 8457, 756, 10141, 1330, 14367, 17752, 198, 6738, 3797, 88, 13, 8457, 756, 10141, 1330, 2124, 17752, 198, 6738, 3797, 88, 13, 8457, 756, 10141, 13, 19738, 273, 1330, 336, 76, ...
3.175676
74
# -*- coding: utf8 -*- import datetime import mock import os import unittest import webapp2 from google.appengine.ext import testbed, deferred from google.appengine.api import queueinfo from . import models from .handler import application from .wrapper import defer TESTCONFIG_DIR = os.path.join( os.path.dirnam...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 23, 532, 9, 12, 198, 198, 11748, 4818, 8079, 198, 11748, 15290, 198, 11748, 28686, 198, 11748, 555, 715, 395, 198, 11748, 3992, 1324, 17, 198, 198, 6738, 23645, 13, 1324, 18392, 13, 2302, 1330, ...
3.057851
121
from django.db import models
[ 6738, 42625, 14208, 13, 9945, 1330, 4981, 628 ]
3.75
8
"""MIT License Copyright (c) 2018 rongjiewang 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, modify, merge, publish, di...
[ 37811, 36393, 13789, 198, 198, 15269, 357, 66, 8, 2864, 374, 506, 73, 769, 648, 198, 198, 5990, 3411, 318, 29376, 7520, 11, 1479, 286, 3877, 11, 284, 597, 1048, 16727, 257, 4866, 198, 1659, 428, 3788, 290, 3917, 10314, 3696, 357, 11...
2.725055
902
""" This module provides the interactive Python console. """ import sys import traceback from browser import window
[ 37811, 198, 220, 220, 220, 770, 8265, 3769, 262, 14333, 11361, 8624, 13, 198, 37811, 198, 11748, 25064, 198, 11748, 12854, 1891, 198, 198, 6738, 6444, 1330, 4324, 628, 198 ]
4.1
30
""" Test setting a breakpoint on an overloaded function by name. """ import re import lldb from lldbsuite.test.decorators import * from lldbsuite.test.lldbtest import * from lldbsuite.test import lldbutil
[ 37811, 198, 14402, 4634, 257, 2270, 4122, 319, 281, 50068, 2163, 416, 1438, 13, 198, 37811, 198, 198, 11748, 302, 198, 11748, 32660, 9945, 198, 6738, 32660, 67, 1443, 84, 578, 13, 9288, 13, 12501, 273, 2024, 1330, 1635, 198, 6738, 326...
2.4375
96
from tkinter import * # ---------------------------- CONSTANTS ------------------------------- # PINK = "#e2979c" RED = "#e7305b" GREEN = "#9bdeac" YELLOW = "#f7f5dd" FONT_NAME = "Courier" WORK_MIN = 25 SHORT_BREAK_MIN = 5 LONG_BREAK_MIN = 20 is_counting = False reps = 0 timer = None # ---------------------------- ...
[ 6738, 256, 74, 3849, 1330, 1635, 198, 198, 2, 34400, 10541, 7102, 2257, 1565, 4694, 34400, 24305, 1303, 198, 47, 17248, 796, 25113, 68, 1959, 3720, 66, 1, 198, 22083, 796, 25113, 68, 22, 22515, 65, 1, 198, 43016, 796, 25113, 24, 65,...
2.869388
490
# tests for narps code # - currently these are all just smoke tests import pytest import os import pandas from narps import Narps from AnalyzeMaps import mk_overlap_maps,\ mk_range_maps, mk_std_maps,\ mk_correlation_maps_unthresh, analyze_clusters,\ plot_distance_from_mean, get_thresh_similarity from MetaA...
[ 2, 5254, 329, 30083, 862, 2438, 198, 2, 532, 3058, 777, 389, 477, 655, 7523, 5254, 198, 198, 11748, 12972, 9288, 198, 11748, 28686, 198, 11748, 19798, 292, 198, 6738, 30083, 862, 1330, 13596, 862, 198, 6738, 16213, 2736, 47010, 1330, ...
2.62949
529
""" Convenience functions for plotting DTCWT-related objects. """ from __future__ import absolute_import import numpy as np from matplotlib.pyplot import * __all__ = ( 'overlay_quiver', ) def overlay_quiver(image, vectorField, level, offset): """Overlays nicely coloured quiver plot of complex coefficients ...
[ 37811, 198, 3103, 574, 1240, 5499, 329, 29353, 360, 4825, 39386, 12, 5363, 5563, 13, 198, 198, 37811, 198, 198, 6738, 11593, 37443, 834, 1330, 4112, 62, 11748, 198, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 2603, 29487, 8019, 13, ...
2.628898
962
import grokcore.component as grok from grokcore.component.interfaces import IContext import grokcore.view as view from zope.interface import Interface from grokcore.registries.tests.registries.interfaces import IExample
[ 11748, 7128, 74, 7295, 13, 42895, 355, 7128, 74, 198, 6738, 7128, 74, 7295, 13, 42895, 13, 3849, 32186, 1330, 314, 21947, 198, 11748, 7128, 74, 7295, 13, 1177, 355, 1570, 198, 6738, 1976, 3008, 13, 39994, 1330, 26491, 198, 6738, 7128,...
3.7
60
from graphdata.shared.shared1D import AuxPlotLabelLL1D from graphdata.shared.shared1D import ProcessData1D from graphdata.shared.shared1D import LoadData1D from graphdata.shared.figsizes import LogLogSize from graphdata.shared.shared import ExtendDictionary from graphdata.shared.shared import ProcessComplex from gr...
[ 198, 6738, 4823, 7890, 13, 28710, 13, 28710, 16, 35, 1330, 47105, 43328, 33986, 3069, 16, 35, 220, 198, 6738, 4823, 7890, 13, 28710, 13, 28710, 16, 35, 1330, 10854, 6601, 16, 35, 220, 198, 6738, 4823, 7890, 13, 28710, 13, 28710, 16,...
2.257507
1,099
import datetime import json import requests import pytest import random from tests.suites.test_payment import TestPayment from tests.utilities.settings import get_settings, get_test_data, setup_access_data
[ 11748, 4818, 8079, 198, 11748, 33918, 198, 11748, 7007, 198, 11748, 12972, 9288, 198, 11748, 4738, 198, 198, 6738, 5254, 13, 2385, 2737, 13, 9288, 62, 37301, 1330, 6208, 19197, 434, 198, 6738, 5254, 13, 315, 2410, 13, 33692, 1330, 651, ...
3.714286
56
# -*- coding: utf-8 -*- # This file is auto-generated, don't edit it. Thanks. from Tea.core import TeaCore from alibabacloud_tea_openapi.client import Client as OpenApiClient from alibabacloud_tea_openapi import models as open_api_models from alibabacloud_tea_util.client import Client as UtilClient from alibabacloud_d...
[ 2, 532, 9, 12, 19617, 25, 3384, 69, 12, 23, 532, 9, 12, 198, 2, 770, 2393, 318, 8295, 12, 27568, 11, 836, 470, 4370, 340, 13, 6930, 13, 198, 6738, 15777, 13, 7295, 1330, 15777, 14055, 198, 198, 6738, 435, 571, 397, 37779, 2778, ...
3.017341
173
from __future__ import annotations import argparse import pickle import numpy as np import json import logging import math import glob import random import os import sys import datetime import time from functools import partial from pathlib import Path from collections import defaultdict from shutil import copyfile f...
[ 6738, 11593, 37443, 834, 1330, 37647, 198, 198, 11748, 1822, 29572, 198, 11748, 2298, 293, 198, 11748, 299, 32152, 355, 45941, 198, 11748, 33918, 198, 11748, 18931, 198, 11748, 10688, 198, 11748, 15095, 198, 11748, 4738, 198, 11748, 28686, ...
3.641732
254
prim = int(input('primeiro termo: ')) raz = int(input('razao: ')) dec = prim + (10 - 1) * raz for c in range(prim, dec + raz, raz): print(' {}'.format(c,), end=' ->') print('acabou')
[ 19795, 796, 493, 7, 15414, 10786, 35505, 7058, 3381, 78, 25, 705, 4008, 198, 3247, 796, 493, 7, 15414, 10786, 3247, 5488, 25, 705, 4008, 198, 12501, 796, 2684, 1343, 357, 940, 532, 352, 8, 1635, 374, 1031, 198, 1640, 269, 287, 2837,...
2.375
80
""" A script that partitions the dataset for transferability scenarios """ # basics import numpy as np from PIL import Image # torch... import torch # custom libs import utils # ------------------------------------------------------------------------------ # Misc. functions # ---------------------------------...
[ 37811, 198, 220, 220, 220, 317, 4226, 326, 43869, 262, 27039, 329, 4351, 1799, 13858, 198, 37811, 198, 2, 19165, 198, 11748, 299, 32152, 355, 45941, 198, 6738, 350, 4146, 1330, 7412, 198, 198, 2, 28034, 986, 198, 11748, 28034, 198, 19...
6.529412
85