content stringlengths 1 1.04M | input_ids listlengths 1 774k | ratio_char_token float64 0.38 22.9 | token_count int64 1 774k |
|---|---|---|---|
# Generated by Django 3.0.5 on 2020-04-16 08:23
from django.db import migrations, models
| [
2,
2980,
515,
416,
37770,
513,
13,
15,
13,
20,
319,
12131,
12,
3023,
12,
1433,
8487,
25,
1954,
198,
198,
6738,
42625,
14208,
13,
9945,
1330,
15720,
602,
11,
4981,
628
] | 2.84375 | 32 |
# coding=utf-8
from OTLMOW.OTLModel.Datatypes.KeuzelijstField import KeuzelijstField
# Generated with OTLEnumerationCreator. To modify: extend, do not edit
class KlPLCModelnaam(KeuzelijstField):
"""De modelnaam van de PLC."""
naam = 'KlPLCModelnaam'
label = 'PLC model'
objectUri = 'https://wegenenverk... | [
2,
19617,
28,
40477,
12,
23,
198,
6738,
440,
14990,
44,
3913,
13,
2394,
43,
17633,
13,
27354,
265,
9497,
13,
8896,
10277,
417,
2926,
301,
15878,
1330,
3873,
10277,
417,
2926,
301,
15878,
628,
198,
2,
2980,
515,
351,
21676,
2538,
77,... | 2.366071 | 224 |
from multidict import MultiDict
| [
6738,
1963,
312,
713,
1330,
15237,
35,
713,
628,
628
] | 3.5 | 10 |
import json
import random
import datetime
import threading
import time
import traceback
from flask import redirect, render_template
from flask.ext.classy import FlaskView, route
import inflect
from app import app, db
from app.models import *
from app.forms import SimpleMturkForm
from mturk import grant_qualification... | [
11748,
33918,
198,
11748,
4738,
198,
11748,
4818,
8079,
198,
11748,
4704,
278,
198,
11748,
640,
198,
11748,
12854,
1891,
198,
198,
6738,
42903,
1330,
18941,
11,
8543,
62,
28243,
198,
6738,
42903,
13,
2302,
13,
4871,
88,
1330,
46947,
768... | 2.537135 | 754 |
import os
import shutil
import unittest
from base64 import b64encode
from sonLib.bioio import TestStatus
from sonLib.bioio import getTempFile
from sonLib.bioio import getTempDirectory
from sonLib.bioio import system
from toil.job import Job
from toil.common import Toil
from cactus.shared.common import cactus_call, Chi... | [
11748,
28686,
198,
11748,
4423,
346,
198,
11748,
555,
715,
395,
198,
6738,
2779,
2414,
1330,
275,
2414,
268,
8189,
198,
198,
6738,
3367,
25835,
13,
65,
952,
952,
1330,
6208,
19580,
198,
6738,
3367,
25835,
13,
65,
952,
952,
1330,
651,
... | 3.073171 | 123 |
import factory
from tests.datasets import factories as datasets_factoryboy
from wazimap_ng.profile import models
from django.core.files.base import ContentFile
| [
11748,
8860,
198,
198,
6738,
5254,
13,
19608,
292,
1039,
1330,
17590,
355,
40522,
62,
69,
9548,
7081,
198,
6738,
266,
1031,
320,
499,
62,
782,
13,
13317,
1330,
4981,
198,
198,
6738,
42625,
14208,
13,
7295,
13,
16624,
13,
8692,
1330,
... | 3.469388 | 49 |
#!/usr/bin/python
import UniversalMolecularSystem as UMS
import sys
UMS.MainAsMol22XYZ(len(sys.argv),sys.argv)
| [
2,
48443,
14629,
14,
8800,
14,
29412,
198,
11748,
14499,
44,
2305,
10440,
11964,
355,
471,
5653,
198,
11748,
25064,
198,
198,
52,
5653,
13,
13383,
1722,
44,
349,
1828,
34278,
57,
7,
11925,
7,
17597,
13,
853,
85,
828,
17597,
13,
853,... | 2.434783 | 46 |
from sacred import Experiment
from sacred.utils import apply_backspaces_and_linefeeds
from experiments.utils import get_mongo_observer
from experiments.evaluation import import_weights_into_network
from xview.datasets import get_dataset
from xview.models import get_model
import numpy as np
from os import path, mkdir
fr... | [
6738,
13626,
1330,
29544,
198,
6738,
13626,
13,
26791,
1330,
4174,
62,
1891,
2777,
2114,
62,
392,
62,
1370,
12363,
82,
198,
6738,
10256,
13,
26791,
1330,
651,
62,
76,
25162,
62,
672,
15388,
198,
6738,
10256,
13,
18206,
2288,
1330,
133... | 3.355263 | 152 |
# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from django.core.management.base import BaseCommand, CommandError
from django.contrib.auth import authenticate
from spackm... | [
2,
15069,
2211,
12,
1238,
2481,
13914,
45036,
3549,
2351,
4765,
11,
11419,
290,
584,
198,
2,
1338,
441,
4935,
34152,
13,
4091,
262,
1353,
12,
5715,
27975,
38162,
9947,
2393,
329,
3307,
13,
198,
2,
198,
2,
30628,
55,
12,
34156,
12,
... | 3.605263 | 152 |
import itertools
f = open("day9.txt","r")
XMAS = f.readlines()
#print(getFirstWeakness(7, XMAS))
print(getFirstWeakness(25, XMAS))
#preamble is first 25
#test preamble is first 5
#part2
#number is 23278925
#print(contiguous_set(127, XMAS))
print(max(contiguous_set(23278925, XMAS)) + min(contiguous_set(23278925, XMAS))) | [
11748,
340,
861,
10141,
198,
69,
796,
1280,
7203,
820,
24,
13,
14116,
2430,
81,
4943,
198,
55,
31180,
796,
277,
13,
961,
6615,
3419,
198,
2,
4798,
7,
1136,
5962,
44898,
1108,
7,
22,
11,
1395,
31180,
4008,
198,
4798,
7,
1136,
5962,... | 2.48062 | 129 |
from wbb import app
from wbb import app2
from pyrogram import filters
import bs4
import aiohttp
import requests
_MODULE_ = "Apps"
_HELP_ = """To search an app on playstore"""
@app.on_message(filters.command("ply"))
| [
6738,
266,
11848,
1330,
598,
198,
6738,
266,
11848,
1330,
598,
17,
198,
6738,
12972,
39529,
1330,
16628,
198,
11748,
275,
82,
19,
198,
11748,
257,
952,
4023,
198,
11748,
7007,
198,
198,
62,
33365,
24212,
62,
796,
366,
48433,
1,
198,
... | 2.722892 | 83 |
import sys
from vacs.models import Command, Experiment, Vac, Evaluation, Assignment, Participant, Score, ValAssignment, Validation
from django.contrib.auth import get_user_model
import numpy as np
from scipy.misc import comb
import math
# Exclude ids that were not recoverable from the db
full_exclude_id = [2657, 2662, ... | [
11748,
25064,
198,
6738,
6658,
82,
13,
27530,
1330,
9455,
11,
29544,
11,
25709,
11,
34959,
11,
50144,
11,
29880,
11,
15178,
11,
3254,
8021,
16747,
11,
3254,
24765,
198,
6738,
42625,
14208,
13,
3642,
822,
13,
18439,
1330,
651,
62,
7220... | 2.416593 | 4,532 |
__version__ = 0.805 | [
834,
9641,
834,
796,
657,
13,
28256
] | 2.714286 | 7 |
from ConfigParser import SafeConfigParser
from datetime import datetime, timedelta
import HTMLParser
import logging, logging.config, re, sys, os
from time import time
from dateutil import parser, rrule, tz
import praw
from requests.exceptions import HTTPError
from sqlalchemy import create_engine
from sqlalchemy import... | [
6738,
17056,
46677,
1330,
19978,
16934,
46677,
198,
6738,
4818,
8079,
1330,
4818,
8079,
11,
28805,
12514,
198,
11748,
11532,
46677,
198,
11748,
18931,
11,
18931,
13,
11250,
11,
302,
11,
25064,
11,
28686,
198,
6738,
640,
1330,
640,
198,
... | 2.285558 | 4,563 |
import tensorflow as tf
import numpy as np
import os
import glob
def tf_cov(x):
"""Calculate covariance for x.
Equivalent to np.cov(x.T)
"""
mean_x = tf.reduce_mean(x, axis=0, keepdims=True)
mx = tf.matmul(tf.transpose(mean_x), mean_x)
vx = tf.matmul(tf.transpose(x), x)/tf.cast(tf.shape(x)[0... | [
11748,
11192,
273,
11125,
355,
48700,
198,
11748,
299,
32152,
355,
45941,
198,
11748,
28686,
198,
11748,
15095,
628,
198,
4299,
48700,
62,
66,
709,
7,
87,
2599,
198,
220,
220,
220,
37227,
9771,
3129,
378,
44829,
590,
329,
2124,
13,
62... | 2.113152 | 1,361 |
from selenium import webdriver
from selenium.webdriver.support.ui import Select
from time import sleep
pathWebdriver = 'C:\\Program Files (x86)\chromedriver.exe'
driver = webdriver.Chrome(pathWebdriver)
xubioLogin = 'https://xubio.com/NXV/newLogin'
xubioMayores = 'https://xubio.com/NXV/contabilidad/libro-mayor'
user... | [
6738,
384,
11925,
1505,
1330,
3992,
26230,
198,
6738,
384,
11925,
1505,
13,
12384,
26230,
13,
11284,
13,
9019,
1330,
9683,
198,
6738,
640,
1330,
3993,
198,
198,
6978,
13908,
26230,
796,
705,
34,
25,
6852,
15167,
13283,
357,
87,
4521,
... | 2.52007 | 573 |
from .wms import WMS
from .session import session
wms = wms.WMS()
# Create a session object accessible via wms.session
wms.session = session(WMS)
| [
6738,
764,
86,
907,
1330,
370,
5653,
198,
6738,
764,
29891,
1330,
6246,
198,
198,
86,
907,
796,
266,
907,
13,
54,
5653,
3419,
198,
2,
13610,
257,
6246,
2134,
9857,
2884,
266,
907,
13,
29891,
198,
86,
907,
13,
29891,
796,
6246,
7,
... | 3.0625 | 48 |
from django.forms.models import BaseModelFormSet
from django.forms.formsets import BaseFormSet
from django.forms.util import ErrorDict
# add some helpful methods to the formset
# add the FormSetMixin to the base FormSet classes
| [
6738,
42625,
14208,
13,
23914,
13,
27530,
1330,
7308,
17633,
8479,
7248,
198,
6738,
42625,
14208,
13,
23914,
13,
23914,
1039,
1330,
7308,
8479,
7248,
198,
6738,
42625,
14208,
13,
23914,
13,
22602,
1330,
13047,
35,
713,
628,
198,
2,
751,... | 3.640625 | 64 |
#!python
# file listtree.py
class ListTree:
'''
Mix-in that returns an __str__ trace of the entire class tree and all
its objects' attrs at and above self; run by print(), str() returns
constructed string; uses __X attr names to avoid impacting clients;
recurses to superclasses explicitly, uses str... | [
2,
0,
29412,
198,
2,
2393,
1351,
21048,
13,
9078,
198,
198,
4871,
7343,
27660,
25,
198,
220,
220,
220,
705,
7061,
198,
220,
220,
220,
15561,
12,
259,
326,
5860,
281,
11593,
2536,
834,
12854,
286,
262,
2104,
1398,
5509,
290,
477,
1... | 2.972603 | 146 |
import pymysql.cursors
| [
11748,
279,
4948,
893,
13976,
13,
66,
1834,
669,
628
] | 2.4 | 10 |
import unittest
import os
import pytest
import distutils.spawn
DLPOLY_FOUND = distutils.spawn.find_executable('DLPOLY.Z')
# needsDLPOLY = unittest.skipIf(not DLPOLY_FOUND, "DLPOLY not available")
needsDLPOLY = pytest.mark.skipif(not DLPOLY_FOUND, reason="DLPOLY not available")
| [
11748,
555,
715,
395,
198,
11748,
28686,
198,
11748,
12972,
9288,
198,
198,
11748,
1233,
26791,
13,
48183,
198,
19260,
45472,
56,
62,
37,
15919,
796,
1233,
26791,
13,
48183,
13,
19796,
62,
18558,
18187,
10786,
19260,
45472,
56,
13,
57,
... | 2.67619 | 105 |
c = str(input('Digite o nome da sua cidade: ')).lower().strip()
#'c' recebe o nome da cidade que são colocadas em letras minúsculas e logo depois é retirado os espaços desnecessários no começo e no fim da cadeia de caracteres
print(f'Sua cidade tem "Santo" no nome? {"santo" in c}')
#O operador 'in' verifica se tem "sa... | [
66,
796,
965,
7,
15414,
10786,
19511,
578,
267,
299,
462,
12379,
424,
64,
269,
312,
671,
25,
705,
29720,
21037,
22446,
36311,
3419,
198,
2,
6,
66,
6,
1407,
1350,
267,
299,
462,
12379,
269,
312,
671,
8358,
264,
28749,
951,
420,
387... | 2.35 | 200 |
"""
Definition for singly-linked list with a random pointer.
class RandomListNode:
def __init__(self, x):
self.label = x
self.next = None
self.random = None
"""
# @param head: A RandomListNode
# @return: A RandomListNode
| [
37811,
198,
36621,
329,
1702,
306,
12,
25614,
1351,
351,
257,
4738,
17562,
13,
198,
4871,
14534,
8053,
19667,
25,
198,
220,
220,
220,
825,
11593,
15003,
834,
7,
944,
11,
2124,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
2116,
13,
... | 2.59 | 100 |
from fastapi import FastAPI
import random
app = FastAPI()
@app.get("/api")
@app.get("/api/{name}")
@app.get("/piada") | [
6738,
3049,
15042,
1330,
12549,
17614,
198,
11748,
4738,
198,
198,
1324,
796,
12549,
17614,
3419,
198,
198,
31,
1324,
13,
1136,
7203,
14,
15042,
4943,
628,
198,
31,
1324,
13,
1136,
7203,
14,
15042,
14,
90,
3672,
92,
4943,
628,
198,
... | 2.411765 | 51 |
# For spymaster AI, doesn't need to hide or shuffle words, just define red/blue/neutral/assassin at the start, and put team color in explicitly
import numpy as np
import pandas as pd
import tensorflow as tf
from sklearn.neighbors import NearestNeighbors
| [
2,
1114,
599,
4948,
1603,
9552,
11,
1595,
470,
761,
284,
7808,
393,
36273,
2456,
11,
655,
8160,
2266,
14,
17585,
14,
29797,
14,
562,
44961,
379,
262,
923,
11,
290,
1234,
1074,
3124,
287,
11777,
198,
11748,
299,
32152,
355,
45941,
19... | 3.628571 | 70 |
# Generated by Django 2.2.11 on 2021-04-18 21:19
from django.db import migrations
| [
2,
2980,
515,
416,
37770,
362,
13,
17,
13,
1157,
319,
33448,
12,
3023,
12,
1507,
2310,
25,
1129,
198,
198,
6738,
42625,
14208,
13,
9945,
1330,
15720,
602,
628
] | 2.8 | 30 |
from qtpy import QtCore, QtGui
| [
6738,
10662,
83,
9078,
1330,
33734,
14055,
11,
33734,
8205,
72,
628
] | 2.666667 | 12 |
from . import mlp
#from . import lenet
from . import resnet
#from . import senet
| [
6738,
764,
1330,
25962,
79,
198,
2,
6738,
764,
1330,
18896,
316,
198,
6738,
764,
1330,
581,
3262,
198,
2,
6738,
764,
1330,
3308,
316,
198
] | 3.115385 | 26 |
# Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
"""Client and server classes corresponding to protobuf-defined services."""
import grpc
from google.ads.google_ads.v5.proto.resources import feed_mapping_pb2 as google_dot_ads_dot_googleads__v5_dot_proto_dot_resources_dot_feed__mapping__pb2
from goo... | [
2,
2980,
515,
416,
262,
308,
49,
5662,
11361,
8435,
17050,
13877,
13,
8410,
5626,
48483,
0,
198,
37811,
11792,
290,
4382,
6097,
11188,
284,
1237,
672,
3046,
12,
23211,
2594,
526,
15931,
198,
11748,
1036,
14751,
198,
198,
6738,
23645,
... | 2.595745 | 1,034 |
import numpy as np
from collections import Counter
from Tree import DecisionTree | [
11748,
299,
32152,
355,
45941,
198,
6738,
17268,
1330,
15034,
198,
6738,
12200,
1330,
26423,
27660
] | 5 | 16 |
"""
FCS file reader supporting file format spec 3.0, 3.1.
Data extraction currently supports:
$MODE: (L) List
$DATATYPE: I,F,D
FCS3.0 http://murphylab.web.cmu.edu/FCSAPI/FCS3.html
FCS3.1 https://www.ncbi.nlm.nih.gov/pmc/articles/PMC2892967/
A data set is a (HEADER, TEXT, DATA) group... | [
37811,
198,
220,
220,
220,
376,
7902,
2393,
9173,
6493,
2393,
5794,
1020,
513,
13,
15,
11,
513,
13,
16,
13,
198,
220,
220,
220,
6060,
22236,
3058,
6971,
25,
198,
220,
220,
220,
220,
220,
220,
220,
720,
49058,
25,
357,
43,
8,
734... | 2.341006 | 5,387 |
from django.shortcuts import render
from django.http import HttpResponse, HttpResponseRedirect
from django.core.serializers import serialize
from .forms import ConfirmedCaseForm, SpaceTimeFormset, ContagionSiteForm
from .models import ConfirmedCase, ContagionSite
| [
6738,
42625,
14208,
13,
19509,
23779,
1330,
8543,
198,
6738,
42625,
14208,
13,
4023,
1330,
367,
29281,
31077,
11,
367,
29281,
31077,
7738,
1060,
198,
6738,
42625,
14208,
13,
7295,
13,
46911,
11341,
1330,
11389,
1096,
198,
198,
6738,
764,
... | 3.722222 | 72 |
# Generated by Django 2.1.7 on 2020-02-10 11:42
from django.db import migrations, models
| [
2,
2980,
515,
416,
37770,
362,
13,
16,
13,
22,
319,
12131,
12,
2999,
12,
940,
1367,
25,
3682,
198,
198,
6738,
42625,
14208,
13,
9945,
1330,
15720,
602,
11,
4981,
628
] | 2.84375 | 32 |
from algosdk import kmd
from algosdk.wallet import Wallet
from algosdk.v2client import algod
import json
# define sandbox values for kmd client
kmd_address = "http://localhost:4002"
kmd_token = "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
# define sandbox values for algod client
algod_addres... | [
6738,
435,
70,
418,
34388,
1330,
479,
9132,
198,
6738,
435,
70,
418,
34388,
13,
44623,
1330,
37249,
198,
6738,
435,
70,
418,
34388,
13,
85,
17,
16366,
1330,
435,
25344,
198,
11748,
33918,
198,
198,
2,
8160,
35204,
3815,
329,
479,
91... | 3.175182 | 137 |
import logging
from functools import partial
import numpy as np
from ..utils import find_borders, find_inconsistent
np.seterr(invalid='raise')
def find_active_pixels(e_coord, n_coord, e_coord_inc, n_coord_inc, min_inc=1e-6):
"""
Finds active pixels
Returns a boolean array identifying which pixels hav... | [
11748,
18931,
198,
6738,
1257,
310,
10141,
1330,
13027,
198,
198,
11748,
299,
32152,
355,
45941,
198,
198,
6738,
11485,
26791,
1330,
1064,
62,
65,
6361,
11,
1064,
62,
1939,
684,
7609,
198,
198,
37659,
13,
82,
2357,
81,
7,
259,
12102,
... | 2.226102 | 6,214 |
import os
class Config:
'''
General configuration parent class
'''
# SQLALCHEMY_DATABASE_URI = 'postgresql+psycopg2://qyunky:Lewis860@localhost/blog'
SECRET_KEY = os.environ.get('SECRET_KEY')
QUOTES_API_BASE_URL = ' http://quotes.stormconsultancy.co.uk/popular.json'
MAIL_SERVER = 'smtp.googl... | [
11748,
28686,
198,
4871,
17056,
25,
198,
220,
220,
220,
705,
7061,
198,
220,
220,
220,
3611,
8398,
2560,
1398,
198,
220,
220,
220,
705,
7061,
198,
220,
220,
220,
1303,
16363,
1847,
3398,
3620,
56,
62,
35,
1404,
6242,
11159,
62,
4726... | 2.578947 | 399 |
# Driver code
n=raw_input('Enter size : ')
arr=[]
for i in range(0,n):
arr.append(input('enter element'))
print(firstNR(arr, n))
| [
197,
198,
2,
12434,
2438,
198,
77,
28,
1831,
62,
15414,
10786,
17469,
2546,
1058,
705,
8,
198,
3258,
28,
21737,
198,
1640,
1312,
287,
2837,
7,
15,
11,
77,
2599,
198,
220,
5240,
13,
33295,
7,
15414,
10786,
9255,
5002,
6,
4008,
198,... | 2.462963 | 54 |
# -*- coding: utf-8 -*-
"""
Tests the main functionalities of the tree_models module.
"""
import logging
import couchdb
from django.utils.unittest.case import TestCase
from bilanci import tree_models
from bilanci.models import Voce
__author__ = 'guglielmo'
| [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
37811,
198,
51,
3558,
262,
1388,
10345,
871,
286,
262,
5509,
62,
27530,
8265,
13,
198,
37811,
198,
198,
11748,
18931,
198,
11748,
18507,
9945,
198,
6738,
42625,
14208,
1... | 2.977011 | 87 |
#!/usr/bin/python
# -*- coding: utf-8 -*-
import httplib
# causes httplib to return the partial response from a server in case the read fails to be complete.
httplib.HTTPResponse.read = patch_http_response_read(httplib.HTTPResponse.read) | [
2,
48443,
14629,
14,
8800,
14,
29412,
198,
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
198,
11748,
1841,
489,
571,
198,
198,
2,
5640,
1841,
489,
571,
284,
1441,
262,
13027,
2882,
422,
257,
4382,
287,
1339,
262,
... | 2.845238 | 84 |
# Copyright (c) 2020, The InferLO authors. All rights reserved.
# Licensed under the Apache License, Version 2.0 - see LICENSE file.
import numpy as np
from inferlo import PairWiseFiniteModel
from inferlo.testing import tree_potts_model, line_potts_model
from inferlo.testing.test_utils import check_samples
| [
2,
15069,
357,
66,
8,
12131,
11,
383,
554,
2232,
21982,
7035,
13,
1439,
2489,
10395,
13,
198,
2,
49962,
739,
262,
24843,
13789,
11,
10628,
362,
13,
15,
532,
766,
38559,
24290,
2393,
13,
198,
11748,
299,
32152,
355,
45941,
198,
198,
... | 3.450549 | 91 |
n = int(input('Digite um número inteiro: '))
print(f'O antecessor de {n} é \033[7;30m{n-1}\033[m e o sucessor é \033[30m{n+1}\033[m')
| [
77,
796,
493,
7,
15414,
10786,
19511,
578,
23781,
299,
21356,
647,
78,
493,
68,
7058,
25,
705,
4008,
198,
4798,
7,
69,
6,
46,
29692,
919,
273,
390,
1391,
77,
92,
38251,
3467,
44427,
58,
22,
26,
1270,
76,
90,
77,
12,
16,
32239,
... | 1.942029 | 69 |
# coding=utf-8
if __name__ == '__main__':
s = Solution()
# s.parse_and_print()
print s.find_position([1,2,3,4], 3)
| [
2,
19617,
28,
40477,
12,
23,
628,
198,
198,
361,
11593,
3672,
834,
6624,
705,
834,
12417,
834,
10354,
198,
220,
220,
220,
264,
796,
28186,
3419,
198,
220,
220,
220,
1303,
264,
13,
29572,
62,
392,
62,
4798,
3419,
198,
220,
220,
220... | 2.096774 | 62 |
import math
a = int(input())
b = int(input())
g = math.gcd(a, b)
a //= g
b //= g
if a%b:
if a//b:
print(a//b, end=' ')
print(f'{a%b}/{b}')
else:
print(a//b) | [
11748,
10688,
201,
198,
64,
796,
493,
7,
15414,
28955,
201,
198,
65,
796,
493,
7,
15414,
28955,
201,
198,
70,
796,
10688,
13,
70,
10210,
7,
64,
11,
275,
8,
201,
198,
64,
3373,
28,
308,
201,
198,
65,
3373,
28,
308,
201,
198,
20... | 1.673077 | 104 |
#!/home/mostafa_karimi/anaconda2/bin/python
# -*- coding: utf-8 -*-
import pandas as pn
import numpy as np
from sklearn import preprocessing
from scipy.stats.stats import pearsonr
print("kernel methylation islands completed")
Kernel()
| [
198,
2,
48443,
11195,
14,
1712,
28485,
62,
21070,
25236,
14,
272,
330,
13533,
17,
14,
8800,
14,
29412,
220,
198,
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
628,
198,
11748,
19798,
292,
355,
279,
77,
198,
11748,
299,... | 2.880952 | 84 |
"""
Tests the packet encoder
Created on Jul 10, 2020
@author: Joseph Paetz, hpaulson
"""
from __future__ import absolute_import
from fprime_gds.common.encoders.pkt_encoder import PktEncoder
from fprime_gds.common.data_types.pkt_data import PktData
from fprime_gds.common.utils.config_manager import ConfigManager
fro... | [
37811,
198,
51,
3558,
262,
19638,
2207,
12342,
198,
198,
41972,
319,
5979,
838,
11,
12131,
198,
31,
9800,
25,
7212,
11243,
23773,
11,
27673,
2518,
1559,
198,
37811,
198,
198,
6738,
11593,
37443,
834,
1330,
4112,
62,
11748,
628,
198,
6... | 2.334322 | 1,011 |
from rest_framework import serializers
from django.contrib.auth.models import Group, Permission
from .models import Accounts, Ticket, TicketType, TicketRecord
| [
6738,
1334,
62,
30604,
1330,
11389,
11341,
198,
6738,
42625,
14208,
13,
3642,
822,
13,
18439,
13,
27530,
1330,
4912,
11,
2448,
3411,
198,
198,
6738,
764,
27530,
1330,
35584,
11,
24014,
11,
24014,
6030,
11,
24014,
23739,
628,
198
] | 4.05 | 40 |
from random import randint
import sys
file = ['edit', 'delicious', 'wiki', 'flickr', 'youtube', 'dblp']
vertexNum = [21504191,4535197,1870709,2302925,3223589,1103412]
file = ['edit']
for i in range(len(file)):
print file[i]
f = open(file[i]+'.earliest.query', 'w')
for j in range(int(sys.argv[1])):
l... | [
6738,
4738,
1330,
43720,
600,
198,
11748,
25064,
198,
7753,
796,
37250,
19312,
3256,
705,
12381,
6243,
3256,
705,
15466,
3256,
705,
2704,
18994,
3256,
705,
11604,
3256,
705,
67,
2436,
79,
20520,
198,
332,
16886,
33111,
796,
685,
2481,
3... | 2.201058 | 189 |
#!/usr/bin/python3
"""Update DNS records."""
import logging
import os
import sys
from CloudFlare import CloudFlare
from CloudFlare.exceptions import (
CloudFlareError,
CloudFlareInternalError,
CloudFlareAPIError,
)
import requests
DEBUG = True
if DEBUG:
logging.getLogger().setLevel(logging.INFO)
... | [
2,
48443,
14629,
14,
8800,
14,
29412,
18,
198,
37811,
10260,
18538,
4406,
526,
15931,
198,
198,
11748,
18931,
198,
11748,
28686,
198,
11748,
25064,
198,
198,
6738,
10130,
7414,
533,
1330,
10130,
7414,
533,
198,
6738,
10130,
7414,
533,
1... | 2.367264 | 1,729 |
from .imagenet import imagenet_iterator
from .imagenet import multiple_imagenet_iterator
from .cifar10 import cifar10_iterator
from .cifar10 import cifar100_iterator
# from dali_imagenet import get_dali_iter
| [
6738,
764,
320,
11286,
316,
1330,
3590,
268,
316,
62,
48727,
198,
6738,
764,
320,
11286,
316,
1330,
3294,
62,
320,
11286,
316,
62,
48727,
198,
6738,
764,
66,
361,
283,
940,
1330,
269,
361,
283,
940,
62,
48727,
198,
6738,
764,
66,
... | 2.971429 | 70 |
import os
from settings import job_directory
| [
11748,
28686,
198,
198,
6738,
6460,
1330,
1693,
62,
34945,
628
] | 4.272727 | 11 |
#-*- coding:Utf-8 -*-
"""
.. currentmodule:: pylayers.antprop.antenna
This module handles antennas
An antenna can be loaded from various file formats among
+ .vsh2
+ .vsh3
+ .sh2
+ .sh3
+ .mat
+ .trx
Antenna derives from Pattern
Examples
--------
.. plot::
:include-source:
>>> import matplotlib.pyplot a... | [
2,
12,
9,
12,
19617,
25,
18274,
69,
12,
23,
532,
9,
12,
198,
37811,
198,
198,
492,
1459,
21412,
3712,
279,
2645,
6962,
13,
415,
22930,
13,
415,
13713,
198,
198,
1212,
8265,
17105,
43813,
198,
2025,
20509,
460,
307,
9639,
422,
2972... | 1.688575 | 97,590 |
import numpy as np
np.set_printoptions(linewidth=200)
# 2D integrals with simpson rule
# http://mathfaculty.fullerton.edu/mathews/n2003/SimpsonsRule2DMod.html
import quadratureCoefs as qc
rfunc_default = slater
if __name__ == "__main__":
import matplotlib.pyplot as plt
ymax = 5.0
xs = np.arange(... | [
198,
11748,
299,
32152,
355,
45941,
198,
198,
37659,
13,
2617,
62,
4798,
25811,
7,
2815,
413,
5649,
28,
2167,
8,
198,
198,
2,
362,
35,
4132,
30691,
351,
985,
8430,
3896,
198,
2,
220,
2638,
1378,
11018,
38942,
10672,
13,
12853,
29111... | 1.780093 | 864 |
###############################
#
# Created by Patrik Valkovic
# 3/12/2021
#
###############################
import unittest
import torch as t
import ffeat
from ffeat.strategies import crossover
from ffeat.utils import decay
from test.repeat import repeat
if __name__ == '__main__':
unittest.main()
| [
14468,
7804,
4242,
21017,
198,
2,
198,
2,
15622,
416,
9606,
74,
569,
971,
17215,
198,
2,
513,
14,
1065,
14,
1238,
2481,
198,
2,
198,
14468,
7804,
4242,
21017,
198,
11748,
555,
715,
395,
198,
11748,
28034,
355,
256,
198,
11748,
277,
... | 3.290323 | 93 |
#!/usr/bin/python3
# ******************************************************************************
# Copyright (c) Huawei Technologies Co., Ltd. 2020-2020. All rights reserved.
# licensed under the Mulan PSL v2.
# You can use this software according to the terms and conditions of the Mulan PSL v2.
# You may obtain a c... | [
2,
48443,
14629,
14,
8800,
14,
29412,
18,
198,
2,
41906,
17174,
46068,
1174,
198,
2,
15069,
357,
66,
8,
43208,
21852,
1766,
1539,
12052,
13,
12131,
12,
42334,
13,
1439,
2489,
10395,
13,
198,
2,
11971,
739,
262,
17996,
272,
6599,
43,... | 2.420919 | 3,155 |
"""
training
Created by: Martin Sicho
On: 19-11-19, 15:23
"""
import torch
from abc import abstractmethod
from torch import Tensor
from drugex.core import model, util
from drugex.api.corpus import Corpus, BasicCorpus
from drugex.api.pretrain.serialization import GeneratorDeserializer, StateProvider, GeneratorSerial... | [
37811,
198,
34409,
198,
198,
41972,
416,
25,
5780,
311,
38720,
198,
2202,
25,
678,
12,
1157,
12,
1129,
11,
1315,
25,
1954,
198,
37811,
198,
11748,
28034,
198,
198,
6738,
450,
66,
1330,
12531,
24396,
198,
198,
6738,
28034,
1330,
309,
... | 3.421053 | 95 |
#!/usr/bin/env python3
import pandas as pd
import seaborn as sns
import matplotlib.pyplot as plt
d = []
for line in open("counts.tsv"):
chapter, chunks, words = line.strip().split()
d.append((int(chapter), int(chunks), int(words)))
df = pd.DataFrame(d, columns=["chapter", "chunks", "words"])
sns.set_style(... | [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
18,
198,
198,
11748,
19798,
292,
355,
279,
67,
198,
11748,
384,
397,
1211,
355,
3013,
82,
198,
11748,
2603,
29487,
8019,
13,
9078,
29487,
355,
458,
83,
628,
198,
67,
796,
17635,
198,
1640... | 2.519886 | 352 |
if __name__ == '__main__':
arr = [2, 8, 5, 3, 9, 4]
#arr = []
sorted_arr = insertion_sort(arr)
sorted_arr1 = insertion_sort(sorted_arr)
print(sorted_arr1)
| [
361,
11593,
3672,
834,
6624,
705,
834,
12417,
834,
10354,
198,
220,
220,
220,
5240,
796,
685,
17,
11,
807,
11,
642,
11,
513,
11,
860,
11,
604,
60,
198,
220,
220,
220,
1303,
3258,
796,
17635,
198,
220,
220,
220,
23243,
62,
3258,
... | 2.134146 | 82 |
# SPDX-License-Identifier: Apache-2.0
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import importlib
import pkgutil
from types import ModuleType
from typing import Optional, List
import numpy as np # type: ignore
all_numeric_dtypes = [
np.int8, np... | [
2,
30628,
55,
12,
34156,
12,
33234,
7483,
25,
24843,
12,
17,
13,
15,
198,
198,
6738,
11593,
37443,
834,
1330,
4112,
62,
11748,
198,
6738,
11593,
37443,
834,
1330,
7297,
198,
6738,
11593,
37443,
834,
1330,
3601,
62,
8818,
198,
198,
1... | 2.67867 | 361 |
from django.conf import settings
from django.urls import reverse
from django.utils import timezone
from zeep import Client
from misaghestan.subscriptions.models import SubscriptionTransaction, UserSubscription
| [
6738,
42625,
14208,
13,
10414,
1330,
6460,
198,
6738,
42625,
14208,
13,
6371,
82,
1330,
9575,
198,
6738,
42625,
14208,
13,
26791,
1330,
640,
11340,
198,
6738,
41271,
538,
1330,
20985,
198,
198,
6738,
2984,
363,
3634,
272,
13,
7266,
1204... | 4 | 53 |
from typing import Optional, Iterable, Union
| [
6738,
19720,
1330,
32233,
11,
40806,
540,
11,
4479,
628,
198
] | 4.272727 | 11 |
from __future__ import print_function
from pyNastran.bdf.mesh_utils.test.test_convert import TestConvert
from pyNastran.bdf.mesh_utils.test.test_cutting_plane import TestCuttingPlane
from pyNastran.bdf.mesh_utils.test.test_mass import TestMass
from pyNastran.bdf.mesh_utils.test.test_mesh_quality import TestMeshQuality... | [
6738,
11593,
37443,
834,
1330,
3601,
62,
8818,
198,
198,
6738,
12972,
45,
459,
2596,
13,
65,
7568,
13,
76,
5069,
62,
26791,
13,
9288,
13,
9288,
62,
1102,
1851,
1330,
6208,
3103,
1851,
198,
6738,
12972,
45,
459,
2596,
13,
65,
7568,
... | 2.60396 | 303 |
from ply import lex, yacc
| [
6738,
35960,
1330,
31191,
11,
331,
4134,
628,
628,
628,
198
] | 2.909091 | 11 |
"""Defines the GraphQL schema for custom URLs."""
import graphene
from graphene import Node
from graphene_django.filter import DjangoFilterConnectionField
from graphene_django.rest_framework.mutation import SerializerMutation
from graphene_django.types import DjangoObjectType
from cdsso.users.api.serializers import US... | [
37811,
7469,
1127,
262,
29681,
9711,
32815,
329,
2183,
32336,
526,
15931,
198,
11748,
42463,
198,
6738,
42463,
1330,
19081,
198,
6738,
42463,
62,
28241,
14208,
13,
24455,
1330,
37770,
22417,
32048,
15878,
198,
6738,
42463,
62,
28241,
14208,... | 3.375 | 240 |
import torch.optim as optim
import torch.optim.lr_scheduler as lr_scheduler
from torchvision.transforms import Compose
from dataset.dense_transform import Normalize, Rotate90, VFlip, Pad, RandomRotate
from dataset.dense_transform import RandomCropAndScale, HFlip, ToTensor, ColorJitterImage, LightingImage
from tools.ad... | [
11748,
28034,
13,
40085,
355,
6436,
198,
11748,
28034,
13,
40085,
13,
14050,
62,
1416,
704,
18173,
355,
300,
81,
62,
1416,
704,
18173,
198,
6738,
28034,
10178,
13,
7645,
23914,
1330,
3082,
577,
198,
198,
6738,
27039,
13,
67,
1072,
62,... | 2.418403 | 2,304 |
"""Unit test package for ensemble."""
| [
37811,
26453,
1332,
5301,
329,
34549,
526,
15931,
198
] | 4.222222 | 9 |
import numpy as np
import math
import autogen as ag
# # basic operator test
# print (CppADScalar(1.0), -CppADScalar(1.0))
# assert CppADScalar(1.0) == CppADScalar(1.0)
# assert -CppADScalar(1.0) == CppADScalar(-1.0)
# # assert CppADScalar(2.0)**2 == CppADScalar(4.0)
# assert CppADScalar(1.0) * CppADScalar(5.0) == CppA... | [
11748,
299,
32152,
355,
45941,
198,
11748,
10688,
198,
11748,
1960,
6644,
355,
556,
198,
198,
2,
1303,
4096,
10088,
1332,
198,
2,
3601,
357,
34,
381,
2885,
3351,
282,
283,
7,
16,
13,
15,
828,
532,
34,
381,
2885,
3351,
282,
283,
7,... | 2.021978 | 637 |
from napari_plugin_engine import napari_hook_implementation
from .napari_splineit import napari_splineit
@napari_hook_implementation
| [
6738,
25422,
2743,
62,
33803,
62,
18392,
1330,
25422,
2743,
62,
25480,
62,
320,
32851,
198,
6738,
764,
77,
499,
2743,
62,
22018,
500,
270,
1330,
25422,
2743,
62,
22018,
500,
270,
628,
198,
31,
77,
499,
2743,
62,
25480,
62,
320,
3285... | 3.068182 | 44 |
# -*- coding: utf-8 -*-
from pathlib import Path
import os
import os.path
import sys
import getopt
import json
import shutil
import re
import sys
import getopt
import gettext
def main(argv):
"""
WebPerf Core - Regression Test
Usage:
verify_result.py -h
Options and arguments:
-h/--help... | [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
6738,
3108,
8019,
1330,
10644,
198,
11748,
28686,
198,
11748,
28686,
13,
6978,
198,
11748,
25064,
198,
11748,
651,
8738,
198,
11748,
33918,
198,
11748,
4423,
346,
198,
117... | 2.085603 | 1,028 |
#==============================================================================
# -*- encoding: utf-8 -*-
#==============================================================================
#==============================================================================
# Módulos Importados do Python / Devito / Examples
#=... | [
2,
23926,
25609,
855,
198,
2,
532,
9,
12,
21004,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
2,
23926,
25609,
855,
198,
198,
2,
23926,
25609,
855,
198,
2,
337,
10205,
67,
377,
418,
17267,
22484,
466,
11361,
1220,
6245,
10094,
1220,
2... | 2.947628 | 3,857 |
"""
Description:
-----------
This Script Mask the url behind another url
Usage:
-----
python3 maskurl.py
"""
import sys
import argparse
from urllib.parse import urlparse
from requests import post
banner = r"""
__ __ _ ____ _ __ _ _ ____ _
| \/ | / \ / ___| | |/ /... | [
37811,
198,
11828,
25,
198,
32284,
198,
220,
220,
220,
770,
12327,
18007,
262,
19016,
2157,
1194,
19016,
198,
198,
28350,
25,
198,
30934,
198,
220,
220,
220,
21015,
18,
9335,
6371,
13,
9078,
220,
198,
220,
220,
220,
220,
198,
37811,
... | 2.174948 | 966 |
from src.markdown_converter import MarkdownConverter
from re import compile
@MarkdownConverter.register
| [
6738,
12351,
13,
4102,
2902,
62,
1102,
332,
353,
1330,
2940,
2902,
3103,
332,
353,
198,
6738,
302,
1330,
17632,
628,
198,
31,
9704,
2902,
3103,
332,
353,
13,
30238,
198
] | 3.419355 | 31 |
from jinja2 import Template
from IPython.display import IFrame, HTML
import os
import json
from .base_plotter import IPlotter
class GCPlotter(IPlotter):
"""
Class for creating Google Charts in ipython notebook
"""
head = '''
<!-- Load Google Charts -->
<script type='text/javascript' s... | [
6738,
474,
259,
6592,
17,
1330,
37350,
198,
6738,
6101,
7535,
13,
13812,
1330,
314,
19778,
11,
11532,
198,
11748,
28686,
198,
11748,
33918,
198,
6738,
764,
8692,
62,
29487,
353,
1330,
314,
43328,
353,
628,
198,
4871,
20145,
43328,
353,
... | 1.889104 | 2,065 |
from .json_out import JSONOut
outputs = {
JSONOut.slug: JSONOut
}
__all__ = [
'JSONOut'
]
| [
6738,
764,
17752,
62,
448,
1330,
19449,
7975,
198,
198,
22915,
82,
796,
1391,
198,
220,
220,
220,
19449,
7975,
13,
6649,
1018,
25,
19449,
7975,
198,
92,
198,
198,
834,
439,
834,
796,
685,
198,
220,
220,
220,
705,
40386,
7975,
6,
1... | 2.173913 | 46 |
# -*- coding: utf-8 -*-
import json
import os
from celery.schedules import crontab
from eventkit_cloud.celery import app
from eventkit_cloud.settings.base import is_true
from eventkit_cloud.settings.contrib import * # NOQA
# Celery config
CELERY_TRACK_STARTED = True
"""
IMPORTANT
Don't propagate exceptions in th... | [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
11748,
33918,
198,
11748,
28686,
198,
6738,
18725,
1924,
13,
1416,
704,
5028,
1330,
1067,
756,
397,
198,
198,
6738,
1785,
15813,
62,
17721,
13,
7015,
88,
1330,
598,
198,... | 2.258652 | 1,647 |
import cv2
# path
path = r'D:\DLive\PINet\dataset\Test_images\11A00160.jpg'
# Reading an image in default mode
image = cv2.imread(path)
# Window name in which image is displayed
window_name = 'image'
# Using cv2.imshow() method
# Displaying the image
cv2.imshow(window_name, image)
#waits for user to ... | [
11748,
269,
85,
17,
220,
198,
220,
220,
198,
2,
3108,
220,
198,
6978,
796,
374,
6,
35,
7479,
35,
18947,
59,
44032,
316,
59,
19608,
292,
316,
59,
14402,
62,
17566,
59,
1157,
32,
405,
14198,
13,
9479,
6,
198,
220,
220,
198,
2,
1... | 2.645714 | 175 |
from tabnanny import verbose
from embed_video.fields import EmbedVideoField
from core.utils import get_file_path
from django.db import models
from pydoc import describe
CHOICES_RATTING = [
(0, "L"),
(10, "10"),
(12, "12"),
(14, "14"),
(16, "16"),
(18, "18"),
]
| [
6738,
7400,
77,
7737,
1330,
15942,
577,
198,
6738,
11525,
62,
15588,
13,
25747,
1330,
13302,
276,
10798,
15878,
198,
6738,
4755,
13,
26791,
1330,
651,
62,
7753,
62,
6978,
198,
6738,
42625,
14208,
13,
9945,
1330,
4981,
198,
6738,
279,
... | 2.423729 | 118 |
#%%
import time
start = time.time()
#import gdal, ogr, osr
from osgeo import gdal
from osgeo import ogr
from osgeo import osr
from osgeo.gdalnumeric import *
from osgeo.gdalconst import *
#import numpy as np
#import scipy.ndimage as ndimage
#import pandas as pd
from subprocess import call
from itertools import compres... | [
2,
16626,
198,
11748,
640,
198,
9688,
796,
640,
13,
2435,
3419,
198,
198,
2,
11748,
308,
31748,
11,
267,
2164,
11,
267,
27891,
198,
6738,
28686,
469,
78,
1330,
308,
31748,
198,
6738,
28686,
469,
78,
1330,
267,
2164,
198,
6738,
28686... | 2.047566 | 4,478 |
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
"""
Created on Wed Dec 23 23:32:28 2020
@author: cjburke
Solve the rubik's cube with a Iterative Deepening Depth First Search
With a precalculated pattern database of minimum length to solve
for various configurations.
This borrows heavily from the excellent Blog pie... | [
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,
3300,
4280,
2242,
2242,
25,
2624,
25,
2078,
12131,
198,
198,
31,
9800,
25,
269,
73,
6236,... | 2.209236 | 5,587 |
"""
"""
import sys
from functools import wraps
import logging
from six import with_metaclass
from .errors import ResourceExistsError
logger = logging.getLogger("nar")
registry = {}
# todo: add namespaces to avoid name clashes, e.g. "Person" exists in several namespaces
class Registry(type):
"""Metaclass f... | [
37811,
198,
198,
37811,
198,
198,
11748,
25064,
198,
6738,
1257,
310,
10141,
1330,
27521,
198,
11748,
18931,
198,
6738,
2237,
1330,
351,
62,
4164,
330,
31172,
198,
6738,
764,
48277,
1330,
20857,
3109,
1023,
12331,
628,
198,
6404,
1362,
... | 2.283737 | 1,156 |
import datetime
| [
11748,
4818,
8079,
628
] | 4.25 | 4 |
"""Configuration store, retrieval, validation, and supporting functionality."""
import configparser
import logging
import os
from .general import CHECKSUM_TAG_PREFIX
from .general import CHECKSUM_TAG_PREFIX_NORMALIZED
from .general import SyncError
DEFAULT_CONFIG_DIR = '~/.config/flickrsyncr'
DEFAULT_SECTION_NAME = '... | [
37811,
38149,
3650,
11,
45069,
11,
21201,
11,
290,
6493,
11244,
526,
15931,
198,
11748,
4566,
48610,
198,
11748,
18931,
198,
11748,
28686,
198,
198,
6738,
764,
24622,
1330,
5870,
25171,
50,
5883,
62,
42197,
62,
47,
31688,
10426,
198,
67... | 2.606593 | 2,275 |
##
# Copyright (c) 2015-2017 Apple Inc. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable l... | [
2235,
198,
2,
15069,
357,
66,
8,
1853,
12,
5539,
4196,
3457,
13,
1439,
2489,
10395,
13,
198,
2,
198,
2,
49962,
739,
262,
24843,
13789,
11,
10628,
362,
13,
15,
357,
1169,
366,
34156,
15341,
198,
2,
345,
743,
407,
779,
428,
2393,
... | 2.401029 | 4,274 |
n = int(input("Enter a number: "))
factorial = 1
for i in range(1, n + 1):
factorial *= i
print(f"Factorial of {n} is {factorial}")
| [
77,
796,
493,
7,
15414,
7203,
17469,
257,
1271,
25,
366,
4008,
198,
198,
22584,
5132,
796,
352,
198,
198,
1640,
1312,
287,
2837,
7,
16,
11,
299,
1343,
352,
2599,
198,
220,
220,
220,
1109,
5132,
1635,
28,
1312,
198,
198,
4798,
7,
... | 2.355932 | 59 |
import dropbox
import hashlib
import math
import os
import pdbox
import shutil
from pdbox.utils import DropboxError, dbx_uri, execute, normpath
def get_remote(path, meta=None):
"""
Get a RemoteFile or RemoteFolder from path.
Raises:
- ValueError
"""
if meta: # Don't look up the path, just us... | [
11748,
4268,
3524,
198,
11748,
12234,
8019,
198,
11748,
10688,
198,
11748,
28686,
198,
11748,
279,
67,
3524,
198,
11748,
4423,
346,
198,
198,
6738,
279,
67,
3524,
13,
26791,
1330,
38930,
12331,
11,
20613,
87,
62,
9900,
11,
12260,
11,
... | 2.197143 | 9,242 |
from mol_tree import Vocab, MolTree
from jtnn_vae import JTNNVAE
from jtnn_f import JTNNVAEMLP
from jtnn_mj import JTNNVAEMJ
from jtnn_enc import JTNNEncoder
from jtmpn import JTMPN
from mpn import MPN
from nnutils import create_var
from datautils import MolTreeFolder, PairTreeFolder, MolTreeDataset, MolTreeFolderMLP, ... | [
6738,
18605,
62,
21048,
1330,
47208,
397,
11,
17958,
27660,
198,
6738,
474,
83,
20471,
62,
33353,
1330,
449,
51,
6144,
11731,
36,
198,
6738,
474,
83,
20471,
62,
69,
1330,
449,
51,
6144,
11731,
3620,
19930,
198,
6738,
474,
83,
20471,
... | 2.77686 | 121 |
from django.contrib.localflavor.fi.forms import (FIZipCodeField,
FISocialSecurityNumber, FIMunicipalitySelect)
from utils import LocalFlavorTestCase
| [
6738,
42625,
14208,
13,
3642,
822,
13,
17946,
1604,
75,
5570,
13,
12463,
13,
23914,
1330,
357,
11674,
41729,
10669,
15878,
11,
198,
220,
220,
220,
376,
1797,
9402,
24074,
15057,
11,
376,
3955,
9462,
1483,
17563,
8,
198,
198,
6738,
338... | 3.058824 | 51 |
#!/usr/bin/python3
import argparse
import os
parser = argparse.ArgumentParser()
parser.add_argument('infile', nargs='+',
help='one or more input files')
parser.add_argument('--generate', action='store_true',
help='generate new instance and exit')
parser.add_argument('--heurist... | [
2,
48443,
14629,
14,
8800,
14,
29412,
18,
198,
198,
11748,
1822,
29572,
198,
11748,
28686,
198,
198,
48610,
796,
1822,
29572,
13,
28100,
1713,
46677,
3419,
198,
198,
48610,
13,
2860,
62,
49140,
10786,
259,
7753,
3256,
299,
22046,
11639,... | 2.039261 | 866 |
import sqreen
| [
11748,
19862,
1361,
628
] | 3.75 | 4 |
from extutils.flags import (
DuplicatedCodeError,
FlagCodeEnum, FlagSingleEnum, FlagDoubleEnum, FlagPrefixedDoubleEnum,
is_flag_instance, is_flag_class, is_flag_single, is_flag_double
)
from tests.base import TestCase
__all__ = ["TestFlagMisc", "TestFlagCodeEnum", "TestFlagSingleEnum", "TestFlagDoubleEnum"... | [
6738,
1070,
26791,
13,
33152,
1330,
357,
198,
220,
220,
220,
49821,
3474,
10669,
12331,
11,
198,
220,
220,
220,
19762,
10669,
4834,
388,
11,
19762,
28008,
4834,
388,
11,
19762,
25628,
4834,
388,
11,
19762,
36698,
2966,
25628,
4834,
388,... | 2.715328 | 137 |
# -*- coding: utf8 -*-
from __future__ import (
absolute_import,
division,
print_function,
unicode_literals
)
from lxml.html import fragment_fromstring, document_fromstring
from breadability.readable import Article
from breadability.annotated_text import AnnotatedTextHandler
from .utils import load_sn... | [
2,
532,
9,
12,
19617,
25,
3384,
69,
23,
532,
9,
12,
198,
198,
6738,
11593,
37443,
834,
1330,
357,
198,
220,
220,
220,
4112,
62,
11748,
11,
198,
220,
220,
220,
7297,
11,
198,
220,
220,
220,
3601,
62,
8818,
11,
198,
220,
220,
22... | 3.116071 | 112 |
from lib.pyse import Pyse
from selenium.webdriver.support import expected_conditions as EC
from selenium.webdriver.support.ui import WebDriverWait
from appium.webdriver.common.mobileby import MobileBy
from appium.webdriver.connectiontype import ConnectionType
| [
6738,
9195,
13,
9078,
325,
1330,
9485,
325,
201,
198,
6738,
384,
11925,
1505,
13,
12384,
26230,
13,
11284,
1330,
2938,
62,
17561,
1756,
355,
13182,
201,
198,
6738,
384,
11925,
1505,
13,
12384,
26230,
13,
11284,
13,
9019,
1330,
5313,
3... | 3.467532 | 77 |
#!/usr/bin/env python3
"""
@Filename: streamlit_server.py
@Author: dulanj
@Time: 12/02/2022 16:38
"""
import streamlit as st
from backend import SportEventDetectionBackend
if 'process_button' not in st.session_state:
st.session_state['process_button'] = False
if 'dataframe' not in st.session_state:... | [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
18,
198,
37811,
198,
31,
35063,
25,
220,
220,
220,
4269,
18250,
62,
15388,
13,
9078,
198,
31,
13838,
25,
220,
220,
220,
220,
220,
288,
377,
272,
73,
198,
31,
7575,
25,
220,
220,
220,
... | 2.527098 | 1,144 |
# -*- coding: utf-8 -*-
# quiz-orm/app.py
from flask import Flask
from flask_sqlalchemy import SQLAlchemy
import os
app = Flask(__name__)
# konfiguracja aplikacji
app.config.update(dict(
SECRET_KEY='bardzosekretnawartosc',
DATABASE=os.path.join(app.root_path, 'quiz.db'),
SQLALCHEMY_DATABASE_URI='sqlite:/... | [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
2,
38964,
12,
579,
14,
1324,
13,
9078,
198,
198,
6738,
42903,
1330,
46947,
198,
6738,
42903,
62,
25410,
282,
26599,
1330,
16363,
2348,
26599,
198,
11748,
28686,
198,
198... | 2.056818 | 264 |
from microbit import *
import random
import time
random.seed()
#afbeeldingen
blad = Image("00000:"
"09990:"
"09990:"
"09990:"
"09990:")
steen = Image("00000:"
"00000:"
"09990:"
"99999:"
"999... | [
6738,
4580,
2545,
1330,
1635,
201,
198,
11748,
4738,
201,
198,
11748,
640,
201,
198,
201,
198,
25120,
13,
28826,
3419,
201,
198,
201,
198,
2,
1878,
20963,
335,
36795,
201,
198,
2436,
324,
796,
7412,
7203,
20483,
11097,
201,
198,
220,
... | 1.632075 | 848 |
#!/usr/bin/env python3
"""Setup script."""
from setuptools import setup, find_packages
setup(
name="obormot",
version="0.0.0",
author="Britsyn Eugene, Luzyanin Artemiy, Rassolov Sergey",
author_email="ebritsyn@gmail.com, kek@obormor.com, kek@obormot.ru",
url="https://github.com/ebritsyn/obormot"... | [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
18,
198,
198,
37811,
40786,
4226,
526,
15931,
198,
198,
6738,
900,
37623,
10141,
1330,
9058,
11,
1064,
62,
43789,
628,
198,
40406,
7,
198,
220,
220,
220,
1438,
2625,
672,
579,
313,
1600,
... | 2.056751 | 511 |
#
# Copyright (C) 2016, 2017
# The Board of Trustees of the Leland Stanford Junior University
# Written by Stephane Thiell <sthiell@stanford.edu>
#
# 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 Lic... | [
2,
198,
2,
15069,
357,
34,
8,
1584,
11,
2177,
198,
2,
220,
220,
220,
220,
220,
383,
5926,
286,
9870,
2841,
286,
262,
406,
8822,
13863,
20000,
2059,
198,
2,
22503,
416,
39644,
1531,
536,
494,
297,
1279,
48476,
494,
297,
31,
14192,
... | 2.520595 | 874 |
'''
Script which runs a ModelBuilder model externally.
Imports the toolbox which contains the model of interest - in this case the "BombExplosion" model from the Practical1_Models.tbx.
This model simulates the impact of a bomb exploding on the buildings in its vicinity.
The model is run by specifiying the locations of ... | [
7061,
6,
198,
7391,
543,
4539,
257,
9104,
32875,
2746,
45107,
13,
198,
3546,
3742,
262,
2891,
3524,
543,
4909,
262,
2746,
286,
1393,
532,
287,
428,
1339,
262,
366,
48478,
18438,
18442,
1,
2746,
422,
262,
13672,
605,
16,
62,
5841,
14... | 2.69209 | 708 |
from .bar import bar
from .animation import animation
__version__ = '0.0.3'
| [
6738,
764,
5657,
1330,
2318,
198,
6738,
764,
11227,
341,
1330,
11034,
198,
834,
9641,
834,
796,
705,
15,
13,
15,
13,
18,
6,
198
] | 3.04 | 25 |
from tkinter import *
from tkinter import messagebox
import requests
import json
type = 'ann'
cnt=0
apiKey = 'YOUR_API_KEY_HERE'
BASE_URL = f'http://newsapi.org/v2/top-headlines?country=in&category={type}&apiKey=' + apiKey
root = Tk()
obj = NewsApp(root)
root.mainloop() | [
6738,
256,
74,
3849,
1330,
1635,
201,
198,
6738,
256,
74,
3849,
1330,
3275,
3524,
201,
198,
11748,
7007,
201,
198,
11748,
33918,
201,
198,
201,
198,
4906,
796,
705,
1236,
6,
201,
198,
66,
429,
28,
15,
201,
198,
15042,
9218,
796,
7... | 2.257576 | 132 |
"""empty message
Revision ID: 77f2a6d0342a
Revises:
Create Date: 2020-05-01 15:46:52.747402
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '77f2a6d0342a'
down_revision = None
branch_labels = None
depends_on = None
| [
37811,
28920,
3275,
198,
198,
18009,
1166,
4522,
25,
8541,
69,
17,
64,
21,
67,
15,
31575,
64,
198,
18009,
2696,
25,
220,
198,
16447,
7536,
25,
12131,
12,
2713,
12,
486,
1315,
25,
3510,
25,
4309,
13,
48882,
32531,
198,
198,
37811,
... | 2.564815 | 108 |