content
stringlengths 1
1.04M
| input_ids
sequencelengths 1
774k
| ratio_char_token
float64 0.38
22.9
| token_count
int64 1
774k
|
---|---|---|---|
""" [ raycast select module ] """
from bpy.types import Operator
import bpy
from bpy import ops as O
from .DoRaycast import do_raycast
from . import CallbackOptions
class PerformRaycastSelect(Operator):
"""Run a side differentiation and select the points by raycast"""
bl_idname = "view3d.raycast_select_pair"
bl_label = "RayCast Select Operator"
bl_options = {'REGISTER', 'UNDO'}
# Establish some variables
execution_function_name: bpy.props.StringProperty(name='callback', default='run_by_selection')
# Initialize some variables
execution_function = None
save_mode = None
break_number = 0
| [
37811,
685,
26842,
2701,
2922,
8265,
2361,
37227,
198,
6738,
275,
9078,
13,
19199,
1330,
35946,
198,
11748,
275,
9078,
198,
6738,
275,
9078,
1330,
39628,
355,
440,
198,
198,
6738,
764,
5211,
19591,
2701,
1330,
466,
62,
2433,
2701,
198,
6738,
764,
1330,
4889,
1891,
29046,
628,
198,
4871,
35006,
19591,
2701,
17563,
7,
18843,
1352,
2599,
198,
220,
220,
220,
37227,
10987,
257,
1735,
32488,
290,
2922,
262,
2173,
416,
26842,
2701,
37811,
198,
220,
220,
220,
698,
62,
312,
3672,
796,
366,
1177,
18,
67,
13,
2433,
2701,
62,
19738,
62,
24874,
1,
198,
220,
220,
220,
698,
62,
18242,
796,
366,
19591,
19248,
9683,
35946,
1,
198,
220,
220,
220,
698,
62,
25811,
796,
1391,
6,
31553,
41517,
3256,
705,
4944,
18227,
6,
92,
198,
220,
220,
220,
220,
198,
220,
220,
220,
1303,
10062,
17148,
617,
9633,
198,
220,
220,
220,
9706,
62,
8818,
62,
3672,
25,
275,
9078,
13,
1676,
862,
13,
10100,
21746,
7,
3672,
11639,
47423,
3256,
4277,
11639,
5143,
62,
1525,
62,
49283,
11537,
198,
220,
220,
220,
220,
198,
220,
220,
220,
1303,
20768,
1096,
617,
9633,
198,
220,
220,
220,
9706,
62,
8818,
796,
6045,
198,
220,
220,
220,
3613,
62,
14171,
796,
6045,
198,
220,
220,
220,
2270,
62,
17618,
796,
657,
198
] | 2.995349 | 215 |
"""Free Google Translate API for Python. Translates totally free of charge."""
__all__ = 'Translator',
__version__ = '3.2.1'
from aiogoogletrans.client import Translator
from aiogoogletrans.constants import LANGCODES, LANGUAGES
| [
37811,
11146,
3012,
3602,
17660,
7824,
329,
11361,
13,
3602,
75,
689,
6635,
1479,
286,
3877,
526,
15931,
198,
834,
439,
834,
796,
705,
8291,
41880,
3256,
198,
834,
9641,
834,
796,
705,
18,
13,
17,
13,
16,
6,
628,
198,
6738,
257,
72,
24076,
519,
1616,
26084,
13,
16366,
1330,
3602,
41880,
198,
6738,
257,
72,
24076,
519,
1616,
26084,
13,
9979,
1187,
1330,
406,
15567,
34,
3727,
1546,
11,
406,
15567,
52,
25552,
198
] | 3.026316 | 76 |
import uuid
import pytest
from selenium.common.exceptions import TimeoutException
from skyportal.tests import api
@pytest.mark.flaky(reruns=2)
@pytest.mark.flaky(reruns=2)
@pytest.mark.flaky(reruns=2)
@pytest.mark.flaky(reruns=2)
@pytest.mark.flaky(reruns=2)
@pytest.mark.flaky(reruns=2)
| [
11748,
334,
27112,
198,
11748,
12972,
9288,
198,
6738,
384,
11925,
1505,
13,
11321,
13,
1069,
11755,
1330,
3862,
448,
16922,
198,
198,
6738,
6766,
634,
282,
13,
41989,
1330,
40391,
628,
198,
198,
31,
9078,
9288,
13,
4102,
13,
2704,
15492,
7,
260,
48381,
28,
17,
8,
628,
198,
31,
9078,
9288,
13,
4102,
13,
2704,
15492,
7,
260,
48381,
28,
17,
8,
628,
198,
31,
9078,
9288,
13,
4102,
13,
2704,
15492,
7,
260,
48381,
28,
17,
8,
628,
198,
31,
9078,
9288,
13,
4102,
13,
2704,
15492,
7,
260,
48381,
28,
17,
8,
628,
198,
31,
9078,
9288,
13,
4102,
13,
2704,
15492,
7,
260,
48381,
28,
17,
8,
628,
198,
31,
9078,
9288,
13,
4102,
13,
2704,
15492,
7,
260,
48381,
28,
17,
8,
198
] | 2.341085 | 129 |
from pypy.rpython.ootypesystem.ootype import ROOT, Instance, \
addMethods, meth, Meth, Void
from pypy.translator.backendopt.checkvirtual import check_virtual_methods
| [
6738,
279,
4464,
88,
13,
81,
29412,
13,
1025,
9497,
6781,
13,
1025,
2981,
1330,
15107,
2394,
11,
2262,
590,
11,
3467,
198,
220,
220,
220,
220,
751,
46202,
11,
11248,
11,
39675,
11,
18331,
198,
6738,
279,
4464,
88,
13,
7645,
41880,
13,
1891,
437,
8738,
13,
9122,
32844,
1330,
2198,
62,
32844,
62,
24396,
82,
628
] | 2.965517 | 58 |
from .URL_PARSER import get_text
| [
6738,
764,
21886,
62,
27082,
35009,
1330,
651,
62,
5239,
198
] | 3 | 11 |
import argparse, logging, filepattern
from pathlib import Path
# Initialize the logger
logging.basicConfig(
format="%(asctime)s - %(name)-8s - %(levelname)-8s - %(message)s",
datefmt="%d-%b-%y %H:%M:%S",
)
logger = logging.getLogger("main")
logger.setLevel(logging.INFO)
if __name__ == "__main__":
# Setup the Argument parsing
logger.info("Parsing arguments...")
parser = argparse.ArgumentParser(
prog="main", description="Extract individual fields of view from a czi file."
)
parser.add_argument(
"--stitchDir",
dest="stitch_dir",
type=str,
help="Stitching vector to recycle",
required=True,
)
parser.add_argument(
"--collectionDir",
dest="collection_dir",
type=str,
help="Image collection to place in new stitching vector",
required=True,
)
parser.add_argument(
"--filepattern",
dest="pattern",
type=str,
help="Stitching vector regular expression",
required=False,
)
parser.add_argument(
"--outDir",
dest="output_dir",
type=str,
help="The directory in which to save stitching vectors.",
required=True,
)
# Get the arguments
args = parser.parse_args()
stitch_dir = Path(args.stitch_dir)
collection_dir = Path(args.collection_dir)
if collection_dir.joinpath("images").is_dir():
# switch to images folder if present
inpDir = collection_dir.joinpath("images").absolute()
pattern = args.pattern
output_dir = Path(args.output_dir)
logger.info("stitch_dir = {}".format(stitch_dir))
logger.info("collection_dir = {}".format(collection_dir))
logger.info("filepattern = {}".format(pattern))
logger.info("output_dir = {}".format(output_dir))
main(stitch_dir, collection_dir, output_dir, pattern)
| [
11748,
1822,
29572,
11,
18931,
11,
2393,
33279,
198,
6738,
3108,
8019,
1330,
10644,
198,
198,
2,
20768,
1096,
262,
49706,
198,
6404,
2667,
13,
35487,
16934,
7,
198,
220,
220,
220,
5794,
2625,
4,
7,
292,
310,
524,
8,
82,
532,
4064,
7,
3672,
13219,
23,
82,
532,
4064,
7,
5715,
3672,
13219,
23,
82,
532,
4064,
7,
20500,
8,
82,
1600,
198,
220,
220,
220,
3128,
69,
16762,
2625,
4,
67,
12,
4,
65,
12,
4,
88,
4064,
39,
25,
4,
44,
25,
4,
50,
1600,
198,
8,
198,
6404,
1362,
796,
18931,
13,
1136,
11187,
1362,
7203,
12417,
4943,
198,
6404,
1362,
13,
2617,
4971,
7,
6404,
2667,
13,
10778,
8,
628,
628,
198,
361,
11593,
3672,
834,
6624,
366,
834,
12417,
834,
1298,
628,
220,
220,
220,
1303,
31122,
262,
45751,
32096,
198,
220,
220,
220,
49706,
13,
10951,
7203,
47,
945,
278,
7159,
9313,
8,
198,
220,
220,
220,
30751,
796,
1822,
29572,
13,
28100,
1713,
46677,
7,
198,
220,
220,
220,
220,
220,
220,
220,
1172,
2625,
12417,
1600,
6764,
2625,
11627,
974,
1981,
7032,
286,
1570,
422,
257,
269,
17027,
2393,
526,
198,
220,
220,
220,
1267,
628,
220,
220,
220,
30751,
13,
2860,
62,
49140,
7,
198,
220,
220,
220,
220,
220,
220,
220,
366,
438,
301,
2007,
35277,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
2244,
2625,
301,
2007,
62,
15908,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
2099,
28,
2536,
11,
198,
220,
220,
220,
220,
220,
220,
220,
1037,
2625,
1273,
19811,
15879,
284,
48914,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
2672,
28,
17821,
11,
198,
220,
220,
220,
1267,
198,
220,
220,
220,
30751,
13,
2860,
62,
49140,
7,
198,
220,
220,
220,
220,
220,
220,
220,
366,
438,
43681,
35277,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
2244,
2625,
43681,
62,
15908,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
2099,
28,
2536,
11,
198,
220,
220,
220,
220,
220,
220,
220,
1037,
2625,
5159,
4947,
284,
1295,
287,
649,
48945,
15879,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
2672,
28,
17821,
11,
198,
220,
220,
220,
1267,
198,
220,
220,
220,
30751,
13,
2860,
62,
49140,
7,
198,
220,
220,
220,
220,
220,
220,
220,
366,
438,
7753,
33279,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
2244,
2625,
33279,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
2099,
28,
2536,
11,
198,
220,
220,
220,
220,
220,
220,
220,
1037,
2625,
1273,
19811,
15879,
3218,
5408,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
2672,
28,
25101,
11,
198,
220,
220,
220,
1267,
198,
220,
220,
220,
30751,
13,
2860,
62,
49140,
7,
198,
220,
220,
220,
220,
220,
220,
220,
366,
438,
448,
35277,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
2244,
2625,
22915,
62,
15908,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
2099,
28,
2536,
11,
198,
220,
220,
220,
220,
220,
220,
220,
1037,
2625,
464,
8619,
287,
543,
284,
3613,
48945,
30104,
33283,
198,
220,
220,
220,
220,
220,
220,
220,
2672,
28,
17821,
11,
198,
220,
220,
220,
1267,
628,
220,
220,
220,
1303,
3497,
262,
7159,
198,
220,
220,
220,
26498,
796,
30751,
13,
29572,
62,
22046,
3419,
198,
220,
220,
220,
24695,
62,
15908,
796,
10644,
7,
22046,
13,
301,
2007,
62,
15908,
8,
198,
220,
220,
220,
4947,
62,
15908,
796,
10644,
7,
22046,
13,
43681,
62,
15908,
8,
198,
220,
220,
220,
611,
4947,
62,
15908,
13,
22179,
6978,
7203,
17566,
11074,
271,
62,
15908,
33529,
198,
220,
220,
220,
220,
220,
220,
220,
1303,
5078,
284,
4263,
9483,
611,
1944,
198,
220,
220,
220,
220,
220,
220,
220,
287,
79,
35277,
796,
4947,
62,
15908,
13,
22179,
6978,
7203,
17566,
11074,
48546,
3419,
198,
220,
220,
220,
3912,
796,
26498,
13,
33279,
198,
220,
220,
220,
5072,
62,
15908,
796,
10644,
7,
22046,
13,
22915,
62,
15908,
8,
198,
220,
220,
220,
49706,
13,
10951,
7203,
301,
2007,
62,
15908,
796,
23884,
1911,
18982,
7,
301,
2007,
62,
15908,
4008,
198,
220,
220,
220,
49706,
13,
10951,
7203,
43681,
62,
15908,
796,
23884,
1911,
18982,
7,
43681,
62,
15908,
4008,
198,
220,
220,
220,
49706,
13,
10951,
7203,
7753,
33279,
796,
23884,
1911,
18982,
7,
33279,
4008,
198,
220,
220,
220,
49706,
13,
10951,
7203,
22915,
62,
15908,
796,
23884,
1911,
18982,
7,
22915,
62,
15908,
4008,
628,
220,
220,
220,
1388,
7,
301,
2007,
62,
15908,
11,
4947,
62,
15908,
11,
5072,
62,
15908,
11,
3912,
8,
198
] | 2.469201 | 763 |
#
# @lc app=leetcode id=1 lang=python3
#
# [1] Two Sum
#
# @lc code=start
# @lc code=end
| [
2,
198,
2,
2488,
44601,
598,
28,
293,
316,
8189,
4686,
28,
16,
42392,
28,
29412,
18,
198,
2,
198,
2,
685,
16,
60,
4930,
5060,
198,
2,
198,
198,
2,
2488,
44601,
2438,
28,
9688,
198,
2,
2488,
44601,
2438,
28,
437,
628
] | 2.068182 | 44 |
from flask import Flask
from flask_bootstrap import Bootstrap
from flask_sqlalchemy import SQLAlchemy
from config import config
from config import Config as CF
from utils import log
bootstrap = Bootstrap()
db = SQLAlchemy()
| [
6738,
42903,
1330,
46947,
198,
6738,
42903,
62,
18769,
26418,
1330,
18892,
26418,
198,
6738,
42903,
62,
25410,
282,
26599,
1330,
16363,
2348,
26599,
198,
6738,
4566,
1330,
4566,
198,
6738,
4566,
1330,
17056,
355,
18551,
198,
6738,
3384,
4487,
1330,
2604,
198,
198,
18769,
26418,
796,
18892,
26418,
3419,
198,
9945,
796,
16363,
2348,
26599,
3419,
628
] | 3.896552 | 58 |
# -*- coding: utf-8 -*-
# @Author: aaronpmishkin
# @Date: 2017-07-28 21:07:21
# @Last Modified by: aaronpmishkin
# @Last Modified time: 2017-08-09 13:09:35
import numpy as np
from scipy.spatial.distance import cdist
class RBF():
""" RBF
Implementation of the radial basis function kernel. Also called the squared exponential kernel.
Arguments:
----------
dim: integer
The dimensionality of inputs to the kernel (i.e. dimension of X).
length_scale: number
The length scale of the kernel function.
var: number
The variance magnitude of the kernel function.
"""
def get_parameters(self):
""" get_parameters
Get the kernel's parameters.
"""
return np.array([self.length_scale, self.var])
def set_parameters(self, theta):
""" set_parameters
Set the kernel's parameters.
Arguments:
----------
theta: array-like, shape = [2, ]
An array containing the new parameters of the kernel.
The parameter order is [length_scale, variance]
"""
self.length_scale = theta[0]
self.var = theta[1]
def cov(self, X, Y=None, theta=None):
""" cov
Compute the covariance matrix of X and Y using the RBF kernel.
Arguments:
----------
X: array-like, shape = [n_samples, n_features]
An array of inputs.
Y (optional): array-like, shape = [m_samples, n_features]
A second array of inputs.
If Y is None, then the covariance matrix of X with itself will be computed.
theta (optional): array-like, shape = [2, ]
An array of parameter values for the kernel.
"""
# print(X, Y)
if Y is None:
Y = X
if theta is None:
theta = np.array([self.length_scale, self.var])
# Compute a matrix of squared eucledian distances between X and Y
dist = cdist(X, Y, 'sqeuclidean')
K = theta[1] * np.exp(dist / (-2 * (theta[0] ** 2)))
# print(K.shape)
return K
def cov_gradient(self, X, theta=None):
""" cov_gradient
Compute the gradient of the covariance matrix of X with respect to the parameters
of the RBF kernel.
Arguments:
----------
X: array-like, shape = [n_samples, n_features]
An array of inputs.
theta (optional): array-like, shape = [2, ]
An array of parameter values for the kernel.
"""
if theta is None:
theta = np.array([self.length_scale, self.var])
dist = cdist(X, X, 'sqeuclidean')
K = np.exp(dist / (-2 * (theta[0] ** 2)))
dK_dl = theta[1] * (theta[0] ** -3) * dist * K
dK_dvar = K
return np.array([dK_dl, dK_dvar])
class Additive():
""" RBF
Implementation of the additive kernel as described by Duvenaud et al, 2011
Arguments:
----------
dim: integer,
The dimensionality of inputs to the kernel (i.e. dimension of X).
order: number, order <= dim
The order of the additive kernel.
base_kernels: array-like, shape = [dim, ]
The set of base kernel functions, one for each dimension.
var: array-like, shape = [order, ]
An array of variance magnitudes, one for each order d: 1 <= d <= D
"""
def get_parameters(self):
""" get_parameters
Get the kernel's parameters, which include the parameters of the base kernels.
"""
theta = np.copy(self.var)
for kernel in self.base_kernels:
theta = np.append(theta, kernel.get_parameters())
return theta
def set_parameters(self, theta):
""" set_parameters
Set the kernel's parameters. This must include the parameters of the base kernels.
Arguments:
----------
theta: array-like, shape = [n_parameter, ]
An array containing the new parameters of the kernel.
The first |self.order| elements must be the interaction variance parameters.
The remaining elements must be parameters for the base kernels.
"""
self.var = theta[0:self.order]
param_index = self.order
for kernel in self.base_kernels:
kernel.set_parameters(theta[param_index:param_index + kernel.num_parameters])
param_index += kernel.num_parameters
def __cov__(self, X, Y=None, order=None, theta=None, base_kernels=None):
""" __cov__
Compute the covariance matrix of inputs X and Y. Returns both the covariance matrix
and a list of covariance matrices for each order of interaction.
This is an internal helper. To obtain the just covariance matrix of X (and Y), call "cov"
instead.
Arguments:
----------
X: array-like, shape = [n_samples, n_features]
An array of inputs.
Y (optional): array-like, shape = [m_samples, n_features]
A second array of inputs.
theta: array-like, shape = [n_parameter, ]
The kernel parameters to use when computing the covariance.
If None, the current parameters of the kernel are used.
order: integer
The interaction order that will be used.
If None, the current kernel setting will be used.
base_kernels: array-like, shape = [n_features, ]
The list of base_kernels, one for each feature.
Exactly one base_kernel must be provided per input feature.
If None, the current base_kernels of the kernel are used.
"""
if Y is None:
Y = X
if theta is None:
theta = self.theta
if order is None:
order = self.order
if base_kernels is None:
base_kernels = self.base_kernels
# Z is the array of covariance matrices produced by application of the base kernels.
Z = np.ones((len(base_kernels), X.shape[0], Y.shape[0]))
# S is the array of of k^th power sums of the matrices in Z, k = 1 ... self.order
S = np.ones((order + 1, X.shape[0], Y.shape[0]))
# K is the array of k^th order additive kernels, k = 1 ... order
K = np.zeros((order + 1, X.shape[0], Y.shape[0]))
K[0] = 1
p_index = len(base_kernels)
for i, kernel in enumerate(base_kernels):
params = theta[p_index:p_index + kernel.num_parameters]
p_index += kernel.num_parameters
Z[i] = kernel.cov(X[:, i].reshape(X.shape[0], 1),
Y[:, i].reshape(Y.shape[0], 1),
theta=params)
Z_d = np.copy(Z)
for d in range(1, order + 1):
S[d] = np.sum(Z_d, axis=0)
Z_d = Z_d * Z_d
for d in range(1, order + 1):
for j in range(1, d + 1):
K[d] += ((-1) ** (j - 1)) * K[d - j] * S[j]
K[d] = K[d] / d
for d in range(1, order + 1):
K[d] = theta[d - 1] * K[d]
return np.sum(K[1:], axis=0), K[1:]
def cov(self, X, Y=None, order=None, theta=None, base_kernels=None):
""" cov
Compute the covariance matrix of inputs X and Y using __cov__.
Arguments:
----------
X: array-like, shape = [n_samples, n_features]
An array of inputs.
Y (optional): array-like, shape = [m_samples, n_features]
A second array of inputs.
theta: array-like, shape = [n_parameter, ]
The kernel parameters to use when computing the covariance.
If None, the current parameters of the kernel are used.
order: integer
The interaction order that will be used.
If None, the current kernel setting will be used.
base_kernels: array-like, shape = [X.shape[0], ]
The base_kernels to use for each feature.
Exactly one base_kernel must be provided per input feature.
If None, the current base_kernels of the kernel are used.
"""
K, K_orders = self.__cov__(X, Y, order, theta, base_kernels)
return K
def cov_gradient(self, X, theta=None):
""" cov_gradient
Compute the gradient of the covariance matrix of X with respect to the parameters
of the additive kernel and the base kernels.
Arguments:
----------
X: array-like, shape = [n_samples, n_features]
An array of inputs.
theta: array-like, shape = [n_parameter, ]
The kernel parameters to use when computing the covariance.
If None, the current parameters of the kernel are used.
"""
if theta is None:
theta = self.theta
gradient = []
p_index = self.dim
K, K_orders = self.__cov__(X, theta=theta)
for i in range(self.order):
gradient.append(K_orders[i])
for i, ki in enumerate(self.base_kernels):
dK_dki = self.cov(np.delete(X, i, axis=1),
order=(self.order - 1),
base_kernels=np.delete(self.base_kernels, i))
dki_dtheta = ki.cov_gradient(X, theta[p_index: p_index + ki.num_parameters])
gradient.extend((dK_dki + 1) * dki_dtheta)
return np.array(gradient)
| [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
2,
2488,
13838,
25,
257,
8045,
4426,
680,
5116,
198,
2,
2488,
10430,
25,
220,
220,
2177,
12,
2998,
12,
2078,
2310,
25,
2998,
25,
2481,
198,
2,
2488,
5956,
40499,
416,
25,
220,
220,
257,
8045,
4426,
680,
5116,
198,
2,
2488,
5956,
40499,
640,
25,
2177,
12,
2919,
12,
2931,
1511,
25,
2931,
25,
2327,
198,
198,
11748,
299,
32152,
355,
45941,
198,
6738,
629,
541,
88,
13,
2777,
34961,
13,
30246,
1330,
269,
17080,
628,
198,
4871,
17986,
37,
33529,
198,
220,
220,
220,
37227,
17986,
37,
198,
220,
220,
220,
46333,
286,
262,
44503,
4308,
2163,
9720,
13,
4418,
1444,
262,
44345,
39682,
9720,
13,
198,
220,
220,
220,
20559,
2886,
25,
198,
220,
220,
220,
24200,
438,
198,
220,
220,
220,
220,
220,
220,
220,
5391,
25,
18253,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
15793,
1483,
286,
17311,
284,
262,
9720,
357,
72,
13,
68,
13,
15793,
286,
1395,
737,
198,
220,
220,
220,
220,
220,
220,
220,
4129,
62,
9888,
25,
1271,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
4129,
5046,
286,
262,
9720,
2163,
13,
198,
220,
220,
220,
220,
220,
220,
220,
1401,
25,
1271,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
24198,
14735,
286,
262,
9720,
2163,
13,
198,
220,
220,
220,
37227,
628,
220,
220,
220,
825,
651,
62,
17143,
7307,
7,
944,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
651,
62,
17143,
7307,
198,
220,
220,
220,
220,
220,
220,
220,
3497,
262,
9720,
338,
10007,
13,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
45941,
13,
18747,
26933,
944,
13,
13664,
62,
9888,
11,
2116,
13,
7785,
12962,
628,
220,
220,
220,
825,
900,
62,
17143,
7307,
7,
944,
11,
262,
8326,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
900,
62,
17143,
7307,
198,
220,
220,
220,
220,
220,
220,
220,
5345,
262,
9720,
338,
10007,
13,
198,
220,
220,
220,
220,
220,
220,
220,
20559,
2886,
25,
198,
220,
220,
220,
220,
220,
220,
220,
24200,
438,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
262,
8326,
25,
7177,
12,
2339,
11,
5485,
796,
685,
17,
11,
2361,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1052,
7177,
7268,
262,
649,
10007,
286,
262,
9720,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
11507,
1502,
318,
685,
13664,
62,
9888,
11,
24198,
60,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
198,
220,
220,
220,
220,
220,
220,
220,
2116,
13,
13664,
62,
9888,
796,
262,
8326,
58,
15,
60,
198,
220,
220,
220,
220,
220,
220,
220,
2116,
13,
7785,
796,
262,
8326,
58,
16,
60,
628,
220,
220,
220,
825,
39849,
7,
944,
11,
1395,
11,
575,
28,
14202,
11,
262,
8326,
28,
14202,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
39849,
198,
220,
220,
220,
220,
220,
220,
220,
3082,
1133,
262,
44829,
590,
17593,
286,
1395,
290,
575,
1262,
262,
17986,
37,
9720,
13,
198,
220,
220,
220,
220,
220,
220,
220,
20559,
2886,
25,
198,
220,
220,
220,
220,
220,
220,
220,
24200,
438,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1395,
25,
7177,
12,
2339,
11,
5485,
796,
685,
77,
62,
82,
12629,
11,
299,
62,
40890,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1052,
7177,
286,
17311,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
575,
357,
25968,
2599,
7177,
12,
2339,
11,
5485,
796,
685,
76,
62,
82,
12629,
11,
299,
62,
40890,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
317,
1218,
7177,
286,
17311,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1002,
575,
318,
6045,
11,
788,
262,
44829,
590,
17593,
286,
1395,
351,
2346,
481,
307,
29231,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
262,
8326,
357,
25968,
2599,
7177,
12,
2339,
11,
5485,
796,
685,
17,
11,
2361,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1052,
7177,
286,
11507,
3815,
329,
262,
9720,
13,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
628,
220,
220,
220,
220,
220,
220,
220,
1303,
3601,
7,
55,
11,
575,
8,
198,
220,
220,
220,
220,
220,
220,
220,
611,
575,
318,
6045,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
575,
796,
1395,
628,
220,
220,
220,
220,
220,
220,
220,
611,
262,
8326,
318,
6045,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
262,
8326,
796,
45941,
13,
18747,
26933,
944,
13,
13664,
62,
9888,
11,
2116,
13,
7785,
12962,
628,
220,
220,
220,
220,
220,
220,
220,
1303,
3082,
1133,
257,
17593,
286,
44345,
304,
84,
20095,
666,
18868,
1022,
1395,
290,
575,
198,
220,
220,
220,
220,
220,
220,
220,
1233,
796,
269,
17080,
7,
55,
11,
575,
11,
705,
31166,
12496,
565,
485,
272,
11537,
628,
220,
220,
220,
220,
220,
220,
220,
509,
796,
262,
8326,
58,
16,
60,
1635,
45941,
13,
11201,
7,
17080,
1220,
13841,
17,
1635,
357,
1169,
8326,
58,
15,
60,
12429,
362,
22305,
628,
220,
220,
220,
220,
220,
220,
220,
1303,
3601,
7,
42,
13,
43358,
8,
628,
220,
220,
220,
220,
220,
220,
220,
1441,
509,
628,
220,
220,
220,
825,
39849,
62,
49607,
7,
944,
11,
1395,
11,
262,
8326,
28,
14202,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
39849,
62,
49607,
198,
220,
220,
220,
220,
220,
220,
220,
3082,
1133,
262,
31312,
286,
262,
44829,
590,
17593,
286,
1395,
351,
2461,
284,
262,
10007,
198,
220,
220,
220,
220,
220,
220,
220,
286,
262,
17986,
37,
9720,
13,
198,
220,
220,
220,
220,
220,
220,
220,
20559,
2886,
25,
198,
220,
220,
220,
220,
220,
220,
220,
24200,
438,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1395,
25,
7177,
12,
2339,
11,
5485,
796,
685,
77,
62,
82,
12629,
11,
299,
62,
40890,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1052,
7177,
286,
17311,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
262,
8326,
357,
25968,
2599,
7177,
12,
2339,
11,
5485,
796,
685,
17,
11,
2361,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1052,
7177,
286,
11507,
3815,
329,
262,
9720,
13,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
628,
220,
220,
220,
220,
220,
220,
220,
611,
262,
8326,
318,
6045,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
262,
8326,
796,
45941,
13,
18747,
26933,
944,
13,
13664,
62,
9888,
11,
2116,
13,
7785,
12962,
628,
220,
220,
220,
220,
220,
220,
220,
1233,
796,
269,
17080,
7,
55,
11,
1395,
11,
705,
31166,
12496,
565,
485,
272,
11537,
628,
220,
220,
220,
220,
220,
220,
220,
509,
796,
45941,
13,
11201,
7,
17080,
1220,
13841,
17,
1635,
357,
1169,
8326,
58,
15,
60,
12429,
362,
22305,
628,
220,
220,
220,
220,
220,
220,
220,
288,
42,
62,
25404,
796,
262,
8326,
58,
16,
60,
1635,
357,
1169,
8326,
58,
15,
60,
12429,
532,
18,
8,
1635,
1233,
1635,
509,
628,
220,
220,
220,
220,
220,
220,
220,
288,
42,
62,
67,
7785,
796,
509,
628,
220,
220,
220,
220,
220,
220,
220,
1441,
45941,
13,
18747,
26933,
67,
42,
62,
25404,
11,
288,
42,
62,
67,
7785,
12962,
628,
198,
4871,
3060,
1800,
33529,
198,
220,
220,
220,
37227,
17986,
37,
198,
220,
220,
220,
46333,
286,
262,
38298,
9720,
355,
3417,
416,
10343,
574,
3885,
2123,
435,
11,
2813,
198,
220,
220,
220,
20559,
2886,
25,
198,
220,
220,
220,
24200,
438,
198,
220,
220,
220,
220,
220,
220,
220,
5391,
25,
18253,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
15793,
1483,
286,
17311,
284,
262,
9720,
357,
72,
13,
68,
13,
15793,
286,
1395,
737,
198,
220,
220,
220,
220,
220,
220,
220,
1502,
25,
1271,
11,
1502,
19841,
5391,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
1502,
286,
262,
38298,
9720,
13,
198,
220,
220,
220,
220,
220,
220,
220,
2779,
62,
74,
44930,
25,
7177,
12,
2339,
11,
5485,
796,
685,
27740,
11,
2361,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
900,
286,
2779,
9720,
5499,
11,
530,
329,
1123,
15793,
13,
198,
220,
220,
220,
220,
220,
220,
220,
1401,
25,
7177,
12,
2339,
11,
5485,
796,
685,
2875,
11,
2361,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1052,
7177,
286,
24198,
7842,
10455,
11,
530,
329,
1123,
1502,
288,
25,
352,
19841,
288,
19841,
360,
198,
220,
220,
220,
37227,
628,
220,
220,
220,
825,
651,
62,
17143,
7307,
7,
944,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
651,
62,
17143,
7307,
198,
220,
220,
220,
220,
220,
220,
220,
3497,
262,
9720,
338,
10007,
11,
543,
2291,
262,
10007,
286,
262,
2779,
50207,
13,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
198,
220,
220,
220,
220,
220,
220,
220,
262,
8326,
796,
45941,
13,
30073,
7,
944,
13,
7785,
8,
628,
220,
220,
220,
220,
220,
220,
220,
329,
9720,
287,
2116,
13,
8692,
62,
74,
44930,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
262,
8326,
796,
45941,
13,
33295,
7,
1169,
8326,
11,
9720,
13,
1136,
62,
17143,
7307,
28955,
628,
220,
220,
220,
220,
220,
220,
220,
1441,
262,
8326,
628,
220,
220,
220,
825,
900,
62,
17143,
7307,
7,
944,
11,
262,
8326,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
900,
62,
17143,
7307,
198,
220,
220,
220,
220,
220,
220,
220,
5345,
262,
9720,
338,
10007,
13,
770,
1276,
2291,
262,
10007,
286,
262,
2779,
50207,
13,
198,
220,
220,
220,
220,
220,
220,
220,
20559,
2886,
25,
198,
220,
220,
220,
220,
220,
220,
220,
24200,
438,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
262,
8326,
25,
7177,
12,
2339,
11,
5485,
796,
685,
77,
62,
17143,
2357,
11,
2361,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1052,
7177,
7268,
262,
649,
10007,
286,
262,
9720,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
717,
930,
944,
13,
2875,
91,
4847,
1276,
307,
262,
10375,
24198,
10007,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
5637,
4847,
1276,
307,
10007,
329,
262,
2779,
50207,
13,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
198,
220,
220,
220,
220,
220,
220,
220,
2116,
13,
7785,
796,
262,
8326,
58,
15,
25,
944,
13,
2875,
60,
198,
220,
220,
220,
220,
220,
220,
220,
5772,
62,
9630,
796,
2116,
13,
2875,
628,
220,
220,
220,
220,
220,
220,
220,
329,
9720,
287,
2116,
13,
8692,
62,
74,
44930,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
9720,
13,
2617,
62,
17143,
7307,
7,
1169,
8326,
58,
17143,
62,
9630,
25,
17143,
62,
9630,
1343,
9720,
13,
22510,
62,
17143,
7307,
12962,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
5772,
62,
9630,
15853,
9720,
13,
22510,
62,
17143,
7307,
628,
220,
220,
220,
825,
11593,
66,
709,
834,
7,
944,
11,
1395,
11,
575,
28,
14202,
11,
1502,
28,
14202,
11,
262,
8326,
28,
14202,
11,
2779,
62,
74,
44930,
28,
14202,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
11593,
66,
709,
834,
198,
220,
220,
220,
220,
220,
220,
220,
3082,
1133,
262,
44829,
590,
17593,
286,
17311,
1395,
290,
575,
13,
16409,
1111,
262,
44829,
590,
17593,
198,
220,
220,
220,
220,
220,
220,
220,
290,
257,
1351,
286,
44829,
590,
2603,
45977,
329,
1123,
1502,
286,
10375,
13,
198,
220,
220,
220,
220,
220,
220,
220,
770,
318,
281,
5387,
31904,
13,
1675,
7330,
262,
655,
44829,
590,
17593,
286,
1395,
357,
392,
575,
828,
869,
366,
66,
709,
1,
198,
220,
220,
220,
220,
220,
220,
220,
2427,
13,
198,
220,
220,
220,
220,
220,
220,
220,
20559,
2886,
25,
198,
220,
220,
220,
220,
220,
220,
220,
24200,
438,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1395,
25,
7177,
12,
2339,
11,
5485,
796,
685,
77,
62,
82,
12629,
11,
299,
62,
40890,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1052,
7177,
286,
17311,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
575,
357,
25968,
2599,
7177,
12,
2339,
11,
5485,
796,
685,
76,
62,
82,
12629,
11,
299,
62,
40890,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
317,
1218,
7177,
286,
17311,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
262,
8326,
25,
7177,
12,
2339,
11,
5485,
796,
685,
77,
62,
17143,
2357,
11,
2361,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
9720,
10007,
284,
779,
618,
14492,
262,
44829,
590,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1002,
6045,
11,
262,
1459,
10007,
286,
262,
9720,
389,
973,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1502,
25,
18253,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
10375,
1502,
326,
481,
307,
973,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1002,
6045,
11,
262,
1459,
9720,
4634,
481,
307,
973,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2779,
62,
74,
44930,
25,
7177,
12,
2339,
11,
5485,
796,
685,
77,
62,
40890,
11,
2361,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
1351,
286,
2779,
62,
74,
44930,
11,
530,
329,
1123,
3895,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
36819,
530,
2779,
62,
33885,
1276,
307,
2810,
583,
5128,
3895,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1002,
6045,
11,
262,
1459,
2779,
62,
74,
44930,
286,
262,
9720,
389,
973,
13,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
628,
220,
220,
220,
220,
220,
220,
220,
611,
575,
318,
6045,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
575,
796,
1395,
628,
220,
220,
220,
220,
220,
220,
220,
611,
262,
8326,
318,
6045,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
262,
8326,
796,
2116,
13,
1169,
8326,
628,
220,
220,
220,
220,
220,
220,
220,
611,
1502,
318,
6045,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1502,
796,
2116,
13,
2875,
628,
220,
220,
220,
220,
220,
220,
220,
611,
2779,
62,
74,
44930,
318,
6045,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2779,
62,
74,
44930,
796,
2116,
13,
8692,
62,
74,
44930,
628,
220,
220,
220,
220,
220,
220,
220,
1303,
1168,
318,
262,
7177,
286,
44829,
590,
2603,
45977,
4635,
416,
3586,
286,
262,
2779,
50207,
13,
198,
220,
220,
220,
220,
220,
220,
220,
1168,
796,
45941,
13,
1952,
19510,
11925,
7,
8692,
62,
74,
44930,
828,
1395,
13,
43358,
58,
15,
4357,
575,
13,
43358,
58,
15,
60,
4008,
198,
220,
220,
220,
220,
220,
220,
220,
1303,
311,
318,
262,
7177,
286,
286,
479,
61,
400,
1176,
21784,
286,
262,
2603,
45977,
287,
1168,
11,
479,
796,
352,
2644,
2116,
13,
2875,
198,
220,
220,
220,
220,
220,
220,
220,
311,
796,
45941,
13,
1952,
19510,
2875,
1343,
352,
11,
1395,
13,
43358,
58,
15,
4357,
575,
13,
43358,
58,
15,
60,
4008,
198,
220,
220,
220,
220,
220,
220,
220,
1303,
509,
318,
262,
7177,
286,
479,
61,
400,
1502,
38298,
50207,
11,
479,
796,
352,
2644,
1502,
198,
220,
220,
220,
220,
220,
220,
220,
509,
796,
45941,
13,
9107,
418,
19510,
2875,
1343,
352,
11,
1395,
13,
43358,
58,
15,
4357,
575,
13,
43358,
58,
15,
60,
4008,
198,
220,
220,
220,
220,
220,
220,
220,
509,
58,
15,
60,
796,
352,
628,
220,
220,
220,
220,
220,
220,
220,
279,
62,
9630,
796,
18896,
7,
8692,
62,
74,
44930,
8,
198,
220,
220,
220,
220,
220,
220,
220,
329,
1312,
11,
9720,
287,
27056,
378,
7,
8692,
62,
74,
44930,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
42287,
796,
262,
8326,
58,
79,
62,
9630,
25,
79,
62,
9630,
1343,
9720,
13,
22510,
62,
17143,
7307,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
279,
62,
9630,
15853,
9720,
13,
22510,
62,
17143,
7307,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1168,
58,
72,
60,
796,
9720,
13,
66,
709,
7,
55,
58,
45299,
1312,
4083,
3447,
1758,
7,
55,
13,
43358,
58,
15,
4357,
352,
828,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
575,
58,
45299,
1312,
4083,
3447,
1758,
7,
56,
13,
43358,
58,
15,
4357,
352,
828,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
262,
8326,
28,
37266,
8,
628,
220,
220,
220,
220,
220,
220,
220,
1168,
62,
67,
796,
45941,
13,
30073,
7,
57,
8,
198,
220,
220,
220,
220,
220,
220,
220,
329,
288,
287,
2837,
7,
16,
11,
1502,
1343,
352,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
311,
58,
67,
60,
796,
45941,
13,
16345,
7,
57,
62,
67,
11,
16488,
28,
15,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1168,
62,
67,
796,
1168,
62,
67,
1635,
1168,
62,
67,
628,
220,
220,
220,
220,
220,
220,
220,
329,
288,
287,
2837,
7,
16,
11,
1502,
1343,
352,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
329,
474,
287,
2837,
7,
16,
11,
288,
1343,
352,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
509,
58,
67,
60,
15853,
14808,
12,
16,
8,
12429,
357,
73,
532,
352,
4008,
1635,
509,
58,
67,
532,
474,
60,
1635,
311,
58,
73,
60,
628,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
509,
58,
67,
60,
796,
509,
58,
67,
60,
1220,
288,
628,
220,
220,
220,
220,
220,
220,
220,
329,
288,
287,
2837,
7,
16,
11,
1502,
1343,
352,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
509,
58,
67,
60,
796,
262,
8326,
58,
67,
532,
352,
60,
1635,
509,
58,
67,
60,
628,
220,
220,
220,
220,
220,
220,
220,
1441,
45941,
13,
16345,
7,
42,
58,
16,
25,
4357,
16488,
28,
15,
828,
509,
58,
16,
47715,
628,
220,
220,
220,
825,
39849,
7,
944,
11,
1395,
11,
575,
28,
14202,
11,
1502,
28,
14202,
11,
262,
8326,
28,
14202,
11,
2779,
62,
74,
44930,
28,
14202,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
39849,
198,
220,
220,
220,
220,
220,
220,
220,
3082,
1133,
262,
44829,
590,
17593,
286,
17311,
1395,
290,
575,
1262,
11593,
66,
709,
834,
13,
198,
220,
220,
220,
220,
220,
220,
220,
20559,
2886,
25,
198,
220,
220,
220,
220,
220,
220,
220,
24200,
438,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1395,
25,
7177,
12,
2339,
11,
5485,
796,
685,
77,
62,
82,
12629,
11,
299,
62,
40890,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1052,
7177,
286,
17311,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
575,
357,
25968,
2599,
7177,
12,
2339,
11,
5485,
796,
685,
76,
62,
82,
12629,
11,
299,
62,
40890,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
317,
1218,
7177,
286,
17311,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
262,
8326,
25,
7177,
12,
2339,
11,
5485,
796,
685,
77,
62,
17143,
2357,
11,
2361,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
9720,
10007,
284,
779,
618,
14492,
262,
44829,
590,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1002,
6045,
11,
262,
1459,
10007,
286,
262,
9720,
389,
973,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1502,
25,
18253,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
10375,
1502,
326,
481,
307,
973,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1002,
6045,
11,
262,
1459,
9720,
4634,
481,
307,
973,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2779,
62,
74,
44930,
25,
7177,
12,
2339,
11,
5485,
796,
685,
55,
13,
43358,
58,
15,
4357,
2361,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
2779,
62,
74,
44930,
284,
779,
329,
1123,
3895,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
36819,
530,
2779,
62,
33885,
1276,
307,
2810,
583,
5128,
3895,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1002,
6045,
11,
262,
1459,
2779,
62,
74,
44930,
286,
262,
9720,
389,
973,
13,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
198,
220,
220,
220,
220,
220,
220,
220,
509,
11,
509,
62,
6361,
796,
2116,
13,
834,
66,
709,
834,
7,
55,
11,
575,
11,
1502,
11,
262,
8326,
11,
2779,
62,
74,
44930,
8,
628,
220,
220,
220,
220,
220,
220,
220,
1441,
509,
628,
220,
220,
220,
825,
39849,
62,
49607,
7,
944,
11,
1395,
11,
262,
8326,
28,
14202,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
39849,
62,
49607,
198,
220,
220,
220,
220,
220,
220,
220,
3082,
1133,
262,
31312,
286,
262,
44829,
590,
17593,
286,
1395,
351,
2461,
284,
262,
10007,
198,
220,
220,
220,
220,
220,
220,
220,
286,
262,
38298,
9720,
290,
262,
2779,
50207,
13,
198,
220,
220,
220,
220,
220,
220,
220,
20559,
2886,
25,
198,
220,
220,
220,
220,
220,
220,
220,
24200,
438,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1395,
25,
7177,
12,
2339,
11,
5485,
796,
685,
77,
62,
82,
12629,
11,
299,
62,
40890,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1052,
7177,
286,
17311,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
262,
8326,
25,
7177,
12,
2339,
11,
5485,
796,
685,
77,
62,
17143,
2357,
11,
2361,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
383,
9720,
10007,
284,
779,
618,
14492,
262,
44829,
590,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1002,
6045,
11,
262,
1459,
10007,
286,
262,
9720,
389,
973,
13,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
198,
220,
220,
220,
220,
220,
220,
220,
611,
262,
8326,
318,
6045,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
262,
8326,
796,
2116,
13,
1169,
8326,
628,
220,
220,
220,
220,
220,
220,
220,
31312,
796,
17635,
198,
220,
220,
220,
220,
220,
220,
220,
279,
62,
9630,
796,
2116,
13,
27740,
628,
220,
220,
220,
220,
220,
220,
220,
509,
11,
509,
62,
6361,
796,
2116,
13,
834,
66,
709,
834,
7,
55,
11,
262,
8326,
28,
1169,
8326,
8,
628,
220,
220,
220,
220,
220,
220,
220,
329,
1312,
287,
2837,
7,
944,
13,
2875,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
31312,
13,
33295,
7,
42,
62,
6361,
58,
72,
12962,
628,
220,
220,
220,
220,
220,
220,
220,
329,
1312,
11,
47748,
287,
27056,
378,
7,
944,
13,
8692,
62,
74,
44930,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
288,
42,
62,
67,
4106,
796,
2116,
13,
66,
709,
7,
37659,
13,
33678,
7,
55,
11,
1312,
11,
16488,
28,
16,
828,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1502,
16193,
944,
13,
2875,
532,
352,
828,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2779,
62,
74,
44930,
28,
37659,
13,
33678,
7,
944,
13,
8692,
62,
74,
44930,
11,
1312,
4008,
628,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
288,
4106,
62,
67,
1169,
8326,
796,
47748,
13,
66,
709,
62,
49607,
7,
55,
11,
262,
8326,
58,
79,
62,
9630,
25,
279,
62,
9630,
1343,
47748,
13,
22510,
62,
17143,
7307,
12962,
628,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
31312,
13,
2302,
437,
19510,
67,
42,
62,
67,
4106,
1343,
352,
8,
1635,
288,
4106,
62,
67,
1169,
8326,
8,
628,
220,
220,
220,
220,
220,
220,
220,
1441,
45941,
13,
18747,
7,
49607,
8,
628,
628,
628,
628
] | 2.162785 | 4,466 |
from flask import Blueprint, jsonify, request
from playhouse.shortcuts import model_to_dict
from flask_login import current_user, login_required
import models
waitlists = Blueprint('waitlists', 'waitlists')
print()
# Index route
@waitlist.route('/', methods=["GET"])
# Create route
@waitlist.route('/', methods=["POST"])
@login_required
# Show route
@waitlist.route('/<id>', methods=["GET"])
# Update route
@waitlist.route('/<id>', methods=["PUT"])
# Delete route
@waitlist.route('/<id>', methods=["DELETE"])
| [
6738,
42903,
1330,
39932,
11,
33918,
1958,
11,
2581,
198,
6738,
711,
4803,
13,
19509,
23779,
1330,
2746,
62,
1462,
62,
11600,
198,
6738,
42903,
62,
38235,
1330,
1459,
62,
7220,
11,
17594,
62,
35827,
198,
198,
11748,
4981,
198,
198,
17077,
20713,
796,
39932,
10786,
17077,
20713,
3256,
705,
17077,
20713,
11537,
198,
4798,
3419,
198,
198,
2,
12901,
6339,
198,
31,
17077,
4868,
13,
38629,
10786,
14,
3256,
5050,
28,
14692,
18851,
8973,
8,
198,
198,
2,
13610,
6339,
198,
31,
17077,
4868,
13,
38629,
10786,
14,
3256,
5050,
28,
14692,
32782,
8973,
8,
198,
31,
38235,
62,
35827,
628,
198,
2,
5438,
6339,
198,
31,
17077,
4868,
13,
38629,
10786,
14,
27,
312,
29,
3256,
5050,
28,
14692,
18851,
8973,
8,
198,
198,
2,
10133,
6339,
198,
31,
17077,
4868,
13,
38629,
10786,
14,
27,
312,
29,
3256,
5050,
28,
14692,
30076,
8973,
8,
628,
198,
2,
23520,
6339,
198,
31,
17077,
4868,
13,
38629,
10786,
14,
27,
312,
29,
3256,
5050,
28,
14692,
7206,
2538,
9328,
8973,
8,
198
] | 2.99422 | 173 |
import itertools
print(pairs_difference(2,[1, 5, 3, 4, 2]))
| [
11748,
340,
861,
10141,
201,
198,
201,
198,
201,
198,
201,
198,
4798,
7,
79,
3468,
62,
26069,
1945,
7,
17,
17414,
16,
11,
642,
11,
513,
11,
604,
11,
362,
60,
4008,
201,
198
] | 1.942857 | 35 |
from PyQt5.QtWidgets import QLabel
from PyQt5.QtCore import Qt, pyqtSignal, QTimer
from PyQt5.QtGui import QPainter, QColor, QPen | [
6738,
9485,
48,
83,
20,
13,
48,
83,
54,
312,
11407,
1330,
1195,
33986,
198,
6738,
9485,
48,
83,
20,
13,
48,
83,
14055,
1330,
33734,
11,
12972,
39568,
11712,
282,
11,
1195,
48801,
198,
6738,
9485,
48,
83,
20,
13,
48,
83,
8205,
72,
1330,
1195,
38490,
353,
11,
1195,
10258,
11,
1195,
25553
] | 2.345455 | 55 |
keyboard.send_keys("<alt>+<page_up>") | [
2539,
3526,
13,
21280,
62,
13083,
7203,
27,
2501,
29,
10,
27,
7700,
62,
929,
29,
4943
] | 2.176471 | 17 |
import json
import logging
import logging.config
import os
import sqlite3
import yaml
import paho.mqtt.client as paho
DATABASE = os.environ.get("DB_NAME")
if __name__ == "__main__":
db = get_db()
with db:
try:
db.execute("CREATE TABLE devices_table (device_id TEXT NOT NULL, lights_on INTEGER NOT NULL)")
except:
pass
try:
db.execute("INSERT INTO devices_table VALUES ('123', 0)")
except:
pass
wait_for_messages()
| [
11748,
33918,
198,
11748,
18931,
198,
11748,
18931,
13,
11250,
198,
11748,
28686,
198,
11748,
44161,
578,
18,
198,
198,
11748,
331,
43695,
198,
11748,
279,
17108,
13,
76,
80,
926,
13,
16366,
355,
279,
17108,
628,
198,
35,
1404,
6242,
11159,
796,
28686,
13,
268,
2268,
13,
1136,
7203,
11012,
62,
20608,
4943,
628,
628,
628,
628,
628,
198,
361,
11593,
3672,
834,
6624,
366,
834,
12417,
834,
1298,
198,
220,
220,
220,
20613,
796,
651,
62,
9945,
3419,
628,
220,
220,
220,
351,
20613,
25,
198,
220,
220,
220,
220,
220,
220,
220,
1949,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
20613,
13,
41049,
7203,
43387,
6158,
43679,
4410,
62,
11487,
357,
25202,
62,
312,
40383,
5626,
15697,
11,
7588,
62,
261,
17828,
7156,
1137,
5626,
15697,
8,
4943,
198,
220,
220,
220,
220,
220,
220,
220,
2845,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1208,
628,
220,
220,
220,
220,
220,
220,
220,
1949,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
20613,
13,
41049,
7203,
20913,
17395,
39319,
4410,
62,
11487,
26173,
35409,
19203,
10163,
3256,
657,
8,
4943,
198,
220,
220,
220,
220,
220,
220,
220,
2845,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1208,
628,
220,
220,
220,
4043,
62,
1640,
62,
37348,
1095,
3419,
198
] | 2.221277 | 235 |
def reverse(s):
''' (str) -> str
Return a reversed version of s.
>>> reverse('hello')
'olleh'
>>> reverse('a')
'a'
'''
new = ''
for i in range(len(s)):
new += s[len(s) - 1 - i]
return new
def is_palindrome(s):
''' (str) -> bool
Return True iff s is a palindrome.
>>> is_palindrome('noon')
True
>>> is_palindrome('racecar')
True
>>> is_palindrome('dented')
False
'''
return reverse(s) == s
def is_palindrome2(s):
''' (str) -> bool
Return True iff s is a palindrome.
>>> is_palindrome2('noon')
True
>>> is_palindrome2('racecar')
True
>>> is_palindrome2('dented')
False
'''
half_s = ''
if (len(s) % 2) == 0:
half_s += s[len(s) // 2 :]
else:
half_s += s[(len(s) // 2) + 1:]
return reverse(half_s) == s[:len(s) // 2]
# compare the first half of s to the reverse of the second half
# omit the middle character of an odd-length string
#n = len(s)
#return s[:n // 2] == reverse(s[n - n // 2:]) | [
4299,
9575,
7,
82,
2599,
198,
220,
220,
220,
705,
7061,
357,
2536,
8,
4613,
965,
198,
220,
220,
220,
220,
198,
220,
220,
220,
8229,
257,
17687,
2196,
286,
264,
13,
198,
220,
220,
220,
220,
198,
220,
220,
220,
13163,
9575,
10786,
31373,
11537,
198,
220,
220,
220,
705,
349,
293,
71,
6,
198,
220,
220,
220,
13163,
9575,
10786,
64,
11537,
198,
220,
220,
220,
705,
64,
6,
198,
220,
220,
220,
705,
7061,
198,
220,
220,
220,
649,
796,
10148,
198,
220,
220,
220,
329,
1312,
287,
2837,
7,
11925,
7,
82,
8,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
649,
15853,
264,
58,
11925,
7,
82,
8,
532,
352,
532,
1312,
60,
198,
220,
220,
220,
1441,
649,
198,
220,
220,
220,
220,
198,
198,
4299,
318,
62,
18596,
521,
5998,
7,
82,
2599,
198,
220,
220,
220,
705,
7061,
357,
2536,
8,
4613,
20512,
198,
220,
220,
220,
220,
198,
220,
220,
220,
8229,
6407,
611,
69,
264,
318,
257,
6340,
521,
5998,
13,
198,
220,
220,
220,
220,
198,
220,
220,
220,
13163,
318,
62,
18596,
521,
5998,
10786,
6357,
11537,
198,
220,
220,
220,
6407,
198,
220,
220,
220,
13163,
318,
62,
18596,
521,
5998,
10786,
16740,
7718,
11537,
198,
220,
220,
220,
6407,
198,
220,
220,
220,
13163,
318,
62,
18596,
521,
5998,
10786,
67,
4714,
11537,
198,
220,
220,
220,
10352,
198,
220,
220,
220,
705,
7061,
198,
220,
220,
220,
220,
198,
220,
220,
220,
1441,
9575,
7,
82,
8,
6624,
264,
198,
220,
220,
220,
220,
198,
4299,
318,
62,
18596,
521,
5998,
17,
7,
82,
2599,
198,
220,
220,
220,
705,
7061,
357,
2536,
8,
4613,
20512,
198,
220,
220,
220,
220,
198,
220,
220,
220,
8229,
6407,
611,
69,
264,
318,
257,
6340,
521,
5998,
13,
198,
220,
220,
220,
220,
198,
220,
220,
220,
13163,
318,
62,
18596,
521,
5998,
17,
10786,
6357,
11537,
198,
220,
220,
220,
6407,
198,
220,
220,
220,
13163,
318,
62,
18596,
521,
5998,
17,
10786,
16740,
7718,
11537,
198,
220,
220,
220,
6407,
198,
220,
220,
220,
13163,
318,
62,
18596,
521,
5998,
17,
10786,
67,
4714,
11537,
198,
220,
220,
220,
10352,
198,
220,
220,
220,
705,
7061,
198,
220,
220,
220,
220,
198,
220,
220,
220,
2063,
62,
82,
796,
10148,
198,
220,
220,
220,
611,
357,
11925,
7,
82,
8,
4064,
362,
8,
6624,
657,
25,
198,
220,
220,
220,
220,
220,
220,
220,
2063,
62,
82,
15853,
264,
58,
11925,
7,
82,
8,
3373,
362,
1058,
60,
198,
220,
220,
220,
2073,
25,
198,
220,
220,
220,
220,
220,
220,
220,
2063,
62,
82,
15853,
264,
58,
7,
11925,
7,
82,
8,
3373,
362,
8,
1343,
352,
47715,
198,
220,
220,
220,
1441,
9575,
7,
13959,
62,
82,
8,
6624,
264,
58,
25,
11925,
7,
82,
8,
3373,
362,
60,
198,
220,
220,
220,
220,
198,
220,
220,
220,
1303,
8996,
262,
717,
2063,
286,
264,
284,
262,
9575,
286,
262,
1218,
2063,
198,
220,
220,
220,
1303,
42848,
262,
3504,
2095,
286,
281,
5629,
12,
13664,
4731,
198,
220,
220,
220,
1303,
77,
796,
18896,
7,
82,
8,
198,
220,
220,
220,
1303,
7783,
264,
58,
25,
77,
3373,
362,
60,
6624,
9575,
7,
82,
58,
77,
532,
299,
3373,
362,
25,
12962
] | 2.019964 | 551 |
# --------------------------------------------------------------------------
# Source file provided under Apache License, Version 2.0, January 2004,
# http://www.apache.org/licenses/
# (c) Copyright IBM Corp. 2015, 2016
# --------------------------------------------------------------------------
# gendoc: ignore
import math
from docplex.mp.compat23 import izip
from docplex.mp.constr import AbstractConstraint, LinearConstraint,\
LogicalConstraint, EquivalenceConstraint, IndicatorConstraint, QuadraticConstraint
from docplex.mp.error_handler import docplex_fatal
from docplex.mp.operand import LinearOperand
from docplex.mp.dvar import Var
from docplex.mp.pwl import PwlFunction
from docplex.mp.progress import ProgressListener
from docplex.mp.utils import is_int, is_number, is_iterable, is_string, generate_constant, \
is_ordered_sequence, is_iterator, resolve_caller_as_string
from docplex.mp.vartype import VarType
import six
_vartype_code_map = {sc().cplex_typecode: sc().short_name for sc in VarType.__subclasses__()}
# noinspection PyAbstractClass
# ------------------------------
# noinspection PyPep8
_tck_map = {'default': StandardTypeChecker,
'standard': StandardTypeChecker,
'std': StandardTypeChecker,
'on': StandardTypeChecker,
# --
'numeric': NumericTypeChecker,
'full': FullTypeChecker,
# --
'off': DummyTypeChecker,
'deploy': DummyTypeChecker,
'no_checks': DummyTypeChecker}
| [
2,
16529,
35937,
198,
2,
8090,
2393,
2810,
739,
24843,
13789,
11,
10628,
362,
13,
15,
11,
3269,
5472,
11,
198,
2,
2638,
1378,
2503,
13,
43073,
13,
2398,
14,
677,
4541,
14,
198,
2,
357,
66,
8,
15069,
19764,
11421,
13,
1853,
11,
1584,
198,
2,
16529,
35937,
198,
198,
2,
308,
437,
420,
25,
8856,
628,
198,
11748,
10688,
198,
198,
6738,
2205,
11141,
13,
3149,
13,
5589,
265,
1954,
1330,
220,
528,
541,
198,
6738,
2205,
11141,
13,
3149,
13,
1102,
2536,
1330,
27741,
3103,
2536,
2913,
11,
44800,
3103,
2536,
2913,
11,
59,
198,
220,
220,
220,
5972,
605,
3103,
2536,
2913,
11,
7889,
2473,
594,
3103,
2536,
2913,
11,
1423,
26407,
3103,
2536,
2913,
11,
20648,
81,
1512,
3103,
2536,
2913,
198,
6738,
2205,
11141,
13,
3149,
13,
18224,
62,
30281,
1330,
2205,
11141,
62,
69,
10254,
198,
6738,
2205,
11141,
13,
3149,
13,
3575,
392,
1330,
44800,
18843,
392,
198,
6738,
2205,
11141,
13,
3149,
13,
67,
7785,
1330,
12372,
198,
6738,
2205,
11141,
13,
3149,
13,
79,
40989,
1330,
350,
40989,
22203,
198,
6738,
2205,
11141,
13,
3149,
13,
33723,
1330,
18387,
33252,
198,
6738,
2205,
11141,
13,
3149,
13,
26791,
1330,
318,
62,
600,
11,
318,
62,
17618,
11,
318,
62,
2676,
540,
11,
318,
62,
8841,
11,
7716,
62,
9979,
415,
11,
3467,
198,
220,
220,
220,
318,
62,
24071,
62,
43167,
11,
318,
62,
48727,
11,
10568,
62,
13345,
263,
62,
292,
62,
8841,
198,
6738,
2205,
11141,
13,
3149,
13,
85,
433,
2981,
1330,
12372,
6030,
198,
11748,
2237,
198,
198,
62,
85,
433,
2981,
62,
8189,
62,
8899,
796,
1391,
1416,
22446,
66,
11141,
62,
4906,
8189,
25,
629,
22446,
19509,
62,
3672,
329,
629,
287,
12372,
6030,
13,
834,
7266,
37724,
834,
3419,
92,
628,
628,
198,
198,
2,
645,
1040,
14978,
9485,
23839,
9487,
628,
628,
628,
198,
2,
220,
34400,
26171,
198,
2,
645,
1040,
14978,
9485,
47,
538,
23,
198,
62,
83,
694,
62,
8899,
796,
1391,
6,
12286,
10354,
8997,
6030,
9787,
263,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
705,
20307,
10354,
8997,
6030,
9787,
263,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
705,
19282,
10354,
8997,
6030,
9787,
263,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
705,
261,
10354,
8997,
6030,
9787,
263,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1303,
1377,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
705,
77,
39223,
10354,
399,
39223,
6030,
9787,
263,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
705,
12853,
10354,
6462,
6030,
9787,
263,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1303,
1377,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
705,
2364,
10354,
360,
13513,
6030,
9787,
263,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
705,
2934,
1420,
10354,
360,
13513,
6030,
9787,
263,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
705,
3919,
62,
42116,
10354,
360,
13513,
6030,
9787,
263,
92,
628
] | 2.864312 | 538 |
"""
This module shows you how to perform various kinds of density calculations.
"""
# Does some sys.path manipulation so we can run examples in-place.
# noinspection PyUnresolvedReferences
import example_config
from colormath.color_objects import SpectralColor
from colormath.density_standards import ANSI_STATUS_T_RED, ISO_VISUAL
EXAMPLE_COLOR = SpectralColor(
observer=2, illuminant='d50',
spec_380nm=0.0600, spec_390nm=0.0600, spec_400nm=0.0641,
spec_410nm=0.0654, spec_420nm=0.0645, spec_430nm=0.0605,
spec_440nm=0.0562, spec_450nm=0.0543, spec_460nm=0.0537,
spec_470nm=0.0541, spec_480nm=0.0559, spec_490nm=0.0603,
spec_500nm=0.0651, spec_510nm=0.0680, spec_520nm=0.0705,
spec_530nm=0.0736, spec_540nm=0.0772, spec_550nm=0.0809,
spec_560nm=0.0870, spec_570nm=0.0990, spec_580nm=0.1128,
spec_590nm=0.1251, spec_600nm=0.1360, spec_610nm=0.1439,
spec_620nm=0.1511, spec_630nm=0.1590, spec_640nm=0.1688,
spec_650nm=0.1828, spec_660nm=0.1996, spec_670nm=0.2187,
spec_680nm=0.2397, spec_690nm=0.2618, spec_700nm=0.2852,
spec_710nm=0.2500, spec_720nm=0.2400, spec_730nm=0.2300)
# Feel free to comment/un-comment examples as you please.
example_auto_status_t_density()
example_manual_status_t_density()
example_visual_density()
| [
37811,
201,
198,
1212,
8265,
2523,
345,
703,
284,
1620,
2972,
6982,
286,
12109,
16765,
13,
201,
198,
37811,
201,
198,
201,
198,
2,
8314,
617,
25064,
13,
6978,
17512,
523,
356,
460,
1057,
6096,
287,
12,
5372,
13,
201,
198,
2,
645,
1040,
14978,
9485,
3118,
411,
5634,
19927,
201,
198,
11748,
1672,
62,
11250,
201,
198,
201,
198,
6738,
951,
579,
776,
13,
8043,
62,
48205,
1330,
13058,
1373,
10258,
201,
198,
6738,
951,
579,
776,
13,
43337,
62,
1481,
1371,
1330,
3537,
11584,
62,
35744,
2937,
62,
51,
62,
22083,
11,
19694,
62,
29817,
25620,
201,
198,
201,
198,
6369,
2390,
16437,
62,
46786,
796,
13058,
1373,
10258,
7,
201,
198,
220,
220,
220,
22890,
28,
17,
11,
2801,
7230,
415,
11639,
67,
1120,
3256,
201,
198,
220,
220,
220,
1020,
62,
23734,
21533,
28,
15,
13,
3312,
405,
11,
1020,
62,
25964,
21533,
28,
15,
13,
3312,
405,
11,
1020,
62,
7029,
21533,
28,
15,
13,
15,
42759,
11,
201,
198,
220,
220,
220,
1020,
62,
33289,
21533,
28,
15,
13,
15,
39111,
11,
1020,
62,
27211,
21533,
28,
15,
13,
3312,
2231,
11,
1020,
62,
31794,
21533,
28,
15,
13,
15,
32417,
11,
201,
198,
220,
220,
220,
1020,
62,
25644,
21533,
28,
15,
13,
2713,
5237,
11,
1020,
62,
17885,
21533,
28,
15,
13,
2713,
3559,
11,
1020,
62,
34716,
21533,
28,
15,
13,
2713,
2718,
11,
201,
198,
220,
220,
220,
1020,
62,
27790,
21533,
28,
15,
13,
2713,
3901,
11,
1020,
62,
22148,
21533,
28,
15,
13,
2713,
3270,
11,
1020,
62,
31503,
21533,
28,
15,
13,
15,
35642,
11,
201,
198,
220,
220,
220,
1020,
62,
4059,
21533,
28,
15,
13,
15,
40639,
11,
1020,
62,
33690,
21533,
28,
15,
13,
3312,
1795,
11,
1020,
62,
31211,
21533,
28,
15,
13,
15,
34801,
11,
201,
198,
220,
220,
220,
1020,
62,
38612,
21533,
28,
15,
13,
2998,
2623,
11,
1020,
62,
35005,
21533,
28,
15,
13,
2998,
4761,
11,
1020,
62,
22730,
21533,
28,
15,
13,
33057,
24,
11,
201,
198,
220,
220,
220,
1020,
62,
34135,
21533,
28,
15,
13,
2919,
2154,
11,
1020,
62,
39254,
21533,
28,
15,
13,
15,
34155,
11,
1020,
62,
39322,
21533,
28,
15,
13,
16,
12762,
11,
201,
198,
220,
220,
220,
1020,
62,
36993,
21533,
28,
15,
13,
1065,
4349,
11,
1020,
62,
8054,
21533,
28,
15,
13,
1485,
1899,
11,
1020,
62,
39132,
21533,
28,
15,
13,
1415,
2670,
11,
201,
198,
220,
220,
220,
1020,
62,
38850,
21533,
28,
15,
13,
1314,
1157,
11,
1020,
62,
30005,
21533,
28,
15,
13,
1314,
3829,
11,
1020,
62,
31102,
21533,
28,
15,
13,
1433,
3459,
11,
201,
198,
220,
220,
220,
1020,
62,
17544,
21533,
28,
15,
13,
1507,
2078,
11,
1020,
62,
39885,
21533,
28,
15,
13,
22288,
11,
1020,
62,
43798,
21533,
28,
15,
13,
17,
23451,
11,
201,
198,
220,
220,
220,
1020,
62,
37397,
21533,
28,
15,
13,
1954,
5607,
11,
1020,
62,
35844,
21533,
28,
15,
13,
2075,
1507,
11,
1020,
62,
9879,
21533,
28,
15,
13,
2078,
4309,
11,
201,
198,
220,
220,
220,
1020,
62,
43147,
21533,
28,
15,
13,
44688,
11,
1020,
62,
23906,
21533,
28,
15,
13,
1731,
405,
11,
1020,
62,
43916,
21533,
28,
15,
13,
1954,
405,
8,
201,
198,
201,
198,
201,
198,
201,
198,
220,
220,
220,
220,
201,
198,
2,
18571,
1479,
284,
2912,
14,
403,
12,
23893,
6096,
355,
345,
3387,
13,
201,
198,
20688,
62,
23736,
62,
13376,
62,
83,
62,
43337,
3419,
201,
198,
20688,
62,
805,
723,
62,
13376,
62,
83,
62,
43337,
3419,
201,
198,
20688,
62,
41464,
62,
43337,
3419,
201,
198
] | 2.16913 | 609 |
'''
Copyright (C) 2021 CG Cookie
https://github.com/CGCookie/retopoflow
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
'''
import inspect
from .debug import ExceptionHandler
from .debug import debugger
from .utils import find_fns
| [
7061,
6,
198,
15269,
357,
34,
8,
33448,
29925,
39606,
198,
5450,
1378,
12567,
13,
785,
14,
34,
15916,
18055,
14,
1186,
404,
1659,
9319,
198,
220,
220,
220,
770,
1430,
318,
1479,
3788,
25,
345,
460,
17678,
4163,
340,
290,
14,
273,
13096,
198,
220,
220,
220,
340,
739,
262,
2846,
286,
262,
22961,
3611,
5094,
13789,
355,
3199,
416,
198,
220,
220,
220,
262,
3232,
10442,
5693,
11,
2035,
2196,
513,
286,
262,
13789,
11,
393,
198,
220,
220,
220,
357,
265,
534,
3038,
8,
597,
1568,
2196,
13,
198,
220,
220,
220,
770,
1430,
318,
9387,
287,
262,
2911,
326,
340,
481,
307,
4465,
11,
198,
220,
220,
220,
475,
42881,
15529,
34764,
56,
26,
1231,
772,
262,
17142,
18215,
286,
198,
220,
220,
220,
34482,
3398,
1565,
5603,
25382,
393,
376,
46144,
7473,
317,
16652,
2149,
37232,
33079,
48933,
13,
220,
4091,
262,
198,
220,
220,
220,
22961,
3611,
5094,
13789,
329,
517,
3307,
13,
198,
220,
220,
220,
921,
815,
423,
2722,
257,
4866,
286,
262,
22961,
3611,
5094,
13789,
198,
220,
220,
220,
1863,
351,
428,
1430,
13,
220,
1002,
407,
11,
766,
1279,
4023,
1378,
2503,
13,
41791,
13,
2398,
14,
677,
4541,
15913,
13,
198,
7061,
6,
198,
198,
11748,
10104,
198,
198,
6738,
764,
24442,
1330,
35528,
25060,
198,
6738,
764,
24442,
1330,
49518,
198,
6738,
764,
26791,
1330,
1064,
62,
69,
5907,
628,
628
] | 3.581197 | 234 |
#
## PyMoira client library
##
## This file contains the Moira-related errors.
#
from . import constants
class BaseError(Exception):
"""Any exception thrown by the library is inhereted from this"""
pass
class ConnectionError(BaseError):
"""An error which prevents the client from having or continuing a meaningful
dialogue with a server (parsing failure, connection failure, etc)"""
pass
class MoiraError(BaseError):
"""An error returned from Moira server itself which has a Moira error code."""
class MoiraUnavailableError(BaseError):
"""An error raised in case when Moira MOTD is not empty."""
pass
class UserError(BaseError):
"""An error related to Moira but not returned from the server."""
pass
class AuthenticationError(BaseError):
"""An error related to the authentication process."""
pass
| [
2,
198,
2235,
9485,
16632,
8704,
5456,
5888,
198,
2235,
198,
2235,
770,
2393,
4909,
262,
4270,
8704,
12,
5363,
8563,
13,
198,
2,
198,
198,
6738,
764,
1330,
38491,
198,
198,
4871,
7308,
12331,
7,
16922,
2599,
198,
220,
220,
220,
37227,
7149,
6631,
8754,
416,
262,
5888,
318,
287,
258,
1186,
276,
422,
428,
37811,
628,
220,
220,
220,
1208,
198,
198,
4871,
26923,
12331,
7,
14881,
12331,
2599,
198,
220,
220,
220,
37227,
2025,
4049,
543,
15174,
262,
5456,
422,
1719,
393,
8282,
257,
11570,
198,
220,
220,
220,
10721,
351,
257,
4382,
357,
79,
945,
278,
5287,
11,
4637,
5287,
11,
3503,
8,
37811,
198,
220,
220,
220,
220,
198,
220,
220,
220,
1208,
198,
198,
4871,
4270,
8704,
12331,
7,
14881,
12331,
2599,
198,
220,
220,
220,
37227,
2025,
4049,
4504,
422,
4270,
8704,
4382,
2346,
543,
468,
257,
4270,
8704,
4049,
2438,
526,
15931,
198,
198,
4871,
4270,
8704,
3118,
15182,
12331,
7,
14881,
12331,
2599,
198,
220,
220,
220,
37227,
2025,
4049,
4376,
287,
1339,
618,
4270,
8704,
42982,
35,
318,
407,
6565,
526,
15931,
198,
220,
220,
220,
220,
198,
220,
220,
220,
1208,
198,
198,
4871,
11787,
12331,
7,
14881,
12331,
2599,
198,
220,
220,
220,
37227,
2025,
4049,
3519,
284,
4270,
8704,
475,
407,
4504,
422,
262,
4382,
526,
15931,
198,
220,
220,
220,
220,
198,
220,
220,
220,
1208,
198,
198,
4871,
48191,
12331,
7,
14881,
12331,
2599,
198,
220,
220,
220,
37227,
2025,
4049,
3519,
284,
262,
18239,
1429,
526,
15931,
628,
220,
220,
220,
1208,
198
] | 3.355212 | 259 |
#!/usr/bin/python
import pytest
import pandas as pd
import numpy as np
from yahoo_fantasy_bot import roster
RBLDR_COLS = ["player_id", "name", "eligible_positions", "selected_position"]
RSEL_COLS = ["player_id", "name", "HR", "OBP", "W", "ERA"]
@pytest.fixture
@pytest.fixture
@pytest.fixture
| [
2,
48443,
14629,
14,
8800,
14,
29412,
198,
198,
11748,
12972,
9288,
198,
11748,
19798,
292,
355,
279,
67,
198,
11748,
299,
32152,
355,
45941,
198,
6738,
331,
12992,
62,
69,
34921,
62,
13645,
1330,
9354,
198,
198,
49,
9148,
7707,
62,
25154,
50,
796,
14631,
7829,
62,
312,
1600,
366,
3672,
1600,
366,
31595,
62,
1930,
1756,
1600,
366,
34213,
62,
9150,
8973,
198,
6998,
3698,
62,
25154,
50,
796,
14631,
7829,
62,
312,
1600,
366,
3672,
1600,
366,
17184,
1600,
366,
9864,
47,
1600,
366,
54,
1600,
366,
46461,
8973,
628,
198,
31,
9078,
9288,
13,
69,
9602,
628,
198,
31,
9078,
9288,
13,
69,
9602,
628,
198,
31,
9078,
9288,
13,
69,
9602,
198
] | 2.57265 | 117 |
#!/usr/bin/env python3
# -*- coding:utf-8 -*-
# author: bigfoolliu
"""
使用邻接表表示图
A --> B
A --> C
B --> C
B --> D
C --> D
D --> C
E --> F
F --> C
"""
def find_one_path(graph, start, end, path=[]):
"""
寻找graph中由start到end顶点的其中一条路径
graph: dict
start: str
end: str
return: list
"""
path = path + [start]
if start == end:
return path
if start not in graph.keys():
return None
for node in graph[start]:
if node not in path: # 保证路径的顶点不重复
new_path = find_one_path(graph, node, end, path)
if new_path:
return new_path
return path
def find_all_paths(graph, start, end, path=[]):
"""
寻找graph中由start到end顶点的所有路径
graph: dict
start: str
end: str
return: [[], ...]
"""
path = path + [start]
if start == end:
return [path]
if start not in graph.keys():
return []
paths = []
for node in graph[start]:
if node not in path:
new_paths = find_all_paths(graph, node, end, path)
for new_path in new_paths:
paths.append(new_path)
return paths
def find_shortest_path(graph, start, end, path=[]):
"""
寻找graph中由start到end顶点的最短路径,思路是将如果每次找到了新路径将旧的存储的最短路径对比
graph: dict
start: str
end: str
return: list
"""
path = path + [start]
if start == end:
return path
if start not in graph.keys():
return None
shortest_path = None
for node in graph[start]:
if node not in path:
new_path = find_shortest_path(graph, node, end, path)
if new_path:
if not shortest_path or len(new_path) < len(shortest_path): # 当有多条最短路径的时候只会记录首条
shortest_path = new_path
return shortest_path
if __name__ == "__main__":
# 使邻接表定义一个有向图
graph = {
"A": ["B", "C"],
"B": ["C", "D"],
"C": ["D"],
"D": ["C"],
"E": ["F"],
"F": ["C"]
}
print(find_one_path(graph, "A", "D")) # 结果正确
print(find_one_path(graph, "B", "F")) # TODO: 结果应该报错或者怎样
print(find_all_paths(graph, "A", "D"))
print(find_shortest_path(graph, "A", "D"))
| [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
18,
198,
2,
532,
9,
12,
19617,
25,
40477,
12,
23,
532,
9,
12,
198,
2,
1772,
25,
1263,
6513,
692,
16115,
628,
198,
37811,
198,
45635,
18796,
101,
165,
224,
119,
162,
236,
98,
26193,
101,
26193,
101,
163,
97,
118,
32368,
122,
198,
32,
14610,
347,
198,
32,
14610,
327,
198,
33,
14610,
327,
198,
33,
14610,
360,
198,
34,
14610,
360,
198,
35,
14610,
327,
198,
36,
14610,
376,
198,
37,
14610,
327,
198,
37811,
628,
198,
4299,
1064,
62,
505,
62,
6978,
7,
34960,
11,
923,
11,
886,
11,
3108,
28,
21737,
2599,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
10263,
107,
119,
33699,
122,
34960,
40792,
18796,
109,
9688,
26344,
108,
437,
165,
94,
114,
163,
224,
117,
21410,
17739,
114,
40792,
31660,
30266,
94,
164,
115,
107,
36181,
226,
198,
220,
220,
220,
4823,
25,
8633,
198,
220,
220,
220,
923,
25,
965,
198,
220,
220,
220,
886,
25,
965,
198,
220,
220,
220,
1441,
25,
1351,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
3108,
796,
3108,
1343,
685,
9688,
60,
198,
220,
220,
220,
611,
923,
6624,
886,
25,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
3108,
198,
220,
220,
220,
611,
923,
407,
287,
4823,
13,
13083,
33529,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
6045,
198,
220,
220,
220,
329,
10139,
287,
4823,
58,
9688,
5974,
198,
220,
220,
220,
220,
220,
220,
220,
611,
10139,
407,
287,
3108,
25,
220,
1303,
220,
46479,
251,
46237,
223,
164,
115,
107,
36181,
226,
21410,
165,
94,
114,
163,
224,
117,
38834,
34932,
235,
13783,
235,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
649,
62,
6978,
796,
1064,
62,
505,
62,
6978,
7,
34960,
11,
10139,
11,
886,
11,
3108,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
611,
649,
62,
6978,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1441,
649,
62,
6978,
198,
220,
220,
220,
1441,
3108,
628,
198,
4299,
1064,
62,
439,
62,
6978,
82,
7,
34960,
11,
923,
11,
886,
11,
3108,
28,
21737,
2599,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
10263,
107,
119,
33699,
122,
34960,
40792,
18796,
109,
9688,
26344,
108,
437,
165,
94,
114,
163,
224,
117,
21410,
33699,
222,
17312,
231,
164,
115,
107,
36181,
226,
198,
220,
220,
220,
4823,
25,
8633,
198,
220,
220,
220,
923,
25,
965,
198,
220,
220,
220,
886,
25,
965,
198,
220,
220,
220,
1441,
25,
16410,
4357,
2644,
60,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
3108,
796,
3108,
1343,
685,
9688,
60,
198,
220,
220,
220,
611,
923,
6624,
886,
25,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
685,
6978,
60,
198,
220,
220,
220,
611,
923,
407,
287,
4823,
13,
13083,
33529,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
17635,
198,
220,
220,
220,
13532,
796,
17635,
198,
220,
220,
220,
329,
10139,
287,
4823,
58,
9688,
5974,
198,
220,
220,
220,
220,
220,
220,
220,
611,
10139,
407,
287,
3108,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
649,
62,
6978,
82,
796,
1064,
62,
439,
62,
6978,
82,
7,
34960,
11,
10139,
11,
886,
11,
3108,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
329,
649,
62,
6978,
287,
649,
62,
6978,
82,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
13532,
13,
33295,
7,
3605,
62,
6978,
8,
198,
220,
220,
220,
1441,
13532,
628,
198,
4299,
1064,
62,
19509,
395,
62,
6978,
7,
34960,
11,
923,
11,
886,
11,
3108,
28,
21737,
2599,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
10263,
107,
119,
33699,
122,
34960,
40792,
18796,
109,
9688,
26344,
108,
437,
165,
94,
114,
163,
224,
117,
21410,
17312,
222,
163,
253,
255,
164,
115,
107,
36181,
226,
171,
120,
234,
45250,
251,
164,
115,
107,
42468,
49546,
36685,
224,
162,
252,
250,
162,
107,
237,
162,
105,
94,
33699,
122,
26344,
108,
12859,
228,
23877,
108,
164,
115,
107,
36181,
226,
49546,
33768,
100,
21410,
27764,
246,
43636,
101,
21410,
17312,
222,
163,
253,
255,
164,
115,
107,
36181,
226,
43380,
117,
162,
107,
242,
198,
220,
220,
220,
4823,
25,
8633,
198,
220,
220,
220,
923,
25,
965,
198,
220,
220,
220,
886,
25,
965,
198,
220,
220,
220,
1441,
25,
1351,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
3108,
796,
3108,
1343,
685,
9688,
60,
198,
220,
220,
220,
611,
923,
6624,
886,
25,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
3108,
198,
220,
220,
220,
611,
923,
407,
287,
4823,
13,
13083,
33529,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
6045,
198,
220,
220,
220,
35581,
62,
6978,
796,
6045,
198,
220,
220,
220,
329,
10139,
287,
4823,
58,
9688,
5974,
198,
220,
220,
220,
220,
220,
220,
220,
611,
10139,
407,
287,
3108,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
649,
62,
6978,
796,
1064,
62,
19509,
395,
62,
6978,
7,
34960,
11,
10139,
11,
886,
11,
3108,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
611,
649,
62,
6978,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
611,
407,
35581,
62,
6978,
393,
18896,
7,
3605,
62,
6978,
8,
1279,
18896,
7,
19509,
395,
62,
6978,
2599,
220,
1303,
10263,
121,
241,
17312,
231,
13783,
248,
30266,
94,
17312,
222,
163,
253,
255,
164,
115,
107,
36181,
226,
21410,
33768,
114,
161,
222,
247,
20998,
103,
27670,
248,
164,
106,
108,
37605,
243,
165,
99,
244,
30266,
94,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
35581,
62,
6978,
796,
649,
62,
6978,
198,
220,
220,
220,
1441,
35581,
62,
6978,
628,
198,
361,
11593,
3672,
834,
6624,
366,
834,
12417,
834,
1298,
198,
220,
220,
220,
1303,
220,
45635,
165,
224,
119,
162,
236,
98,
26193,
101,
22522,
248,
20046,
231,
31660,
10310,
103,
17312,
231,
28938,
239,
32368,
122,
198,
220,
220,
220,
4823,
796,
1391,
198,
220,
220,
220,
220,
220,
220,
220,
366,
32,
1298,
14631,
33,
1600,
366,
34,
33116,
198,
220,
220,
220,
220,
220,
220,
220,
366,
33,
1298,
14631,
34,
1600,
366,
35,
33116,
198,
220,
220,
220,
220,
220,
220,
220,
366,
34,
1298,
14631,
35,
33116,
198,
220,
220,
220,
220,
220,
220,
220,
366,
35,
1298,
14631,
34,
33116,
198,
220,
220,
220,
220,
220,
220,
220,
366,
36,
1298,
14631,
37,
33116,
198,
220,
220,
220,
220,
220,
220,
220,
366,
37,
1298,
14631,
34,
8973,
198,
220,
220,
220,
1782,
628,
220,
220,
220,
3601,
7,
19796,
62,
505,
62,
6978,
7,
34960,
11,
366,
32,
1600,
366,
35,
48774,
220,
1303,
13328,
119,
241,
162,
252,
250,
29826,
96,
163,
94,
106,
198,
220,
220,
220,
3601,
7,
19796,
62,
505,
62,
6978,
7,
34960,
11,
366,
33,
1600,
366,
37,
48774,
220,
1303,
16926,
46,
25,
13328,
119,
241,
162,
252,
250,
41753,
242,
46237,
98,
162,
232,
98,
165,
242,
247,
22755,
244,
38519,
45250,
236,
43718,
115,
628,
220,
220,
220,
3601,
7,
19796,
62,
439,
62,
6978,
82,
7,
34960,
11,
366,
32,
1600,
366,
35,
48774,
198,
220,
220,
220,
3601,
7,
19796,
62,
19509,
395,
62,
6978,
7,
34960,
11,
366,
32,
1600,
366,
35,
48774,
198
] | 1.723005 | 1,278 |
###________________________ 2nd-Order-Free-Response ________________________###
import numpy as np
import matplotlib.pyplot as plt
import matplotlib
matplotlib.rcParams.update({'font.size': 22})
##__________ Functions for dumping characteristic cases __________##
##__________ 2nd order free response __________##
for xii in [1.5, 1.85, 2.5]:
# for xii in [0.00, 1.00, 2.50]:
for wnn in [1, 3, 5]:
for x00 in [-1, -0.5, 0]:
for x_dot00 in [1.5, 3.6, 4.5]:
plot_2order_free_resp(xii, wnn, x00, x_dot00)
| [
21017,
32941,
362,
358,
12,
18743,
12,
11146,
12,
31077,
220,
32941,
21017,
198,
198,
11748,
299,
32152,
355,
45941,
198,
11748,
2603,
29487,
8019,
13,
9078,
29487,
355,
458,
83,
198,
11748,
2603,
29487,
8019,
198,
198,
6759,
29487,
8019,
13,
6015,
10044,
4105,
13,
19119,
15090,
6,
10331,
13,
7857,
10354,
2534,
30072,
198,
198,
2235,
2602,
834,
40480,
329,
30231,
16704,
2663,
220,
2602,
834,
2235,
198,
198,
2235,
2602,
834,
362,
358,
1502,
1479,
2882,
220,
2602,
834,
2235,
198,
198,
1640,
2124,
4178,
287,
685,
16,
13,
20,
11,
352,
13,
5332,
11,
362,
13,
20,
5974,
198,
2,
329,
2124,
4178,
287,
685,
15,
13,
405,
11,
352,
13,
405,
11,
362,
13,
1120,
5974,
198,
220,
220,
220,
329,
266,
20471,
287,
685,
16,
11,
513,
11,
642,
5974,
198,
220,
220,
220,
220,
220,
220,
220,
329,
2124,
405,
287,
25915,
16,
11,
532,
15,
13,
20,
11,
657,
5974,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
329,
2124,
62,
26518,
405,
287,
685,
16,
13,
20,
11,
513,
13,
21,
11,
604,
13,
20,
5974,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
7110,
62,
17,
2875,
62,
5787,
62,
4363,
7,
87,
4178,
11,
266,
20471,
11,
2124,
405,
11,
2124,
62,
26518,
405,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
628
] | 2.296748 | 246 |
from typing import List, Dict
import numpy as np
from em.platform.rendering.dto.time_interval import TimeInterval
from em.platform.rendering.schema.events.event import Event
from em.platform.rendering.schema.processing_strategy import ProcessingStrategy
| [
6738,
19720,
1330,
7343,
11,
360,
713,
198,
198,
11748,
299,
32152,
355,
45941,
198,
198,
6738,
795,
13,
24254,
13,
13287,
278,
13,
67,
1462,
13,
2435,
62,
3849,
2100,
1330,
3862,
9492,
2100,
198,
6738,
795,
13,
24254,
13,
13287,
278,
13,
15952,
2611,
13,
31534,
13,
15596,
1330,
8558,
198,
6738,
795,
13,
24254,
13,
13287,
278,
13,
15952,
2611,
13,
36948,
62,
2536,
4338,
1330,
28403,
13290,
4338,
628
] | 3.520548 | 73 |
#!/usr/bin/env python2
# -*- coding: utf-8 -*-
from doubanfm.views.lrc_view import Lrc
from doubanfm.dal.dal_help import HelpDal
class Help(Lrc):
"""帮助界面"""
| [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
17,
198,
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
6738,
3385,
272,
38353,
13,
33571,
13,
75,
6015,
62,
1177,
1330,
406,
6015,
198,
6738,
3385,
272,
38353,
13,
31748,
13,
31748,
62,
16794,
1330,
10478,
35,
282,
628,
198,
4871,
10478,
7,
43,
6015,
2599,
198,
220,
220,
220,
37227,
30585,
106,
27950,
102,
45911,
234,
165,
251,
95,
37811,
198
] | 2.116883 | 77 |
maps = {
'batting': {
'a': 'assists',
'ab': 'atbats',
'ao': 'air_outs',
'avg': 'batting_avg',
'bb': 'base_on_balls',
'cs': 'caught_stealing',
'e': 'error',
'gidp': 'ground_into_dp',
'go': 'ground_out',
'h': 'hit',
'hbp': 'hit_by_pitch',
'hr': 'home_run',
'lob': 'left_on_base'
}
} | [
31803,
796,
1391,
198,
220,
220,
220,
705,
8664,
889,
10354,
1391,
198,
220,
220,
220,
220,
220,
220,
220,
705,
64,
10354,
705,
562,
1023,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
397,
10354,
705,
265,
50199,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
5488,
10354,
705,
958,
62,
5269,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
615,
70,
10354,
705,
8664,
889,
62,
615,
70,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
11848,
10354,
705,
8692,
62,
261,
62,
21591,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
6359,
10354,
705,
66,
3413,
62,
301,
26919,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
68,
10354,
705,
18224,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
70,
312,
79,
10354,
705,
2833,
62,
20424,
62,
26059,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
2188,
10354,
705,
2833,
62,
448,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
71,
10354,
705,
17945,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
71,
46583,
10354,
705,
17945,
62,
1525,
62,
79,
2007,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
11840,
10354,
705,
11195,
62,
5143,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
75,
672,
10354,
705,
9464,
62,
261,
62,
8692,
6,
198,
220,
220,
220,
1782,
198,
92
] | 1.640167 | 239 |
import networkx as nx
import numpy as np
import scipy.sparse as sp
from grapht.graphtools import *
G = nx.barabasi_albert_graph(100, 2)
G.add_edge(0, 1) # the initial condition of BA(n, 2) means it can have pendant edges, this stops that happening
G_with_pendant = G.copy()
G_with_pendant.add_node(100)
G_with_pendant.add_edge(0, 100)
G_with_isolate = G.copy()
G_with_isolate.add_node(100)
| [
11748,
3127,
87,
355,
299,
87,
198,
11748,
299,
32152,
355,
45941,
198,
11748,
629,
541,
88,
13,
82,
29572,
355,
599,
198,
6738,
4823,
83,
13,
34960,
31391,
1330,
1635,
198,
198,
38,
796,
299,
87,
13,
5657,
397,
17053,
62,
282,
4835,
62,
34960,
7,
3064,
11,
362,
8,
198,
38,
13,
2860,
62,
14907,
7,
15,
11,
352,
8,
1303,
262,
4238,
4006,
286,
23715,
7,
77,
11,
362,
8,
1724,
340,
460,
423,
279,
23048,
13015,
11,
428,
9911,
326,
5836,
198,
38,
62,
4480,
62,
79,
23048,
796,
402,
13,
30073,
3419,
198,
38,
62,
4480,
62,
79,
23048,
13,
2860,
62,
17440,
7,
3064,
8,
198,
38,
62,
4480,
62,
79,
23048,
13,
2860,
62,
14907,
7,
15,
11,
1802,
8,
198,
38,
62,
4480,
62,
271,
27976,
796,
402,
13,
30073,
3419,
198,
38,
62,
4480,
62,
271,
27976,
13,
2860,
62,
17440,
7,
3064,
8,
198
] | 2.538961 | 154 |
"""Recurrent layers and their base classes."""
from tensorflow.keras.layers import RNN
from tensorflow.keras.layers import StackedRNNCells
from tensorflow.keras.layers import SimpleRNN
from tensorflow.keras.layers import GRU
from tensorflow.keras.layers import LSTM
from tensorflow.keras.layers import SimpleRNNCell
from tensorflow.keras.layers import GRUCell
from tensorflow.keras.layers import LSTMCell
| [
37811,
6690,
6657,
11685,
290,
511,
2779,
6097,
526,
15931,
198,
198,
6738,
11192,
273,
11125,
13,
6122,
292,
13,
75,
6962,
1330,
371,
6144,
198,
6738,
11192,
273,
11125,
13,
6122,
292,
13,
75,
6962,
1330,
520,
6021,
49,
6144,
34,
19187,
198,
198,
6738,
11192,
273,
11125,
13,
6122,
292,
13,
75,
6962,
1330,
17427,
49,
6144,
198,
6738,
11192,
273,
11125,
13,
6122,
292,
13,
75,
6962,
1330,
10863,
52,
198,
6738,
11192,
273,
11125,
13,
6122,
292,
13,
75,
6962,
1330,
406,
2257,
44,
198,
198,
6738,
11192,
273,
11125,
13,
6122,
292,
13,
75,
6962,
1330,
17427,
49,
6144,
28780,
198,
6738,
11192,
273,
11125,
13,
6122,
292,
13,
75,
6962,
1330,
10863,
9598,
695,
198,
6738,
11192,
273,
11125,
13,
6122,
292,
13,
75,
6962,
1330,
406,
2257,
9655,
695,
198
] | 2.978102 | 137 |
# Python - 2.7.6 | [
2,
11361,
532,
362,
13,
22,
13,
21
] | 2 | 8 |
import sys
import pybel
filename = ""
verbose = False
if (len(sys.argv)) == 2:
filename = sys.argv[1]
else:
print "usage :", sys.argv[0] , " filename.xyz"
exit(1)
matrix = pybel.ob.matrix3x3()
matrix.RotAboutAxisByAngle(pybel.ob.vector3(1, 0, 0), 90)
if verbose:
for i in range(3):
for j in range(3):
line = "%10.5f "%(matrix.Get(i,j))
sys.stdout.write(line)
sys.stdout.write("\n")
imatrix = matrix.inverse()
if verbose:
print ""
for i in range(3):
for j in range(3):
line = "%10.5f "%(imatrix.Get(i,j))
sys.stdout.write(line)
sys.stdout.write("\n")
rotarray = pybel.ob.doubleArray(9)
matrix.GetArray(rotarray)
mol = pybel.readfile("xyz", filename).next()
mol.OBMol.Rotate(rotarray)
mol.OBMol.Translate(pybel.ob.vector3(1.0, 10.0, 3.0));
print mol.write("xyz")
| [
11748,
25064,
198,
11748,
12972,
6667,
198,
198,
34345,
796,
13538,
198,
19011,
577,
796,
10352,
198,
198,
361,
357,
11925,
7,
17597,
13,
853,
85,
4008,
6624,
362,
25,
220,
198,
220,
29472,
796,
25064,
13,
853,
85,
58,
16,
60,
198,
17772,
25,
198,
220,
3601,
366,
26060,
1058,
1600,
25064,
13,
853,
85,
58,
15,
60,
837,
366,
29472,
13,
5431,
89,
1,
198,
220,
8420,
7,
16,
8,
198,
198,
6759,
8609,
796,
12972,
6667,
13,
672,
13,
6759,
8609,
18,
87,
18,
3419,
198,
6759,
8609,
13,
24864,
8585,
31554,
271,
3886,
13450,
293,
7,
9078,
6667,
13,
672,
13,
31364,
18,
7,
16,
11,
657,
11,
657,
828,
4101,
8,
198,
198,
361,
15942,
577,
25,
198,
220,
329,
1312,
287,
2837,
7,
18,
2599,
198,
220,
220,
220,
220,
220,
329,
474,
287,
2837,
7,
18,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1627,
796,
36521,
940,
13,
20,
69,
36521,
7,
6759,
8609,
13,
3855,
7,
72,
11,
73,
4008,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
25064,
13,
19282,
448,
13,
13564,
7,
1370,
8,
198,
220,
220,
220,
220,
220,
25064,
13,
19282,
448,
13,
13564,
7203,
59,
77,
4943,
198,
198,
320,
265,
8609,
796,
17593,
13,
259,
4399,
3419,
198,
198,
361,
15942,
577,
25,
198,
220,
3601,
13538,
198,
220,
329,
1312,
287,
2837,
7,
18,
2599,
198,
220,
220,
220,
220,
220,
329,
474,
287,
2837,
7,
18,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1627,
796,
36521,
940,
13,
20,
69,
36521,
7,
320,
265,
8609,
13,
3855,
7,
72,
11,
73,
4008,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
25064,
13,
19282,
448,
13,
13564,
7,
1370,
8,
198,
220,
220,
220,
220,
220,
25064,
13,
19282,
448,
13,
13564,
7203,
59,
77,
4943,
198,
198,
10599,
18747,
796,
12972,
6667,
13,
672,
13,
23352,
19182,
7,
24,
8,
198,
6759,
8609,
13,
3855,
19182,
7,
10599,
18747,
8,
198,
198,
43132,
796,
12972,
6667,
13,
961,
7753,
7203,
5431,
89,
1600,
29472,
737,
19545,
3419,
198,
43132,
13,
9864,
44,
349,
13,
24864,
378,
7,
10599,
18747,
8,
198,
43132,
13,
9864,
44,
349,
13,
8291,
17660,
7,
9078,
6667,
13,
672,
13,
31364,
18,
7,
16,
13,
15,
11,
838,
13,
15,
11,
513,
13,
15,
18125,
198,
4798,
18605,
13,
13564,
7203,
5431,
89,
4943,
198
] | 2.06846 | 409 |
# -*- coding: utf-8 -*-
from os import setuid, chown
from pwd import getpwnam
from typing import Union
| [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
198,
6738,
28686,
1330,
900,
27112,
11,
442,
593,
198,
6738,
279,
16993,
1330,
651,
79,
675,
321,
198,
6738,
19720,
1330,
4479,
628,
628
] | 2.74359 | 39 |
#!/usr/bin/env python
""" Tests gristle_determinator.py
Contains a primary class: FileStructureFixtureManager
Which is extended by six classes that override various methods or variables.
This is a failed experiment - since the output isn't as informative as it
should be. This should be redesigned.
See the file "LICENSE" for the full license governing this code.
Copyright 2011,2012,2013,2017 Ken Farmer
"""
#adjust pylint for pytest oddities:
#pylint: disable=missing-docstring
#pylint: disable=unused-argument
#pylint: disable=attribute-defined-outside-init
#pylint: disable=protected-access
#pylint: disable=no-self-use
#pylint: disable=empty-docstring
import tempfile
import csv
import errno
import shutil
import os
from os.path import join as pjoin, dirname
from pprint import pprint as pp
import pytest
import envoy
import datagristle.test_tools as test_tools
import datagristle.file_type as file_type
script_path = dirname(dirname(os.path.realpath((__file__))))
def get_value(parsable_out, division, section, subsection, key):
""" Gets the value (right-most field) out of gristle_determinator
parsable output given the key values for the rest of the fields.
"""
mydialect = csv.Dialect
mydialect.delimiter = '|'
mydialect.quoting = file_type.get_quote_number('QUOTE_ALL')
mydialect.quotechar = '"'
mydialect.lineterminator = '\n'
csvobj = csv.reader(parsable_out.split('\n'), dialect=mydialect)
for record in csvobj:
if not record:
continue
assert len(record) == 5
rec_division = record[0]
rec_section = record[1]
rec_subsection = record[2]
rec_key = record[3]
rec_value = record[4]
if (rec_division == division
and rec_section == section
and rec_subsection == subsection
and rec_key == key):
return rec_value
return None
| [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
198,
37811,
30307,
1036,
12535,
62,
67,
13221,
1352,
13,
9078,
628,
220,
220,
220,
49850,
257,
4165,
1398,
25,
9220,
1273,
5620,
37,
9602,
13511,
198,
220,
220,
220,
9022,
318,
7083,
416,
2237,
6097,
326,
20957,
2972,
5050,
393,
9633,
13,
198,
220,
220,
220,
770,
318,
257,
4054,
6306,
532,
1201,
262,
5072,
2125,
470,
355,
30304,
355,
340,
198,
220,
220,
220,
815,
307,
13,
220,
770,
815,
307,
36240,
13,
628,
220,
220,
220,
4091,
262,
2393,
366,
43,
2149,
24290,
1,
329,
262,
1336,
5964,
15030,
428,
2438,
13,
198,
220,
220,
220,
15069,
2813,
11,
6999,
11,
6390,
11,
5539,
7148,
37755,
198,
37811,
198,
2,
23032,
279,
2645,
600,
329,
12972,
9288,
5629,
871,
25,
198,
2,
79,
2645,
600,
25,
15560,
28,
45688,
12,
15390,
8841,
198,
2,
79,
2645,
600,
25,
15560,
28,
403,
1484,
12,
49140,
198,
2,
79,
2645,
600,
25,
15560,
28,
42348,
12,
23211,
12,
43435,
12,
15003,
198,
2,
79,
2645,
600,
25,
15560,
28,
24326,
12,
15526,
198,
2,
79,
2645,
600,
25,
15560,
28,
3919,
12,
944,
12,
1904,
198,
2,
79,
2645,
600,
25,
15560,
28,
28920,
12,
15390,
8841,
198,
198,
11748,
20218,
7753,
198,
11748,
269,
21370,
198,
11748,
11454,
3919,
198,
11748,
4423,
346,
198,
11748,
28686,
198,
6738,
28686,
13,
6978,
1330,
4654,
355,
279,
22179,
11,
26672,
3672,
198,
6738,
279,
4798,
1330,
279,
4798,
355,
9788,
198,
198,
11748,
12972,
9288,
198,
11748,
39137,
198,
198,
11748,
4818,
363,
1585,
293,
13,
9288,
62,
31391,
355,
1332,
62,
31391,
198,
11748,
4818,
363,
1585,
293,
13,
7753,
62,
4906,
355,
2393,
62,
4906,
198,
198,
12048,
62,
6978,
796,
26672,
3672,
7,
15908,
3672,
7,
418,
13,
6978,
13,
5305,
6978,
19510,
834,
7753,
834,
35514,
628,
628,
198,
4299,
651,
62,
8367,
7,
79,
945,
540,
62,
448,
11,
7297,
11,
2665,
11,
8371,
11,
1994,
2599,
198,
220,
220,
220,
37227,
29620,
262,
1988,
357,
3506,
12,
1712,
2214,
8,
503,
286,
1036,
12535,
62,
67,
13221,
1352,
198,
220,
220,
220,
220,
220,
220,
220,
13544,
540,
5072,
1813,
262,
1994,
3815,
329,
262,
1334,
286,
262,
7032,
13,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
616,
38969,
478,
796,
269,
21370,
13,
24400,
478,
198,
220,
220,
220,
616,
38969,
478,
13,
12381,
320,
2676,
796,
705,
91,
6,
198,
220,
220,
220,
616,
38969,
478,
13,
421,
10720,
796,
2393,
62,
4906,
13,
1136,
62,
22708,
62,
17618,
10786,
10917,
23051,
62,
7036,
11537,
198,
220,
220,
220,
616,
38969,
478,
13,
22708,
10641,
796,
705,
30543,
198,
220,
220,
220,
616,
38969,
478,
13,
2815,
13221,
1352,
796,
705,
59,
77,
6,
628,
220,
220,
220,
269,
21370,
26801,
796,
269,
21370,
13,
46862,
7,
79,
945,
540,
62,
448,
13,
35312,
10786,
59,
77,
33809,
23637,
28,
1820,
38969,
478,
8,
628,
220,
220,
220,
329,
1700,
287,
269,
21370,
26801,
25,
198,
220,
220,
220,
220,
220,
220,
220,
611,
407,
1700,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2555,
198,
220,
220,
220,
220,
220,
220,
220,
6818,
18896,
7,
22105,
8,
6624,
642,
198,
220,
220,
220,
220,
220,
220,
220,
664,
62,
21426,
796,
1700,
58,
15,
60,
198,
220,
220,
220,
220,
220,
220,
220,
664,
62,
5458,
796,
1700,
58,
16,
60,
198,
220,
220,
220,
220,
220,
220,
220,
664,
62,
7266,
5458,
796,
1700,
58,
17,
60,
198,
220,
220,
220,
220,
220,
220,
220,
664,
62,
2539,
796,
1700,
58,
18,
60,
198,
220,
220,
220,
220,
220,
220,
220,
664,
62,
8367,
796,
1700,
58,
19,
60,
628,
220,
220,
220,
220,
220,
220,
220,
611,
357,
8344,
62,
21426,
6624,
7297,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
290,
664,
62,
5458,
6624,
2665,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
290,
664,
62,
7266,
5458,
6624,
8371,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
290,
664,
62,
2539,
6624,
1994,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1441,
664,
62,
8367,
628,
220,
220,
220,
1441,
6045,
628,
628,
628,
628,
628,
198
] | 2.670748 | 735 |
from manimlib.imports import *
import numpy as np
#ahora vamos a explicar el caso de esferas duras, qeu por encima de 50% de ocupacion muestan cristalización
#despues vamos a introducir el tema de espacio disponible
#puedes decir, bueno pero esque si hay muchas esferas o su radio es muy grande, pues no les queda otra que ordenarse para caber, claro.
#Bueno pues esque es eso lo qeu pasa cuando la temperatura es baja que se debe buscar la ordenacion para no solaparse, sino el estado no existiria, o
#o quiza empezarian a solapar y habría una presion extraña de algun lado, pero gracias a que se ordenan el sistema puede existir en equilibrio!!!
#ultima escena ya, ostia
#aqui vamos a poner la equivalencia entre mas espacio disponible y mayor numero de estados
#mencionar que el caso de esferas duras es cierto en algunos coloides, pero para otros muchos casos,
#lo ultimo sera el tema de la segregacion entrópica | [
6738,
582,
320,
8019,
13,
320,
3742,
1330,
1635,
198,
11748,
299,
32152,
355,
45941,
220,
198,
220,
220,
220,
1303,
993,
5799,
410,
321,
418,
257,
1193,
291,
283,
1288,
6124,
78,
390,
1658,
2232,
292,
288,
17786,
11,
10662,
12496,
16964,
2207,
8083,
390,
2026,
4,
390,
267,
25244,
49443,
38779,
395,
272,
1067,
396,
282,
528,
32009,
18840,
198,
220,
220,
220,
1303,
8906,
79,
947,
410,
321,
418,
257,
3120,
66,
343,
1288,
2169,
64,
390,
15024,
48711,
4596,
261,
856,
628,
198,
198,
2,
79,
1739,
274,
875,
343,
11,
809,
23397,
583,
78,
1658,
4188,
33721,
27678,
881,
292,
1658,
2232,
292,
267,
424,
5243,
1658,
285,
4669,
4490,
68,
11,
279,
947,
645,
10287,
627,
18082,
267,
9535,
8358,
2760,
268,
17208,
31215,
16212,
263,
11,
10212,
78,
13,
198,
2,
38374,
23397,
279,
947,
1658,
4188,
1658,
1658,
78,
2376,
10662,
12496,
279,
15462,
18912,
25440,
8591,
4124,
2541,
64,
1658,
275,
27792,
8358,
384,
390,
1350,
1323,
7718,
8591,
2760,
268,
49443,
31215,
645,
1540,
499,
17208,
11,
264,
2879,
1288,
1556,
4533,
645,
2152,
343,
544,
11,
267,
220,
198,
2,
78,
627,
23638,
795,
46057,
3699,
257,
1540,
499,
283,
331,
387,
1671,
29690,
555,
64,
906,
295,
3131,
30644,
390,
435,
7145,
300,
4533,
11,
583,
78,
1036,
330,
4448,
257,
8358,
384,
2760,
268,
272,
1288,
264,
396,
19687,
279,
1739,
68,
2152,
343,
551,
1602,
22282,
27250,
10185,
628,
628,
198,
198,
2,
586,
8083,
3671,
8107,
21349,
11,
23619,
544,
198,
220,
220,
220,
1303,
36129,
72,
410,
321,
418,
257,
279,
14491,
8591,
6854,
29634,
920,
260,
12422,
15024,
48711,
4596,
261,
856,
331,
9591,
997,
3529,
390,
1556,
22484,
628,
220,
220,
220,
220,
628,
220,
220,
220,
1303,
3653,
66,
295,
283,
8358,
1288,
6124,
78,
390,
1658,
2232,
292,
288,
17786,
1658,
269,
72,
13806,
551,
435,
7145,
418,
951,
78,
1460,
11,
583,
78,
31215,
30972,
4951,
881,
418,
6124,
418,
11,
220,
198,
198,
2,
5439,
3789,
25147,
1055,
64,
1288,
2169,
64,
390,
8591,
32301,
49443,
24481,
10205,
79,
3970
] | 2.701705 | 352 |
# Copyright 2020 Johns Hopkins University (Shinji Watanabe)
# Northwestern Polytechnical University (Pengcheng Guo)
# Apache 2.0 (http://www.apache.org/licenses/LICENSE-2.0)
# Adapted by Florian Lux 2021
import torch
class Swish(torch.nn.Module):
"""
Construct an Swish activation function for Conformer.
"""
def forward(self, x):
"""
Return Swish activation function.
"""
return x * torch.sigmoid(x)
| [
2,
15069,
12131,
25824,
21183,
2059,
357,
44592,
7285,
12242,
272,
11231,
8,
198,
2,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
30197,
12280,
47944,
2059,
357,
47,
1516,
2395,
782,
1962,
78,
8,
198,
2,
220,
24843,
362,
13,
15,
220,
357,
4023,
1378,
2503,
13,
43073,
13,
2398,
14,
677,
4541,
14,
43,
2149,
24290,
12,
17,
13,
15,
8,
198,
2,
30019,
276,
416,
4432,
666,
17145,
33448,
198,
198,
11748,
28034,
628,
198,
4871,
2451,
680,
7,
13165,
354,
13,
20471,
13,
26796,
2599,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
28407,
281,
2451,
680,
14916,
2163,
329,
1482,
16354,
13,
198,
220,
220,
220,
37227,
628,
220,
220,
220,
825,
2651,
7,
944,
11,
2124,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
198,
220,
220,
220,
220,
220,
220,
220,
8229,
2451,
680,
14916,
2163,
13,
198,
220,
220,
220,
220,
220,
220,
220,
37227,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
2124,
1635,
28034,
13,
82,
17225,
1868,
7,
87,
8,
198
] | 2.568306 | 183 |
import os, sys
lib_path = os.path.abspath(os.path.join('..', 'utils'))
sys.path.append(lib_path)
import ftplib as FTP
import credentials as cred
import RPIO
import RPi.GPIO as GPIO
from pump import Pump
# use BCM mode to play well with RPIO
GPIO.setmode(GPIO.BCM)
# start dispatch loop in background
RPIO.wait_for_interrupts(threaded=True)
p0 = Pump(23, 24)
| [
171,
119,
123,
11748,
28686,
11,
25064,
198,
8019,
62,
6978,
796,
28686,
13,
6978,
13,
397,
2777,
776,
7,
418,
13,
6978,
13,
22179,
10786,
492,
3256,
705,
26791,
6,
4008,
198,
17597,
13,
6978,
13,
33295,
7,
8019,
62,
6978,
8,
198,
198,
11748,
10117,
489,
571,
355,
45854,
198,
11748,
18031,
355,
2600,
198,
11748,
25812,
9399,
198,
11748,
25812,
72,
13,
16960,
9399,
355,
50143,
198,
6738,
8901,
1330,
23220,
198,
198,
2,
779,
11843,
44,
4235,
284,
711,
880,
351,
25812,
9399,
198,
16960,
9399,
13,
2617,
14171,
7,
16960,
9399,
13,
2749,
44,
8,
198,
198,
2,
923,
27965,
9052,
287,
4469,
198,
20031,
9399,
13,
17077,
62,
1640,
62,
3849,
3622,
82,
7,
16663,
276,
28,
17821,
8,
198,
198,
79,
15,
796,
23220,
7,
1954,
11,
1987,
8,
628,
198
] | 2.644928 | 138 |
"""Multiple calls in one logical line."""
import cyberbrain
cyberbrain.init()
x = {f(x=1), f(y=2)}
cyberbrain.register(x)
| [
37811,
31217,
3848,
287,
530,
12219,
1627,
526,
15931,
198,
198,
11748,
10075,
27825,
198,
198,
948,
527,
27825,
13,
15003,
3419,
628,
198,
198,
87,
796,
1391,
69,
7,
87,
28,
16,
828,
277,
7,
88,
28,
17,
38165,
628,
198,
948,
527,
27825,
13,
30238,
7,
87,
8,
198
] | 2.529412 | 51 |
import math
class Shape:
"""Container to store 3D Image/array/feature/tensor sizes.
This is a convenience class because size specifications are often required
yet their format is ambigous. Sometimes, images are specified as CHW
(Tensorflow), sometimes as HWC (NumPy, Matplotlib). Sometimes, only the
width and height are needed which Tensorflow needs as (height, width) yet
eg. PIL returns as (width, height).
This container class accepts the three size parameters and can return them
in all possible formats.
Inputs:
chan: int
Number of channels. Must be non-negative or None.
height: int
Must be non-negative (can *not* be None).
width: int
Must be non-negative (can *not* be None).
"""
| [
11748,
10688,
198,
198,
4871,
25959,
25,
198,
220,
220,
220,
37227,
29869,
284,
3650,
513,
35,
7412,
14,
18747,
14,
30053,
14,
83,
22854,
10620,
13,
628,
220,
220,
220,
770,
318,
257,
15607,
1398,
780,
2546,
20640,
389,
1690,
2672,
198,
220,
220,
220,
1865,
511,
5794,
318,
18203,
516,
13,
8975,
11,
4263,
389,
7368,
355,
5870,
54,
198,
220,
220,
220,
357,
51,
22854,
11125,
828,
3360,
355,
367,
27353,
357,
33111,
20519,
11,
6550,
29487,
8019,
737,
8975,
11,
691,
262,
198,
220,
220,
220,
9647,
290,
6001,
389,
2622,
543,
309,
22854,
11125,
2476,
355,
357,
17015,
11,
9647,
8,
1865,
198,
220,
220,
220,
29206,
13,
350,
4146,
5860,
355,
357,
10394,
11,
6001,
737,
628,
220,
220,
220,
770,
9290,
1398,
18178,
262,
1115,
2546,
10007,
290,
460,
1441,
606,
198,
220,
220,
220,
287,
477,
1744,
17519,
13,
628,
220,
220,
220,
23412,
82,
25,
198,
220,
220,
220,
220,
220,
220,
220,
442,
272,
25,
493,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
7913,
286,
9619,
13,
12039,
307,
1729,
12,
31591,
393,
6045,
13,
198,
220,
220,
220,
220,
220,
220,
220,
6001,
25,
493,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
12039,
307,
1729,
12,
31591,
357,
5171,
1635,
1662,
9,
307,
6045,
737,
198,
220,
220,
220,
220,
220,
220,
220,
9647,
25,
493,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
12039,
307,
1729,
12,
31591,
357,
5171,
1635,
1662,
9,
307,
6045,
737,
198,
220,
220,
220,
37227,
198
] | 2.958955 | 268 |
import os
import sys
folder = sys.argv[1]
script = sys.argv[2]
for root, dirs, files in os.walk(folder):
for filename in files:
data_file = "{}/{}".format(root,filename)
os.system("python3 {} {}".format(script,data_file))
| [
11748,
28686,
198,
11748,
25064,
198,
198,
43551,
796,
25064,
13,
853,
85,
58,
16,
60,
198,
12048,
796,
25064,
13,
853,
85,
58,
17,
60,
198,
198,
1640,
6808,
11,
288,
17062,
11,
3696,
287,
28686,
13,
11152,
7,
43551,
2599,
198,
220,
220,
220,
329,
29472,
287,
3696,
25,
198,
220,
220,
220,
220,
220,
220,
220,
1366,
62,
7753,
796,
45144,
92,
14,
90,
92,
1911,
18982,
7,
15763,
11,
34345,
8,
198,
220,
220,
220,
220,
220,
220,
220,
28686,
13,
10057,
7203,
29412,
18,
23884,
23884,
1911,
18982,
7,
12048,
11,
7890,
62,
7753,
4008,
198
] | 2.415842 | 101 |
import numpy as np
import tensorflow as tf
import itertools
import os # used for directory operations
import io
from PIL import Image # used to read images from directory
import random
tf.enable_eager_execution()
# Global constants
# Information from input tfrecord files
SOURCE_ID = 'image/source_id'
BBOX_CONFIDENCE = 'image/object/bbox/confidence'
BBOX_XMIN = 'image/object/bbox/xmin'
BBOX_YMIN = 'image/object/bbox/ymin'
BBOX_XMAX = 'image/object/bbox/xmax'
BBOX_YMAX = 'image/object/bbox/ymax'
# confidence threshold for determine as neg/pos examples
CONF_THRESHOLD = {'neg': 0.1, 'pos': 0.9}
OUTPUT_IMAGE_SIZE = (64, 64)
# Reads tfrecords and parse the labels and data needed for the new dataset.
# Parse and cleanup the labels to a more straigtforward format.
# Transform raw image data and label into a tfexample format.
# Write all images into the test TFrecord file.
# Striped out only the maximum confidence bbox of a image. Function is called in generate_tfexamples_from_detections().
# Striped out ALL bbox where confidence is over threshold. Function is called in generate_tfexamples_from_detections().
# Read image from path and check exclude non RGB image.
# Strip the bboxes from the parsed_image_dataset that are over threshold and added the tfexample to the return list.
# Write positive and negative tfexamples to tfrecord using the writer. A balance boolean parameter can decide to balance the pos and neg examples count.
# Write tfrecords in batches of input record files.
# Filter the dataset with images bbox lower than the threshold, and copy the image bbox to output directory. These images will be handpicked to be used as negative examples in the test set.
| [
11748,
299,
32152,
355,
45941,
198,
11748,
11192,
273,
11125,
355,
48700,
198,
11748,
340,
861,
10141,
198,
11748,
28686,
220,
1303,
973,
329,
8619,
4560,
198,
11748,
33245,
198,
6738,
350,
4146,
1330,
7412,
220,
1303,
973,
284,
1100,
4263,
422,
8619,
198,
11748,
4738,
198,
198,
27110,
13,
21633,
62,
68,
3536,
62,
18558,
1009,
3419,
198,
198,
2,
8060,
38491,
198,
2,
6188,
422,
5128,
48700,
22105,
3696,
198,
47690,
62,
2389,
796,
705,
9060,
14,
10459,
62,
312,
6,
198,
33,
39758,
62,
10943,
37,
2389,
18310,
796,
705,
9060,
14,
15252,
14,
65,
3524,
14,
39745,
6,
198,
33,
39758,
62,
55,
23678,
796,
705,
9060,
14,
15252,
14,
65,
3524,
14,
87,
1084,
6,
198,
33,
39758,
62,
56,
23678,
796,
705,
9060,
14,
15252,
14,
65,
3524,
14,
88,
1084,
6,
198,
33,
39758,
62,
55,
22921,
796,
705,
9060,
14,
15252,
14,
65,
3524,
14,
87,
9806,
6,
198,
33,
39758,
62,
56,
22921,
796,
705,
9060,
14,
15252,
14,
65,
3524,
14,
4948,
897,
6,
198,
198,
2,
6628,
11387,
329,
5004,
355,
2469,
14,
1930,
6096,
198,
10943,
37,
62,
4221,
19535,
39,
15173,
796,
1391,
6,
12480,
10354,
657,
13,
16,
11,
705,
1930,
10354,
657,
13,
24,
92,
198,
2606,
7250,
3843,
62,
3955,
11879,
62,
33489,
796,
357,
2414,
11,
5598,
8,
628,
198,
2,
4149,
82,
48700,
8344,
3669,
290,
21136,
262,
14722,
290,
1366,
2622,
329,
262,
649,
27039,
13,
628,
198,
2,
2547,
325,
290,
27425,
262,
14722,
284,
257,
517,
3534,
328,
83,
11813,
5794,
13,
628,
198,
2,
26981,
8246,
2939,
1366,
290,
6167,
656,
257,
48700,
20688,
5794,
13,
628,
198,
2,
19430,
477,
4263,
656,
262,
1332,
24958,
22105,
2393,
13,
198,
198,
2,
18508,
276,
503,
691,
262,
5415,
6628,
275,
3524,
286,
257,
2939,
13,
15553,
318,
1444,
287,
7716,
62,
27110,
1069,
12629,
62,
6738,
62,
15255,
478,
507,
22446,
628,
198,
2,
18508,
276,
503,
11096,
275,
3524,
810,
6628,
318,
625,
11387,
13,
15553,
318,
1444,
287,
7716,
62,
27110,
1069,
12629,
62,
6738,
62,
15255,
478,
507,
22446,
628,
198,
2,
4149,
2939,
422,
3108,
290,
2198,
19607,
1729,
25228,
2939,
13,
628,
198,
2,
18508,
262,
275,
29305,
422,
262,
44267,
62,
9060,
62,
19608,
292,
316,
326,
389,
625,
11387,
290,
2087,
262,
48700,
20688,
284,
262,
1441,
1351,
13,
198,
198,
2,
19430,
3967,
290,
4633,
48700,
1069,
12629,
284,
48700,
22105,
1262,
262,
6260,
13,
317,
5236,
25131,
11507,
460,
5409,
284,
5236,
262,
1426,
290,
2469,
6096,
954,
13,
628,
198,
2,
19430,
48700,
8344,
3669,
287,
37830,
286,
5128,
1700,
3696,
13,
628,
198,
2,
25853,
262,
27039,
351,
4263,
275,
3524,
2793,
621,
262,
11387,
11,
290,
4866,
262,
2939,
275,
3524,
284,
5072,
8619,
13,
2312,
4263,
481,
307,
1021,
41891,
284,
307,
973,
355,
4633,
6096,
287,
262,
1332,
900,
13,
628
] | 3.513347 | 487 |
import os
import unittest
import tempfile
import hiro
import jiracli.cache
| [
11748,
28686,
198,
11748,
555,
715,
395,
198,
11748,
20218,
7753,
198,
11748,
289,
7058,
198,
11748,
474,
343,
330,
4528,
13,
23870,
628
] | 3.166667 | 24 |
# -*- coding: utf-8 -*-
import sys
sys.path.insert(0, os.path.join(os.path.dirname(
os.path.realpath(__file__)), "../"))
from Functions import processing_utils as pu
def on_log(client, userdata, level, buf):
"""
Log callback
"""
print("log: ", buf)
pass
def on_disconnect(client, userdata, flags, rc=0):
"""
Callback to define what's happening when disconnecting
"""
print("DisConnected flags {0}, result code:{1}, client_id: {2} ".format(flags, rc, client._client_id))
def on_message(client, userdata, message):
"""
Callback to handle subscription topics incoming messages
"""
msg = message
pu.motion_clf(msg)
def on_connect(client, userdata, flags, rc):
"""
Callback to define what to happen when connecting
"""
if(rc==0):
print("connecting to broker ", broker)
print("subscribing to topics ")
client.subscribe(in_topic)
elif(rc==3):
print("server unavailable")
client.loop_stop()
sys.exit("Server is unavailable, please try later")
elif(rc==5):
print("Invalid Credentials")
client.loop_stop()
sys.exit(5)
else:
print("Bad connection, returned code=",rc)
client.loop_stop()
sys.exit("Bad connection, returned code={0}".format(rc))
if __name__ == '__main__':
u_name. u_pass, in_topic, out_topic = pu.p_type_service_args()
broker = "localhost"
client = mqtt.Client("P-type")
client.username_pw_set(username, user_pass)
client.on_message = on_message
client.on_log = on_log
client.on_connect = on_connect
client.on_disconnect = on_disconnect
try:
client.connect(broker)
except:
print("Error connecting")
sys.exit()
client.loop_forever()
| [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
11748,
25064,
198,
17597,
13,
6978,
13,
28463,
7,
15,
11,
28686,
13,
6978,
13,
22179,
7,
418,
13,
6978,
13,
15908,
3672,
7,
198,
220,
220,
220,
28686,
13,
6978,
13,
5305,
6978,
7,
834,
7753,
834,
36911,
366,
492,
30487,
4008,
198,
6738,
40480,
1330,
7587,
62,
26791,
355,
47574,
628,
198,
4299,
319,
62,
6404,
7,
16366,
11,
2836,
7890,
11,
1241,
11,
42684,
2599,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
220,
220,
220,
220,
5972,
23838,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
3601,
7203,
6404,
25,
33172,
42684,
8,
198,
220,
220,
220,
1208,
198,
198,
4299,
319,
62,
6381,
8443,
7,
16366,
11,
2836,
7890,
11,
9701,
11,
48321,
28,
15,
2599,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
220,
220,
220,
220,
4889,
1891,
284,
8160,
644,
338,
5836,
618,
22837,
278,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
3601,
7203,
7279,
13313,
276,
9701,
1391,
15,
5512,
1255,
2438,
29164,
16,
5512,
5456,
62,
312,
25,
1391,
17,
92,
27071,
18982,
7,
33152,
11,
48321,
11,
5456,
13557,
16366,
62,
312,
4008,
198,
198,
4299,
319,
62,
20500,
7,
16366,
11,
2836,
7890,
11,
3275,
2599,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
220,
220,
220,
220,
4889,
1891,
284,
5412,
14569,
10233,
15619,
6218,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
31456,
796,
3275,
198,
220,
220,
220,
47574,
13,
38714,
62,
565,
69,
7,
19662,
8,
198,
198,
4299,
319,
62,
8443,
7,
16366,
11,
2836,
7890,
11,
9701,
11,
48321,
2599,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
220,
220,
220,
220,
4889,
1891,
284,
8160,
644,
284,
1645,
618,
14320,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
611,
7,
6015,
855,
15,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
3601,
7203,
8443,
278,
284,
20426,
33172,
20426,
8,
198,
220,
220,
220,
220,
220,
220,
220,
3601,
7203,
7266,
1416,
23098,
284,
10233,
366,
8,
198,
220,
220,
220,
220,
220,
220,
220,
5456,
13,
7266,
12522,
7,
259,
62,
26652,
8,
628,
220,
220,
220,
1288,
361,
7,
6015,
855,
18,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
3601,
7203,
15388,
23485,
4943,
198,
220,
220,
220,
220,
220,
220,
220,
5456,
13,
26268,
62,
11338,
3419,
198,
220,
220,
220,
220,
220,
220,
220,
25064,
13,
37023,
7203,
10697,
318,
23485,
11,
3387,
1949,
1568,
4943,
198,
220,
220,
220,
1288,
361,
7,
6015,
855,
20,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
3601,
7203,
44651,
327,
445,
14817,
4943,
198,
220,
220,
220,
220,
220,
220,
220,
5456,
13,
26268,
62,
11338,
3419,
198,
220,
220,
220,
220,
220,
220,
220,
25064,
13,
37023,
7,
20,
8,
198,
220,
220,
220,
2073,
25,
198,
220,
220,
220,
220,
220,
220,
220,
3601,
7203,
22069,
4637,
11,
4504,
2438,
28,
1600,
6015,
8,
198,
220,
220,
220,
220,
220,
220,
220,
5456,
13,
26268,
62,
11338,
3419,
198,
220,
220,
220,
220,
220,
220,
220,
25064,
13,
37023,
7203,
22069,
4637,
11,
4504,
2438,
34758,
15,
92,
1911,
18982,
7,
6015,
4008,
628,
198,
361,
11593,
3672,
834,
6624,
705,
834,
12417,
834,
10354,
198,
220,
220,
220,
334,
62,
3672,
13,
334,
62,
6603,
11,
287,
62,
26652,
11,
503,
62,
26652,
796,
47574,
13,
79,
62,
4906,
62,
15271,
62,
22046,
3419,
198,
220,
220,
220,
20426,
796,
366,
36750,
1,
628,
220,
220,
220,
5456,
796,
285,
80,
926,
13,
11792,
7203,
47,
12,
4906,
4943,
198,
220,
220,
220,
5456,
13,
29460,
62,
79,
86,
62,
2617,
7,
29460,
11,
2836,
62,
6603,
8,
198,
220,
220,
220,
5456,
13,
261,
62,
20500,
796,
319,
62,
20500,
198,
220,
220,
220,
5456,
13,
261,
62,
6404,
796,
319,
62,
6404,
198,
220,
220,
220,
5456,
13,
261,
62,
8443,
796,
319,
62,
8443,
198,
220,
220,
220,
5456,
13,
261,
62,
6381,
8443,
796,
319,
62,
6381,
8443,
628,
220,
220,
220,
1949,
25,
198,
197,
220,
220,
220,
5456,
13,
8443,
7,
7957,
6122,
8,
198,
220,
220,
220,
2845,
25,
198,
197,
220,
220,
220,
3601,
7203,
12331,
14320,
4943,
198,
197,
220,
220,
220,
25064,
13,
37023,
3419,
628,
220,
220,
220,
5456,
13,
26268,
62,
754,
332,
3419,
198
] | 2.447154 | 738 |
from insomniac import activation_controller
exec(activation_controller.get_extra_feature("action_warmup"))
| [
6738,
1035,
296,
8461,
330,
1330,
14916,
62,
36500,
198,
198,
18558,
7,
48545,
62,
36500,
13,
1136,
62,
26086,
62,
30053,
7203,
2673,
62,
31975,
929,
48774,
198
] | 3.724138 | 29 |
# -*- coding:UTF-8 -*-
import logging
from datetime import datetime
from typing import List, Callable
from minimir import Struct
from minimir.BattleAction import BattleAction
from minimir.Utils import Utils
| [
2,
532,
9,
12,
19617,
25,
48504,
12,
23,
532,
9,
12,
198,
11748,
18931,
198,
6738,
4818,
8079,
1330,
4818,
8079,
198,
6738,
19720,
1330,
7343,
11,
4889,
540,
198,
198,
6738,
10356,
343,
1330,
32112,
198,
6738,
10356,
343,
13,
24064,
12502,
1330,
5838,
12502,
198,
6738,
10356,
343,
13,
18274,
4487,
1330,
7273,
4487,
628
] | 3.603448 | 58 |
# -*- coding: utf-8 -*-
import concurrent.futures
import logging
import os
import sys
from Crypto.Cipher import AES
from m3u8_To_MP4 import v2_abstract_task_processor
from m3u8_To_MP4.helpers import path_helper
from m3u8_To_MP4.helpers import printer_helper
from m3u8_To_MP4.networks.synchronous.sync_http_requester import request_for
| [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
201,
198,
11748,
24580,
13,
69,
315,
942,
201,
198,
11748,
18931,
201,
198,
11748,
28686,
201,
198,
11748,
25064,
201,
198,
201,
198,
6738,
36579,
13,
34,
10803,
1330,
34329,
201,
198,
201,
198,
6738,
285,
18,
84,
23,
62,
2514,
62,
7378,
19,
1330,
410,
17,
62,
397,
8709,
62,
35943,
62,
41341,
201,
198,
6738,
285,
18,
84,
23,
62,
2514,
62,
7378,
19,
13,
16794,
364,
1330,
3108,
62,
2978,
525,
201,
198,
6738,
285,
18,
84,
23,
62,
2514,
62,
7378,
19,
13,
16794,
364,
1330,
20632,
62,
2978,
525,
201,
198,
6738,
285,
18,
84,
23,
62,
2514,
62,
7378,
19,
13,
3262,
5225,
13,
28869,
11413,
516,
13,
27261,
62,
4023,
62,
8897,
7834,
1330,
2581,
62,
1640,
201,
198,
201,
198,
201,
198,
201,
198
] | 2.431507 | 146 |
from django.db import models
from django.db.models import fields
from rest_framework import serializers
from .models import Todo | [
6738,
42625,
14208,
13,
9945,
1330,
4981,
198,
6738,
42625,
14208,
13,
9945,
13,
27530,
1330,
7032,
198,
6738,
1334,
62,
30604,
1330,
11389,
11341,
198,
6738,
764,
27530,
1330,
309,
24313
] | 4 | 32 |
from rest_framework import serializers
from legislature.models import District, State
| [
6738,
1334,
62,
30604,
1330,
11389,
11341,
198,
198,
6738,
15928,
13,
27530,
1330,
5665,
11,
1812,
628,
198
] | 4.684211 | 19 |
from flask_wtf import FlaskForm
from wtforms import PasswordField, RadioField, StringField
from wtforms.fields.html5 import EmailField
import wtforms.validators as validate
| [
6738,
42903,
62,
86,
27110,
1330,
46947,
8479,
198,
6738,
266,
83,
23914,
1330,
30275,
15878,
11,
8829,
15878,
11,
10903,
15878,
198,
6738,
266,
83,
23914,
13,
25747,
13,
6494,
20,
1330,
9570,
15878,
198,
11748,
266,
83,
23914,
13,
12102,
2024,
355,
26571,
628
] | 3.782609 | 46 |
#!/usr/bin/env python
import tensorflow as tf
import numpy as np
import scipy.signal
from scipy import misc
import scipy.io
from PIL import Image
import json
import os
from offline_feature import *
from bbox_tool import *
import glob
from reward_function import *
from semantic_environment import *
from shortest_path import *
IMAGE_WIDTH = 600
IMAGE_HEIGHT = 450
# cfg = json.load(open('../config.json','r'))
cfg = json.load(open(os.path.join(os.path.dirname(os.path.dirname(__file__)), 'config.json'),'r'))
| [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
198,
11748,
11192,
273,
11125,
355,
48700,
198,
11748,
299,
32152,
355,
45941,
198,
11748,
629,
541,
88,
13,
12683,
282,
198,
6738,
629,
541,
88,
1330,
12747,
198,
11748,
629,
541,
88,
13,
952,
198,
6738,
350,
4146,
1330,
7412,
198,
11748,
33918,
198,
11748,
28686,
198,
6738,
18043,
62,
30053,
1330,
1635,
198,
6738,
275,
3524,
62,
25981,
1330,
1635,
198,
11748,
15095,
198,
6738,
6721,
62,
8818,
1330,
1635,
198,
6738,
37865,
62,
38986,
1330,
1635,
198,
6738,
35581,
62,
6978,
1330,
1635,
198,
198,
3955,
11879,
62,
54,
2389,
4221,
796,
10053,
198,
3955,
11879,
62,
13909,
9947,
796,
18523,
198,
198,
2,
30218,
70,
796,
33918,
13,
2220,
7,
9654,
10786,
40720,
11250,
13,
17752,
41707,
81,
6,
4008,
198,
37581,
796,
33918,
13,
2220,
7,
9654,
7,
418,
13,
6978,
13,
22179,
7,
418,
13,
6978,
13,
15908,
3672,
7,
418,
13,
6978,
13,
15908,
3672,
7,
834,
7753,
834,
36911,
705,
11250,
13,
17752,
33809,
6,
81,
6,
4008,
628,
628,
628,
628,
628,
198
] | 2.894444 | 180 |
#!/usr/bin/env python
from pymap3d.vincenty import vdist
from argparse import ArgumentParser
if __name__ == '__main__': # pragma: no cover
main()
| [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
198,
6738,
279,
4948,
499,
18,
67,
13,
7114,
1087,
88,
1330,
410,
17080,
198,
6738,
1822,
29572,
1330,
45751,
46677,
628,
198,
198,
361,
11593,
3672,
834,
6624,
705,
834,
12417,
834,
10354,
220,
1303,
23864,
2611,
25,
645,
3002,
198,
220,
220,
220,
1388,
3419,
198
] | 2.75 | 56 |
from django.urls import path
from mytravelblog.accounts.views import *
urlpatterns = (
path('login/', UserLoginView.as_view(), name='login user'),
path('logout/', UserLogoutConfirmationView.as_view(), name='logout user confirmation'),
path('logout/signout/', UserLogoutView.as_view(), name='logout user'),
path('profile-details/<int:pk>/', UserProfileDetailsView.as_view(), name='profile details'),
path('profile/create/', UserRegisterView.as_view(), name='profile create'),
path('edit-profile/<int:pk>/', EditProfileView.as_view(), name='profile edit'),
path('delete-profile/<int:pk>/', DeleteProfileView.as_view(), name='profile delete'),
path('edit-password/<int:pk>/', ChangeUserPasswordView.as_view(), name='change password'),
)
| [
6738,
42625,
14208,
13,
6371,
82,
1330,
3108,
198,
198,
6738,
616,
35927,
14036,
13,
23317,
82,
13,
33571,
1330,
1635,
198,
198,
6371,
33279,
82,
796,
357,
198,
220,
220,
220,
3108,
10786,
38235,
14,
3256,
11787,
47790,
7680,
13,
292,
62,
1177,
22784,
1438,
11639,
38235,
2836,
33809,
198,
220,
220,
220,
3108,
10786,
6404,
448,
14,
3256,
11787,
11187,
448,
18546,
36241,
7680,
13,
292,
62,
1177,
22784,
1438,
11639,
6404,
448,
2836,
12641,
33809,
198,
220,
220,
220,
3108,
10786,
6404,
448,
14,
12683,
448,
14,
3256,
11787,
11187,
448,
7680,
13,
292,
62,
1177,
22784,
1438,
11639,
6404,
448,
2836,
33809,
628,
220,
220,
220,
3108,
10786,
13317,
12,
36604,
14,
27,
600,
25,
79,
74,
29,
14,
3256,
11787,
37046,
24259,
7680,
13,
292,
62,
1177,
22784,
1438,
11639,
13317,
3307,
33809,
198,
220,
220,
220,
3108,
10786,
13317,
14,
17953,
14,
3256,
11787,
38804,
7680,
13,
292,
62,
1177,
22784,
1438,
11639,
13317,
2251,
33809,
198,
220,
220,
220,
3108,
10786,
19312,
12,
13317,
14,
27,
600,
25,
79,
74,
29,
14,
3256,
5312,
37046,
7680,
13,
292,
62,
1177,
22784,
1438,
11639,
13317,
4370,
33809,
198,
220,
220,
220,
3108,
10786,
33678,
12,
13317,
14,
27,
600,
25,
79,
74,
29,
14,
3256,
23520,
37046,
7680,
13,
292,
62,
1177,
22784,
1438,
11639,
13317,
12233,
33809,
628,
220,
220,
220,
3108,
10786,
19312,
12,
28712,
14,
27,
600,
25,
79,
74,
29,
14,
3256,
9794,
12982,
35215,
7680,
13,
292,
62,
1177,
22784,
1438,
11639,
3803,
9206,
33809,
198,
8,
198
] | 2.972973 | 259 |
# import util
import sys
import os
pioPath = ".platformio/penv/lib/python3.9/site-packages
fullPath = os.path.join(os.path.expanduser('~'), pioPath)
print(fullPath)
sys.path.append(os.path.join(os.path.expanduser('~'), pioPath))
import util
util.get_serial_ports()
| [
2,
1330,
7736,
198,
11748,
25064,
198,
11748,
28686,
198,
79,
952,
15235,
796,
27071,
24254,
952,
14,
3617,
85,
14,
8019,
14,
29412,
18,
13,
24,
14,
15654,
12,
43789,
198,
12853,
15235,
796,
28686,
13,
6978,
13,
22179,
7,
418,
13,
6978,
13,
11201,
392,
7220,
10786,
93,
33809,
279,
952,
15235,
8,
198,
4798,
7,
12853,
15235,
8,
198,
17597,
13,
6978,
13,
33295,
7,
418,
13,
6978,
13,
22179,
7,
418,
13,
6978,
13,
11201,
392,
7220,
10786,
93,
33809,
279,
952,
15235,
4008,
198,
11748,
7736,
198,
22602,
13,
1136,
62,
46911,
62,
3742,
3419,
198
] | 2.623762 | 101 |
# Copyright 2014 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
from pylib.base import environment
from pylib.device import adb_wrapper
from pylib.device import device_errors
from pylib.device import device_utils
from pylib.utils import parallelizer
| [
2,
15069,
1946,
383,
18255,
1505,
46665,
13,
1439,
2489,
10395,
13,
198,
2,
5765,
286,
428,
2723,
2438,
318,
21825,
416,
257,
347,
10305,
12,
7635,
5964,
326,
460,
307,
198,
2,
1043,
287,
262,
38559,
24290,
2393,
13,
198,
198,
6738,
279,
2645,
571,
13,
8692,
1330,
2858,
198,
6738,
279,
2645,
571,
13,
25202,
1330,
512,
65,
62,
48553,
198,
6738,
279,
2645,
571,
13,
25202,
1330,
3335,
62,
48277,
198,
6738,
279,
2645,
571,
13,
25202,
1330,
3335,
62,
26791,
198,
6738,
279,
2645,
571,
13,
26791,
1330,
10730,
7509,
628,
198
] | 3.65625 | 96 |
BASE_URL = 'https://fantasy.premierleague.com/drf/'
FPL_DATA = BASE_URL + 'bootstrap-static'
# (player id)
PLAYER_DATA = BASE_URL + 'element-summary/{}'
# (gameweek)
DREAM_TEAM_DATA = BASE_URL + 'dream-team/{}'
# (team id)
USER_DATA = BASE_URL + 'entry/{}'
# (gameweek)
USER_GAMEWEEK_TEAM_DATA = USER_DATA + '/event/{}/picks'
| [
33,
11159,
62,
21886,
796,
705,
5450,
1378,
69,
34921,
13,
31605,
959,
19316,
13,
785,
14,
7109,
69,
14,
6,
198,
198,
5837,
43,
62,
26947,
796,
49688,
62,
21886,
1343,
705,
18769,
26418,
12,
12708,
6,
198,
198,
2,
357,
7829,
4686,
8,
198,
31519,
1137,
62,
26947,
796,
49688,
62,
21886,
1343,
705,
30854,
12,
49736,
14,
90,
92,
6,
198,
2,
357,
28483,
413,
68,
988,
8,
198,
35,
32235,
62,
9328,
2390,
62,
26947,
796,
49688,
62,
21886,
1343,
705,
25966,
12,
15097,
14,
90,
92,
6,
198,
2,
357,
15097,
4686,
8,
198,
29904,
62,
26947,
796,
49688,
62,
21886,
1343,
705,
13000,
14,
90,
92,
6,
198,
2,
357,
28483,
413,
68,
988,
8,
198,
29904,
62,
38,
2390,
6217,
33823,
62,
9328,
2390,
62,
26947,
796,
1294,
1137,
62,
26947,
1343,
31051,
15596,
14,
90,
92,
14,
79,
3378,
6,
198
] | 2.201342 | 149 |
from flask import current_app, abort, request
from dmutils.authentication import UnauthorizedWWWAuthenticate
def get_allowed_tokens_from_config(config, module='main'):
"""Return a list of allowed auth tokens from the application config"""
env_variable_name = 'DM_API_AUTH_TOKENS'
if module == 'callbacks':
env_variable_name = 'DM_API_CALLBACK_AUTH_TOKENS'
return [token for token in config.get(env_variable_name, '').split(':') if token]
| [
6738,
42903,
1330,
1459,
62,
1324,
11,
15614,
11,
2581,
198,
198,
6738,
288,
21973,
4487,
13,
41299,
3299,
1330,
791,
19721,
17947,
15543,
315,
6925,
5344,
628,
628,
198,
4299,
651,
62,
40845,
62,
83,
482,
641,
62,
6738,
62,
11250,
7,
11250,
11,
8265,
11639,
12417,
6,
2599,
198,
220,
220,
220,
37227,
13615,
257,
1351,
286,
3142,
6284,
16326,
422,
262,
3586,
4566,
37811,
198,
220,
220,
220,
17365,
62,
45286,
62,
3672,
796,
705,
23127,
62,
17614,
62,
32,
24318,
62,
10468,
42,
16938,
6,
628,
220,
220,
220,
611,
8265,
6624,
705,
13345,
10146,
10354,
198,
220,
220,
220,
220,
220,
220,
220,
17365,
62,
45286,
62,
3672,
796,
705,
23127,
62,
17614,
62,
34,
7036,
31098,
62,
32,
24318,
62,
10468,
42,
16938,
6,
628,
220,
220,
220,
1441,
685,
30001,
329,
11241,
287,
4566,
13,
1136,
7,
24330,
62,
45286,
62,
3672,
11,
10148,
737,
35312,
7,
10354,
11537,
611,
11241,
60,
628
] | 2.9375 | 160 |
import numpy as np
from scipy.constants import m_p, c, e
import matplotlib.pyplot as plt
import PyHEADTAIL.particles.generators as generators
from PyHEADTAIL.trackers.transverse_tracking import TransverseMap
from PyHEADTAIL.trackers.detuners import Chromaticity, AmplitudeDetuning
if __name__ == '__main__':
run()
| [
11748,
299,
32152,
355,
45941,
198,
6738,
629,
541,
88,
13,
9979,
1187,
1330,
285,
62,
79,
11,
269,
11,
304,
198,
11748,
2603,
29487,
8019,
13,
9078,
29487,
355,
458,
83,
198,
198,
11748,
9485,
37682,
5603,
4146,
13,
3911,
2983,
13,
8612,
2024,
355,
27298,
198,
6738,
9485,
37682,
5603,
4146,
13,
11659,
364,
13,
7645,
4399,
62,
36280,
1330,
3602,
4399,
13912,
198,
6738,
9485,
37682,
5603,
4146,
13,
11659,
364,
13,
15255,
403,
364,
1330,
18255,
1512,
414,
11,
44074,
3984,
11242,
46493,
628,
198,
198,
361,
11593,
3672,
834,
6624,
705,
834,
12417,
834,
10354,
198,
220,
220,
220,
1057,
3419,
628
] | 3.018692 | 107 |
# calculating_pi.py
# From Classic Computer Science Problems in Python Chapter 1
# Copyright 2018 David Kopec
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
if __name__ == "__main__":
print(calculate_pi(1000000)) | [
2,
26019,
62,
14415,
13,
9078,
198,
2,
3574,
13449,
13851,
5800,
32093,
287,
11361,
7006,
352,
198,
2,
15069,
2864,
3271,
40500,
721,
198,
2,
198,
2,
49962,
739,
262,
24843,
13789,
11,
10628,
362,
13,
15,
357,
1169,
366,
34156,
15341,
198,
2,
345,
743,
407,
779,
428,
2393,
2845,
287,
11846,
351,
262,
13789,
13,
198,
2,
921,
743,
7330,
257,
4866,
286,
262,
13789,
379,
198,
2,
198,
2,
2638,
1378,
2503,
13,
43073,
13,
2398,
14,
677,
4541,
14,
43,
2149,
24290,
12,
17,
13,
15,
198,
2,
198,
2,
17486,
2672,
416,
9723,
1099,
393,
4987,
284,
287,
3597,
11,
3788,
198,
2,
9387,
739,
262,
13789,
318,
9387,
319,
281,
366,
1921,
3180,
1,
29809,
1797,
11,
198,
2,
42881,
34764,
11015,
6375,
7102,
49828,
11053,
3963,
15529,
509,
12115,
11,
2035,
4911,
393,
17142,
13,
198,
2,
4091,
262,
13789,
329,
262,
2176,
3303,
15030,
21627,
290,
198,
2,
11247,
739,
262,
13789,
13,
628,
198,
198,
361,
11593,
3672,
834,
6624,
366,
834,
12417,
834,
1298,
198,
220,
220,
220,
3601,
7,
9948,
3129,
378,
62,
14415,
7,
16,
10535,
4008
] | 3.757895 | 190 |
#
# auth test module - add, update, delete
#
"""
MIT License
Copyright (c) 2017, 2018 Ioan Coman
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, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
"""
DELETE_TESTS = True
import requests
import json
import os
import time
import datetime
import traceback
class AuthTests(ApiTests):
'''
def add(self, title, description, done='yes'):
try:
values = [title, description, done]
data = dict(data=json.dumps(values))
result = json.loads(self.session.post(self.url_add, data).text)
ret = result['ok'], result['data']
except Exception as ex:
ret = False, str(ex)
return ret
def update(self, obid, title, description, done='yes'):
try:
values = [title, description, done]
data = dict(data=json.dumps(values), id=obid)
result = json.loads(self.session.post(self.url_update, data).text)
ret = result['ok'], result['data']
except Exception as ex:
ret = False, str(ex)
return ret
def delete(self, obid):
try:
data = dict(id=obid)
result = json.loads(self.session.post(self.url_delete, data).text)
ret = result['ok'], result['data']
except Exception as ex:
ret = False, str(ex)
return ret
'''
if __name__ == "__main__":
import sys
py = sys.version_info
py3k = py >= (3, 0, 0)
try:
test_function()
except Exception as ex:
print("Exception found: {}".format(ex))
# traceback.print_exc(file=sys.stdout)
msg = 'Program ends, press Enter.'
if py3k:
input(msg)
else:
raw_input(msg)
| [
2,
198,
2,
6284,
1332,
8265,
532,
751,
11,
4296,
11,
12233,
198,
2,
198,
198,
37811,
198,
198,
36393,
13789,
198,
198,
15269,
357,
66,
8,
2177,
11,
2864,
314,
24611,
955,
272,
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,
1169,
366,
25423,
12340,
284,
1730,
198,
259,
262,
10442,
1231,
17504,
11,
1390,
1231,
17385,
262,
2489,
198,
1462,
779,
11,
4866,
11,
13096,
11,
20121,
11,
7715,
11,
14983,
11,
850,
43085,
11,
290,
14,
273,
3677,
198,
22163,
444,
286,
262,
10442,
11,
290,
284,
8749,
6506,
284,
4150,
262,
10442,
318,
198,
69,
700,
1348,
284,
466,
523,
11,
2426,
284,
262,
1708,
3403,
25,
198,
198,
464,
2029,
6634,
4003,
290,
428,
7170,
4003,
2236,
307,
3017,
287,
477,
198,
22163,
444,
393,
8904,
16690,
286,
262,
10442,
13,
198,
198,
10970,
47466,
3180,
36592,
2389,
1961,
366,
1921,
3180,
1600,
42881,
34764,
56,
3963,
15529,
509,
12115,
11,
7788,
32761,
6375,
198,
3955,
49094,
11,
47783,
2751,
21728,
5626,
40880,
5390,
3336,
34764,
11015,
3963,
34482,
3398,
1565,
5603,
25382,
11,
198,
37,
46144,
7473,
317,
16652,
2149,
37232,
33079,
48933,
5357,
44521,
1268,
10913,
2751,
12529,
13,
3268,
8005,
49261,
50163,
3336,
198,
32,
24318,
20673,
6375,
27975,
38162,
9947,
367,
15173,
4877,
9348,
43031,
19146,
7473,
15529,
47666,
3955,
11,
29506,
25552,
6375,
25401,
198,
43,
3539,
25382,
11,
7655,
2767,
16879,
3268,
3537,
40282,
3963,
27342,
10659,
11,
309,
9863,
6375,
25401,
54,
24352,
11,
5923,
1797,
2751,
16034,
11,
198,
12425,
3963,
6375,
3268,
7102,
45,
24565,
13315,
3336,
47466,
6375,
3336,
23210,
6375,
25401,
5550,
1847,
20754,
3268,
3336,
198,
15821,
37485,
13,
198,
198,
37811,
198,
198,
7206,
2538,
9328,
62,
51,
1546,
4694,
796,
6407,
198,
198,
11748,
7007,
198,
11748,
33918,
198,
11748,
28686,
198,
11748,
640,
198,
11748,
4818,
8079,
198,
11748,
12854,
1891,
628,
198,
198,
4871,
26828,
51,
3558,
7,
32,
14415,
51,
3558,
2599,
628,
220,
220,
220,
705,
7061,
198,
220,
220,
220,
825,
751,
7,
944,
11,
3670,
11,
6764,
11,
1760,
11639,
8505,
6,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
1949,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3815,
796,
685,
7839,
11,
6764,
11,
1760,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1366,
796,
8633,
7,
7890,
28,
17752,
13,
67,
8142,
7,
27160,
4008,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1255,
796,
33918,
13,
46030,
7,
944,
13,
29891,
13,
7353,
7,
944,
13,
6371,
62,
2860,
11,
1366,
737,
5239,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1005,
796,
1255,
17816,
482,
6,
4357,
1255,
17816,
7890,
20520,
198,
220,
220,
220,
220,
220,
220,
220,
2845,
35528,
355,
409,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1005,
796,
10352,
11,
965,
7,
1069,
8,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
1005,
628,
220,
220,
220,
825,
4296,
7,
944,
11,
909,
312,
11,
3670,
11,
6764,
11,
1760,
11639,
8505,
6,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
1949,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3815,
796,
685,
7839,
11,
6764,
11,
1760,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1366,
796,
8633,
7,
7890,
28,
17752,
13,
67,
8142,
7,
27160,
828,
4686,
28,
672,
312,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1255,
796,
33918,
13,
46030,
7,
944,
13,
29891,
13,
7353,
7,
944,
13,
6371,
62,
19119,
11,
1366,
737,
5239,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1005,
796,
1255,
17816,
482,
6,
4357,
1255,
17816,
7890,
20520,
198,
220,
220,
220,
220,
220,
220,
220,
2845,
35528,
355,
409,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1005,
796,
10352,
11,
965,
7,
1069,
8,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
1005,
628,
220,
220,
220,
825,
12233,
7,
944,
11,
909,
312,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
1949,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1366,
796,
8633,
7,
312,
28,
672,
312,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1255,
796,
33918,
13,
46030,
7,
944,
13,
29891,
13,
7353,
7,
944,
13,
6371,
62,
33678,
11,
1366,
737,
5239,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1005,
796,
1255,
17816,
482,
6,
4357,
1255,
17816,
7890,
20520,
198,
220,
220,
220,
220,
220,
220,
220,
2845,
35528,
355,
409,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1005,
796,
10352,
11,
965,
7,
1069,
8,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
1005,
198,
220,
220,
220,
220,
220,
220,
220,
705,
7061,
628,
198,
361,
11593,
3672,
834,
6624,
366,
834,
12417,
834,
1298,
198,
220,
220,
220,
1330,
25064,
628,
220,
220,
220,
12972,
796,
25064,
13,
9641,
62,
10951,
198,
220,
220,
220,
12972,
18,
74,
796,
12972,
18189,
357,
18,
11,
657,
11,
657,
8,
198,
220,
220,
220,
1949,
25,
198,
220,
220,
220,
220,
220,
220,
220,
1332,
62,
8818,
3419,
198,
220,
220,
220,
2845,
35528,
355,
409,
25,
198,
220,
220,
220,
220,
220,
220,
220,
3601,
7203,
16922,
1043,
25,
23884,
1911,
18982,
7,
1069,
4008,
198,
220,
220,
220,
220,
220,
220,
220,
1303,
12854,
1891,
13,
4798,
62,
41194,
7,
7753,
28,
17597,
13,
19282,
448,
8,
198,
220,
220,
220,
31456,
796,
705,
15167,
5645,
11,
1803,
6062,
2637,
198,
220,
220,
220,
611,
12972,
18,
74,
25,
198,
220,
220,
220,
220,
220,
220,
220,
5128,
7,
19662,
8,
198,
220,
220,
220,
2073,
25,
198,
220,
220,
220,
220,
220,
220,
220,
8246,
62,
15414,
7,
19662,
8,
198
] | 2.61284 | 1,028 |
"""TODO: Use dataclasses."""
from __future__ import annotations
import abc
import datetime
import sys
from collections import MutableMapping
from typing import Any
from typing import Dict
from typing import Iterator
from typing import KeysView
from typing import List
from typing import Optional
from typing import Tuple
from typing import Type
from typing import Union
from logbook import Logger
from logbook import StreamHandler
from steam.steamid import SteamID
from rs2wapy.adapters import adapters
from rs2wapy.epicgamesstore import EGSID
from rs2wapy.steam import SteamWebAPI
BAN_DATE_FMT = "%Y/%m/%d %H:%M:%S"
StreamHandler(sys.stdout, level="WARNING").push_application()
logger = Logger(__name__)
HEX_COLOR_BLUE_TEAM = "#50A0F0"
HEX_COLOR_RED_TEAM = "#E54927"
HEX_COLOR_UNKNOWN_TEAM = "transparent"
HEX_COLOR_ALL_TEAM = ""
HEX_COLOR_TO_TEAM = {
HEX_COLOR_BLUE_TEAM: BlueTeam,
HEX_COLOR_RED_TEAM: RedTeam,
HEX_COLOR_UNKNOWN_TEAM: UnknownTeam,
HEX_COLOR_ALL_TEAM: AllTeam,
}
TEAM_INDEX_TO_TEAM: Dict[int, Type[Team]] = {
0: RedTeam,
1: BlueTeam,
}
TEAM_TO_TEAM_INDEX: Dict[Type[Team], int] = {
RedTeam: 0,
BlueTeam: 1,
}
# TODO: SteamPlayer and EGSPlayer classes?
CHAT_CHANNEL_ALL_STR = "(ALL)"
CHAT_CHANNEL_TEAM_STR = "(TEAM)"
TEAMNOTICE_TEAM = CHAT_CHANNEL_TEAM_STR
TEAMNOTICE_TO_CHAT_CHANNEL = {
None: ChatChannelAll,
TEAMNOTICE_TEAM: ChatChannelTeam,
}
CHAT_CHANNEL_TO_STR = {
ChatChannelAll: CHAT_CHANNEL_ALL_STR,
ChatChannelTeam: CHAT_CHANNEL_TEAM_STR,
}
# TODO: Refactor attributes etc.
| [
37811,
51,
3727,
46,
25,
5765,
4818,
330,
28958,
526,
15931,
198,
198,
6738,
11593,
37443,
834,
1330,
37647,
198,
198,
11748,
450,
66,
198,
11748,
4818,
8079,
198,
11748,
25064,
198,
6738,
17268,
1330,
13859,
540,
44,
5912,
198,
6738,
19720,
1330,
4377,
198,
6738,
19720,
1330,
360,
713,
198,
6738,
19720,
1330,
40806,
1352,
198,
6738,
19720,
1330,
26363,
7680,
198,
6738,
19720,
1330,
7343,
198,
6738,
19720,
1330,
32233,
198,
6738,
19720,
1330,
309,
29291,
198,
6738,
19720,
1330,
5994,
198,
6738,
19720,
1330,
4479,
198,
198,
6738,
2604,
2070,
1330,
5972,
1362,
198,
6738,
2604,
2070,
1330,
13860,
25060,
198,
6738,
13324,
13,
21465,
312,
1330,
9094,
2389,
198,
198,
6738,
44608,
17,
86,
12826,
13,
324,
12126,
1330,
46363,
198,
6738,
44608,
17,
86,
12826,
13,
538,
291,
19966,
8095,
1330,
412,
14313,
2389,
198,
6738,
44608,
17,
86,
12826,
13,
21465,
1330,
9094,
13908,
17614,
198,
198,
33,
1565,
62,
35,
6158,
62,
37,
13752,
796,
36521,
56,
14,
4,
76,
14,
4,
67,
4064,
39,
25,
4,
44,
25,
4,
50,
1,
198,
198,
12124,
25060,
7,
17597,
13,
19282,
448,
11,
1241,
2625,
31502,
11074,
14689,
62,
31438,
3419,
198,
6404,
1362,
796,
5972,
1362,
7,
834,
3672,
834,
8,
628,
198,
198,
39,
6369,
62,
46786,
62,
9148,
8924,
62,
9328,
2390,
796,
25113,
1120,
32,
15,
37,
15,
1,
198,
39,
6369,
62,
46786,
62,
22083,
62,
9328,
2390,
796,
25113,
36,
44966,
1983,
1,
198,
39,
6369,
62,
46786,
62,
4944,
44706,
62,
9328,
2390,
796,
366,
7645,
8000,
1,
198,
39,
6369,
62,
46786,
62,
7036,
62,
9328,
2390,
796,
13538,
628,
628,
628,
198,
198,
39,
6369,
62,
46786,
62,
10468,
62,
9328,
2390,
796,
1391,
198,
220,
220,
220,
367,
6369,
62,
46786,
62,
9148,
8924,
62,
9328,
2390,
25,
4518,
15592,
11,
198,
220,
220,
220,
367,
6369,
62,
46786,
62,
22083,
62,
9328,
2390,
25,
2297,
15592,
11,
198,
220,
220,
220,
367,
6369,
62,
46786,
62,
4944,
44706,
62,
9328,
2390,
25,
16185,
15592,
11,
198,
220,
220,
220,
367,
6369,
62,
46786,
62,
7036,
62,
9328,
2390,
25,
1439,
15592,
11,
198,
92,
198,
198,
9328,
2390,
62,
12115,
6369,
62,
10468,
62,
9328,
2390,
25,
360,
713,
58,
600,
11,
5994,
58,
15592,
11907,
796,
1391,
198,
220,
220,
220,
657,
25,
2297,
15592,
11,
198,
220,
220,
220,
352,
25,
4518,
15592,
11,
198,
92,
198,
198,
9328,
2390,
62,
10468,
62,
9328,
2390,
62,
12115,
6369,
25,
360,
713,
58,
6030,
58,
15592,
4357,
493,
60,
796,
1391,
198,
220,
220,
220,
2297,
15592,
25,
657,
11,
198,
220,
220,
220,
4518,
15592,
25,
352,
11,
198,
92,
628,
198,
2,
16926,
46,
25,
9094,
14140,
290,
412,
14313,
14140,
6097,
30,
628,
198,
31542,
62,
3398,
22846,
3698,
62,
7036,
62,
18601,
796,
30629,
7036,
16725,
198,
31542,
62,
3398,
22846,
3698,
62,
9328,
2390,
62,
18601,
796,
30629,
9328,
2390,
16725,
198,
9328,
2390,
11929,
8476,
62,
9328,
2390,
796,
5870,
1404,
62,
3398,
22846,
3698,
62,
9328,
2390,
62,
18601,
628,
628,
198,
198,
9328,
2390,
11929,
8476,
62,
10468,
62,
31542,
62,
3398,
22846,
3698,
796,
1391,
198,
220,
220,
220,
6045,
25,
24101,
29239,
3237,
11,
198,
220,
220,
220,
33536,
11929,
8476,
62,
9328,
2390,
25,
24101,
29239,
15592,
11,
198,
92,
198,
198,
31542,
62,
3398,
22846,
3698,
62,
10468,
62,
18601,
796,
1391,
198,
220,
220,
220,
24101,
29239,
3237,
25,
5870,
1404,
62,
3398,
22846,
3698,
62,
7036,
62,
18601,
11,
198,
220,
220,
220,
24101,
29239,
15592,
25,
5870,
1404,
62,
3398,
22846,
3698,
62,
9328,
2390,
62,
18601,
11,
198,
92,
628,
628,
628,
628,
628,
198,
2,
16926,
46,
25,
6524,
11218,
12608,
3503,
13,
628
] | 2.523052 | 629 |
l = int(input("digite a largura: "))
a = int(input("digite a altura: "))
L = A = 1
while A <= a:
while L <= l:
print("#", end="")
L += 1
A += 1
L = 1
print()
| [
75,
796,
493,
7,
15414,
7203,
12894,
578,
257,
2552,
5330,
25,
366,
4008,
198,
64,
796,
493,
7,
15414,
7203,
12894,
578,
257,
5988,
5330,
25,
366,
4008,
198,
43,
796,
317,
796,
352,
198,
4514,
317,
19841,
257,
25,
198,
220,
220,
220,
981,
406,
19841,
300,
25,
198,
220,
220,
220,
220,
220,
220,
220,
3601,
7203,
2,
1600,
886,
2625,
4943,
198,
220,
220,
220,
220,
220,
220,
220,
406,
15853,
352,
198,
220,
220,
220,
317,
15853,
352,
198,
220,
220,
220,
406,
796,
352,
198,
220,
220,
220,
3601,
3419,
198
] | 1.958763 | 97 |
from unittest import TestCase
import plotly.graph_objs as go
from nose.tools import raises
| [
6738,
555,
715,
395,
1330,
6208,
20448,
198,
11748,
7110,
306,
13,
34960,
62,
672,
8457,
355,
467,
198,
6738,
9686,
13,
31391,
1330,
12073,
628,
628
] | 3.481481 | 27 |
# -*- coding: utf-8 -*-
# Copyright (c) 2014 Plivo Team. See LICENSE.txt for details.
import time
import msgpack
VALID_IDENTIFIER_SET = set(list('abcdefghijklmnopqrstuvwxyz0123456789_-'))
def is_valid_identifier(identifier):
"""Checks if the given identifier is valid or not. A valid
identifier may consists of the following characters with a
maximum length of 100 characters, minimum of 1 character.
Valid characters for an identifier,
- A to Z
- a to z
- 0 to 9
- _ (underscore)
- - (hypen)
"""
if not isinstance(identifier, basestring):
return False
if len(identifier) > 100 or len(identifier) < 1:
return False
condensed_form = set(list(identifier.lower()))
return condensed_form.issubset(VALID_IDENTIFIER_SET)
def is_valid_interval(interval):
"""Checks if the given interval is valid. A valid interval
is always a positive, non-zero integer value.
"""
if not isinstance(interval, (int, long)):
return False
if interval <= 0:
return False
return True
def is_valid_requeue_limit(requeue_limit):
"""Checks if the given requeue limit is valid.
A valid requeue limit is always greater than
or equal to -1.
"""
if not isinstance(requeue_limit, (int, long)):
return False
if requeue_limit <= -2:
return False
return True
def serialize_payload(payload):
"""Tries to serialize the payload using msgpack. If it is
not serializable, raises a TypeError.
"""
return msgpack.packb(payload)
def deserialize_payload(payload):
"""Tries to deserialize the payload using msgpack.
"""
return msgpack.unpackb(payload)
def generate_epoch():
"""Generates an unix epoch in ms.
"""
return int(time.time() * 1000)
| [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
2,
15069,
357,
66,
8,
1946,
1345,
23593,
4816,
13,
4091,
38559,
24290,
13,
14116,
329,
3307,
13,
198,
11748,
640,
198,
11748,
31456,
8002,
198,
198,
23428,
2389,
62,
25256,
5064,
38311,
62,
28480,
796,
900,
7,
4868,
10786,
39305,
4299,
456,
2926,
41582,
10295,
404,
80,
81,
301,
14795,
86,
5431,
89,
486,
1954,
2231,
3134,
4531,
62,
19355,
4008,
628,
198,
4299,
318,
62,
12102,
62,
738,
7483,
7,
738,
7483,
2599,
198,
220,
220,
220,
37227,
7376,
4657,
611,
262,
1813,
27421,
318,
4938,
393,
407,
13,
317,
4938,
198,
220,
220,
220,
27421,
743,
10874,
286,
262,
1708,
3435,
351,
257,
198,
220,
220,
220,
5415,
4129,
286,
1802,
3435,
11,
5288,
286,
352,
2095,
13,
628,
220,
220,
220,
48951,
3435,
329,
281,
27421,
11,
198,
220,
220,
220,
220,
220,
220,
220,
532,
317,
284,
1168,
198,
220,
220,
220,
220,
220,
220,
220,
532,
257,
284,
1976,
198,
220,
220,
220,
220,
220,
220,
220,
532,
657,
284,
860,
198,
220,
220,
220,
220,
220,
220,
220,
532,
4808,
357,
41116,
7295,
8,
198,
220,
220,
220,
220,
220,
220,
220,
532,
532,
357,
12114,
3617,
8,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
611,
407,
318,
39098,
7,
738,
7483,
11,
1615,
395,
1806,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
10352,
628,
220,
220,
220,
611,
18896,
7,
738,
7483,
8,
1875,
1802,
393,
18896,
7,
738,
7483,
8,
1279,
352,
25,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
10352,
628,
220,
220,
220,
38784,
62,
687,
796,
900,
7,
4868,
7,
738,
7483,
13,
21037,
3419,
4008,
198,
220,
220,
220,
1441,
38784,
62,
687,
13,
747,
549,
2617,
7,
23428,
2389,
62,
25256,
5064,
38311,
62,
28480,
8,
628,
198,
4299,
318,
62,
12102,
62,
3849,
2100,
7,
3849,
2100,
2599,
198,
220,
220,
220,
37227,
7376,
4657,
611,
262,
1813,
16654,
318,
4938,
13,
317,
4938,
16654,
198,
220,
220,
220,
318,
1464,
257,
3967,
11,
1729,
12,
22570,
18253,
1988,
13,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
611,
407,
318,
39098,
7,
3849,
2100,
11,
357,
600,
11,
890,
8,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
10352,
628,
220,
220,
220,
611,
16654,
19841,
657,
25,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
10352,
628,
220,
220,
220,
1441,
6407,
628,
198,
4299,
318,
62,
12102,
62,
260,
36560,
62,
32374,
7,
260,
36560,
62,
32374,
2599,
198,
220,
220,
220,
37227,
7376,
4657,
611,
262,
1813,
1038,
68,
518,
4179,
318,
4938,
13,
198,
220,
220,
220,
317,
4938,
1038,
68,
518,
4179,
318,
1464,
3744,
621,
198,
220,
220,
220,
393,
4961,
284,
532,
16,
13,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
611,
407,
318,
39098,
7,
260,
36560,
62,
32374,
11,
357,
600,
11,
890,
8,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
10352,
628,
220,
220,
220,
611,
1038,
68,
518,
62,
32374,
19841,
532,
17,
25,
198,
220,
220,
220,
220,
220,
220,
220,
1441,
10352,
628,
220,
220,
220,
1441,
6407,
628,
198,
4299,
11389,
1096,
62,
15577,
2220,
7,
15577,
2220,
2599,
198,
220,
220,
220,
37227,
51,
1678,
284,
11389,
1096,
262,
21437,
1262,
31456,
8002,
13,
1002,
340,
318,
198,
220,
220,
220,
407,
11389,
13821,
11,
12073,
257,
5994,
12331,
13,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
1441,
31456,
8002,
13,
8002,
65,
7,
15577,
2220,
8,
628,
198,
4299,
748,
48499,
1096,
62,
15577,
2220,
7,
15577,
2220,
2599,
198,
220,
220,
220,
37227,
51,
1678,
284,
748,
48499,
1096,
262,
21437,
1262,
31456,
8002,
13,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
1441,
31456,
8002,
13,
403,
8002,
65,
7,
15577,
2220,
8,
628,
198,
4299,
7716,
62,
538,
5374,
33529,
198,
220,
220,
220,
37227,
8645,
689,
281,
555,
844,
36835,
287,
13845,
13,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
1441,
493,
7,
2435,
13,
2435,
3419,
1635,
8576,
8,
198
] | 2.643064 | 692 |
import copy
import generators
import math
import neighbor_states as ns
import numpy as np
import plotter
import random as rand
n = 200
iterations = 500000
temperature = 1000
decay_rate = 0.99995
swap_type = "consecutive"
low = 0
high = 1
distribution = "uniform"
first_path, best_path, distances_plot_data, temperatures_plot_data = travelling_salesman_problem(n, iterations, temperature, decay_rate, swap_type, low, high, distribution)
plotter.plot_data(first_path, best_path, distances_plot_data, temperatures_plot_data)
| [
11748,
4866,
198,
11748,
27298,
198,
11748,
10688,
198,
11748,
4780,
62,
27219,
355,
36545,
198,
11748,
299,
32152,
355,
45941,
198,
11748,
7110,
353,
198,
11748,
4738,
355,
43720,
628,
628,
198,
198,
77,
796,
939,
198,
2676,
602,
796,
5323,
830,
198,
11498,
21069,
796,
8576,
198,
12501,
323,
62,
4873,
796,
657,
13,
24214,
20,
198,
2032,
499,
62,
4906,
796,
366,
1102,
4552,
425,
1,
198,
9319,
796,
657,
198,
8929,
796,
352,
198,
17080,
3890,
796,
366,
403,
6933,
1,
198,
198,
11085,
62,
6978,
11,
1266,
62,
6978,
11,
18868,
62,
29487,
62,
7890,
11,
10101,
62,
29487,
62,
7890,
796,
16574,
62,
82,
2040,
805,
62,
45573,
7,
77,
11,
34820,
11,
5951,
11,
22119,
62,
4873,
11,
16075,
62,
4906,
11,
1877,
11,
1029,
11,
6082,
8,
198,
198,
29487,
353,
13,
29487,
62,
7890,
7,
11085,
62,
6978,
11,
1266,
62,
6978,
11,
18868,
62,
29487,
62,
7890,
11,
10101,
62,
29487,
62,
7890,
8,
198
] | 3.206061 | 165 |
import gym
from gym import spaces
import torch
import torch.nn as nn
from matplotlib import pyplot as plt
import pandas as pd
import numpy as np
from xitorch.interpolate import Interp1D
from tqdm.auto import tqdm, trange
import time
from rcmodel.room import Room
from rcmodel.building import Building
from rcmodel.RCModel import RCModel
from rcmodel.tools import InputScaling
from rcmodel.tools import BuildingTemperatureDataset
class LSIEnv(gym.Env):
"""Custom Environment that follows gym interface"""
metadata = {'render.modes': ['human']}
# action
# (observation, reward, done, info)
# self.state, reward, done, {}
if __name__ == '__main__':
path_sorted = '/Users/benfourcin/OneDrive - University of Exeter/PhD/LSI/Data/210813data_sorted.csv'
time_data = torch.tensor(pd.read_csv(path_sorted, skiprows=0).iloc[:, 1], dtype=torch.float64)
temp_data = torch.tensor(pd.read_csv(path_sorted, skiprows=0).iloc[:, 2:].to_numpy(dtype=np.float32),
dtype=torch.float32)
######
path = '/Users/benfourcin/OneDrive - University of Exeter/PhD/LSI/Data/DummyData/'
dt = 30 # timestep (seconds), data and the model are sampled at this frequency
sample_size = int(5 * (60 ** 2 * 24) / dt) # one day of data
training_data = BuildingTemperatureDataset(path + 'train5d.csv', sample_size)
train_dataloader = torch.utils.data.DataLoader(training_data, batch_size=1, shuffle=False)
######
time_data = time_data[0:100]
temp_data = temp_data[0:100, :]
policy = PolicyNetwork(7, 2)
RC, Tout_continuous = initialise_model(policy)
env = LSIEnv(RC, time_data)
reinforce = Reinforce(env, time_data, temp_data, alpha=1e-2)
num_episodes = 10
step_size = 24*60**2 / 30 # timesteps in 1 day
start_time = time.time()
plot_total_rewards, plot_ER = reinforce.train(num_episodes, step_size)
print(f'fin, duration: {(time.time() - start_time) / 60:.1f} minutes')
fig, axs = plt.subplots(1, 2, figsize=(10, 7),)
axs[0].plot(torch.stack(plot_ER).detach().numpy(), label='expected rewards')
axs[0].legend()
axs[1].plot(torch.stack(plot_total_rewards).detach().numpy(), label='total rewards')
axs[1].legend()
plt.savefig('Rewards.png')
plt.show()
| [
11748,
11550,
198,
6738,
11550,
1330,
9029,
198,
198,
11748,
28034,
198,
11748,
28034,
13,
20471,
355,
299,
77,
198,
6738,
2603,
29487,
8019,
1330,
12972,
29487,
355,
458,
83,
198,
11748,
19798,
292,
355,
279,
67,
198,
11748,
299,
32152,
355,
45941,
198,
6738,
2124,
2072,
354,
13,
3849,
16104,
378,
1330,
4225,
79,
16,
35,
198,
6738,
256,
80,
36020,
13,
23736,
1330,
256,
80,
36020,
11,
491,
858,
198,
11748,
640,
198,
198,
6738,
48321,
19849,
13,
3823,
1330,
10096,
198,
6738,
48321,
19849,
13,
16894,
1330,
11819,
198,
6738,
48321,
19849,
13,
7397,
17633,
1330,
13987,
17633,
198,
6738,
48321,
19849,
13,
31391,
1330,
23412,
3351,
4272,
198,
6738,
48321,
19849,
13,
31391,
1330,
11819,
42492,
27354,
292,
316,
628,
628,
198,
4871,
406,
11584,
4834,
85,
7,
1360,
76,
13,
4834,
85,
2599,
198,
220,
220,
220,
37227,
15022,
9344,
326,
5679,
11550,
7071,
37811,
198,
220,
220,
220,
20150,
796,
1391,
6,
13287,
13,
76,
4147,
10354,
37250,
10734,
20520,
92,
628,
220,
220,
220,
1303,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2223,
628,
220,
220,
220,
1303,
220,
220,
220,
220,
220,
220,
220,
220,
220,
357,
672,
3168,
341,
11,
6721,
11,
1760,
11,
7508,
8,
198,
220,
220,
220,
1303,
2116,
13,
5219,
11,
6721,
11,
1760,
11,
23884,
198,
198,
361,
11593,
3672,
834,
6624,
705,
834,
12417,
834,
10354,
628,
198,
220,
220,
220,
3108,
62,
82,
9741,
796,
31051,
14490,
14,
11722,
14337,
17879,
14,
3198,
24825,
532,
2059,
286,
1475,
2357,
14,
2725,
35,
14,
6561,
40,
14,
6601,
14,
17,
15711,
1485,
7890,
62,
82,
9741,
13,
40664,
6,
198,
220,
220,
220,
640,
62,
7890,
796,
28034,
13,
83,
22854,
7,
30094,
13,
961,
62,
40664,
7,
6978,
62,
82,
9741,
11,
14267,
8516,
28,
15,
737,
346,
420,
58,
45299,
352,
4357,
288,
4906,
28,
13165,
354,
13,
22468,
2414,
8,
198,
220,
220,
220,
20218,
62,
7890,
796,
28034,
13,
83,
22854,
7,
30094,
13,
961,
62,
40664,
7,
6978,
62,
82,
9741,
11,
14267,
8516,
28,
15,
737,
346,
420,
58,
45299,
362,
25,
4083,
1462,
62,
77,
32152,
7,
67,
4906,
28,
37659,
13,
22468,
2624,
828,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
288,
4906,
28,
13165,
354,
13,
22468,
2624,
8,
628,
220,
220,
220,
46424,
2,
198,
220,
220,
220,
3108,
796,
31051,
14490,
14,
11722,
14337,
17879,
14,
3198,
24825,
532,
2059,
286,
1475,
2357,
14,
2725,
35,
14,
6561,
40,
14,
6601,
14,
35,
13513,
6601,
14,
6,
198,
220,
220,
220,
288,
83,
796,
1542,
220,
1303,
4628,
395,
538,
357,
43012,
828,
1366,
290,
262,
2746,
389,
35846,
379,
428,
8373,
198,
220,
220,
220,
6291,
62,
7857,
796,
493,
7,
20,
1635,
357,
1899,
12429,
362,
1635,
1987,
8,
1220,
288,
83,
8,
220,
1303,
530,
1110,
286,
1366,
628,
220,
220,
220,
3047,
62,
7890,
796,
11819,
42492,
27354,
292,
316,
7,
6978,
1343,
705,
27432,
20,
67,
13,
40664,
3256,
6291,
62,
7857,
8,
198,
220,
220,
220,
4512,
62,
67,
10254,
1170,
263,
796,
28034,
13,
26791,
13,
7890,
13,
6601,
17401,
7,
34409,
62,
7890,
11,
15458,
62,
7857,
28,
16,
11,
36273,
28,
25101,
8,
198,
220,
220,
220,
46424,
2,
628,
628,
198,
220,
220,
220,
640,
62,
7890,
796,
640,
62,
7890,
58,
15,
25,
3064,
60,
198,
220,
220,
220,
20218,
62,
7890,
796,
20218,
62,
7890,
58,
15,
25,
3064,
11,
1058,
60,
628,
220,
220,
220,
2450,
796,
7820,
26245,
7,
22,
11,
362,
8,
198,
220,
220,
220,
13987,
11,
309,
448,
62,
18487,
5623,
796,
4238,
786,
62,
19849,
7,
30586,
8,
198,
220,
220,
220,
17365,
796,
406,
11584,
4834,
85,
7,
7397,
11,
640,
62,
7890,
8,
198,
220,
220,
220,
19594,
796,
22299,
3174,
7,
24330,
11,
640,
62,
7890,
11,
20218,
62,
7890,
11,
17130,
28,
16,
68,
12,
17,
8,
628,
220,
220,
220,
997,
62,
538,
8052,
796,
838,
198,
220,
220,
220,
2239,
62,
7857,
796,
1987,
9,
1899,
1174,
17,
1220,
1542,
220,
1303,
4628,
395,
25386,
287,
352,
1110,
198,
220,
220,
220,
923,
62,
2435,
796,
640,
13,
2435,
3419,
198,
220,
220,
220,
7110,
62,
23350,
62,
260,
2017,
11,
7110,
62,
1137,
796,
19594,
13,
27432,
7,
22510,
62,
538,
8052,
11,
2239,
62,
7857,
8,
628,
220,
220,
220,
3601,
7,
69,
6,
15643,
11,
9478,
25,
1391,
7,
2435,
13,
2435,
3419,
532,
923,
62,
2435,
8,
1220,
3126,
25,
13,
16,
69,
92,
2431,
11537,
628,
220,
220,
220,
2336,
11,
7877,
82,
796,
458,
83,
13,
7266,
489,
1747,
7,
16,
11,
362,
11,
2336,
7857,
16193,
940,
11,
767,
828,
8,
198,
220,
220,
220,
7877,
82,
58,
15,
4083,
29487,
7,
13165,
354,
13,
25558,
7,
29487,
62,
1137,
737,
15255,
620,
22446,
77,
32152,
22784,
6167,
11639,
40319,
11530,
11537,
198,
220,
220,
220,
7877,
82,
58,
15,
4083,
1455,
437,
3419,
628,
220,
220,
220,
7877,
82,
58,
16,
4083,
29487,
7,
13165,
354,
13,
25558,
7,
29487,
62,
23350,
62,
260,
2017,
737,
15255,
620,
22446,
77,
32152,
22784,
6167,
11639,
23350,
11530,
11537,
198,
220,
220,
220,
7877,
82,
58,
16,
4083,
1455,
437,
3419,
628,
220,
220,
220,
458,
83,
13,
21928,
5647,
10786,
30003,
1371,
13,
11134,
11537,
198,
220,
220,
220,
458,
83,
13,
12860,
3419,
628
] | 2.487152 | 934 |
import sys
from WidgetManager import WidgetManager
from Dashboard import Dashboard
from asciimatics.screen import Screen
from asciimatics.exceptions import ResizeScreenError
"""
The application is initialized using an asciimatics wrapper
"""
widgetmanager = WidgetManager()
last_scene = None
while True:
try:
Screen.wrapper(app, catch_interrupt=True, arguments=[last_scene])
sys.exit(0)
except ResizeScreenError as e:
pass
last_scene = e.scene
| [
11748,
25064,
201,
198,
201,
198,
6738,
370,
17484,
13511,
1330,
370,
17484,
13511,
201,
198,
6738,
16189,
3526,
1330,
16189,
3526,
201,
198,
201,
198,
6738,
355,
979,
320,
23372,
13,
9612,
1330,
15216,
201,
198,
6738,
355,
979,
320,
23372,
13,
1069,
11755,
1330,
1874,
1096,
23901,
12331,
201,
198,
201,
198,
201,
198,
37811,
201,
198,
464,
3586,
318,
23224,
1262,
281,
355,
979,
320,
23372,
29908,
201,
198,
37811,
201,
198,
201,
198,
201,
198,
201,
198,
42655,
37153,
796,
370,
17484,
13511,
3419,
201,
198,
12957,
62,
29734,
796,
6045,
201,
198,
4514,
6407,
25,
201,
198,
220,
220,
220,
1949,
25,
201,
198,
220,
220,
220,
220,
220,
220,
220,
15216,
13,
48553,
7,
1324,
11,
4929,
62,
3849,
3622,
28,
17821,
11,
7159,
41888,
12957,
62,
29734,
12962,
201,
198,
220,
220,
220,
220,
220,
220,
220,
25064,
13,
37023,
7,
15,
8,
201,
198,
220,
220,
220,
2845,
1874,
1096,
23901,
12331,
355,
304,
25,
201,
198,
220,
220,
220,
220,
220,
220,
220,
1208,
201,
198,
220,
220,
220,
220,
220,
220,
220,
938,
62,
29734,
796,
304,
13,
29734,
201,
198
] | 2.696335 | 191 |
@jit | [
31,
45051
] | 2 | 2 |
import pyxel
import math
# ablak szélessége, magassága, címe
pyxel.init(255,255, caption="Hello")
# Mit csináljunk egy képkocka előtt
# Hogyan rajzolunk ki egy-egy képkockát
# Elindítjuk
pyxel.run(update, draw) | [
11748,
12972,
87,
417,
198,
11748,
10688,
198,
2,
46624,
461,
264,
89,
2634,
1203,
2634,
469,
11,
2153,
562,
6557,
4908,
11,
269,
8836,
1326,
198,
9078,
87,
417,
13,
15003,
7,
13381,
11,
13381,
11,
8305,
2625,
15496,
4943,
198,
198,
2,
11707,
269,
31369,
6557,
75,
73,
2954,
304,
1360,
479,
2634,
79,
74,
735,
64,
1288,
129,
239,
926,
198,
198,
2,
22411,
4121,
374,
1228,
89,
349,
2954,
47748,
304,
1360,
12,
68,
1360,
479,
2634,
79,
74,
735,
6557,
83,
198,
220,
220,
220,
220,
198,
2,
2574,
521,
8836,
83,
73,
2724,
198,
9078,
87,
417,
13,
5143,
7,
19119,
11,
3197,
8
] | 1.972727 | 110 |
from rest_framework import serializers
from crisiscleanup.calls.models import Gateway
from crisiscleanup.calls.models import Language
| [
6738,
1334,
62,
30604,
1330,
11389,
11341,
198,
198,
6738,
4442,
2304,
13087,
929,
13,
66,
5691,
13,
27530,
1330,
29916,
198,
6738,
4442,
2304,
13087,
929,
13,
66,
5691,
13,
27530,
1330,
15417,
198
] | 3.857143 | 35 |
from contextlib import contextmanager
from sqlalchemy import create_engine
from sqlalchemy.orm import sessionmaker
from ..config import settings
__engine = create_engine(settings.DATABASE)
__session_maker = sessionmaker(bind=__engine)
@contextmanager
| [
6738,
4732,
8019,
1330,
4732,
37153,
198,
198,
6738,
44161,
282,
26599,
1330,
2251,
62,
18392,
198,
6738,
44161,
282,
26599,
13,
579,
1330,
6246,
10297,
198,
198,
6738,
11485,
11250,
1330,
6460,
198,
198,
834,
18392,
796,
2251,
62,
18392,
7,
33692,
13,
35,
1404,
6242,
11159,
8,
198,
834,
29891,
62,
10297,
796,
6246,
10297,
7,
21653,
28,
834,
18392,
8,
628,
198,
198,
31,
22866,
37153,
198
] | 3.671429 | 70 |
import re
| [
11748,
302,
201,
198,
220,
220,
220,
220
] | 1.875 | 8 |
from csv import DictReader
from cd4ml.filenames import file_names
| [
6738,
269,
21370,
1330,
360,
713,
33634,
198,
6738,
22927,
19,
4029,
13,
10379,
268,
1047,
1330,
2393,
62,
14933,
628
] | 3.190476 | 21 |
from django.urls import path
from .views import PriorityListView, PriorityDetailView
urlpatterns = (
path('', PriorityListView.as_view(), name='priority-list'),
path('<str:priority>', PriorityDetailView.as_view(), name='priority-detail'),
) | [
6738,
42625,
14208,
13,
6371,
82,
1330,
3108,
198,
6738,
764,
33571,
1330,
34416,
8053,
7680,
11,
34416,
11242,
603,
7680,
198,
198,
6371,
33279,
82,
796,
357,
198,
220,
220,
220,
3108,
10786,
3256,
34416,
8053,
7680,
13,
292,
62,
1177,
22784,
1438,
11639,
49336,
12,
4868,
33809,
198,
220,
220,
220,
3108,
10786,
27,
2536,
25,
49336,
29,
3256,
34416,
11242,
603,
7680,
13,
292,
62,
1177,
22784,
1438,
11639,
49336,
12,
49170,
33809,
198,
8
] | 3.192308 | 78 |
# Configuration file for the Sphinx documentation builder.
#
# This file only contains a selection of the most common options. For a full
# list see the documentation:
# https://www.sphinx-doc.org/en/master/usage/configuration.html
# -- Path setup --------------------------------------------------------------
# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
# documentation root, use os.path.abspath to make it absolute, like shown here.
#
import os
import sys
from typing import List
sys.path.insert(0, os.path.abspath("../../src/"))
on_rtd = os.environ.get("READTHEDOCS") == "True"
# -- Project information -----------------------------------------------------
project = "redgrease"
copyright = "2021, Lyngon Pte. Ltd."
author = "Anders Åström"
version = "0.1" # can this be dynamic somehow?
# -- General configuration ---------------------------------------------------
autoclass_content = "both"
# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions: List[str] = [
"sphinx.ext.napoleon",
"sphinx.ext.autodoc",
"sphinx.ext.viewcode",
"sphinx_tabs.tabs",
# "sphinxcontrib.osexample",
]
# ["recommonmark"]
# Add any paths that contain templates here, relative to this directory.
templates_path = ["_templates"]
# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
# This pattern also affects html_static_path and html_extra_path.
exclude_patterns: List[str] = []
# -- Options for HTML output -------------------------------------------------
# pygments_style = "fruity"
# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
#
html_theme = "sphinx_rtd_theme"
html_theme_options = {
# 'analytics_id': 'UA-XXXXXXX-1', # Provided by Google in your dashboard
# "analytics_anonymize_ip": True,
"display_version": True,
"prev_next_buttons_location": "both",
"style_external_links": True,
# "style_nav_header_background": "#7a0c00",
}
html_logo = "../images/redgrease_icon_02.png"
html_favicon = "../images/LyngonIcon_v3.ico"
# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ["_static"]
# custom.css is inside one of the html_static_path folders (e.g. _static)
html_css_files = ["custom.css"]
ml_css_files = [] # type: List[str]
# def setup(app):
# app.add_stylesheet("custom.css")
| [
2,
28373,
2393,
329,
262,
45368,
28413,
10314,
27098,
13,
198,
2,
198,
2,
770,
2393,
691,
4909,
257,
6356,
286,
262,
749,
2219,
3689,
13,
1114,
257,
1336,
198,
2,
1351,
766,
262,
10314,
25,
198,
2,
3740,
1378,
2503,
13,
82,
746,
28413,
12,
15390,
13,
2398,
14,
268,
14,
9866,
14,
26060,
14,
11250,
3924,
13,
6494,
198,
198,
2,
1377,
10644,
9058,
20368,
1783,
26171,
198,
198,
2,
1002,
18366,
357,
273,
13103,
284,
3188,
351,
1960,
375,
420,
8,
389,
287,
1194,
8619,
11,
198,
2,
751,
777,
29196,
284,
25064,
13,
6978,
994,
13,
1002,
262,
8619,
318,
3585,
284,
262,
198,
2,
10314,
6808,
11,
779,
28686,
13,
6978,
13,
397,
2777,
776,
284,
787,
340,
4112,
11,
588,
3402,
994,
13,
198,
2,
198,
11748,
28686,
198,
11748,
25064,
198,
6738,
19720,
1330,
7343,
198,
198,
17597,
13,
6978,
13,
28463,
7,
15,
11,
28686,
13,
6978,
13,
397,
2777,
776,
7203,
40720,
40720,
10677,
30487,
4008,
198,
198,
261,
62,
81,
8671,
796,
28686,
13,
268,
2268,
13,
1136,
7203,
15675,
4221,
1961,
4503,
50,
4943,
6624,
366,
17821,
1,
198,
198,
2,
1377,
4935,
1321,
20368,
19351,
12,
198,
198,
16302,
796,
366,
445,
16694,
589,
1,
198,
22163,
4766,
796,
366,
1238,
2481,
11,
9334,
782,
261,
350,
660,
13,
12052,
526,
198,
9800,
796,
366,
1870,
364,
6184,
227,
2536,
9101,
76,
1,
198,
9641,
796,
366,
15,
13,
16,
1,
220,
1303,
460,
428,
307,
8925,
7599,
30,
628,
198,
2,
1377,
3611,
8398,
20368,
1783,
6329,
198,
2306,
420,
31172,
62,
11299,
796,
366,
16885,
1,
198,
198,
2,
3060,
597,
45368,
28413,
7552,
8265,
3891,
994,
11,
355,
13042,
13,
1119,
460,
307,
198,
2,
18366,
2406,
351,
45368,
28413,
357,
13190,
705,
82,
746,
28413,
13,
2302,
15885,
11537,
393,
534,
2183,
198,
2,
3392,
13,
198,
2302,
5736,
25,
7343,
58,
2536,
60,
796,
685,
198,
220,
220,
220,
366,
82,
746,
28413,
13,
2302,
13,
77,
499,
25637,
1600,
198,
220,
220,
220,
366,
82,
746,
28413,
13,
2302,
13,
2306,
375,
420,
1600,
198,
220,
220,
220,
366,
82,
746,
28413,
13,
2302,
13,
1177,
8189,
1600,
198,
220,
220,
220,
366,
82,
746,
28413,
62,
8658,
82,
13,
8658,
82,
1600,
198,
220,
220,
220,
1303,
220,
220,
220,
366,
82,
746,
28413,
3642,
822,
13,
577,
87,
1403,
1600,
198,
60,
198,
2,
14631,
260,
11321,
4102,
8973,
198,
198,
2,
3060,
597,
13532,
326,
3994,
24019,
994,
11,
3585,
284,
428,
8619,
13,
198,
11498,
17041,
62,
6978,
796,
14631,
62,
11498,
17041,
8973,
198,
198,
2,
7343,
286,
7572,
11,
3585,
284,
2723,
8619,
11,
326,
2872,
3696,
290,
198,
2,
29196,
284,
8856,
618,
2045,
329,
2723,
3696,
13,
198,
2,
770,
3912,
635,
10975,
27711,
62,
12708,
62,
6978,
290,
27711,
62,
26086,
62,
6978,
13,
198,
1069,
9152,
62,
33279,
82,
25,
7343,
58,
2536,
60,
796,
17635,
628,
198,
2,
1377,
18634,
329,
11532,
5072,
20368,
1783,
12,
198,
198,
2,
12972,
11726,
62,
7635,
796,
366,
69,
622,
414,
1,
198,
198,
2,
383,
7505,
284,
779,
329,
11532,
290,
11532,
10478,
5468,
13,
220,
4091,
262,
10314,
329,
198,
2,
257,
1351,
286,
3170,
259,
13460,
13,
198,
2,
198,
6494,
62,
43810,
796,
366,
82,
746,
28413,
62,
81,
8671,
62,
43810,
1,
198,
6494,
62,
43810,
62,
25811,
796,
1391,
198,
220,
220,
220,
1303,
705,
38200,
14094,
62,
312,
10354,
705,
34970,
12,
24376,
43145,
12,
16,
3256,
220,
1303,
220,
29750,
416,
3012,
287,
534,
30415,
198,
220,
220,
220,
1303,
366,
38200,
14094,
62,
272,
5177,
1096,
62,
541,
1298,
6407,
11,
198,
220,
220,
220,
366,
13812,
62,
9641,
1298,
6407,
11,
198,
220,
220,
220,
366,
47050,
62,
19545,
62,
4360,
27288,
62,
24886,
1298,
366,
16885,
1600,
198,
220,
220,
220,
366,
7635,
62,
22615,
62,
28751,
1298,
6407,
11,
198,
220,
220,
220,
1303,
366,
7635,
62,
28341,
62,
25677,
62,
25249,
1298,
25113,
22,
64,
15,
66,
405,
1600,
198,
92,
198,
198,
6494,
62,
6404,
78,
796,
366,
40720,
17566,
14,
445,
16694,
589,
62,
4749,
62,
2999,
13,
11134,
1,
198,
6494,
62,
69,
615,
4749,
796,
366,
40720,
17566,
14,
31633,
782,
261,
19578,
62,
85,
18,
13,
3713,
1,
628,
198,
2,
3060,
597,
13532,
326,
3994,
2183,
9037,
3696,
357,
10508,
355,
3918,
15747,
8,
994,
11,
198,
2,
3585,
284,
428,
8619,
13,
1119,
389,
18984,
706,
262,
3170,
259,
9037,
3696,
11,
198,
2,
523,
257,
2393,
3706,
366,
12286,
13,
25471,
1,
481,
49312,
262,
3170,
259,
366,
12286,
13,
25471,
1911,
198,
6494,
62,
12708,
62,
6978,
796,
14631,
62,
12708,
8973,
198,
2,
2183,
13,
25471,
318,
2641,
530,
286,
262,
27711,
62,
12708,
62,
6978,
24512,
357,
68,
13,
70,
13,
4808,
12708,
8,
198,
6494,
62,
25471,
62,
16624,
796,
14631,
23144,
13,
25471,
8973,
198,
198,
4029,
62,
25471,
62,
16624,
796,
17635,
220,
1303,
2099,
25,
7343,
58,
2536,
60,
628,
198,
2,
825,
9058,
7,
1324,
2599,
198,
2,
220,
220,
220,
220,
598,
13,
2860,
62,
47720,
25473,
7203,
23144,
13,
25471,
4943,
198
] | 3.210587 | 869 |
CHOICES = ["A", "C", "G", "T"] | [
44899,
34444,
796,
14631,
32,
1600,
366,
34,
1600,
366,
38,
1600,
366,
51,
8973
] | 2 | 15 |
"""
[17-08-21] Challenge #328 [Easy] Latin Squares
https://www.reddit.com/r/dailyprogrammer/comments/6v29zk/170821_challenge_328_easy_latin_squares/
#**Description**
A [Latin square](https://en.wikipedia.org/wiki/Latin_square) is an n × n array filled with n different symbols, each
occurring exactly once in each row and exactly once in each column.
For example:
>1
And,
>1 2
>2 1
Another one,
>1 2 3
>3 1 2
>2 3 1
In this challenge, you have to check whether a given array is a Latin square.
#**Input Description**
Let the user enter the length of the array followed by *n x n* numbers. Fill an array from left to right starting from
above.
#**Output Description**
If it is a Latin square, then display true. Else, display false.
#**Challenge Input**
> 5
> 1 2 3 4 5 5 1 2 3 4 4 5 1 2 3 3 4 5 1 2 2 3 4 5 1
> 2
> 1 3 3 4
> 4
> 1 2 3 4 1 3 2 4 2 3 4 1 4 3 2 1
#**Challenge Output**
> true
> false
> false
---------
#**Bonus**
A Latin square is said to be reduced if both its first row and its first column are in their natural order.
You can reduce a Latin square by reordering the rows and columns. The example in the description can be reduced to this
>1 2 3
>2 3 1
>3 1 2
If a given array turns out to be a Latin square, then your program should reduce it and display it.
Edit: /u/tomekanco has pointed out that many solutions which have an error. I shall look into this. Meanwhile, I have
added an extra challenge input-output for you to check.
"""
if __name__ == "__main__":
main()
| [
37811,
198,
58,
1558,
12,
2919,
12,
2481,
60,
13879,
1303,
34256,
685,
28406,
60,
9133,
5056,
3565,
198,
198,
5450,
1378,
2503,
13,
10748,
13,
785,
14,
81,
14,
29468,
23065,
647,
14,
15944,
14,
21,
85,
1959,
89,
74,
14,
1558,
2919,
2481,
62,
36747,
3540,
62,
34256,
62,
38171,
62,
75,
10680,
62,
16485,
3565,
14,
198,
198,
2,
1174,
11828,
1174,
198,
32,
685,
49022,
6616,
16151,
5450,
1378,
268,
13,
31266,
13,
2398,
14,
15466,
14,
49022,
62,
23415,
8,
1849,
271,
281,
1849,
77,
1849,
12906,
1849,
77,
1849,
18747,
5901,
351,
1849,
77,
1849,
39799,
14354,
11,
1123,
198,
13966,
14924,
3446,
1752,
287,
1123,
5752,
290,
3446,
1752,
287,
1123,
5721,
13,
198,
1890,
1672,
25,
198,
29,
16,
198,
1870,
11,
198,
29,
16,
362,
198,
29,
17,
352,
198,
6610,
530,
11,
220,
198,
29,
16,
362,
513,
220,
198,
29,
18,
352,
362,
198,
29,
17,
513,
352,
198,
818,
428,
4427,
11,
345,
423,
284,
2198,
1771,
257,
1813,
7177,
318,
257,
9133,
6616,
13,
220,
198,
2,
1174,
20560,
12489,
1174,
198,
5756,
262,
2836,
3802,
262,
4129,
286,
262,
7177,
3940,
416,
1635,
77,
2124,
299,
9,
3146,
13,
27845,
281,
7177,
422,
1364,
284,
826,
3599,
422,
198,
29370,
13,
220,
198,
2,
1174,
26410,
12489,
1174,
198,
1532,
340,
318,
257,
9133,
6616,
11,
788,
3359,
2081,
13,
25974,
11,
3359,
3991,
13,
220,
198,
2,
1174,
41812,
3540,
23412,
1174,
198,
29,
642,
220,
198,
29,
352,
362,
513,
604,
642,
642,
352,
362,
513,
604,
604,
642,
352,
362,
513,
513,
604,
642,
352,
362,
362,
513,
604,
642,
352,
198,
29,
362,
198,
29,
352,
513,
513,
604,
198,
29,
604,
198,
29,
352,
362,
513,
604,
352,
513,
362,
604,
362,
513,
604,
352,
604,
513,
362,
352,
220,
198,
2,
1174,
41812,
3540,
25235,
1174,
198,
29,
220,
2081,
198,
29,
3991,
198,
29,
3991,
220,
198,
45537,
198,
2,
1174,
29435,
1174,
198,
32,
9133,
6616,
318,
531,
284,
307,
1849,
445,
19513,
611,
1111,
663,
717,
5752,
290,
663,
717,
5721,
389,
287,
511,
3288,
1502,
13,
198,
1639,
460,
4646,
257,
9133,
6616,
416,
302,
34555,
262,
15274,
290,
15180,
13,
383,
1672,
287,
262,
6764,
460,
307,
5322,
284,
428,
198,
29,
16,
362,
513,
198,
29,
17,
513,
352,
198,
29,
18,
352,
362,
198,
1532,
257,
1813,
7177,
4962,
503,
284,
307,
257,
9133,
6616,
11,
788,
534,
1430,
815,
4646,
340,
290,
3359,
340,
13,
220,
198,
18378,
25,
1220,
84,
14,
83,
462,
27541,
1073,
468,
6235,
503,
326,
867,
8136,
543,
423,
281,
4049,
13,
314,
2236,
804,
656,
428,
13,
11214,
11,
314,
423,
198,
29373,
281,
3131,
4427,
5128,
12,
22915,
329,
345,
284,
2198,
13,
220,
198,
37811,
628,
198,
198,
361,
11593,
3672,
834,
6624,
366,
834,
12417,
834,
1298,
198,
220,
220,
220,
1388,
3419,
198
] | 3.071283 | 491 |
from qore import *
from libs.menu import Menu
from libs.monitor import Monitor
from libs.agents import Agents
from libs.header import AppHeader
from libs.health import Health
AutomicTerminal.run(title="Automic", log="textual.log")
| [
6738,
10662,
382,
1330,
1635,
201,
198,
6738,
9195,
82,
13,
26272,
1330,
21860,
201,
198,
6738,
9195,
82,
13,
41143,
1330,
18289,
201,
198,
6738,
9195,
82,
13,
49638,
1330,
28295,
201,
198,
6738,
9195,
82,
13,
25677,
1330,
2034,
39681,
201,
198,
6738,
9195,
82,
13,
13948,
1330,
3893,
201,
198,
201,
198,
16541,
10179,
44798,
282,
13,
5143,
7,
7839,
2625,
16541,
10179,
1600,
2604,
2625,
5239,
723,
13,
6404,
4943,
201,
198
] | 3.157895 | 76 |
# -*- coding: utf-8 -*-
# @Time : 2021-04-26 7:52 p.m.
# @Author : young wang
# @FileName: quality.py
# @Software: PyCharm
import numpy as np
from skimage.filters import gaussian
from scipy.ndimage import median_filter
from misc.processing import imag2uint
def ROI(x, y, width, height,s):
'''obtain the ROI from the standard layout [330x512]
parameters
----------
s has the standard dimension [330x512]
y is defined as the axial direction: 330
x is defined as the lateral direction: 512
height refers the increment in the axial direction > 0
width refers the increment in the lateral direction > 0
'''
# fetch ROI
if height > 0 and width > 0:
if (x >= 0) and (y >= 0) and (x + width <= s.shape[1]) and (y + height <= s.shape[0]):
roi = s[y:y + height, x:x + width]
return roi
def SF(s):
'''obtain the sparsity fraction from given region of interest
parameters
----------
i_{mn} represents the matrix of pixel intensities at
each location \left(m,n\right) in an N by M image patch,
where im,n0 is the l_0 norm of i_{mn}, i.e.,
the number of nonzero elements
'''
return (1 - np.count_nonzero(s) / s.size)
def SNR(roi_h,roi_b):
'''compute the SNR of a given homogenous region
SNR = 10*log10(uh/σb)
Improving ultrasound images with
elevational angular compounding based on
acoustic refraction
https://doi.org/10.1038/s41598-020-75092-8
parameters
----------
roi_h: array_like
homogeneous region
roi_b: array_like
background region
'''
mean_h = np.mean(roi_h)
std_b = np.std(roi_b)
with np.errstate(divide='ignore'):
snr = 10*np.log10(mean_h/ std_b)
return snr
def CNR(roi_h,roi_a):
'''compute the CNR between homogeneous and region free of
structure
CNR = 10*log((|uh-ub|/σb)
Reference:
Improving ultrasound images with
elevational angular compounding based on
acoustic refraction
https://doi.org/10.1038/s41598-020-75092-8
parameters
----------
roi_h: array_like
homogeneous region
roi_a: array_like
region free of structure
'''
h_mean = np.mean(roi_h)
a_mean = np.mean(roi_a)
a_std = np.std(roi_a)
with np.errstate(divide='ignore'):
cnr = abs(h_mean - a_mean) / a_std
return 10*np.log10(cnr)
| [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
2,
2488,
7575,
220,
220,
220,
1058,
33448,
12,
3023,
12,
2075,
767,
25,
4309,
279,
13,
76,
13,
198,
2,
2488,
13838,
220,
1058,
1862,
266,
648,
198,
2,
2488,
8979,
5376,
25,
3081,
13,
9078,
198,
2,
2488,
25423,
25,
9485,
1925,
1670,
198,
198,
11748,
299,
32152,
355,
45941,
198,
6738,
1341,
9060,
13,
10379,
1010,
1330,
31986,
31562,
198,
6738,
629,
541,
88,
13,
358,
9060,
1330,
14288,
62,
24455,
198,
6738,
12747,
13,
36948,
1330,
3590,
17,
28611,
628,
198,
4299,
15107,
40,
7,
87,
11,
331,
11,
9647,
11,
6001,
11,
82,
2599,
198,
220,
220,
220,
705,
7061,
672,
3153,
262,
15107,
40,
422,
262,
3210,
12461,
685,
26073,
87,
25836,
60,
628,
220,
220,
220,
10007,
198,
220,
220,
220,
24200,
438,
198,
220,
220,
220,
264,
468,
262,
3210,
15793,
685,
26073,
87,
25836,
60,
198,
220,
220,
220,
331,
318,
5447,
355,
262,
7877,
498,
4571,
25,
25508,
198,
220,
220,
220,
2124,
318,
5447,
355,
262,
25653,
4571,
25,
22243,
198,
220,
220,
220,
6001,
10229,
262,
18703,
287,
262,
7877,
498,
4571,
1875,
657,
198,
220,
220,
220,
9647,
10229,
262,
18703,
287,
262,
25653,
4571,
1875,
657,
198,
220,
220,
220,
705,
7061,
198,
220,
220,
220,
1303,
21207,
15107,
40,
198,
220,
220,
220,
611,
6001,
1875,
657,
290,
9647,
1875,
657,
25,
198,
220,
220,
220,
220,
220,
220,
220,
611,
357,
87,
18189,
657,
8,
290,
357,
88,
18189,
657,
8,
290,
357,
87,
1343,
9647,
19841,
264,
13,
43358,
58,
16,
12962,
290,
357,
88,
1343,
6001,
19841,
264,
13,
43358,
58,
15,
60,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
686,
72,
796,
264,
58,
88,
25,
88,
1343,
6001,
11,
2124,
25,
87,
1343,
9647,
60,
198,
220,
220,
220,
1441,
686,
72,
198,
198,
4299,
14362,
7,
82,
2599,
198,
220,
220,
220,
705,
7061,
672,
3153,
262,
599,
45826,
13390,
422,
1813,
3814,
286,
1393,
628,
220,
220,
220,
10007,
198,
220,
220,
220,
24200,
438,
198,
220,
220,
220,
1312,
23330,
10295,
92,
6870,
262,
17593,
286,
17465,
17509,
871,
379,
198,
220,
220,
220,
1123,
4067,
3467,
9464,
7,
76,
11,
77,
59,
3506,
8,
287,
281,
399,
416,
337,
2939,
8529,
11,
198,
220,
220,
220,
810,
545,
11,
77,
15,
318,
262,
300,
62,
15,
2593,
286,
1312,
23330,
10295,
5512,
1312,
13,
68,
1539,
198,
220,
220,
220,
262,
1271,
286,
1729,
22570,
4847,
198,
220,
220,
220,
705,
7061,
628,
220,
220,
220,
1441,
357,
16,
532,
45941,
13,
9127,
62,
13159,
22570,
7,
82,
8,
1220,
264,
13,
7857,
8,
198,
198,
4299,
11346,
49,
7,
305,
72,
62,
71,
11,
305,
72,
62,
65,
2599,
628,
220,
220,
220,
705,
7061,
5589,
1133,
262,
11346,
49,
286,
257,
1813,
3488,
27897,
3814,
628,
220,
220,
220,
11346,
49,
796,
838,
9,
6404,
940,
7,
7456,
14,
38392,
65,
8,
628,
220,
220,
220,
12205,
1075,
37721,
4263,
351,
198,
220,
220,
220,
7662,
864,
32558,
552,
9969,
1912,
319,
198,
220,
220,
220,
26071,
1006,
7861,
198,
220,
220,
220,
3740,
1378,
34023,
13,
2398,
14,
940,
13,
940,
2548,
14,
82,
35038,
4089,
12,
33618,
12,
15426,
5892,
12,
23,
628,
220,
220,
220,
10007,
198,
220,
220,
220,
24200,
438,
198,
220,
220,
220,
686,
72,
62,
71,
25,
7177,
62,
2339,
198,
220,
220,
220,
3488,
32269,
3814,
628,
220,
220,
220,
686,
72,
62,
65,
25,
7177,
62,
2339,
198,
220,
220,
220,
4469,
3814,
628,
220,
220,
220,
705,
7061,
628,
220,
220,
220,
1612,
62,
71,
796,
45941,
13,
32604,
7,
305,
72,
62,
71,
8,
198,
220,
220,
220,
14367,
62,
65,
796,
45941,
13,
19282,
7,
305,
72,
62,
65,
8,
628,
220,
220,
220,
351,
45941,
13,
8056,
5219,
7,
7146,
485,
11639,
46430,
6,
2599,
628,
220,
220,
220,
220,
220,
220,
220,
3013,
81,
796,
838,
9,
37659,
13,
6404,
940,
7,
32604,
62,
71,
14,
14367,
62,
65,
8,
628,
220,
220,
220,
1441,
3013,
81,
198,
198,
4299,
327,
24723,
7,
305,
72,
62,
71,
11,
305,
72,
62,
64,
2599,
628,
220,
220,
220,
705,
7061,
5589,
1133,
262,
327,
24723,
1022,
3488,
32269,
290,
3814,
1479,
286,
198,
220,
220,
220,
4645,
628,
220,
220,
220,
327,
24723,
796,
838,
9,
6404,
19510,
91,
7456,
12,
549,
91,
14,
38392,
65,
8,
628,
220,
220,
220,
20984,
25,
198,
220,
220,
220,
12205,
1075,
37721,
4263,
351,
198,
220,
220,
220,
7662,
864,
32558,
552,
9969,
1912,
319,
198,
220,
220,
220,
26071,
1006,
7861,
198,
220,
220,
220,
3740,
1378,
34023,
13,
2398,
14,
940,
13,
940,
2548,
14,
82,
35038,
4089,
12,
33618,
12,
15426,
5892,
12,
23,
628,
198,
220,
220,
220,
10007,
198,
220,
220,
220,
24200,
438,
198,
220,
220,
220,
686,
72,
62,
71,
25,
7177,
62,
2339,
198,
220,
220,
220,
3488,
32269,
3814,
198,
220,
220,
220,
686,
72,
62,
64,
25,
7177,
62,
2339,
198,
220,
220,
220,
3814,
1479,
286,
4645,
198,
220,
220,
220,
705,
7061,
628,
220,
220,
220,
289,
62,
32604,
796,
45941,
13,
32604,
7,
305,
72,
62,
71,
8,
198,
220,
220,
220,
257,
62,
32604,
796,
45941,
13,
32604,
7,
305,
72,
62,
64,
8,
628,
220,
220,
220,
257,
62,
19282,
796,
45941,
13,
19282,
7,
305,
72,
62,
64,
8,
628,
220,
220,
220,
351,
45941,
13,
8056,
5219,
7,
7146,
485,
11639,
46430,
6,
2599,
628,
220,
220,
220,
220,
220,
220,
220,
269,
48624,
796,
2352,
7,
71,
62,
32604,
532,
257,
62,
32604,
8,
1220,
257,
62,
19282,
628,
220,
220,
220,
1441,
838,
9,
37659,
13,
6404,
940,
7,
31522,
81,
8,
628,
220,
220,
220,
220,
628
] | 2.436992 | 984 |
import requests
import sqlite3
conn = sqlite3.connect('twitter_resources.db', check_same_thread=False)
c = conn.cursor()
| [
11748,
7007,
198,
11748,
44161,
578,
18,
198,
198,
37043,
796,
44161,
578,
18,
13,
8443,
10786,
6956,
62,
37540,
13,
9945,
3256,
2198,
62,
31642,
62,
16663,
28,
25101,
8,
198,
66,
796,
48260,
13,
66,
21471,
3419,
628,
628,
198
] | 3 | 42 |
import csv
from copy import copy, deepcopy
import pytest
from hypothesis import given
from hypothesis.extra.pandas import data_frames, column
from canvasxpress.data.matrix import CXCSVData
from tests.util.hypothesis_support import everything_except
csv_sample = """
"C1","C2","C3"
1,2,3
4,5,6
"""
@given(
data_frames([column('A', dtype=int), column('B', dtype=int)])
)
@given(everything_except(dict, str))
@given(everything_except(dict, str))
| [
11748,
269,
21370,
198,
6738,
4866,
1330,
4866,
11,
2769,
30073,
198,
198,
11748,
12972,
9288,
198,
6738,
14078,
1330,
1813,
198,
6738,
14078,
13,
26086,
13,
79,
392,
292,
1330,
1366,
62,
37805,
11,
5721,
198,
198,
6738,
21978,
87,
8439,
13,
7890,
13,
6759,
8609,
1330,
327,
55,
7902,
53,
6601,
198,
6738,
5254,
13,
22602,
13,
36362,
313,
8497,
62,
11284,
1330,
2279,
62,
16341,
198,
198,
40664,
62,
39873,
796,
37227,
198,
1,
34,
16,
2430,
34,
17,
2430,
34,
18,
1,
198,
16,
11,
17,
11,
18,
198,
19,
11,
20,
11,
21,
198,
37811,
628,
198,
31,
35569,
7,
198,
220,
220,
220,
1366,
62,
37805,
26933,
28665,
10786,
32,
3256,
288,
4906,
28,
600,
828,
5721,
10786,
33,
3256,
288,
4906,
28,
600,
8,
12962,
198,
8,
628,
198,
31,
35569,
7,
37814,
62,
16341,
7,
11600,
11,
965,
4008,
628,
198,
31,
35569,
7,
37814,
62,
16341,
7,
11600,
11,
965,
4008,
628,
628,
628
] | 2.828221 | 163 |
from .edges import make_edges
| [
6738,
764,
276,
3212,
1330,
787,
62,
276,
3212,
198
] | 3 | 10 |
from nose.tools import assert_equal
| [
6738,
9686,
13,
31391,
1330,
6818,
62,
40496,
198
] | 4 | 9 |
import ctypes.util
from .ffi_build import ffi
def _dlopen(generated_ffi, *names):
"""Try various names for the same library, for different platforms."""
for name in names:
for lib_name in (name, 'lib' + name):
try:
path = ctypes.util.find_library(lib_name)
lib = generated_ffi.dlopen(path or lib_name)
if lib:
return lib
except OSError:
pass
raise OSError("dlopen() failed to load a library: %s" % ' / '.join(names))
pango = _dlopen(ffi, 'pango', 'pango-1', 'pango-1.0', 'pango-1.0-0')
gobject = _dlopen(ffi, 'gobject-2.0', 'gobject-2.0-0')
# Imports are normally always put at the top of the file.
# But the wrapper API requires that the pango library be loaded first.
# Therefore, we have to disable linting rules for these lines.
from .version import * # noqa
from .enums import * # noqa
from .convert import * # noqa
from .font_description import FontDescription # noqa
from .rectangle import Rectangle # noqa
from .item import Item # noqa
from .context import Context # noqa
from .glyph_item import GlyphItem # noqa
from .glyph_item_iter import GlyphItemIter # noqa
from .layout_run import LayoutRun # noqa
from .layout_iter import LayoutIter # noqa
from .layout import Layout # noqa
| [
11748,
269,
19199,
13,
22602,
198,
6738,
764,
487,
72,
62,
11249,
1330,
277,
12463,
628,
198,
4299,
4808,
25404,
9654,
7,
27568,
62,
487,
72,
11,
1635,
14933,
2599,
198,
220,
220,
220,
37227,
23433,
2972,
3891,
329,
262,
976,
5888,
11,
329,
1180,
9554,
526,
15931,
198,
220,
220,
220,
329,
1438,
287,
3891,
25,
198,
220,
220,
220,
220,
220,
220,
220,
329,
9195,
62,
3672,
287,
357,
3672,
11,
705,
8019,
6,
1343,
1438,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1949,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3108,
796,
269,
19199,
13,
22602,
13,
19796,
62,
32016,
7,
8019,
62,
3672,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
9195,
796,
7560,
62,
487,
72,
13,
25404,
9654,
7,
6978,
393,
9195,
62,
3672,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
611,
9195,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1441,
9195,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2845,
440,
5188,
81,
1472,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1208,
198,
220,
220,
220,
5298,
440,
5188,
81,
1472,
7203,
25404,
9654,
3419,
4054,
284,
3440,
257,
5888,
25,
4064,
82,
1,
4064,
705,
1220,
45302,
22179,
7,
14933,
4008,
628,
198,
79,
14208,
796,
4808,
25404,
9654,
7,
487,
72,
11,
705,
79,
14208,
3256,
705,
79,
14208,
12,
16,
3256,
705,
79,
14208,
12,
16,
13,
15,
3256,
705,
79,
14208,
12,
16,
13,
15,
12,
15,
11537,
198,
70,
15252,
796,
4808,
25404,
9654,
7,
487,
72,
11,
705,
70,
15252,
12,
17,
13,
15,
3256,
705,
70,
15252,
12,
17,
13,
15,
12,
15,
11537,
628,
198,
2,
1846,
3742,
389,
7685,
1464,
1234,
379,
262,
1353,
286,
262,
2393,
13,
198,
2,
887,
262,
29908,
7824,
4433,
326,
262,
279,
14208,
5888,
307,
9639,
717,
13,
198,
2,
8447,
11,
356,
423,
284,
15560,
300,
600,
278,
3173,
329,
777,
3951,
13,
198,
6738,
764,
9641,
1330,
1635,
220,
1303,
645,
20402,
198,
6738,
764,
268,
5700,
1330,
1635,
220,
1303,
645,
20402,
198,
6738,
764,
1102,
1851,
1330,
1635,
220,
1303,
645,
20402,
198,
6738,
764,
10331,
62,
11213,
1330,
24060,
11828,
220,
1303,
645,
20402,
198,
6738,
764,
2554,
9248,
1330,
48599,
9248,
220,
1303,
645,
20402,
198,
6738,
764,
9186,
1330,
9097,
220,
1303,
645,
20402,
198,
6738,
764,
22866,
1330,
30532,
220,
1303,
645,
20402,
198,
6738,
764,
10853,
746,
62,
9186,
1330,
27949,
746,
7449,
220,
1303,
645,
20402,
198,
6738,
764,
10853,
746,
62,
9186,
62,
2676,
1330,
27949,
746,
7449,
29993,
220,
1303,
645,
20402,
198,
6738,
764,
39786,
62,
5143,
1330,
47639,
10987,
220,
1303,
645,
20402,
198,
6738,
764,
39786,
62,
2676,
1330,
47639,
29993,
220,
1303,
645,
20402,
198,
6738,
764,
39786,
1330,
47639,
220,
1303,
645,
20402,
198
] | 2.538023 | 526 |
# -*- coding: utf-8 -*-
import os
from datetime import datetime
from src.utils.filemeta import get_filename
from src.loader.converter import Converter
from src.utils.logging import logger
| [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
198,
11748,
28686,
198,
6738,
4818,
8079,
1330,
4818,
8079,
198,
198,
6738,
12351,
13,
26791,
13,
7753,
28961,
1330,
651,
62,
34345,
198,
198,
6738,
12351,
13,
29356,
13,
1102,
332,
353,
1330,
35602,
353,
198,
6738,
12351,
13,
26791,
13,
6404,
2667,
1330,
49706,
198
] | 3.131148 | 61 |
import os
import json
import glob
# test_name = 'time_solve_r_essentials_r_base_conda_forge'
test_name = 'time_solve_anaconda_44'
for f in glob.glob("*.json"):
with open(f) as fd:
d = json.load(fd)
if f != 'machine.json' and d:
# timeval = ((d.get('results', {}) or {}).get(test_name, {}) or {}).get('result', [0])[0]
# if timeval < 1.0 and f != "machine.json":
# print("remove {}".format(f))
# os.remove(f)
if 'params' in d:
if 'conda-env' not in d['params']:
d['params']['conda-env'] = ""
d['requirements']['conda-env'] = ""
elif d['params']['conda-env'] == []:
d['params']['conda-env'] = ""
d['requirements']['conda-env'] = ""
else:
d['params'] = {'conda-env': ""}
d['requirements']['conda-env'] = ""
if "chardet-mock" in d['env_name']:
d['env_name'] = d['env_name'].replace("chardet-mock", 'chardet-conda-env-mock')
f = f.replace("chardet-mock", 'chardet-conda-env-mock')
with open(f, 'w') as fd:
json.dump(d, fd, indent=2)
else:
print("file {} appears corrupt".format(f))
| [
11748,
28686,
198,
11748,
33918,
198,
11748,
15095,
198,
198,
2,
1332,
62,
3672,
796,
705,
2435,
62,
82,
6442,
62,
81,
62,
408,
14817,
62,
81,
62,
8692,
62,
66,
13533,
62,
30293,
6,
198,
9288,
62,
3672,
796,
705,
2435,
62,
82,
6442,
62,
272,
330,
13533,
62,
2598,
6,
198,
198,
1640,
277,
287,
15095,
13,
4743,
672,
7203,
24620,
17752,
1,
2599,
198,
220,
220,
220,
351,
1280,
7,
69,
8,
355,
277,
67,
25,
198,
220,
220,
220,
220,
220,
220,
220,
288,
796,
33918,
13,
2220,
7,
16344,
8,
198,
220,
220,
220,
611,
277,
14512,
705,
30243,
13,
17752,
6,
290,
288,
25,
198,
220,
220,
220,
220,
220,
220,
220,
1303,
640,
2100,
796,
14808,
67,
13,
1136,
10786,
43420,
3256,
23884,
8,
393,
23884,
737,
1136,
7,
9288,
62,
3672,
11,
23884,
8,
393,
23884,
737,
1136,
10786,
20274,
3256,
685,
15,
12962,
58,
15,
60,
198,
220,
220,
220,
220,
220,
220,
220,
1303,
611,
640,
2100,
1279,
352,
13,
15,
290,
277,
14512,
366,
30243,
13,
17752,
1298,
198,
220,
220,
220,
220,
220,
220,
220,
1303,
220,
220,
220,
220,
3601,
7203,
28956,
23884,
1911,
18982,
7,
69,
4008,
198,
220,
220,
220,
220,
220,
220,
220,
1303,
220,
220,
220,
220,
28686,
13,
28956,
7,
69,
8,
198,
220,
220,
220,
220,
220,
220,
220,
611,
705,
37266,
6,
287,
288,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
611,
705,
66,
13533,
12,
24330,
6,
407,
287,
288,
17816,
37266,
6,
5974,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
288,
17816,
37266,
6,
7131,
6,
66,
13533,
12,
24330,
20520,
796,
13538,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
288,
17816,
8897,
18883,
6,
7131,
6,
66,
13533,
12,
24330,
20520,
796,
13538,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1288,
361,
288,
17816,
37266,
6,
7131,
6,
66,
13533,
12,
24330,
20520,
6624,
685,
5974,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
288,
17816,
37266,
6,
7131,
6,
66,
13533,
12,
24330,
20520,
796,
13538,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
288,
17816,
8897,
18883,
6,
7131,
6,
66,
13533,
12,
24330,
20520,
796,
13538,
198,
220,
220,
220,
220,
220,
220,
220,
2073,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
288,
17816,
37266,
20520,
796,
1391,
6,
66,
13533,
12,
24330,
10354,
13538,
92,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
288,
17816,
8897,
18883,
6,
7131,
6,
66,
13533,
12,
24330,
20520,
796,
13538,
198,
220,
220,
220,
220,
220,
220,
220,
611,
366,
30215,
316,
12,
76,
735,
1,
287,
288,
17816,
24330,
62,
3672,
6,
5974,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
288,
17816,
24330,
62,
3672,
20520,
796,
288,
17816,
24330,
62,
3672,
6,
4083,
33491,
7203,
30215,
316,
12,
76,
735,
1600,
705,
30215,
316,
12,
66,
13533,
12,
24330,
12,
76,
735,
11537,
198,
220,
220,
220,
220,
220,
220,
220,
277,
796,
277,
13,
33491,
7203,
30215,
316,
12,
76,
735,
1600,
705,
30215,
316,
12,
66,
13533,
12,
24330,
12,
76,
735,
11537,
198,
220,
220,
220,
220,
220,
220,
220,
351,
1280,
7,
69,
11,
705,
86,
11537,
355,
277,
67,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
33918,
13,
39455,
7,
67,
11,
277,
67,
11,
33793,
28,
17,
8,
198,
220,
220,
220,
2073,
25,
198,
220,
220,
220,
220,
220,
220,
220,
3601,
7203,
7753,
23884,
3568,
10622,
1911,
18982,
7,
69,
4008,
198
] | 1.904984 | 642 |
import asyncio as _asyncio
from typing import Callable as _Callable
from . import database as _database
from .chat_log import PssChatLogger as _PssChatLogger
from .reaction_role import ReactionRole as _ReactionRole
from .reaction_role import ReactionRoleChange as _ReactionRoleChange
from .reaction_role import ReactionRoleRequirement as _ReactionRoleRequirement
from .. import utils as _utils
# ---------- Initialization ----------
# ---------- DB Schema ----------
# ---------- Helper -----------
# ---------- Testing ----------
if __name__ == '__main__':
_asyncio.get_event_loop().run_until_complete(test()) | [
11748,
30351,
952,
355,
4808,
292,
13361,
952,
198,
6738,
19720,
1330,
4889,
540,
355,
4808,
14134,
540,
198,
198,
6738,
764,
1330,
6831,
355,
4808,
48806,
198,
6738,
764,
17006,
62,
6404,
1330,
350,
824,
30820,
11187,
1362,
355,
4808,
47,
824,
30820,
11187,
1362,
198,
6738,
764,
260,
2673,
62,
18090,
1330,
39912,
47445,
355,
4808,
3041,
2673,
47445,
198,
6738,
764,
260,
2673,
62,
18090,
1330,
39912,
47445,
19400,
355,
4808,
3041,
2673,
47445,
19400,
198,
6738,
764,
260,
2673,
62,
18090,
1330,
39912,
47445,
16844,
24615,
355,
4808,
3041,
2673,
47445,
16844,
24615,
198,
6738,
11485,
1330,
3384,
4487,
355,
4808,
26791,
628,
198,
2,
24200,
438,
20768,
1634,
24200,
438,
628,
628,
198,
198,
2,
24200,
438,
20137,
10011,
2611,
24200,
438,
628,
628,
628,
628,
198,
198,
2,
24200,
438,
5053,
525,
24200,
6329,
628,
628,
198,
198,
2,
24200,
438,
23983,
24200,
438,
628,
198,
361,
11593,
3672,
834,
6624,
705,
834,
12417,
834,
10354,
198,
220,
220,
220,
4808,
292,
13361,
952,
13,
1136,
62,
15596,
62,
26268,
22446,
5143,
62,
28446,
62,
20751,
7,
9288,
28955
] | 3.448649 | 185 |
from button_logic import ButtonLogic
from fake_hw import FakeHardware
from hardware import Hardware, is_pi
from internet_checker import InternetChecker
from paper_status import PaperStatus
from recording import Recording
from tg import Telegram
import os
if __name__ == '__main__':
main() | [
6738,
4936,
62,
6404,
291,
1330,
20969,
11187,
291,
198,
6738,
8390,
62,
36599,
1330,
33482,
49865,
198,
6738,
6890,
1330,
28715,
11,
318,
62,
14415,
198,
6738,
5230,
62,
9122,
263,
1330,
4455,
9787,
263,
198,
6738,
3348,
62,
13376,
1330,
14962,
19580,
198,
6738,
8296,
1330,
43905,
198,
6738,
256,
70,
1330,
50203,
198,
11748,
28686,
628,
198,
361,
11593,
3672,
834,
6624,
705,
834,
12417,
834,
10354,
198,
220,
220,
220,
1388,
3419
] | 3.868421 | 76 |
#Import Modules
import pygame as pg
from pygame import gfxdraw
from math import *
from random import randint
from time import sleep
from glob import glob
import easygui
import types
#Custom Modules
from sceneFile import scene,world,player
import guibuttons
import shapes
pg.init() #Initialize pygame
VERSION = "Beta 0.4" # Version
textFont = "font/opensans.ttf" # set default font
w = 800 # Screen size
h = 600
translate = (w/2,h/2)
d = pg.display.set_mode((w,h)) # Initialize the display
pg.display.set_caption("Ivy3d v " + VERSION)
pg.display.set_icon(pg.image.load("favicon.png"))
running = True
#Projects 3d Point To 2d Point
#Multiplies two vectors
#Adds two vectors
#Rotates vector by another vector
# Calculates the normals for three vectors
# Gets the average of a list of vectors
# Rendering function takes in scene as a list of dictionaries (see example in sceneFile.py)
#Gets collision for physics
# Calculates all of the physics
# Return a text surface
# Display text
# Class for dealing with buttons
meshes = shapes.meshes # Get meshes from shapes.py
keys = [] # List of keys and if they are pressed
for i in range(0,1024):
keys.append(False)
a = 0
sim = False
sel = 0
buff = ""
mouse = {
"x":0,
"y":0,
"pressed":False
} # Mouse dictionary with x position, y position, and if the mouse is pressed
while running: # Loop while program is running
for e in pg.event.get(): # Get all events
if e.type == pg.QUIT: # if program is closed, stop running
running = False
if e.type == pg.MOUSEMOTION: # Get mouse motion
ms = pg.mouse.get_pos()
mouse["x"] = ms[0]
mouse["y"] = ms[1]
if e.type == pg.MOUSEBUTTONDOWN: # Get mouse button
mouse["pressed"] = True
if e.type == pg.MOUSEBUTTONUP:
mouse["pressed"] = False
if e.type == pg.KEYDOWN: # Get keydown
keys[e.key] = True
if(e.key == pg.K_p):
if(not(sim)):
buff = str(scene)
else:
scene = eval(buff)
sim = not(sim)
if e.type == pg.KEYUP:
keys[e.key] = False
# Clear screen
d.fill(world["background"])
if sim: # Simulate
scene = simulate(scene,world,keys)
render(scene) #Render
if(not(sim)):
pos = scene[sel]["position"]
pg.draw.line(d,(255,0,0),project(pos),project( (pos[0]+25,pos[1],pos[2]) ) ,4) #Draw axies at position
pg.draw.line(d,(0,255,0),project(pos),project( (pos[0] ,pos[1]+25,pos[2]) ) ,4)
pg.draw.line(d,(0,0,255),project(pos),project( (pos[0] ,pos[1],pos[2]+25) ) ,4)
guiEvents = gui(mouse["x"],mouse["y"],mouse["pressed"],scene[sel],sel) #Get all button
if(guiEvents[0]["pressed"]):
sel+=1
if(sel > len(scene)-1):
sel = 0
sleep(0.1)
if(guiEvents[1]["pressed"]):
scene[sel]["shape"]+=1
if(scene[sel]["shape"] > len(shapes.meshes)-1):
scene[sel]["shape"] = 0
sleep(0.1)
name = "position"
if(guiEvents[2]["pressed"]):
pos = scene[sel][name]
scene[sel][name] = (pos[0]-4,pos[1],pos[2])
if(guiEvents[3]["pressed"]):
pos = scene[sel][name]
scene[sel][name] = (pos[0]+4,pos[1],pos[2])
if(guiEvents[4]["pressed"]):
pos = scene[sel][name]
scene[sel][name] = (pos[0],pos[1]-4,pos[2])
if(guiEvents[5]["pressed"]):
pos = scene[sel][name]
scene[sel][name] = (pos[0],pos[1]+4,pos[2])
if(guiEvents[6]["pressed"]):
pos = scene[sel][name]
scene[sel][name] = (pos[0],pos[1],pos[2]-4)
if(guiEvents[7]["pressed"]):
pos = scene[sel][name]
scene[sel][name] = (pos[0],pos[1],pos[2]+4)
name = "scale"
if(guiEvents[8]["pressed"]):
pos = scene[sel][name]
scene[sel][name] = (pos[0]-4,pos[1],pos[2])
if(guiEvents[9]["pressed"]):
pos = scene[sel][name]
scene[sel][name] = (pos[0]+4,pos[1],pos[2])
if(guiEvents[10]["pressed"]):
pos = scene[sel][name]
scene[sel][name] = (pos[0],pos[1]-4,pos[2])
if(guiEvents[11]["pressed"]):
pos = scene[sel][name]
scene[sel][name] = (pos[0],pos[1]+4,pos[2])
if(guiEvents[12]["pressed"]):
pos = scene[sel][name]
scene[sel][name] = (pos[0],pos[1],pos[2]-4)
if(guiEvents[13]["pressed"]):
pos = scene[sel][name]
scene[sel][name] = (pos[0],pos[1],pos[2]+4)
if(guiEvents[14]["pressed"]):
pos = scene[sel]["material"]["color"]
scene[sel]["material"]["color"] = (pos[0]-4,pos[1],pos[2])
if(guiEvents[15]["pressed"]):
pos = scene[sel]["material"]["color"]
scene[sel]["material"]["color"] = (pos[0]+4,pos[1],pos[2])
if(guiEvents[16]["pressed"]):
pos = scene[sel]["material"]["color"]
scene[sel]["material"]["color"] = (pos[0],pos[1]-4,pos[2])
if(guiEvents[17]["pressed"]):
pos = scene[sel]["material"]["color"]
scene[sel]["material"]["color"] = (pos[0],pos[1]+4,pos[2])
if(guiEvents[18]["pressed"]):
pos = scene[sel]["material"]["color"]
scene[sel]["material"]["color"] = (pos[0],pos[1],pos[2]-4)
if(guiEvents[19]["pressed"]):
pos = scene[sel]["material"]["color"]
scene[sel]["material"]["color"] = (pos[0],pos[1],pos[2]+4)
if(guiEvents[20]["pressed"]):
scene[sel]["physics"]["rigidBody"] = not(scene[sel]["physics"]["rigidBody"])
sleep(0.1)
if(guiEvents[21]["pressed"]):
scene[sel]["physics"]["control"] = not(scene[sel]["physics"]["control"])
sleep(0.1)
if(guiEvents[22]["pressed"]):
scene[sel]["physics"]["bounce"]-= 0.01
if(guiEvents[23]["pressed"]):
scene[sel]["physics"]["bounce"]+= 0.01
if(guiEvents[24]["pressed"]):
scene[sel]["physics"]["friction"]-= 0.01
if(guiEvents[25]["pressed"]):
scene[sel]["physics"]["friction"]+= 0.01
if(guiEvents[26]["pressed"]):
inText = easygui.fileopenbox(default="maps/",filetypes=["*.png","*.jpg","*.jpeg","*.gif","*.*"])
if type(inText) == type(" "):
scene[sel]["material"]["map"] = inText
else:
scene[sel]["material"]["map"] = "none"
if(guiEvents[27]["pressed"]):
aaa = {
"shape":0,
"position":(0,0,0),
"scale":(25,25,25),
"rotation":(0,0,0),
"material":{
"wire":False,
"color":(200,63,63),
"map":"none"
},
"physics": {
"rigidBody":False,
"velocity":(0,0,0),
"friction":0.05,
"bounce":0,
"control":False
}
}
scene.append(aaa)
sel = len(scene)-1
sleep(0.1)
if(guiEvents[28]["pressed"]):
if(sel != 0):
scene.pop(sel)
sel = 0
print("Removed Mesh.")
else:
easygui.msgbox(msg="Cannot Remove Mesh",title="Error:")
sleep(0.1)
if(guiEvents[29]["pressed"]):
d.fill(world["background"])
render(scene)
# antialias()
pg.image.save(d,easygui.filesavebox(filetypes=["*.png","*.jpg","*.*"]))
easygui.msgbox(msg="Rendered And Exported",title="Success!")
sleep(0.1)
if(guiEvents[30]["pressed"]):
buff = str(scene)
try:
numFrames = int(easygui.enterbox("How Many Frames?"))
except:
easygui.msgbox(msg="Number Must Be A Valid Integer",title="Error:")
numFrames = 0
for i in range(numFrames):
scene = simulate(scene,world,keys)
d.fill(world["background"])
render(scene)
pg.display.update()
pg.image.save(d,"output/" + str(i) + ".png")
print("Done " +str(i) + "/" + str(numFrames))
scene = eval(buff)
if(guiEvents[31]["pressed"]):
scene[sel]["material"]["wire"] = not(scene[sel]["material"]["wire"])
sleep(0.1)
if(guiEvents[32]["pressed"]):
try:
f = open(easygui.fileopenbox(default="scenes/",filetypes=["*.ivy","*.*"]),"r")
buff = str(scene)
try:
scene = eval(f.read())
except:
easygui.msgbox(msg="Invalid Input File",title="Error:")
scene = eval(buff)
f.close()
except:
print("Blank File")
if(guiEvents[33]["pressed"]):
try:
f = open(easygui.filesavebox(default="scenes/",filetypes=["*.ivy","*.*"]),"w")
f.write(str(scene))
f.close()
except:
print("Blank File")
if(guiEvents[36]["pressed"]):
rt = scene[sel]["rotation"]
rt = (rt[0],rt[1]-0.1)
scene[sel]["rotation"] = rt
if(guiEvents[37]["pressed"]):
rt = scene[sel]["rotation"]
rt = (rt[0],rt[1]+0.1)
scene[sel]["rotation"] = rt
if(guiEvents[34]["pressed"]):
rt = scene[sel]["rotation"]
rt = (rt[0]-0.1,rt[1])
scene[sel]["rotation"] = rt
if(guiEvents[35]["pressed"]):
rt = scene[sel]["rotation"]
rt = (rt[0]+0.1,rt[1])
scene[sel]["rotation"] = rt
clr = scene[sel]["material"]["color"]
r = clr[0]
g = clr[1]
b = clr[2]
r = max(min(r,255),0)
g = max(min(g,255),0)
b = max(min(b,255),0)
scene[sel]["material"]["color"] = (r,g,b)
pg.display.update()
| [
2,
20939,
3401,
5028,
198,
11748,
12972,
6057,
355,
23241,
198,
6738,
12972,
6057,
1330,
308,
21373,
19334,
198,
6738,
10688,
1330,
1635,
198,
6738,
4738,
1330,
43720,
600,
198,
6738,
640,
1330,
3993,
198,
6738,
15095,
1330,
15095,
198,
11748,
2562,
48317,
198,
11748,
3858,
198,
2,
15022,
3401,
5028,
198,
6738,
3715,
8979,
1330,
3715,
11,
6894,
11,
7829,
198,
11748,
915,
571,
15318,
684,
198,
11748,
15268,
628,
198,
6024,
13,
15003,
3419,
1303,
24243,
1096,
12972,
6057,
198,
198,
43717,
796,
366,
43303,
657,
13,
19,
1,
1303,
10628,
198,
198,
5239,
23252,
796,
366,
10331,
14,
44813,
504,
13,
926,
69,
1,
1303,
900,
4277,
10369,
198,
198,
86,
796,
10460,
1303,
15216,
2546,
198,
71,
796,
10053,
198,
7645,
17660,
796,
357,
86,
14,
17,
11,
71,
14,
17,
8,
628,
628,
198,
67,
796,
23241,
13,
13812,
13,
2617,
62,
14171,
19510,
86,
11,
71,
4008,
1303,
20768,
1096,
262,
3359,
198,
6024,
13,
13812,
13,
2617,
62,
6888,
1159,
7203,
40,
7670,
18,
67,
410,
366,
1343,
44156,
2849,
8,
198,
6024,
13,
13812,
13,
2617,
62,
4749,
7,
6024,
13,
9060,
13,
2220,
7203,
69,
615,
4749,
13,
11134,
48774,
198,
198,
20270,
796,
6407,
198,
198,
2,
16775,
82,
513,
67,
6252,
1675,
362,
67,
6252,
628,
198,
2,
15205,
24705,
444,
734,
30104,
628,
198,
2,
46245,
734,
30104,
628,
198,
2,
24864,
689,
15879,
416,
1194,
15879,
628,
198,
198,
2,
27131,
689,
262,
2593,
874,
329,
1115,
30104,
628,
198,
2,
29620,
262,
2811,
286,
257,
1351,
286,
30104,
628,
628,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
198,
2,
28703,
1586,
2163,
2753,
287,
3715,
355,
257,
1351,
286,
48589,
3166,
357,
3826,
1672,
287,
3715,
8979,
13,
9078,
8,
628,
220,
220,
220,
220,
220,
220,
220,
220,
198,
220,
220,
220,
220,
198,
220,
220,
220,
220,
628,
198,
220,
220,
220,
220,
628,
198,
198,
2,
38,
1039,
17661,
329,
11887,
628,
198,
198,
2,
27131,
689,
477,
286,
262,
11887,
628,
628,
198,
2,
8229,
257,
2420,
4417,
198,
198,
2,
16531,
2420,
628,
198,
2,
5016,
329,
7219,
351,
12163,
628,
220,
220,
220,
220,
220,
220,
220,
220,
628,
220,
220,
220,
220,
198,
220,
220,
220,
220,
198,
198,
6880,
956,
796,
15268,
13,
6880,
956,
1303,
3497,
48754,
422,
15268,
13,
9078,
628,
198,
13083,
796,
17635,
1303,
7343,
286,
8251,
290,
611,
484,
389,
12070,
198,
1640,
1312,
287,
2837,
7,
15,
11,
35500,
2599,
198,
220,
220,
220,
8251,
13,
33295,
7,
25101,
8,
198,
198,
64,
796,
657,
198,
198,
14323,
796,
10352,
198,
741,
796,
657,
198,
198,
36873,
796,
13538,
628,
198,
35888,
796,
1391,
198,
220,
220,
220,
366,
87,
1298,
15,
11,
198,
220,
220,
220,
366,
88,
1298,
15,
11,
198,
220,
220,
220,
366,
45477,
1298,
25101,
198,
92,
1303,
21839,
22155,
351,
2124,
2292,
11,
331,
2292,
11,
290,
611,
262,
10211,
318,
12070,
628,
198,
198,
4514,
2491,
25,
1303,
26304,
981,
1430,
318,
2491,
198,
220,
220,
220,
329,
304,
287,
23241,
13,
15596,
13,
1136,
33529,
1303,
3497,
477,
2995,
628,
198,
220,
220,
220,
220,
220,
220,
220,
611,
304,
13,
4906,
6624,
23241,
13,
10917,
2043,
25,
1303,
611,
1430,
318,
4838,
11,
2245,
2491,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2491,
796,
10352,
628,
198,
220,
220,
220,
220,
220,
220,
220,
611,
304,
13,
4906,
6624,
23241,
13,
44,
20958,
3620,
2394,
2849,
25,
1303,
3497,
10211,
6268,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
13845,
796,
23241,
13,
35888,
13,
1136,
62,
1930,
3419,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
10211,
14692,
87,
8973,
796,
13845,
58,
15,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
10211,
14692,
88,
8973,
796,
13845,
58,
16,
60,
198,
220,
220,
220,
220,
220,
220,
220,
611,
304,
13,
4906,
6624,
23241,
13,
44,
2606,
5188,
47526,
11357,
41925,
25,
1303,
3497,
10211,
4936,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
10211,
14692,
45477,
8973,
796,
6407,
198,
220,
220,
220,
220,
220,
220,
220,
611,
304,
13,
4906,
6624,
23241,
13,
44,
2606,
5188,
47526,
11357,
8577,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
10211,
14692,
45477,
8973,
796,
10352,
628,
220,
220,
220,
220,
220,
220,
220,
611,
304,
13,
4906,
6624,
23241,
13,
20373,
41925,
25,
1303,
3497,
1994,
2902,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
8251,
58,
68,
13,
2539,
60,
796,
6407,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
611,
7,
68,
13,
2539,
6624,
23241,
13,
42,
62,
79,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
611,
7,
1662,
7,
14323,
8,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
6940,
796,
965,
7,
29734,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2073,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
796,
5418,
7,
36873,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
985,
796,
407,
7,
14323,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
198,
220,
220,
220,
220,
220,
220,
220,
611,
304,
13,
4906,
6624,
23241,
13,
20373,
8577,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
8251,
58,
68,
13,
2539,
60,
796,
10352,
628,
220,
220,
220,
1303,
11459,
3159,
198,
220,
220,
220,
288,
13,
20797,
7,
6894,
14692,
25249,
8973,
8,
628,
198,
220,
220,
220,
220,
198,
220,
220,
220,
611,
985,
25,
1303,
3184,
5039,
198,
220,
220,
220,
220,
220,
220,
220,
3715,
796,
29308,
7,
29734,
11,
6894,
11,
13083,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
198,
220,
220,
220,
220,
198,
220,
220,
220,
220,
628,
220,
220,
220,
8543,
7,
29734,
8,
1303,
45819,
198,
220,
220,
220,
611,
7,
1662,
7,
14323,
8,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
1,
9150,
8973,
198,
220,
220,
220,
220,
220,
220,
220,
23241,
13,
19334,
13,
1370,
7,
67,
11,
7,
13381,
11,
15,
11,
15,
828,
16302,
7,
1930,
828,
16302,
7,
220,
357,
1930,
58,
15,
48688,
1495,
11,
1930,
58,
16,
4357,
1930,
58,
17,
12962,
220,
1267,
837,
19,
8,
1303,
25302,
7877,
444,
379,
2292,
198,
220,
220,
220,
220,
220,
220,
220,
23241,
13,
19334,
13,
1370,
7,
67,
11,
7,
15,
11,
13381,
11,
15,
828,
16302,
7,
1930,
828,
16302,
7,
220,
357,
1930,
58,
15,
60,
837,
1930,
58,
16,
48688,
1495,
11,
1930,
58,
17,
12962,
220,
1267,
837,
19,
8,
198,
220,
220,
220,
220,
220,
220,
220,
23241,
13,
19334,
13,
1370,
7,
67,
11,
7,
15,
11,
15,
11,
13381,
828,
16302,
7,
1930,
828,
16302,
7,
220,
357,
1930,
58,
15,
60,
837,
1930,
58,
16,
4357,
1930,
58,
17,
48688,
1495,
8,
220,
1267,
837,
19,
8,
628,
198,
220,
220,
220,
220,
220,
220,
220,
11774,
37103,
796,
11774,
7,
35888,
14692,
87,
33116,
35888,
14692,
88,
33116,
35888,
14692,
45477,
33116,
29734,
58,
741,
4357,
741,
8,
1303,
3855,
477,
4936,
628,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
15,
7131,
1,
45477,
8973,
2599,
220,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
384,
75,
47932,
16,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
611,
7,
741,
1875,
18896,
7,
29734,
13219,
16,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
384,
75,
796,
657,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3993,
7,
15,
13,
16,
8,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
16,
7131,
1,
45477,
8973,
2599,
220,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
43358,
8973,
47932,
16,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
611,
7,
29734,
58,
741,
7131,
1,
43358,
8973,
1875,
18896,
7,
1477,
7916,
13,
6880,
956,
13219,
16,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
43358,
8973,
796,
657,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3993,
7,
15,
13,
16,
8,
628,
220,
220,
220,
220,
220,
220,
220,
1438,
796,
366,
9150,
1,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
17,
7131,
1,
45477,
8973,
2599,
220,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
3672,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
3672,
60,
796,
357,
1930,
58,
15,
45297,
19,
11,
1930,
58,
16,
4357,
1930,
58,
17,
12962,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
18,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
3672,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
3672,
60,
796,
357,
1930,
58,
15,
48688,
19,
11,
1930,
58,
16,
4357,
1930,
58,
17,
12962,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
19,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
3672,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
3672,
60,
796,
357,
1930,
58,
15,
4357,
1930,
58,
16,
45297,
19,
11,
1930,
58,
17,
12962,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
20,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
3672,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
3672,
60,
796,
357,
1930,
58,
15,
4357,
1930,
58,
16,
48688,
19,
11,
1930,
58,
17,
12962,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
21,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
3672,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
3672,
60,
796,
357,
1930,
58,
15,
4357,
1930,
58,
16,
4357,
1930,
58,
17,
45297,
19,
8,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
22,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
3672,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
3672,
60,
796,
357,
1930,
58,
15,
4357,
1930,
58,
16,
4357,
1930,
58,
17,
48688,
19,
8,
628,
220,
220,
220,
220,
220,
220,
220,
1438,
796,
366,
9888,
1,
198,
220,
220,
220,
220,
220,
220,
220,
220,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
23,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
3672,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
3672,
60,
796,
357,
1930,
58,
15,
45297,
19,
11,
1930,
58,
16,
4357,
1930,
58,
17,
12962,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
24,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
3672,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
3672,
60,
796,
357,
1930,
58,
15,
48688,
19,
11,
1930,
58,
16,
4357,
1930,
58,
17,
12962,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
940,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
3672,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
3672,
60,
796,
357,
1930,
58,
15,
4357,
1930,
58,
16,
45297,
19,
11,
1930,
58,
17,
12962,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1157,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
3672,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
3672,
60,
796,
357,
1930,
58,
15,
4357,
1930,
58,
16,
48688,
19,
11,
1930,
58,
17,
12962,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1065,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
3672,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
3672,
60,
796,
357,
1930,
58,
15,
4357,
1930,
58,
16,
4357,
1930,
58,
17,
45297,
19,
8,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1485,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
3672,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
3672,
60,
796,
357,
1930,
58,
15,
4357,
1930,
58,
16,
4357,
1930,
58,
17,
48688,
19,
8,
628,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1415,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8043,
8973,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8043,
8973,
796,
357,
1930,
58,
15,
45297,
19,
11,
1930,
58,
16,
4357,
1930,
58,
17,
12962,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1314,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8043,
8973,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8043,
8973,
796,
357,
1930,
58,
15,
48688,
19,
11,
1930,
58,
16,
4357,
1930,
58,
17,
12962,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1433,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8043,
8973,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8043,
8973,
796,
357,
1930,
58,
15,
4357,
1930,
58,
16,
45297,
19,
11,
1930,
58,
17,
12962,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1558,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8043,
8973,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8043,
8973,
796,
357,
1930,
58,
15,
4357,
1930,
58,
16,
48688,
19,
11,
1930,
58,
17,
12962,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1507,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8043,
8973,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8043,
8973,
796,
357,
1930,
58,
15,
4357,
1930,
58,
16,
4357,
1930,
58,
17,
45297,
19,
8,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1129,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1426,
796,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8043,
8973,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8043,
8973,
796,
357,
1930,
58,
15,
4357,
1930,
58,
16,
4357,
1930,
58,
17,
48688,
19,
8,
628,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1238,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
746,
23154,
1,
7131,
1,
4359,
312,
25842,
8973,
796,
407,
7,
29734,
58,
741,
7131,
1,
746,
23154,
1,
7131,
1,
4359,
312,
25842,
8973,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3993,
7,
15,
13,
16,
8,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
2481,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
746,
23154,
1,
7131,
1,
13716,
8973,
796,
407,
7,
29734,
58,
741,
7131,
1,
746,
23154,
1,
7131,
1,
13716,
8973,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3993,
7,
15,
13,
16,
8,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1828,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
746,
23154,
1,
7131,
1,
65,
8652,
8973,
12,
28,
657,
13,
486,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1954,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
746,
23154,
1,
7131,
1,
65,
8652,
8973,
47932,
657,
13,
486,
628,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1731,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
746,
23154,
1,
7131,
1,
69,
46214,
8973,
12,
28,
657,
13,
486,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1495,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
746,
23154,
1,
7131,
1,
69,
46214,
8973,
47932,
657,
13,
486,
628,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
2075,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
287,
8206,
796,
2562,
48317,
13,
7753,
9654,
3524,
7,
12286,
2625,
31803,
14,
1600,
7753,
19199,
28,
14692,
24620,
11134,
2430,
24620,
9479,
2430,
24620,
73,
22071,
2430,
24620,
27908,
2430,
9,
15885,
8973,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
611,
2099,
7,
259,
8206,
8,
6624,
2099,
7203,
366,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8899,
8973,
796,
287,
8206,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2073,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8899,
8973,
796,
366,
23108,
1,
628,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1983,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
257,
7252,
796,
1391,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
366,
43358,
1298,
15,
11,
628,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
366,
9150,
1298,
7,
15,
11,
15,
11,
15,
828,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
366,
9888,
1298,
7,
1495,
11,
1495,
11,
1495,
828,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
366,
10599,
341,
1298,
7,
15,
11,
15,
11,
15,
828,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
366,
33665,
1298,
90,
628,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
366,
21809,
1298,
25101,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
366,
8043,
1298,
7,
2167,
11,
5066,
11,
5066,
828,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
366,
8899,
2404,
23108,
1,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
8964,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
366,
746,
23154,
1298,
1391,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
366,
4359,
312,
25842,
1298,
25101,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
366,
626,
11683,
1298,
7,
15,
11,
15,
11,
15,
828,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
366,
69,
46214,
1298,
15,
13,
2713,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
366,
65,
8652,
1298,
15,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
366,
13716,
1298,
25101,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1782,
628,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1782,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
13,
33295,
7,
46071,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
384,
75,
796,
18896,
7,
29734,
13219,
16,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3993,
7,
15,
13,
16,
8,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
2078,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
611,
7,
741,
14512,
657,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
13,
12924,
7,
741,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
384,
75,
796,
657,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3601,
7203,
45975,
47529,
19570,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2073,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2562,
48317,
13,
19662,
3524,
7,
19662,
2625,
34,
34574,
17220,
47529,
1600,
7839,
2625,
12331,
25,
4943,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3993,
7,
15,
13,
16,
8,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1959,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
288,
13,
20797,
7,
6894,
14692,
25249,
8973,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
8543,
7,
29734,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1303,
1885,
498,
4448,
3419,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
23241,
13,
9060,
13,
21928,
7,
67,
11,
38171,
48317,
13,
16624,
1015,
3524,
7,
7753,
19199,
28,
14692,
24620,
11134,
2430,
24620,
9479,
2430,
9,
15885,
8973,
4008,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2562,
48317,
13,
19662,
3524,
7,
19662,
2625,
49,
30398,
843,
1475,
9213,
1600,
7839,
2625,
33244,
2474,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3993,
7,
15,
13,
16,
8,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
1270,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
6940,
796,
965,
7,
29734,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1949,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
997,
35439,
796,
493,
7,
38171,
48317,
13,
9255,
3524,
7203,
2437,
4650,
36291,
1701,
4008,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2845,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2562,
48317,
13,
19662,
3524,
7,
19662,
2625,
15057,
12039,
1355,
317,
48951,
34142,
1600,
7839,
2625,
12331,
25,
4943,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
997,
35439,
796,
657,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
329,
1312,
287,
2837,
7,
22510,
35439,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
796,
29308,
7,
29734,
11,
6894,
11,
13083,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
288,
13,
20797,
7,
6894,
14692,
25249,
8973,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
8543,
7,
29734,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
23241,
13,
13812,
13,
19119,
3419,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
23241,
13,
9060,
13,
21928,
7,
67,
553,
22915,
30487,
1343,
965,
7,
72,
8,
1343,
27071,
11134,
4943,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3601,
7203,
45677,
366,
1343,
2536,
7,
72,
8,
1343,
220,
12813,
1,
1343,
965,
7,
22510,
35439,
4008,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
796,
5418,
7,
36873,
8,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
3132,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
21809,
8973,
796,
407,
7,
29734,
58,
741,
7131,
1,
33665,
1,
7131,
1,
21809,
8973,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3993,
7,
15,
13,
16,
8,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
2624,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1949,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
277,
796,
1280,
7,
38171,
48317,
13,
7753,
9654,
3524,
7,
12286,
2625,
28123,
14,
1600,
7753,
19199,
28,
14692,
24620,
452,
88,
2430,
9,
15885,
8973,
27267,
81,
4943,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
6940,
796,
965,
7,
29734,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1949,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
796,
5418,
7,
69,
13,
961,
28955,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2845,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2562,
48317,
13,
19662,
3524,
7,
19662,
2625,
44651,
23412,
9220,
1600,
7839,
2625,
12331,
25,
4943,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
796,
5418,
7,
36873,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
277,
13,
19836,
3419,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2845,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3601,
7203,
3629,
962,
9220,
4943,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
2091,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1949,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
277,
796,
1280,
7,
38171,
48317,
13,
16624,
1015,
3524,
7,
12286,
2625,
28123,
14,
1600,
7753,
19199,
28,
14692,
24620,
452,
88,
2430,
9,
15885,
8973,
27267,
86,
4943,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
277,
13,
13564,
7,
2536,
7,
29734,
4008,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
277,
13,
19836,
3419,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2845,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3601,
7203,
3629,
962,
9220,
4943,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
2623,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
374,
83,
796,
3715,
58,
741,
7131,
1,
10599,
341,
8973,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
374,
83,
796,
357,
17034,
58,
15,
4357,
17034,
58,
16,
45297,
15,
13,
16,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
10599,
341,
8973,
796,
374,
83,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
2718,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
374,
83,
796,
3715,
58,
741,
7131,
1,
10599,
341,
8973,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
374,
83,
796,
357,
17034,
58,
15,
4357,
17034,
58,
16,
48688,
15,
13,
16,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
10599,
341,
8973,
796,
374,
83,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
2682,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
374,
83,
796,
3715,
58,
741,
7131,
1,
10599,
341,
8973,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
374,
83,
796,
357,
17034,
58,
15,
45297,
15,
13,
16,
11,
17034,
58,
16,
12962,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
10599,
341,
8973,
796,
374,
83,
198,
220,
220,
220,
220,
220,
220,
220,
611,
7,
48317,
37103,
58,
2327,
7131,
1,
45477,
8973,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
374,
83,
796,
3715,
58,
741,
7131,
1,
10599,
341,
8973,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
374,
83,
796,
357,
17034,
58,
15,
48688,
15,
13,
16,
11,
17034,
58,
16,
12962,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
3715,
58,
741,
7131,
1,
10599,
341,
8973,
796,
374,
83,
628,
220,
220,
220,
537,
81,
796,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8043,
8973,
628,
220,
220,
220,
374,
796,
537,
81,
58,
15,
60,
198,
220,
220,
220,
308,
796,
537,
81,
58,
16,
60,
198,
220,
220,
220,
275,
796,
537,
81,
58,
17,
60,
628,
220,
220,
220,
374,
796,
3509,
7,
1084,
7,
81,
11,
13381,
828,
15,
8,
198,
220,
220,
220,
308,
796,
3509,
7,
1084,
7,
70,
11,
13381,
828,
15,
8,
198,
220,
220,
220,
275,
796,
3509,
7,
1084,
7,
65,
11,
13381,
828,
15,
8,
198,
220,
220,
220,
3715,
58,
741,
7131,
1,
33665,
1,
7131,
1,
8043,
8973,
796,
357,
81,
11,
70,
11,
65,
8,
628,
220,
220,
220,
23241,
13,
13812,
13,
19119,
3419,
198
] | 1.832207 | 5,769 |
from daipecore.decorator.notebook_function import notebook_function
@notebook_function
| [
6738,
288,
1872,
431,
7295,
13,
12501,
273,
1352,
13,
11295,
2070,
62,
8818,
1330,
20922,
62,
8818,
628,
198,
31,
11295,
2070,
62,
8818,
198
] | 3.423077 | 26 |
# coding=utf-8
import re
import ast
from setuptools import setup
from os import path
_version_re = re.compile(r'__version__\s+=\s+(.*)')
with open('psi/app/__init__.py', 'rb') as f:
version = str(ast.literal_eval(_version_re.search(
f.read().decode('utf-8')).group(1)))
with open('etc/requirements/common.txt', 'r') as f:
install_reqs = [
s for s in [
line.strip(' \n') for line in f
] if not s.startswith('#') and s != ''
]
with open('etc/requirements/test.txt', 'r') as f:
tests_reqs = [
s for s in [
line.strip(' \n') for line in f
] if not s.startswith('#') and s != '' and not s.startswith('-r ')
]
# read the contents of your README file
this_directory = path.abspath(path.dirname(__file__))
with open(path.join(this_directory, 'README.md'), encoding='utf-8') as f:
long_description = f.read()
setup(
name="betterlifepsi",
version=version,
packages=['psi'],
include_package_data=True,
author="Lawrence Liu",
author_email="[email protected]",
description="Betterlife Intelligent PSI(Purchase, Sales and Inventory) system",
long_description=long_description,
long_description_content_type='text/markdown',
license="MIT",
keywords="Betterlife, Intelligent, Purchase Order, Sales Order, Inventory Management, Retail",
url="https://github.com/betterlife/psi",
install_requires=install_reqs,
tests_require=tests_reqs,
setup_requires=install_reqs,
classifiers=[
'Development Status :: 2 - Pre-Alpha',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Topic :: Office/Business :: Financial :: Point-Of-Sale',
'Topic :: Office/Business :: Financial',
'Topic :: Office/Business :: Financial :: Accounting',
'Natural Language :: Chinese (Simplified)',
'Natural Language :: English',
'Framework :: Flask',
],
)
| [
2,
19617,
28,
40477,
12,
23,
198,
198,
11748,
302,
198,
11748,
6468,
198,
6738,
900,
37623,
10141,
1330,
9058,
198,
6738,
28686,
1330,
3108,
198,
198,
62,
9641,
62,
260,
796,
302,
13,
5589,
576,
7,
81,
6,
834,
9641,
834,
59,
82,
47932,
59,
82,
33747,
15885,
8,
11537,
198,
198,
4480,
1280,
10786,
862,
72,
14,
1324,
14,
834,
15003,
834,
13,
9078,
3256,
705,
26145,
11537,
355,
277,
25,
198,
220,
220,
220,
2196,
796,
965,
7,
459,
13,
18250,
1691,
62,
18206,
28264,
9641,
62,
260,
13,
12947,
7,
198,
220,
220,
220,
220,
220,
220,
220,
277,
13,
961,
22446,
12501,
1098,
10786,
40477,
12,
23,
11537,
737,
8094,
7,
16,
22305,
198,
198,
4480,
1280,
10786,
14784,
14,
8897,
18883,
14,
11321,
13,
14116,
3256,
705,
81,
11537,
355,
277,
25,
198,
220,
220,
220,
2721,
62,
42180,
82,
796,
685,
198,
220,
220,
220,
220,
220,
220,
220,
264,
329,
264,
287,
685,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1627,
13,
36311,
10786,
3467,
77,
11537,
329,
1627,
287,
277,
198,
220,
220,
220,
220,
220,
220,
220,
2361,
611,
407,
264,
13,
9688,
2032,
342,
10786,
2,
11537,
290,
264,
14512,
10148,
198,
220,
220,
220,
2361,
198,
198,
4480,
1280,
10786,
14784,
14,
8897,
18883,
14,
9288,
13,
14116,
3256,
705,
81,
11537,
355,
277,
25,
198,
220,
220,
220,
5254,
62,
42180,
82,
796,
685,
198,
220,
220,
220,
220,
220,
220,
220,
264,
329,
264,
287,
685,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1627,
13,
36311,
10786,
3467,
77,
11537,
329,
1627,
287,
277,
198,
220,
220,
220,
220,
220,
220,
220,
2361,
611,
407,
264,
13,
9688,
2032,
342,
10786,
2,
11537,
290,
264,
14512,
10148,
290,
407,
264,
13,
9688,
2032,
342,
10786,
12,
81,
705,
8,
198,
220,
220,
220,
2361,
198,
198,
2,
1100,
262,
10154,
286,
534,
20832,
11682,
2393,
198,
5661,
62,
34945,
796,
3108,
13,
397,
2777,
776,
7,
6978,
13,
15908,
3672,
7,
834,
7753,
834,
4008,
198,
4480,
1280,
7,
6978,
13,
22179,
7,
5661,
62,
34945,
11,
705,
15675,
11682,
13,
9132,
33809,
21004,
11639,
40477,
12,
23,
11537,
355,
277,
25,
198,
220,
220,
220,
890,
62,
11213,
796,
277,
13,
961,
3419,
198,
198,
40406,
7,
198,
220,
220,
220,
1438,
2625,
27903,
36195,
538,
13396,
1600,
198,
220,
220,
220,
2196,
28,
9641,
11,
198,
220,
220,
220,
10392,
28,
17816,
862,
72,
6,
4357,
198,
220,
220,
220,
2291,
62,
26495,
62,
7890,
28,
17821,
11,
198,
220,
220,
220,
1772,
2625,
16966,
6784,
18258,
1600,
198,
220,
220,
220,
1772,
62,
12888,
2625,
6270,
6784,
31,
27903,
6042,
13,
952,
1600,
198,
220,
220,
220,
6764,
2625,
28971,
6042,
49452,
6599,
40,
7,
47651,
11,
17329,
290,
35772,
8,
1080,
1600,
198,
220,
220,
220,
890,
62,
11213,
28,
6511,
62,
11213,
11,
198,
220,
220,
220,
890,
62,
11213,
62,
11299,
62,
4906,
11639,
5239,
14,
4102,
2902,
3256,
198,
220,
220,
220,
5964,
2625,
36393,
1600,
198,
220,
220,
220,
26286,
2625,
28971,
6042,
11,
49452,
11,
27637,
8284,
11,
17329,
8284,
11,
35772,
8549,
11,
26702,
1600,
198,
220,
220,
220,
19016,
2625,
5450,
1378,
12567,
13,
785,
14,
27903,
6042,
14,
862,
72,
1600,
198,
220,
220,
220,
2721,
62,
47911,
28,
17350,
62,
42180,
82,
11,
198,
220,
220,
220,
5254,
62,
46115,
28,
41989,
62,
42180,
82,
11,
198,
220,
220,
220,
9058,
62,
47911,
28,
17350,
62,
42180,
82,
11,
198,
220,
220,
220,
1398,
13350,
41888,
198,
220,
220,
220,
220,
220,
220,
220,
705,
41206,
12678,
7904,
362,
532,
3771,
12,
38077,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
34156,
7904,
7294,
40,
20010,
1079,
7904,
17168,
13789,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
18843,
803,
4482,
7904,
7294,
13362,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
15167,
2229,
15417,
7904,
11361,
7904,
513,
13,
19,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
15167,
2229,
15417,
7904,
11361,
7904,
513,
13,
20,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
15167,
2229,
15417,
7904,
11361,
7904,
513,
13,
21,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
15167,
2229,
15417,
7904,
11361,
7904,
513,
13,
22,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
33221,
7904,
4452,
14,
24749,
7904,
11302,
7904,
6252,
12,
5189,
12,
50,
1000,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
33221,
7904,
4452,
14,
24749,
7904,
11302,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
33221,
7904,
4452,
14,
24749,
7904,
11302,
7904,
40964,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
35364,
15417,
7904,
3999,
357,
8890,
489,
1431,
8,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
35364,
15417,
7904,
3594,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
21055,
6433,
7904,
46947,
3256,
198,
220,
220,
220,
16589,
198,
8,
198
] | 2.564345 | 847 |
"""
Convert a fasta/quality files to a fastq file. I can't believe I'm writing this in 2020
"""
import os
import sys
import argparse
from roblib import read_fasta, write_fastq, message
__author__ = 'Rob Edwards'
__copyright__ = 'Copyright 2020, Rob Edwards'
__credits__ = ['Rob Edwards']
__license__ = 'MIT'
__maintainer__ = 'Rob Edwards'
__email__ = '[email protected]'
if __name__ == '__main__':
parser = argparse.ArgumentParser(description=" ")
parser.add_argument('-f', help='fasta file', required=True)
parser.add_argument('-q', help='quality file', required=True)
parser.add_argument('-o', help='output fastq file', required=True)
parser.add_argument('-v', help='verbose output', action='store_true')
args = parser.parse_args()
if not os.path.exists(args.f) and not os.path.exists(args.q):
message("FATAL: either {args.f} or {args.q} not found", "RED")
sys.exit(-1)
fa = read_fasta(args.f, True, False)
qu = read_fasta(args.q, True, True)
write_fastq(fa, qu, args.o, args.v)
| [
37811,
198,
3103,
1851,
257,
3049,
64,
14,
13237,
3696,
284,
257,
3049,
80,
2393,
13,
314,
460,
470,
1975,
314,
1101,
3597,
428,
287,
12131,
198,
37811,
198,
198,
11748,
28686,
198,
11748,
25064,
198,
11748,
1822,
29572,
198,
198,
6738,
686,
2436,
571,
1330,
1100,
62,
7217,
64,
11,
3551,
62,
7217,
80,
11,
3275,
198,
198,
834,
9800,
834,
796,
705,
14350,
17381,
6,
198,
834,
22163,
4766,
834,
796,
705,
15269,
12131,
11,
3851,
17381,
6,
198,
834,
66,
20696,
834,
796,
37250,
14350,
17381,
20520,
198,
834,
43085,
834,
796,
705,
36393,
6,
198,
834,
76,
2913,
10613,
834,
796,
705,
14350,
17381,
6,
198,
834,
12888,
834,
796,
705,
430,
276,
2017,
31,
14816,
13,
785,
6,
198,
198,
361,
11593,
3672,
834,
6624,
705,
834,
12417,
834,
10354,
198,
220,
220,
220,
30751,
796,
1822,
29572,
13,
28100,
1713,
46677,
7,
11213,
2625,
366,
8,
198,
220,
220,
220,
30751,
13,
2860,
62,
49140,
10786,
12,
69,
3256,
1037,
11639,
7217,
64,
2393,
3256,
2672,
28,
17821,
8,
198,
220,
220,
220,
30751,
13,
2860,
62,
49140,
10786,
12,
80,
3256,
1037,
11639,
13237,
2393,
3256,
2672,
28,
17821,
8,
198,
220,
220,
220,
30751,
13,
2860,
62,
49140,
10786,
12,
78,
3256,
1037,
11639,
22915,
3049,
80,
2393,
3256,
2672,
28,
17821,
8,
198,
220,
220,
220,
30751,
13,
2860,
62,
49140,
10786,
12,
85,
3256,
1037,
11639,
19011,
577,
5072,
3256,
2223,
11639,
8095,
62,
7942,
11537,
198,
220,
220,
220,
26498,
796,
30751,
13,
29572,
62,
22046,
3419,
628,
220,
220,
220,
611,
407,
28686,
13,
6978,
13,
1069,
1023,
7,
22046,
13,
69,
8,
290,
407,
28686,
13,
6978,
13,
1069,
1023,
7,
22046,
13,
80,
2599,
198,
220,
220,
220,
220,
220,
220,
220,
3275,
7203,
37,
1404,
1847,
25,
2035,
1391,
22046,
13,
69,
92,
393,
1391,
22046,
13,
80,
92,
407,
1043,
1600,
366,
22083,
4943,
198,
220,
220,
220,
220,
220,
220,
220,
25064,
13,
37023,
32590,
16,
8,
628,
220,
220,
220,
24685,
796,
1100,
62,
7217,
64,
7,
22046,
13,
69,
11,
6407,
11,
10352,
8,
198,
220,
220,
220,
627,
796,
1100,
62,
7217,
64,
7,
22046,
13,
80,
11,
6407,
11,
6407,
8,
628,
220,
220,
220,
3551,
62,
7217,
80,
7,
13331,
11,
627,
11,
26498,
13,
78,
11,
26498,
13,
85,
8,
198
] | 2.654822 | 394 |
#!/usr/bin/env python3
# -*- codint: utf-8 -*-
import datetime
d1 = datetime.datetime.today()
print("today: " ,d1)
d2 = datetime.datetime.now()
print("now: " ,d2)
| [
2,
48443,
14629,
14,
8800,
14,
24330,
21015,
18,
198,
2,
532,
9,
12,
14873,
600,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
198,
11748,
4818,
8079,
198,
198,
67,
16,
796,
4818,
8079,
13,
19608,
8079,
13,
40838,
3419,
198,
4798,
7203,
40838,
25,
366,
837,
67,
16,
8,
198,
198,
67,
17,
796,
4818,
8079,
13,
19608,
8079,
13,
2197,
3419,
198,
4798,
7203,
2197,
25,
366,
837,
67,
17,
8,
628,
628,
198
] | 2.179487 | 78 |
import os
from amokryshev import settings
from django.db.models.fields.files import FieldFile, FileField
class DeduplicatedFieldFile(FieldFile):
"""The implementation of simple deduplication functional while saving the file,
I couldn't find deduplication feature in Django FileField and didn't want to install
additional batteries from third party developers, because the functional, required by me,
too easy, so I wrote a little crutch"""
class FileFieldDedupByName(FileField):
"""The implementation of simple deduplication functional while saving the file,
I couldn't find deduplication feature in Django FileField and didn't want to install
additional batteries from third party developers, because the functional, required by me,
too easy, so I wrote a little crutch"""
attr_class = DeduplicatedFieldFile
| [
11748,
28686,
198,
6738,
716,
482,
563,
7091,
85,
1330,
6460,
198,
6738,
42625,
14208,
13,
9945,
13,
27530,
13,
25747,
13,
16624,
1330,
7663,
8979,
11,
9220,
15878,
628,
198,
4871,
360,
15532,
489,
3474,
15878,
8979,
7,
15878,
8979,
2599,
198,
220,
220,
220,
37227,
464,
7822,
286,
2829,
4648,
84,
489,
3299,
10345,
981,
8914,
262,
2393,
11,
198,
220,
220,
220,
314,
3521,
470,
1064,
4648,
84,
489,
3299,
3895,
287,
37770,
9220,
15878,
290,
1422,
470,
765,
284,
2721,
198,
220,
220,
220,
3224,
13591,
422,
2368,
2151,
6505,
11,
780,
262,
10345,
11,
2672,
416,
502,
11,
198,
220,
220,
220,
1165,
2562,
11,
523,
314,
2630,
257,
1310,
1067,
7140,
37811,
628,
198,
4871,
9220,
15878,
35,
276,
929,
3886,
5376,
7,
8979,
15878,
2599,
198,
220,
220,
220,
37227,
464,
7822,
286,
2829,
4648,
84,
489,
3299,
10345,
981,
8914,
262,
2393,
11,
198,
220,
220,
220,
220,
220,
220,
220,
314,
3521,
470,
1064,
4648,
84,
489,
3299,
3895,
287,
37770,
9220,
15878,
290,
1422,
470,
765,
284,
2721,
198,
220,
220,
220,
220,
220,
220,
220,
3224,
13591,
422,
2368,
2151,
6505,
11,
780,
262,
10345,
11,
2672,
416,
502,
11,
198,
220,
220,
220,
220,
220,
220,
220,
1165,
2562,
11,
523,
314,
2630,
257,
1310,
1067,
7140,
37811,
628,
220,
220,
220,
708,
81,
62,
4871,
796,
360,
15532,
489,
3474,
15878,
8979,
198
] | 3.652542 | 236 |
# Copyright 2019 The Texar 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 applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
"""
Utils of BERT Modules.
"""
import json
import os
from abc import ABC
from typing import Any, Dict
import torch
from texar.torch.modules.pretrained.pretrained_base import PretrainedMixin
__all__ = [
"PretrainedBERTMixin",
]
_BERT_PATH = "https://storage.googleapis.com/bert_models/"
_BIOBERT_PATH = "https://github.com/naver/biobert-pretrained/releases/download/"
class PretrainedBERTMixin(PretrainedMixin, ABC):
r"""A mixin class to support loading pre-trained checkpoints for modules
that implement the BERT model.
Both standard BERT models and many domain specific BERT-based models are
supported. You can specify the :attr:`pretrained_model_name` argument to
pick which pre-trained BERT model to use. All available categories of
pre-trained models (and names) include:
* **Standard BERT**: proposed in (`Devlin et al`. 2018)
`BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding`_
. A bidirectional Transformer language model pre-trained on large text
corpora. Available model names include:
* ``bert-base-uncased``: 12-layer, 768-hidden, 12-heads,
110M parameters.
* ``bert-large-uncased``: 24-layer, 1024-hidden, 16-heads,
340M parameters.
* ``bert-base-cased``: 12-layer, 768-hidden, 12-heads , 110M parameters.
* ``bert-large-cased``: 24-layer, 1024-hidden, 16-heads,
340M parameters.
* ``bert-base-multilingual-uncased``: 102 languages, 12-layer,
768-hidden, 12-heads, 110M parameters.
* ``bert-base-multilingual-cased``: 104 languages, 12-layer, 768-hidden,
12-heads, 110M parameters.
* ``bert-base-chinese``: Chinese Simplified and Traditional, 12-layer,
768-hidden, 12-heads, 110M parameters.
* **BioBERT**: proposed in (`Lee et al`. 2019)
`BioBERT: a pre-trained biomedical language representation model for biomedical text mining`_
. A domain specific language representation model pre-trained on
large-scale biomedical corpora. Based on the BERT architecture, BioBERT
effectively transfers the knowledge from a large amount of biomedical
texts to biomedical text mining models with minimal task-specific
architecture modifications. Available model names include:
* ``biobert-v1.0-pmc``: BioBERT v1.0 (+ PMC 270K) - based on
BERT-base-Cased (same vocabulary)
* ``biobert-v1.0-pubmed-pmc``: BioBERT v1.0 (+ PubMed 200K + PMC 270K) -
based on BERT-base-Cased (same vocabulary)
* ``biobert-v1.0-pubmed``: BioBERT v1.0 (+ PubMed 200K) - based on
BERT-base-Cased (same vocabulary)
* ``biobert-v1.1-pubmed``: BioBERT v1.1 (+ PubMed 1M) - based on
BERT-base-Cased (same vocabulary)
We provide the following BERT classes:
* :class:`~texar.torch.modules.BERTEncoder` for text encoding.
* :class:`~texar.torch.modules.BERTClassifier` for text classification and
sequence tagging.
.. _`BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding`:
https://arxiv.org/abs/1810.04805
.. _`BioBERT: a pre-trained biomedical language representation model for biomedical text mining`:
https://arxiv.org/abs/1901.08746
"""
_MODEL_NAME = "BERT"
_MODEL2URL = {
# Standard BERT
'bert-base-uncased':
_BERT_PATH + "2018_10_18/uncased_L-12_H-768_A-12.zip",
'bert-large-uncased':
_BERT_PATH + "2018_10_18/uncased_L-24_H-1024_A-16.zip",
'bert-base-cased':
_BERT_PATH + "2018_10_18/cased_L-12_H-768_A-12.zip",
'bert-large-cased':
_BERT_PATH + "2018_10_18/cased_L-24_H-1024_A-16.zip",
'bert-base-multilingual-uncased':
_BERT_PATH + "2018_11_23/multi_cased_L-12_H-768_A-12.zip",
'bert-base-multilingual-cased':
_BERT_PATH + "2018_11_03/multilingual_L-12_H-768_A-12.zip",
'bert-base-chinese':
_BERT_PATH + "2018_11_03/chinese_L-12_H-768_A-12.zip",
# BioBERT
'biobert-v1.0-pmc':
_BIOBERT_PATH + 'v1.0-pmc/biobert_v1.0_pmc.tar.gz',
'biobert-v1.0-pubmed-pmc':
_BIOBERT_PATH + 'v1.0-pubmed-pmc/biobert_v1.0_pubmed_pmc.tar.gz',
'biobert-v1.0-pubmed':
_BIOBERT_PATH + 'v1.0-pubmed/biobert_v1.0_pubmed.tar.gz',
'biobert-v1.1-pubmed':
_BIOBERT_PATH + 'v1.1-pubmed/biobert_v1.1_pubmed.tar.gz',
}
_MODEL2CKPT = {
# Standard BERT
'bert-base-uncased': 'bert_model.ckpt',
'bert-large-uncased': 'bert_model.ckpt',
'bert-base-cased': 'bert_model.ckpt',
'bert-large-cased': 'bert_model.ckpt',
'bert-base-multilingual-uncased': 'bert_model.ckpt',
'bert-base-multilingual-cased': 'bert_model.ckpt',
'bert-base-chinese': 'bert_model.ckpt',
# BioBERT
'biobert-v1.0-pmc': 'biobert_model.ckpt',
'biobert-v1.0-pubmed-pmc': 'biobert_model.ckpt',
'biobert-v1.0-pubmed': 'biobert_model.ckpt',
'biobert-v1.1-pubmed': 'model.ckpt-1000000',
}
@classmethod
| [
2,
15069,
13130,
383,
3567,
283,
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,
2393,
2845,
287,
11846,
351,
262,
13789,
13,
198,
2,
921,
743,
7330,
257,
4866,
286,
262,
13789,
379,
198,
2,
198,
2,
220,
220,
220,
220,
220,
2638,
1378,
2503,
13,
43073,
13,
2398,
14,
677,
4541,
14,
43,
2149,
24290,
12,
17,
13,
15,
198,
2,
198,
2,
17486,
2672,
416,
9723,
1099,
393,
4987,
284,
287,
3597,
11,
3788,
198,
2,
9387,
739,
262,
13789,
318,
9387,
319,
281,
366,
1921,
3180,
1,
29809,
1797,
11,
198,
2,
42881,
34764,
11015,
6375,
7102,
49828,
11053,
3963,
15529,
509,
12115,
11,
2035,
4911,
393,
17142,
13,
198,
2,
4091,
262,
13789,
329,
262,
2176,
3303,
15030,
21627,
290,
198,
2,
11247,
739,
262,
13789,
13,
198,
37811,
198,
18274,
4487,
286,
347,
17395,
3401,
5028,
13,
198,
37811,
198,
198,
11748,
33918,
198,
11748,
28686,
198,
6738,
450,
66,
1330,
9738,
198,
6738,
19720,
1330,
4377,
11,
360,
713,
198,
198,
11748,
28034,
198,
198,
6738,
48659,
283,
13,
13165,
354,
13,
18170,
13,
5310,
13363,
13,
5310,
13363,
62,
8692,
1330,
37123,
13363,
35608,
259,
198,
198,
834,
439,
834,
796,
685,
198,
220,
220,
220,
366,
47,
1186,
13363,
13246,
15972,
844,
259,
1600,
198,
60,
198,
198,
62,
13246,
51,
62,
34219,
796,
366,
5450,
1378,
35350,
13,
13297,
499,
271,
13,
785,
14,
4835,
62,
27530,
30487,
198,
62,
3483,
9864,
17395,
62,
34219,
796,
366,
5450,
1378,
12567,
13,
785,
14,
2616,
332,
14,
65,
952,
4835,
12,
5310,
13363,
14,
260,
29329,
14,
15002,
30487,
628,
198,
4871,
37123,
13363,
13246,
15972,
844,
259,
7,
47,
1186,
13363,
35608,
259,
11,
9738,
2599,
198,
220,
220,
220,
374,
37811,
32,
5022,
259,
1398,
284,
1104,
11046,
662,
12,
35311,
36628,
329,
13103,
198,
220,
220,
220,
326,
3494,
262,
347,
17395,
2746,
13,
628,
220,
220,
220,
5747,
3210,
347,
17395,
4981,
290,
867,
7386,
2176,
347,
17395,
12,
3106,
4981,
389,
198,
220,
220,
220,
4855,
13,
921,
460,
11986,
262,
1058,
35226,
25,
63,
5310,
13363,
62,
19849,
62,
3672,
63,
4578,
284,
198,
220,
220,
220,
2298,
543,
662,
12,
35311,
347,
17395,
2746,
284,
779,
13,
1439,
1695,
9376,
286,
198,
220,
220,
220,
662,
12,
35311,
4981,
357,
392,
3891,
8,
2291,
25,
628,
220,
220,
220,
1635,
12429,
23615,
347,
17395,
1174,
25,
5150,
287,
357,
63,
13603,
2815,
2123,
435,
44646,
2864,
8,
198,
220,
220,
220,
220,
220,
4600,
13246,
51,
25,
3771,
12,
34409,
286,
10766,
43484,
4154,
282,
39185,
329,
15417,
28491,
63,
62,
198,
220,
220,
220,
220,
220,
764,
317,
8406,
4154,
282,
3602,
16354,
3303,
2746,
662,
12,
35311,
319,
1588,
2420,
198,
220,
220,
220,
220,
220,
3990,
64,
13,
14898,
2746,
3891,
2291,
25,
628,
220,
220,
220,
220,
220,
220,
220,
1635,
7559,
4835,
12,
8692,
12,
19524,
839,
15506,
25,
1105,
12,
29289,
11,
46720,
12,
30342,
11,
1105,
12,
16600,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
9796,
44,
10007,
13,
198,
220,
220,
220,
220,
220,
220,
220,
1635,
7559,
4835,
12,
11664,
12,
19524,
839,
15506,
25,
1987,
12,
29289,
11,
28119,
12,
30342,
11,
1467,
12,
16600,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
28560,
44,
10007,
13,
198,
220,
220,
220,
220,
220,
220,
220,
1635,
7559,
4835,
12,
8692,
12,
66,
839,
15506,
25,
1105,
12,
29289,
11,
46720,
12,
30342,
11,
1105,
12,
16600,
837,
9796,
44,
10007,
13,
198,
220,
220,
220,
220,
220,
220,
220,
1635,
7559,
4835,
12,
11664,
12,
66,
839,
15506,
25,
1987,
12,
29289,
11,
28119,
12,
30342,
11,
1467,
12,
16600,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
28560,
44,
10007,
13,
198,
220,
220,
220,
220,
220,
220,
220,
1635,
7559,
4835,
12,
8692,
12,
16680,
34900,
12,
19524,
839,
15506,
25,
15143,
8950,
11,
1105,
12,
29289,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
46720,
12,
30342,
11,
1105,
12,
16600,
11,
9796,
44,
10007,
13,
198,
220,
220,
220,
220,
220,
220,
220,
1635,
7559,
4835,
12,
8692,
12,
16680,
34900,
12,
66,
839,
15506,
25,
14436,
8950,
11,
1105,
12,
29289,
11,
46720,
12,
30342,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1105,
12,
16600,
11,
9796,
44,
10007,
13,
198,
220,
220,
220,
220,
220,
220,
220,
1635,
7559,
4835,
12,
8692,
12,
354,
3762,
15506,
25,
3999,
45157,
1431,
290,
29065,
11,
1105,
12,
29289,
11,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
46720,
12,
30342,
11,
1105,
12,
16600,
11,
9796,
44,
10007,
13,
628,
220,
220,
220,
1635,
12429,
42787,
13246,
51,
1174,
25,
5150,
287,
357,
63,
24338,
2123,
435,
44646,
13130,
8,
198,
220,
220,
220,
220,
220,
4600,
42787,
13246,
51,
25,
257,
662,
12,
35311,
48730,
3303,
10552,
2746,
329,
48730,
2420,
9691,
63,
62,
198,
220,
220,
220,
220,
220,
764,
317,
7386,
2176,
3303,
10552,
2746,
662,
12,
35311,
319,
198,
220,
220,
220,
220,
220,
1588,
12,
9888,
48730,
3990,
64,
13,
13403,
319,
262,
347,
17395,
10959,
11,
16024,
13246,
51,
198,
220,
220,
220,
220,
220,
6840,
16395,
262,
3725,
422,
257,
1588,
2033,
286,
48730,
198,
220,
220,
220,
220,
220,
13399,
284,
48730,
2420,
9691,
4981,
351,
10926,
4876,
12,
11423,
198,
220,
220,
220,
220,
220,
10959,
19008,
13,
14898,
2746,
3891,
2291,
25,
628,
220,
220,
220,
220,
220,
220,
220,
1635,
7559,
65,
952,
4835,
12,
85,
16,
13,
15,
12,
4426,
66,
15506,
25,
16024,
13246,
51,
410,
16,
13,
15,
11502,
3122,
34,
20479,
42,
8,
532,
1912,
319,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
347,
17395,
12,
8692,
12,
34,
839,
357,
31642,
25818,
8,
198,
220,
220,
220,
220,
220,
220,
220,
1635,
7559,
65,
952,
4835,
12,
85,
16,
13,
15,
12,
12984,
1150,
12,
4426,
66,
15506,
25,
16024,
13246,
51,
410,
16,
13,
15,
11502,
32131,
939,
42,
1343,
3122,
34,
20479,
42,
8,
532,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1912,
319,
347,
17395,
12,
8692,
12,
34,
839,
357,
31642,
25818,
8,
198,
220,
220,
220,
220,
220,
220,
220,
1635,
7559,
65,
952,
4835,
12,
85,
16,
13,
15,
12,
12984,
1150,
15506,
25,
16024,
13246,
51,
410,
16,
13,
15,
11502,
32131,
939,
42,
8,
532,
1912,
319,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
347,
17395,
12,
8692,
12,
34,
839,
357,
31642,
25818,
8,
198,
220,
220,
220,
220,
220,
220,
220,
1635,
7559,
65,
952,
4835,
12,
85,
16,
13,
16,
12,
12984,
1150,
15506,
25,
16024,
13246,
51,
410,
16,
13,
16,
11502,
32131,
352,
44,
8,
532,
1912,
319,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
347,
17395,
12,
8692,
12,
34,
839,
357,
31642,
25818,
8,
628,
220,
220,
220,
775,
2148,
262,
1708,
347,
17395,
6097,
25,
628,
220,
220,
220,
220,
220,
1635,
1058,
4871,
25,
63,
93,
16886,
283,
13,
13165,
354,
13,
18170,
13,
13246,
51,
27195,
12342,
63,
329,
2420,
21004,
13,
198,
220,
220,
220,
220,
220,
1635,
1058,
4871,
25,
63,
93,
16886,
283,
13,
13165,
354,
13,
18170,
13,
13246,
51,
9487,
7483,
63,
329,
2420,
17923,
290,
198,
220,
220,
220,
220,
220,
220,
220,
8379,
49620,
13,
628,
220,
220,
220,
11485,
4808,
63,
13246,
51,
25,
3771,
12,
34409,
286,
10766,
43484,
4154,
282,
39185,
329,
15417,
28491,
63,
25,
198,
220,
220,
220,
220,
220,
220,
220,
3740,
1378,
283,
87,
452,
13,
2398,
14,
8937,
14,
1507,
940,
13,
3023,
28256,
628,
220,
220,
220,
11485,
4808,
63,
42787,
13246,
51,
25,
257,
662,
12,
35311,
48730,
3303,
10552,
2746,
329,
48730,
2420,
9691,
63,
25,
198,
220,
220,
220,
220,
220,
220,
220,
3740,
1378,
283,
87,
452,
13,
2398,
14,
8937,
14,
1129,
486,
13,
2919,
22,
3510,
198,
220,
220,
220,
37227,
628,
220,
220,
220,
4808,
33365,
3698,
62,
20608,
796,
366,
13246,
51,
1,
198,
220,
220,
220,
4808,
33365,
3698,
17,
21886,
796,
1391,
198,
220,
220,
220,
220,
220,
220,
220,
1303,
8997,
347,
17395,
198,
220,
220,
220,
220,
220,
220,
220,
705,
4835,
12,
8692,
12,
19524,
839,
10354,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
4808,
13246,
51,
62,
34219,
1343,
366,
7908,
62,
940,
62,
1507,
14,
19524,
839,
62,
43,
12,
1065,
62,
39,
12,
30610,
62,
32,
12,
1065,
13,
13344,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
705,
4835,
12,
11664,
12,
19524,
839,
10354,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
4808,
13246,
51,
62,
34219,
1343,
366,
7908,
62,
940,
62,
1507,
14,
19524,
839,
62,
43,
12,
1731,
62,
39,
12,
35500,
62,
32,
12,
1433,
13,
13344,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
705,
4835,
12,
8692,
12,
66,
839,
10354,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
4808,
13246,
51,
62,
34219,
1343,
366,
7908,
62,
940,
62,
1507,
14,
66,
839,
62,
43,
12,
1065,
62,
39,
12,
30610,
62,
32,
12,
1065,
13,
13344,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
705,
4835,
12,
11664,
12,
66,
839,
10354,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
4808,
13246,
51,
62,
34219,
1343,
366,
7908,
62,
940,
62,
1507,
14,
66,
839,
62,
43,
12,
1731,
62,
39,
12,
35500,
62,
32,
12,
1433,
13,
13344,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
705,
4835,
12,
8692,
12,
16680,
34900,
12,
19524,
839,
10354,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
4808,
13246,
51,
62,
34219,
1343,
366,
7908,
62,
1157,
62,
1954,
14,
41684,
62,
66,
839,
62,
43,
12,
1065,
62,
39,
12,
30610,
62,
32,
12,
1065,
13,
13344,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
705,
4835,
12,
8692,
12,
16680,
34900,
12,
66,
839,
10354,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
4808,
13246,
51,
62,
34219,
1343,
366,
7908,
62,
1157,
62,
3070,
14,
16680,
34900,
62,
43,
12,
1065,
62,
39,
12,
30610,
62,
32,
12,
1065,
13,
13344,
1600,
198,
220,
220,
220,
220,
220,
220,
220,
705,
4835,
12,
8692,
12,
354,
3762,
10354,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
4808,
13246,
51,
62,
34219,
1343,
366,
7908,
62,
1157,
62,
3070,
14,
354,
3762,
62,
43,
12,
1065,
62,
39,
12,
30610,
62,
32,
12,
1065,
13,
13344,
1600,
628,
220,
220,
220,
220,
220,
220,
220,
1303,
16024,
13246,
51,
198,
220,
220,
220,
220,
220,
220,
220,
705,
65,
952,
4835,
12,
85,
16,
13,
15,
12,
4426,
66,
10354,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
4808,
3483,
9864,
17395,
62,
34219,
1343,
705,
85,
16,
13,
15,
12,
4426,
66,
14,
65,
952,
4835,
62,
85,
16,
13,
15,
62,
4426,
66,
13,
18870,
13,
34586,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
65,
952,
4835,
12,
85,
16,
13,
15,
12,
12984,
1150,
12,
4426,
66,
10354,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
4808,
3483,
9864,
17395,
62,
34219,
1343,
705,
85,
16,
13,
15,
12,
12984,
1150,
12,
4426,
66,
14,
65,
952,
4835,
62,
85,
16,
13,
15,
62,
12984,
1150,
62,
4426,
66,
13,
18870,
13,
34586,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
65,
952,
4835,
12,
85,
16,
13,
15,
12,
12984,
1150,
10354,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
4808,
3483,
9864,
17395,
62,
34219,
1343,
705,
85,
16,
13,
15,
12,
12984,
1150,
14,
65,
952,
4835,
62,
85,
16,
13,
15,
62,
12984,
1150,
13,
18870,
13,
34586,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
65,
952,
4835,
12,
85,
16,
13,
16,
12,
12984,
1150,
10354,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
4808,
3483,
9864,
17395,
62,
34219,
1343,
705,
85,
16,
13,
16,
12,
12984,
1150,
14,
65,
952,
4835,
62,
85,
16,
13,
16,
62,
12984,
1150,
13,
18870,
13,
34586,
3256,
198,
220,
220,
220,
1782,
198,
220,
220,
220,
4808,
33365,
3698,
17,
34,
42,
11571,
796,
1391,
198,
220,
220,
220,
220,
220,
220,
220,
1303,
8997,
347,
17395,
198,
220,
220,
220,
220,
220,
220,
220,
705,
4835,
12,
8692,
12,
19524,
839,
10354,
705,
4835,
62,
19849,
13,
694,
457,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
4835,
12,
11664,
12,
19524,
839,
10354,
705,
4835,
62,
19849,
13,
694,
457,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
4835,
12,
8692,
12,
66,
839,
10354,
705,
4835,
62,
19849,
13,
694,
457,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
4835,
12,
11664,
12,
66,
839,
10354,
705,
4835,
62,
19849,
13,
694,
457,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
4835,
12,
8692,
12,
16680,
34900,
12,
19524,
839,
10354,
705,
4835,
62,
19849,
13,
694,
457,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
4835,
12,
8692,
12,
16680,
34900,
12,
66,
839,
10354,
705,
4835,
62,
19849,
13,
694,
457,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
4835,
12,
8692,
12,
354,
3762,
10354,
705,
4835,
62,
19849,
13,
694,
457,
3256,
628,
220,
220,
220,
220,
220,
220,
220,
1303,
16024,
13246,
51,
198,
220,
220,
220,
220,
220,
220,
220,
705,
65,
952,
4835,
12,
85,
16,
13,
15,
12,
4426,
66,
10354,
705,
65,
952,
4835,
62,
19849,
13,
694,
457,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
65,
952,
4835,
12,
85,
16,
13,
15,
12,
12984,
1150,
12,
4426,
66,
10354,
705,
65,
952,
4835,
62,
19849,
13,
694,
457,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
65,
952,
4835,
12,
85,
16,
13,
15,
12,
12984,
1150,
10354,
705,
65,
952,
4835,
62,
19849,
13,
694,
457,
3256,
198,
220,
220,
220,
220,
220,
220,
220,
705,
65,
952,
4835,
12,
85,
16,
13,
16,
12,
12984,
1150,
10354,
705,
19849,
13,
694,
457,
12,
16,
10535,
3256,
198,
220,
220,
220,
1782,
628,
220,
220,
220,
2488,
4871,
24396,
198
] | 2.351912 | 2,458 |
#Libraries
from PyQt5.QtWidgets import *
from PyQt5.QtCore import *
from PyQt5.QtGui import *
from os.path import split as PATHSPLIT
#Pythons
from settings import *
| [
2,
43,
11127,
201,
198,
6738,
9485,
48,
83,
20,
13,
48,
83,
54,
312,
11407,
1330,
1635,
201,
198,
6738,
9485,
48,
83,
20,
13,
48,
83,
14055,
1330,
1635,
201,
198,
6738,
9485,
48,
83,
20,
13,
48,
83,
8205,
72,
1330,
1635,
201,
198,
6738,
28686,
13,
6978,
1330,
6626,
355,
46490,
4303,
43,
2043,
201,
198,
201,
198,
2,
47,
5272,
684,
201,
198,
6738,
6460,
1330,
1635,
201
] | 2.369863 | 73 |
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
#
import mock
from oslo_serialization import jsonutils
from congressclient.common import utils
from congressclient.osc.v1 import datasource
from congressclient.tests import common
| [
2,
220,
220,
49962,
739,
262,
24843,
13789,
11,
10628,
362,
13,
15,
357,
1169,
366,
34156,
15341,
345,
743,
198,
2,
220,
220,
407,
779,
428,
2393,
2845,
287,
11846,
351,
262,
13789,
13,
921,
743,
7330,
198,
2,
220,
220,
257,
4866,
286,
262,
13789,
379,
198,
2,
198,
2,
220,
220,
220,
220,
220,
220,
220,
2638,
1378,
2503,
13,
43073,
13,
2398,
14,
677,
4541,
14,
43,
2149,
24290,
12,
17,
13,
15,
198,
2,
198,
2,
220,
220,
17486,
2672,
416,
9723,
1099,
393,
4987,
284,
287,
3597,
11,
3788,
198,
2,
220,
220,
9387,
739,
262,
13789,
318,
9387,
319,
281,
366,
1921,
3180,
1,
29809,
1797,
11,
42881,
198,
2,
220,
220,
34764,
11015,
6375,
7102,
49828,
11053,
3963,
15529,
509,
12115,
11,
2035,
4911,
393,
17142,
13,
4091,
262,
198,
2,
220,
220,
13789,
329,
262,
2176,
3303,
15030,
21627,
290,
11247,
198,
2,
220,
220,
739,
262,
13789,
13,
198,
2,
198,
198,
11748,
15290,
198,
6738,
28686,
5439,
62,
46911,
1634,
1330,
33918,
26791,
198,
198,
6738,
8681,
16366,
13,
11321,
1330,
3384,
4487,
198,
6738,
8681,
16366,
13,
17500,
13,
85,
16,
1330,
19395,
1668,
198,
6738,
8681,
16366,
13,
41989,
1330,
2219,
628,
628,
628,
628,
628,
628,
198
] | 3.587678 | 211 |
# Напечатать три данных действительных числа , и сначала в порядке их возрастания, затем - в порядке убывания
a = input("Введите первое число: ")
b = input("Введите второе число: ")
c = input("Введите третье число: ")
print(min(a, b, c), (max(min(a, b), min(b, c))
if not
min(a, b) == min(b, c)
else min(a, c)), max(a, b, c))
print(max(a, b, c), (min(max(a, b), max(b, c))
if not
max(a, b) == max(b, c)
else max(a, c)), min(a, b, c))
| [
2,
12466,
251,
16142,
140,
123,
16843,
141,
229,
16142,
20375,
16142,
20375,
45367,
220,
20375,
21169,
18849,
12466,
112,
16142,
22177,
22177,
45035,
141,
227,
12466,
112,
16843,
140,
117,
21727,
20375,
38857,
18849,
20375,
16843,
30143,
45367,
22177,
45035,
141,
227,
220,
141,
229,
18849,
21727,
30143,
16142,
837,
12466,
116,
220,
21727,
22177,
16142,
141,
229,
16142,
30143,
16142,
12466,
110,
12466,
123,
15166,
21169,
40623,
43666,
31583,
16843,
12466,
116,
141,
227,
12466,
110,
25443,
115,
21169,
16142,
21727,
20375,
16142,
22177,
18849,
40623,
11,
12466,
115,
16142,
20375,
16843,
43108,
532,
12466,
110,
12466,
123,
15166,
21169,
40623,
43666,
31583,
16843,
220,
35072,
140,
109,
45035,
38857,
16142,
22177,
18849,
40623,
198,
198,
64,
796,
5128,
7203,
140,
240,
38857,
16843,
43666,
18849,
20375,
16843,
12466,
123,
16843,
21169,
38857,
15166,
16843,
220,
141,
229,
18849,
21727,
30143,
15166,
25,
366,
8,
198,
65,
796,
5128,
7203,
140,
240,
38857,
16843,
43666,
18849,
20375,
16843,
12466,
110,
20375,
15166,
21169,
15166,
16843,
220,
141,
229,
18849,
21727,
30143,
15166,
25,
366,
8,
198,
66,
796,
5128,
7203,
140,
240,
38857,
16843,
43666,
18849,
20375,
16843,
220,
20375,
21169,
16843,
20375,
45367,
16843,
220,
141,
229,
18849,
21727,
30143,
15166,
25,
366,
8,
198,
4798,
7,
1084,
7,
64,
11,
275,
11,
269,
828,
357,
9806,
7,
1084,
7,
64,
11,
275,
828,
949,
7,
65,
11,
269,
4008,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
611,
407,
198,
1084,
7,
64,
11,
275,
8,
6624,
949,
7,
65,
11,
269,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2073,
949,
7,
64,
11,
269,
36911,
3509,
7,
64,
11,
275,
11,
269,
4008,
198,
4798,
7,
9806,
7,
64,
11,
275,
11,
269,
828,
357,
1084,
7,
9806,
7,
64,
11,
275,
828,
3509,
7,
65,
11,
269,
4008,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
611,
407,
198,
9806,
7,
64,
11,
275,
8,
6624,
3509,
7,
65,
11,
269,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2073,
3509,
7,
64,
11,
269,
36911,
949,
7,
64,
11,
275,
11,
269,
4008,
198
] | 1.278325 | 406 |
# Generated by Django 2.2.5 on 2019-10-18 17:41
import card.modelfields
import django.core.validators
from django.db import migrations
| [
2,
2980,
515,
416,
37770,
362,
13,
17,
13,
20,
319,
13130,
12,
940,
12,
1507,
1596,
25,
3901,
198,
198,
11748,
2657,
13,
19849,
25747,
198,
11748,
42625,
14208,
13,
7295,
13,
12102,
2024,
198,
6738,
42625,
14208,
13,
9945,
1330,
15720,
602,
628
] | 3.044444 | 45 |
# -*- coding: utf-8 -*-
# BEWARE: to not import this package at startup,
# but only into functions otherwise pip will go crazy
# (we cannot understand why, but it does!)
# which version of python is this?
# Retrocompatibility for Python < 3.6
from sultan.api import Sultan
try:
import_exceptions = (ModuleNotFoundError, ImportError)
except NameError:
import_exceptions = ImportError
| [
2,
532,
9,
12,
19617,
25,
3384,
69,
12,
23,
532,
9,
12,
198,
198,
2,
347,
6217,
12203,
25,
284,
407,
1330,
428,
5301,
379,
13693,
11,
198,
2,
475,
691,
656,
5499,
4306,
7347,
481,
467,
7165,
198,
2,
357,
732,
2314,
1833,
1521,
11,
475,
340,
857,
8133,
198,
198,
2,
543,
2196,
286,
21015,
318,
428,
30,
198,
2,
29884,
5589,
25901,
329,
11361,
1279,
513,
13,
21,
198,
6738,
264,
30454,
13,
15042,
1330,
37399,
198,
28311,
25,
198,
220,
220,
220,
1330,
62,
1069,
11755,
796,
357,
26796,
3673,
21077,
12331,
11,
17267,
12331,
8,
198,
16341,
6530,
12331,
25,
198,
220,
220,
220,
1330,
62,
1069,
11755,
796,
17267,
12331,
628,
628,
198
] | 3.308333 | 120 |
from tkinter import ttk
from tkinter import *
import requests
import json
import os
# variables
page = 0
vplan = None
tableContent = []
navigationLabel = None
leftArrow = None
rightArrow = None
tableHeaders = ["Datum", "Kurs", "Stunde", "Fach", "Raum", "Lehrer", "Info"]
#tableHeaders = ["ID", "Datum", "Kurs", "Stunde", "Fach", "Raum", "Lehrer", "Info"] # test
# config setup
config = {}
configNames = ["Kurs", "History", "Isolate", "width", "height"]
for i in configNames:
config[i] = False
if os.path.exists('config.json'):
config = json.loads(open('config.json', 'r').read())
width = config['width']
height = config['height']
if width < 600:
width = 600
if height < 150:
height = 150
if (width / 50) != (width // 50):
width = (width // 50) * 50
if (height / 50) != (height // 50):
height = (height // 50) * 50
amountRows = (height - 100) // 50
# Tkinter GUI
root = Tk()
root.iconbitmap("icon.ico")
root.title("Vertretungsplan - BBS II Emden //./ by zlyfa! 2018")
root.geometry('%sx%s+0+0' % (width, height))
root.configure(background='#257BF4')
loadingLabel = placeLoadingLabel()
tableHeaderGen()
tableContentGen()
navigationArrowsGen()
navigationLabelGen()
removeLoadingLabel(loadingLabel)
leftArrow.bind('<Enter>', hoverLeftArrowEnter)
leftArrow.bind('<Leave>', hoverLeftArrowLeave)
rightArrow.bind('<Enter>', hoverRightArrowEnter)
rightArrow.bind('<Leave>', hoverRightArrowLeave)
root.mainloop()
| [
6738,
256,
74,
3849,
1330,
256,
30488,
198,
6738,
256,
74,
3849,
1330,
1635,
198,
11748,
7007,
198,
11748,
33918,
198,
11748,
28686,
198,
198,
2,
9633,
198,
198,
7700,
796,
657,
198,
85,
11578,
796,
6045,
198,
11487,
19746,
796,
17635,
198,
28341,
7065,
33986,
796,
6045,
198,
9464,
3163,
808,
796,
6045,
198,
3506,
3163,
808,
796,
6045,
198,
11487,
13847,
364,
796,
14631,
35,
21307,
1600,
366,
42,
1834,
1600,
366,
1273,
917,
68,
1600,
366,
37,
620,
1600,
366,
21762,
388,
1600,
366,
3123,
71,
11751,
1600,
366,
12360,
8973,
198,
2,
11487,
13847,
364,
796,
14631,
2389,
1600,
366,
35,
21307,
1600,
366,
42,
1834,
1600,
366,
1273,
917,
68,
1600,
366,
37,
620,
1600,
366,
21762,
388,
1600,
366,
3123,
71,
11751,
1600,
366,
12360,
8973,
1303,
1332,
198,
198,
2,
4566,
9058,
198,
11250,
796,
23884,
198,
11250,
36690,
796,
14631,
42,
1834,
1600,
366,
18122,
1600,
366,
3792,
27976,
1600,
366,
10394,
1600,
366,
17015,
8973,
198,
1640,
1312,
287,
4566,
36690,
25,
198,
197,
11250,
58,
72,
60,
796,
10352,
198,
361,
28686,
13,
6978,
13,
1069,
1023,
10786,
11250,
13,
17752,
6,
2599,
198,
197,
11250,
796,
33918,
13,
46030,
7,
9654,
10786,
11250,
13,
17752,
3256,
705,
81,
27691,
961,
28955,
198,
198,
10394,
796,
4566,
17816,
10394,
20520,
198,
17015,
796,
4566,
17816,
17015,
20520,
198,
361,
9647,
1279,
10053,
25,
198,
197,
10394,
796,
10053,
198,
361,
6001,
1279,
6640,
25,
198,
197,
17015,
796,
6640,
198,
361,
357,
10394,
1220,
2026,
8,
14512,
357,
10394,
3373,
2026,
2599,
198,
197,
10394,
796,
357,
10394,
3373,
2026,
8,
1635,
2026,
198,
361,
357,
17015,
1220,
2026,
8,
14512,
357,
17015,
3373,
2026,
2599,
198,
197,
17015,
796,
357,
17015,
3373,
2026,
8,
1635,
2026,
198,
17287,
49,
1666,
796,
357,
17015,
532,
1802,
8,
3373,
2026,
198,
198,
2,
309,
74,
3849,
25757,
198,
15763,
796,
309,
74,
3419,
198,
15763,
13,
4749,
2545,
8899,
7203,
4749,
13,
3713,
4943,
198,
15763,
13,
7839,
7203,
42369,
1186,
2150,
82,
11578,
532,
347,
4462,
2873,
2295,
6559,
3373,
19571,
416,
1976,
306,
13331,
0,
2864,
4943,
198,
15763,
13,
469,
15748,
10786,
4,
82,
87,
4,
82,
10,
15,
10,
15,
6,
4064,
357,
10394,
11,
6001,
4008,
198,
15763,
13,
11250,
495,
7,
25249,
11639,
2,
28676,
29499,
19,
11537,
198,
198,
25138,
33986,
796,
1295,
19031,
33986,
3419,
198,
11487,
39681,
13746,
3419,
198,
11487,
19746,
13746,
3419,
198,
28341,
7065,
3163,
8516,
13746,
3419,
198,
28341,
7065,
33986,
13746,
3419,
198,
28956,
19031,
33986,
7,
25138,
33986,
8,
198,
9464,
3163,
808,
13,
21653,
10786,
27,
17469,
29,
3256,
20599,
18819,
3163,
808,
17469,
8,
198,
9464,
3163,
808,
13,
21653,
10786,
27,
35087,
29,
3256,
20599,
18819,
3163,
808,
35087,
8,
198,
3506,
3163,
808,
13,
21653,
10786,
27,
17469,
29,
3256,
20599,
11028,
3163,
808,
17469,
8,
198,
3506,
3163,
808,
13,
21653,
10786,
27,
35087,
29,
3256,
20599,
11028,
3163,
808,
35087,
8,
198,
198,
15763,
13,
12417,
26268,
3419,
198
] | 2.781925 | 509 |
from karabo.simulation.coordinate_helper import east_north_to_long_lat
from karabo.simulation.east_north_coordinate import EastNorthCoordinate
| [
6738,
479,
283,
34748,
13,
14323,
1741,
13,
37652,
4559,
62,
2978,
525,
1330,
7627,
62,
43588,
62,
1462,
62,
6511,
62,
15460,
198,
6738,
479,
283,
34748,
13,
14323,
1741,
13,
23316,
62,
43588,
62,
37652,
4559,
1330,
3687,
14157,
7222,
45480,
198
] | 3.25 | 44 |
from pydrive.auth import GoogleAuth
from pydrive.drive import GoogleDrive
import spec2model.config_manager as yml_manager
config_file_path = 'spec2model/configuration.yml'
| [
6738,
279,
5173,
11590,
13,
18439,
1330,
3012,
30515,
198,
6738,
279,
5173,
11590,
13,
19472,
1330,
3012,
24825,
198,
11748,
1020,
17,
19849,
13,
11250,
62,
37153,
355,
331,
4029,
62,
37153,
198,
198,
11250,
62,
7753,
62,
6978,
796,
705,
16684,
17,
19849,
14,
11250,
3924,
13,
88,
4029,
6,
198
] | 3.264151 | 53 |
#! /usr/bin/python3
# Author: Cavyn VonDeylen
# Date: August 2010
# Larson-Group UWM
# Updated to python 3 by Tyler Cernik
from __future__ import print_function
from __future__ import division
from __future__ import unicode_literals
import struct # Handles binary data
#--------------------------------------------------------------------------------------------------
def readGradsData(fileName, numLevels, begTime, endTime, varNum, numVars):
"""
Reads a GrADS *.dat file and obtains a single-time or time-averaged profile.
Input: filename: A GrADS *.dat file
numLevels: Number of z levels in profile
begTime: Iteration to start averaging at
endTime: Iteration to end averaging at
varNum: Which variable to read (see .ctl file)
numVars: Total number of variables in grads file (see .ctl file)
"""
timeInterval = (endTime-begTime) + 1
# Open in read-binary mode
dataFile = open(fileName, "rb")
# Declare array with one slot per z level
avgField = [0] * numLevels
# Add data from each time iteration to avgField
time = begTime
while True: # Strange loop construct because python doesn't have do-while loops
byte_position = 4*( (varNum-1)*numLevels+numVars*numLevels*(time-1) )
dataFile.seek(byte_position)
# Read data in for each z level
zLevel = 0
while zLevel < numLevels:
# Read 4 bytes
binaryData = dataFile.read(4)
# Translate binary data to a float.
avgField[zLevel] = avgField[zLevel] + list(struct.unpack("f", binaryData))[0]
zLevel += 1
time += 1
if time >= endTime:
break
# Divide by total number of iterations to come up
# with average value across all iterations for each z level
zLevel = 0
while zLevel < numLevels:
avgField[zLevel] = avgField[zLevel]//timeInterval
zLevel += 1
dataFile.close()
return avgField
#--------------------------------------------------------------------------------------------------
# Allows this module to be run as a script
if __name__ == "__main__":
import sys
# If wrong arguments were given, print a helpful message
if len(sys.argv) != 7:
print('Arguments must be: filename z_levels beg_time end_time var_number number_vars')
sys.exit(0)
print(readNetcdfData( sys.argv[1], int(sys.argv[2]), int(sys.argv[3]), int(sys.argv[4]), \
int(sys.argv[5]), int(sys.argv[6]) ))
| [
2,
0,
1220,
14629,
14,
8800,
14,
29412,
18,
198,
2,
6434,
25,
19931,
2047,
26985,
5005,
2645,
268,
198,
2,
7536,
25,
2932,
3050,
198,
2,
42630,
12,
13247,
471,
22117,
198,
2,
19433,
284,
21015,
513,
416,
14886,
327,
1142,
1134,
198,
198,
6738,
11593,
37443,
834,
1330,
3601,
62,
8818,
198,
6738,
11593,
37443,
834,
1330,
7297,
198,
6738,
11593,
37443,
834,
1330,
28000,
1098,
62,
17201,
874,
198,
11748,
2878,
1303,
7157,
829,
13934,
1366,
198,
198,
2,
10097,
3880,
438,
198,
4299,
1100,
8642,
5643,
6601,
7,
7753,
5376,
11,
997,
4971,
82,
11,
4123,
7575,
11,
886,
7575,
11,
1401,
33111,
11,
997,
53,
945,
2599,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
4149,
82,
257,
1902,
47149,
46866,
19608,
2393,
290,
909,
12143,
257,
2060,
12,
2435,
393,
640,
12,
8770,
1886,
7034,
13,
198,
220,
220,
220,
23412,
25,
29472,
25,
317,
1902,
47149,
46866,
19608,
2393,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
997,
4971,
82,
25,
7913,
286,
1976,
2974,
287,
7034,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
4123,
7575,
25,
40806,
341,
284,
923,
20430,
379,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
886,
7575,
25,
40806,
341,
284,
886,
20430,
379,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1401,
33111,
25,
9022,
7885,
284,
1100,
357,
3826,
764,
34168,
2393,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
997,
53,
945,
25,
7472,
1271,
286,
9633,
287,
3915,
82,
2393,
357,
3826,
764,
34168,
2393,
8,
198,
220,
220,
220,
37227,
198,
220,
220,
220,
220,
198,
220,
220,
220,
640,
9492,
2100,
796,
357,
437,
7575,
12,
1350,
70,
7575,
8,
1343,
352,
198,
220,
220,
220,
220,
220,
220,
220,
220,
198,
220,
220,
220,
1303,
4946,
287,
1100,
12,
39491,
4235,
198,
220,
220,
220,
1366,
8979,
796,
1280,
7,
7753,
5376,
11,
366,
26145,
4943,
628,
220,
220,
220,
1303,
16691,
533,
7177,
351,
530,
10852,
583,
1976,
1241,
198,
220,
220,
220,
42781,
15878,
796,
685,
15,
60,
1635,
997,
4971,
82,
628,
220,
220,
220,
1303,
3060,
1366,
422,
1123,
640,
24415,
284,
42781,
15878,
198,
220,
220,
220,
640,
796,
4123,
7575,
198,
220,
220,
220,
981,
6407,
25,
1303,
16810,
9052,
5678,
780,
21015,
1595,
470,
423,
466,
12,
4514,
23607,
198,
220,
220,
220,
220,
220,
220,
220,
18022,
62,
9150,
796,
604,
9,
7,
357,
7785,
33111,
12,
16,
27493,
22510,
4971,
82,
10,
22510,
53,
945,
9,
22510,
4971,
82,
9,
7,
2435,
12,
16,
8,
1267,
198,
220,
220,
220,
220,
220,
220,
220,
1366,
8979,
13,
36163,
7,
26327,
62,
9150,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
198,
220,
220,
220,
220,
220,
220,
220,
1303,
4149,
1366,
287,
329,
1123,
1976,
1241,
198,
220,
220,
220,
220,
220,
220,
220,
1976,
4971,
796,
657,
198,
220,
220,
220,
220,
220,
220,
220,
981,
1976,
4971,
1279,
997,
4971,
82,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1303,
4149,
604,
9881,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
13934,
6601,
796,
1366,
8979,
13,
961,
7,
19,
8,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1303,
3602,
17660,
13934,
1366,
284,
257,
12178,
13,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
42781,
15878,
58,
89,
4971,
60,
796,
42781,
15878,
58,
89,
4971,
60,
1343,
1351,
7,
7249,
13,
403,
8002,
7203,
69,
1600,
13934,
6601,
4008,
58,
15,
60,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
1976,
4971,
15853,
352,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
198,
220,
220,
220,
220,
220,
220,
220,
640,
15853,
352,
198,
220,
220,
220,
220,
220,
220,
220,
611,
640,
18189,
886,
7575,
25,
198,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
220,
2270,
628,
220,
220,
220,
1303,
46894,
416,
2472,
1271,
286,
34820,
284,
1282,
510,
198,
220,
220,
220,
1303,
351,
2811,
1988,
1973,
477,
34820,
329,
1123,
1976,
1241,
198,
220,
220,
220,
1976,
4971,
796,
657,
198,
220,
220,
220,
981,
1976,
4971,
1279,
997,
4971,
82,
25,
198,
220,
220,
220,
220,
220,
220,
220,
42781,
15878,
58,
89,
4971,
60,
796,
42781,
15878,
58,
89,
4971,
60,
1003,
2435,
9492,
2100,
198,
220,
220,
220,
220,
220,
220,
220,
1976,
4971,
15853,
352,
628,
220,
220,
220,
1366,
8979,
13,
19836,
3419,
198,
220,
220,
220,
1441,
42781,
15878,
198,
220,
220,
220,
220,
198,
2,
10097,
3880,
438,
198,
2,
40402,
428,
8265,
284,
307,
1057,
355,
257,
4226,
198,
361,
11593,
3672,
834,
6624,
366,
834,
12417,
834,
1298,
628,
220,
220,
220,
1330,
25064,
198,
220,
220,
220,
220,
198,
220,
220,
220,
1303,
1002,
2642,
7159,
547,
1813,
11,
3601,
257,
7613,
3275,
198,
220,
220,
220,
611,
18896,
7,
17597,
13,
853,
85,
8,
14512,
767,
25,
198,
220,
220,
220,
220,
220,
220,
220,
3601,
10786,
28100,
2886,
1276,
307,
25,
29472,
1976,
62,
46170,
4123,
62,
2435,
886,
62,
2435,
1401,
62,
17618,
1271,
62,
85,
945,
11537,
198,
220,
220,
220,
220,
220,
220,
220,
25064,
13,
37023,
7,
15,
8,
198,
220,
220,
220,
220,
198,
220,
220,
220,
3601,
7,
961,
7934,
66,
7568,
6601,
7,
25064,
13,
853,
85,
58,
16,
4357,
493,
7,
17597,
13,
853,
85,
58,
17,
46570,
493,
7,
17597,
13,
853,
85,
58,
18,
46570,
493,
7,
17597,
13,
853,
85,
58,
19,
46570,
3467,
198,
220,
220,
220,
220,
220,
220,
220,
493,
7,
17597,
13,
853,
85,
58,
20,
46570,
493,
7,
17597,
13,
853,
85,
58,
21,
12962,
15306,
198
] | 2.62831 | 982 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.