hexsha
string
size
int64
ext
string
lang
string
max_stars_repo_path
string
max_stars_repo_name
string
max_stars_repo_head_hexsha
string
max_stars_repo_licenses
list
max_stars_count
int64
max_stars_repo_stars_event_min_datetime
string
max_stars_repo_stars_event_max_datetime
string
max_issues_repo_path
string
max_issues_repo_name
string
max_issues_repo_head_hexsha
string
max_issues_repo_licenses
list
max_issues_count
int64
max_issues_repo_issues_event_min_datetime
string
max_issues_repo_issues_event_max_datetime
string
max_forks_repo_path
string
max_forks_repo_name
string
max_forks_repo_head_hexsha
string
max_forks_repo_licenses
list
max_forks_count
int64
max_forks_repo_forks_event_min_datetime
string
max_forks_repo_forks_event_max_datetime
string
content
string
avg_line_length
float64
max_line_length
int64
alphanum_fraction
float64
qsc_code_num_words_quality_signal
int64
qsc_code_num_chars_quality_signal
float64
qsc_code_mean_word_length_quality_signal
float64
qsc_code_frac_words_unique_quality_signal
float64
qsc_code_frac_chars_top_2grams_quality_signal
float64
qsc_code_frac_chars_top_3grams_quality_signal
float64
qsc_code_frac_chars_top_4grams_quality_signal
float64
qsc_code_frac_chars_dupe_5grams_quality_signal
float64
qsc_code_frac_chars_dupe_6grams_quality_signal
float64
qsc_code_frac_chars_dupe_7grams_quality_signal
float64
qsc_code_frac_chars_dupe_8grams_quality_signal
float64
qsc_code_frac_chars_dupe_9grams_quality_signal
float64
qsc_code_frac_chars_dupe_10grams_quality_signal
float64
qsc_code_frac_chars_replacement_symbols_quality_signal
float64
qsc_code_frac_chars_digital_quality_signal
float64
qsc_code_frac_chars_whitespace_quality_signal
float64
qsc_code_size_file_byte_quality_signal
float64
qsc_code_num_lines_quality_signal
float64
qsc_code_num_chars_line_max_quality_signal
float64
qsc_code_num_chars_line_mean_quality_signal
float64
qsc_code_frac_chars_alphabet_quality_signal
float64
qsc_code_frac_chars_comments_quality_signal
float64
qsc_code_cate_xml_start_quality_signal
float64
qsc_code_frac_lines_dupe_lines_quality_signal
float64
qsc_code_cate_autogen_quality_signal
float64
qsc_code_frac_lines_long_string_quality_signal
float64
qsc_code_frac_chars_string_length_quality_signal
float64
qsc_code_frac_chars_long_word_length_quality_signal
float64
qsc_code_frac_lines_string_concat_quality_signal
float64
qsc_code_cate_encoded_data_quality_signal
float64
qsc_code_frac_chars_hex_words_quality_signal
float64
qsc_code_frac_lines_prompt_comments_quality_signal
float64
qsc_code_frac_lines_assert_quality_signal
float64
qsc_codepython_cate_ast_quality_signal
float64
qsc_codepython_frac_lines_func_ratio_quality_signal
float64
qsc_codepython_cate_var_zero_quality_signal
bool
qsc_codepython_frac_lines_pass_quality_signal
float64
qsc_codepython_frac_lines_import_quality_signal
float64
qsc_codepython_frac_lines_simplefunc_quality_signal
float64
qsc_codepython_score_lines_no_logic_quality_signal
float64
qsc_codepython_frac_lines_print_quality_signal
float64
qsc_code_num_words
int64
qsc_code_num_chars
int64
qsc_code_mean_word_length
int64
qsc_code_frac_words_unique
null
qsc_code_frac_chars_top_2grams
int64
qsc_code_frac_chars_top_3grams
int64
qsc_code_frac_chars_top_4grams
int64
qsc_code_frac_chars_dupe_5grams
int64
qsc_code_frac_chars_dupe_6grams
int64
qsc_code_frac_chars_dupe_7grams
int64
qsc_code_frac_chars_dupe_8grams
int64
qsc_code_frac_chars_dupe_9grams
int64
qsc_code_frac_chars_dupe_10grams
int64
qsc_code_frac_chars_replacement_symbols
int64
qsc_code_frac_chars_digital
int64
qsc_code_frac_chars_whitespace
int64
qsc_code_size_file_byte
int64
qsc_code_num_lines
int64
qsc_code_num_chars_line_max
int64
qsc_code_num_chars_line_mean
int64
qsc_code_frac_chars_alphabet
int64
qsc_code_frac_chars_comments
int64
qsc_code_cate_xml_start
int64
qsc_code_frac_lines_dupe_lines
int64
qsc_code_cate_autogen
int64
qsc_code_frac_lines_long_string
int64
qsc_code_frac_chars_string_length
int64
qsc_code_frac_chars_long_word_length
int64
qsc_code_frac_lines_string_concat
null
qsc_code_cate_encoded_data
int64
qsc_code_frac_chars_hex_words
int64
qsc_code_frac_lines_prompt_comments
int64
qsc_code_frac_lines_assert
int64
qsc_codepython_cate_ast
int64
qsc_codepython_frac_lines_func_ratio
int64
qsc_codepython_cate_var_zero
int64
qsc_codepython_frac_lines_pass
int64
qsc_codepython_frac_lines_import
int64
qsc_codepython_frac_lines_simplefunc
int64
qsc_codepython_score_lines_no_logic
int64
qsc_codepython_frac_lines_print
int64
effective
string
hits
int64
302c9404038c9a9bf2ef91790a1e8062cd4b2b2a
82
py
Python
fastapi/openapi/query.py
takusan64/fastapi-postgres-startkit
3235f7252174c07d8cdd354d49193c1597c8bd53
[ "Apache-2.0" ]
null
null
null
fastapi/openapi/query.py
takusan64/fastapi-postgres-startkit
3235f7252174c07d8cdd354d49193c1597c8bd53
[ "Apache-2.0" ]
null
null
null
fastapi/openapi/query.py
takusan64/fastapi-postgres-startkit
3235f7252174c07d8cdd354d49193c1597c8bd53
[ "Apache-2.0" ]
null
null
null
from pydantic import BaseModel class Query_Model(BaseModel): country_id: int
20.5
31
0.792683
11
82
5.727273
0.909091
0
0
0
0
0
0
0
0
0
0
0
0.158537
82
4
32
20.5
0.913043
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.333333
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
064d3c29ad7a8cdfd2e27adf70ff529f5f4dca4f
222
py
Python
torchfes/ts/__init__.py
AkihideHayashi/torchfes1
83f01525e6071ffd7a884c8e108f9c25ba2b009b
[ "MIT" ]
null
null
null
torchfes/ts/__init__.py
AkihideHayashi/torchfes1
83f01525e6071ffd7a884c8e108f9c25ba2b009b
[ "MIT" ]
null
null
null
torchfes/ts/__init__.py
AkihideHayashi/torchfes1
83f01525e6071ffd7a884c8e108f9c25ba2b009b
[ "MIT" ]
null
null
null
# flake8: noqa from . import neb from .neb import ElasticBand # from .neb import NudgedElasticBand, DoublyNudgedElasticBand, DoublyClimbingNudgedElasticBand from .utils import linear_interpolation from .dimer import Dimer
31.714286
94
0.837838
24
222
7.708333
0.541667
0.075676
0.140541
0
0
0
0
0
0
0
0
0.005102
0.117117
222
6
95
37
0.938776
0.472973
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
0664faaf3a5c09ea5d8e44c15f071c6b47ba92c7
98
py
Python
tests/conftest.py
pyapp-org/pyapp.elasticsearch
6d16c906a0048aed20fb657ba5b92885853d6172
[ "BSD-3-Clause" ]
null
null
null
tests/conftest.py
pyapp-org/pyapp.elasticsearch
6d16c906a0048aed20fb657ba5b92885853d6172
[ "BSD-3-Clause" ]
51
2020-08-10T08:08:20.000Z
2022-03-28T09:01:48.000Z
tests/conftest.py
pyapp-org/pyapp.elasticsearch
6d16c906a0048aed20fb657ba5b92885853d6172
[ "BSD-3-Clause" ]
null
null
null
from pyapp.conf import settings settings.configure(["pyapp_ext.elasticsearch.default_settings"])
24.5
64
0.836735
12
98
6.666667
0.75
0
0
0
0
0
0
0
0
0
0
0
0.061224
98
3
65
32.666667
0.869565
0
0
0
0
0
0.408163
0.408163
0
0
0
0
0
1
0
true
0
0.5
0
0.5
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
1
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
06830a4e3b6adaa3067c47d362852590e0304dea
445
py
Python
fasp/workflow/__init__.py
jb-adams/fasp-scripts
04fb6781f0a72ca1a8b97f6f5d09fc5e166e4595
[ "Apache-2.0" ]
8
2020-09-30T16:45:07.000Z
2021-10-01T09:02:59.000Z
fasp/workflow/__init__.py
jb-adams/fasp-scripts
04fb6781f0a72ca1a8b97f6f5d09fc5e166e4595
[ "Apache-2.0" ]
28
2020-10-09T12:07:26.000Z
2021-04-18T16:33:36.000Z
fasp/workflow/__init__.py
jb-adams/fasp-scripts
04fb6781f0a72ca1a8b97f6f5d09fc5e166e4595
[ "Apache-2.0" ]
3
2020-11-27T17:49:28.000Z
2021-03-10T17:33:38.000Z
from fasp.workflow.wesclient import WESClient from fasp.workflow.dnastack_wesclient import DNAStackWESClient from fasp.workflow.sb_wes_client import sbWESClient from fasp.workflow.sb_wes_client import sbcgcWESClient from fasp.workflow.sb_wes_client import cavaticaWESClient from fasp.workflow.gcpls_samtools import GCPLSsamtools from fasp.workflow.sb_samtools import samtoolsSBClient from fasp.workflow.elixir_wesclient import ElixirWESClient
40.454545
62
0.88764
58
445
6.637931
0.327586
0.166234
0.332468
0.187013
0.257143
0.257143
0.257143
0
0
0
0
0
0.076404
445
11
63
40.454545
0.93674
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
0
0
0
null
0
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
233bcad252a5f4fa2c2df6ab6080f7d54720139d
45
py
Python
face_pose_dataset/estimation/ensemble/__init__.py
samuelbaltanas/face-pose-dataset
84c864c155ac7c0b231032d403c0e2b2bc10b871
[ "MIT" ]
1
2020-06-18T07:58:46.000Z
2020-06-18T07:58:46.000Z
face_pose_dataset/estimation/ensemble/__init__.py
samuelbaltanas/face-pose-dataset
84c864c155ac7c0b231032d403c0e2b2bc10b871
[ "MIT" ]
null
null
null
face_pose_dataset/estimation/ensemble/__init__.py
samuelbaltanas/face-pose-dataset
84c864c155ac7c0b231032d403c0e2b2bc10b871
[ "MIT" ]
null
null
null
from .average import * # from .nnet import *
15
22
0.688889
6
45
5.166667
0.666667
0
0
0
0
0
0
0
0
0
0
0
0.2
45
2
23
22.5
0.861111
0.422222
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
2362db51ee4f61fdac2b40dc4f1ab509cdac350d
77
py
Python
demos/instance_occlsegm/instance_occlsegm_lib/contrib/synthetic2d/evaluations/__init__.py
pazeshun/jsk_apc
0ff42000ad5992f8a31e719a5360a39cf4fa1fde
[ "BSD-3-Clause" ]
null
null
null
demos/instance_occlsegm/instance_occlsegm_lib/contrib/synthetic2d/evaluations/__init__.py
pazeshun/jsk_apc
0ff42000ad5992f8a31e719a5360a39cf4fa1fde
[ "BSD-3-Clause" ]
2
2019-04-11T05:36:23.000Z
2019-08-19T12:58:10.000Z
demos/instance_occlsegm/instance_occlsegm_lib/contrib/synthetic2d/evaluations/__init__.py
pazeshun/jsk_apc
0ff42000ad5992f8a31e719a5360a39cf4fa1fde
[ "BSD-3-Clause" ]
null
null
null
# flake8: noqa from .eval_instance_segmentation_voc import eval_instseg_voc
19.25
60
0.857143
11
77
5.545455
0.818182
0
0
0
0
0
0
0
0
0
0
0.014493
0.103896
77
3
61
25.666667
0.869565
0.155844
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
88bdc1137e5aa84726bcc7329a022a98a83256e2
136
py
Python
Parte1/Cap2/exercicios/num_favorito.py
fabianoflorentino/python-CursoIntensivoDePython
822288cc4b382936dde1bc647e3f8c2b925ced70
[ "Apache-2.0" ]
null
null
null
Parte1/Cap2/exercicios/num_favorito.py
fabianoflorentino/python-CursoIntensivoDePython
822288cc4b382936dde1bc647e3f8c2b925ced70
[ "Apache-2.0" ]
null
null
null
Parte1/Cap2/exercicios/num_favorito.py
fabianoflorentino/python-CursoIntensivoDePython
822288cc4b382936dde1bc647e3f8c2b925ced70
[ "Apache-2.0" ]
1
2020-02-05T13:07:08.000Z
2020-02-05T13:07:08.000Z
# variável que armazena o número favorito num1 = 7 # mostra mensagem com o número favorito print(f'\nMeu número favorito é: {num1}\n')
22.666667
43
0.742647
22
136
4.590909
0.727273
0.415842
0.29703
0
0
0
0
0
0
0
0
0.026549
0.169118
136
5
44
27.2
0.867257
0.566176
0
0
0
0
0.589286
0
0
0
0
0
0
1
0
false
0
0
0
0
0.5
1
0
0
null
1
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
1
0
5
001b55e4f142dea03288dc4a062ebc06ab861744
168
py
Python
app/__init__.py
mcproger/check-friends-vk
aaa5e8e956df1349382fdb61d54f41b4defe2328
[ "Unlicense" ]
null
null
null
app/__init__.py
mcproger/check-friends-vk
aaa5e8e956df1349382fdb61d54f41b4defe2328
[ "Unlicense" ]
null
null
null
app/__init__.py
mcproger/check-friends-vk
aaa5e8e956df1349382fdb61d54f41b4defe2328
[ "Unlicense" ]
null
null
null
from flask import Flask app = Flask(__name__) app.config.from_object('config') from app import views from app import Autorization from app import check_friends
21
33
0.779762
25
168
5
0.44
0.168
0.312
0
0
0
0
0
0
0
0
0
0.166667
168
8
34
21
0.892857
0
0
0
0
0
0.037037
0
0
0
0
0
0
1
0
false
0
0.666667
0
0.666667
0
1
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
5
001f2127e8746b4707826ebccf3eeefa856463d5
646
py
Python
data/IEEE802_16_2009_R3_4_A.py
DELTA37/LDPC-code
e055685d8dfebd50fa19a2638a8934b4a43b7ad3
[ "BSD-2-Clause" ]
2
2020-10-21T07:13:28.000Z
2020-10-21T17:03:35.000Z
data/IEEE802_16_2009_R3_4_A.py
DELTA37/LDPC-code
e055685d8dfebd50fa19a2638a8934b4a43b7ad3
[ "BSD-2-Clause" ]
null
null
null
data/IEEE802_16_2009_R3_4_A.py
DELTA37/LDPC-code
e055685d8dfebd50fa19a2638a8934b4a43b7ad3
[ "BSD-2-Clause" ]
null
null
null
import numpy as np C = np.array([ 6, 38, 3, 93, -1, -1, -1, 30, 70, -1, 86, -1, 37, 38, 4, 11, -1, 46, 48, 0, -1, -1, -1, -1, 62, 94, 19, 84, -1, 92, 78, -1, 15, -1, -1, 92, -1, 45, 24, 32, 30, -1, -1, 0, 0, -1, -1, -1, 71, -1, 55, -1, 12, 66, 45, 79, -1, 78, -1, -1, 10, -1, 22, 55, 70, 82, -1, -1, 0, 0, -1, -1, 38, 61, -1, 66, 9, 73, 47, 64, -1, 39, 61, 43, -1, -1, -1, -1, 95, 32, 0, -1, -1, 0, 0, -1, -1, -1, -1, -1, 32, 52, 55, 80, 95, 22, 6, 51, 24, 90, 44, 20, -1, -1, -1, -1, -1, -1, 0, 0, -1, 63, 31, 88, 20, -1, -1, -1, 6, 40, 56, 16, 71, 53, -1, -1, 27, 26, 48, -1, -1, -1, -1, 0 ]).reshape((6, -1)) r = 96
46.142857
97
0.382353
156
646
1.583333
0.410256
0.251012
0.194332
0.129555
0.165992
0.080972
0.05668
0
0
0
0
0.466523
0.283282
646
13
98
49.692308
0.066955
0
0
0
0
0
0
0
0
0
0
0
0
1
0
false
0
0.1
0
0.1
0
0
0
1
null
1
1
0
0
0
0
0
0
0
0
1
0
0
0
0
0
1
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
002ab15a58736ea028ff0a9b03a185797c931101
138
py
Python
tests/clazz/base/module_1.py
hiroki0525/autoload_module
f3e10dc02d0fd24b8caa872f8c71f8902dc44f83
[ "MIT" ]
10
2020-08-28T13:08:06.000Z
2021-12-21T12:03:05.000Z
tests/clazz/base/module_1.py
hiroki0525/autoload_module
f3e10dc02d0fd24b8caa872f8c71f8902dc44f83
[ "MIT" ]
null
null
null
tests/clazz/base/module_1.py
hiroki0525/autoload_module
f3e10dc02d0fd24b8caa872f8c71f8902dc44f83
[ "MIT" ]
null
null
null
import math from tests.clazz.testmodule import TestModule class Module1(TestModule): def add(self, x): return math.acos(x)
15.333333
45
0.710145
19
138
5.157895
0.736842
0
0
0
0
0
0
0
0
0
0
0.009091
0.202899
138
9
46
15.333333
0.881818
0
0
0
0
0
0
0
0
0
0
0
0
1
0.2
false
0
0.4
0.2
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
1
1
0
0
5
004c455183a42c2d3775b7cf403787a96a4d84e4
144
py
Python
build/lib/stockkly_repo/pricesBusiness.py
squeakycheese75/stockkly_repo
f560128be0cae0eb9b5fdc6d12efb25702deda64
[ "MIT" ]
null
null
null
build/lib/stockkly_repo/pricesBusiness.py
squeakycheese75/stockkly_repo
f560128be0cae0eb9b5fdc6d12efb25702deda64
[ "MIT" ]
null
null
null
build/lib/stockkly_repo/pricesBusiness.py
squeakycheese75/stockkly_repo
f560128be0cae0eb9b5fdc6d12efb25702deda64
[ "MIT" ]
null
null
null
import datetime def calc_movement(change, price): return (change / price) * 100 def calc_change(price, open): return (price - open)
14.4
33
0.6875
19
144
5.105263
0.526316
0.340206
0
0
0
0
0
0
0
0
0
0.026316
0.208333
144
9
34
16
0.824561
0
0
0
0
0
0
0
0
0
0
0
0
1
0.4
false
0
0.2
0.4
1
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
1
0
0
0
5
cc3ca209dded7c28a6d548edc5352602dc006f7c
3,417
py
Python
srfnef/ops/deform_mixins.py
twj2417/srf
63365cfd75199d70eea2273214a4fa580a9fdf2a
[ "Apache-2.0" ]
null
null
null
srfnef/ops/deform_mixins.py
twj2417/srf
63365cfd75199d70eea2273214a4fa580a9fdf2a
[ "Apache-2.0" ]
null
null
null
srfnef/ops/deform_mixins.py
twj2417/srf
63365cfd75199d70eea2273214a4fa580a9fdf2a
[ "Apache-2.0" ]
null
null
null
# encoding: utf-8 ''' @author: Minghao Guo @contact: mh.guo0111@gmail.com @software: nef @file: deform_mixin.py @date: 5/6/2019 @desc: ''' from srfnef import nef_class import tensorflow as tf from srfnef.config import TF_USER_OP_PATH import attr deform_tex_module = tf.load_op_library(TF_USER_OP_PATH + '/tf_deform_tex_module.so') @nef_class class DeformMixin: def _deform_tf(self, image_data: tf.Tensor, mx: tf.Tensor, my: tf.Tensor, mz: tf.Tensor) -> tf.Tensor: image_shape = [int(s) for s in image_data.shape] if isinstance(image_data, tf.Variable): image_data_tf = tf.transpose(image_data) else: image_data_tf = tf.transpose(tf.constant(image_data)) if isinstance(mx, tf.Tensor): mx_tf = tf.transpose(mx) else: mx_tf = tf.transpose(tf.constant(mx)) if isinstance(my, tf.Tensor): my_tf = tf.transpose(my) else: my_tf = tf.transpose(tf.constant(my)) if isinstance(mz, tf.Tensor): mz_tf = tf.transpose(mz) else: mz_tf = tf.transpose(tf.constant(mz)) return tf.transpose( deform_tex_module.deform(image_data_tf, mx_tf, my_tf, mz_tf, image_shape)) def _deform_invert_tf(self, image_data: tf.Tensor, mx: tf.Tensor, my: tf.Tensor, mz: tf.Tensor) -> tf.Tensor: image_shape = [int(s) for s in image_data.shape] if isinstance(image_data, tf.Variable): image_data_tf = tf.transpose(image_data) else: image_data_tf = tf.transpose(tf.constant(image_data)) if isinstance(mx, tf.Tensor): mx_tf = tf.transpose(mx) else: mx_tf = tf.transpose(tf.constant(mx)) if isinstance(my, tf.Tensor): my_tf = tf.transpose(my) else: my_tf = tf.transpose(tf.constant(my)) if isinstance(mz, tf.Tensor): mz_tf = tf.transpose(mz) else: mz_tf = tf.transpose(tf.constant(mz)) return tf.transpose(deform_tex_module.deform_invert(image_data_tf, mx_tf, my_tf, mz_tf, image_shape)) def _shift_tf(self, image_data: tf.Tensor, mx: float, my: float, mz: float) -> tf.Tensor: image_shape = [int(s) for s in image_data.shape] image_data_tf = tf.transpose(tf.constant(image_data)) return tf.transpose(deform_tex_module.shift(image_data_tf, mx, my, mz, image_shape)) def _shift_z_tf(self, image_data: tf.Tensor, mz: float) -> tf.Tensor: image_shape = [int(s) for s in image_data.shape] image_data_tf = tf.transpose(tf.constant(image_data)) return tf.transpose(deform_tex_module.shift_z(image_data_tf, mz, image_shape)) def _rotate_tf(self, image_data: tf.Tensor, angle: float): import numpy as np cos_angle = np.cos(angle) sin_angle = np.sin(angle) image_shape = [int(s) for s in image_data.shape] image_data_tf = tf.transpose(tf.constant(image_data)) return tf.transpose( deform_tex_module.rotate(image_data_tf, image_shape, cos_phi = cos_angle, sin_phi = sin_angle))
38.829545
93
0.590284
470
3,417
4.042553
0.151064
0.146842
0.11
0.086842
0.738947
0.738947
0.714737
0.701579
0.701579
0.701579
0
0.004641
0.306409
3,417
87
94
39.275862
0.797046
0.037752
0
0.676056
0
0
0.007317
0.007317
0
0
0
0
0
1
0.070423
false
0
0.070423
0
0.225352
0
0
0
0
null
0
0
0
0
1
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
cc678621efca294a70bcb21a8df085e5898f69f4
311
py
Python
rubrik_mosaic/exceptions.py
rubrikinc/rubrik-mosaic-sdk-for-python
f9d44e3fe2ece58c42957649e112a590d5f74b05
[ "MIT" ]
null
null
null
rubrik_mosaic/exceptions.py
rubrikinc/rubrik-mosaic-sdk-for-python
f9d44e3fe2ece58c42957649e112a590d5f74b05
[ "MIT" ]
2
2019-08-12T07:31:10.000Z
2019-08-12T07:31:16.000Z
rubrik_mosaic/exceptions.py
rubrikinc/rubrik-mosaic-sdk-for-python
f9d44e3fe2ece58c42957649e112a590d5f74b05
[ "MIT" ]
null
null
null
import sys import traceback class RubrikException(Exception): """Base class for exceptions in this module.""" pass class RubrikConnectionException(RubrikException): pass class InvalidAPIEndPointException(RubrikException): pass class MissingCredentialException(RubrikException): pass
15.55
51
0.77492
27
311
8.925926
0.592593
0.112033
0.19917
0
0
0
0
0
0
0
0
0
0.163987
311
19
52
16.368421
0.926923
0.131833
0
0.4
0
0
0
0
0
0
0
0
0
1
0
true
0.4
0.2
0
0.6
0
1
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
1
0
0
1
0
0
5
ccb2548a1b70b8d5b56835bd204d8d33acfbddb9
276
py
Python
hysds/__init__.py
hysds/hysds
839d527114e115603ea0a2c4c1b7fe474f7b7b39
[ "Apache-2.0" ]
17
2018-04-30T17:53:23.000Z
2021-11-10T18:24:24.000Z
hysds/__init__.py
hysds/hysds
839d527114e115603ea0a2c4c1b7fe474f7b7b39
[ "Apache-2.0" ]
54
2017-10-17T23:22:53.000Z
2022-02-09T22:05:07.000Z
hysds/__init__.py
hysds/hysds
839d527114e115603ea0a2c4c1b7fe474f7b7b39
[ "Apache-2.0" ]
9
2018-01-13T01:07:21.000Z
2021-02-25T21:21:43.000Z
from __future__ import unicode_literals from __future__ import print_function from __future__ import division from __future__ import absolute_import __version__ = "1.1.3" __url__ = "https://github.com/hysds/hysds" __description__ = "HySDS (Hybrid Cloud Science Data System)"
30.666667
60
0.818841
36
276
5.416667
0.638889
0.205128
0.328205
0
0
0
0
0
0
0
0
0.012245
0.112319
276
8
61
34.5
0.783673
0
0
0
0
0
0.271739
0
0
0
0
0
0
1
0
false
0
0.571429
0
0.571429
0.142857
0
0
0
null
1
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
5
ccd65428bc283ca70a90b02e7a5266d6b7ca44bd
74
py
Python
deliravision/torch/models/gans/relativistic/__init__.py
delira-dev/vision_torch
d944aa67d319bd63a2add5cb89e8308413943de6
[ "BSD-2-Clause" ]
4
2019-08-03T09:56:50.000Z
2019-09-05T09:32:06.000Z
deliravision/torch/models/gans/relativistic/__init__.py
delira-dev/vision_torch
d944aa67d319bd63a2add5cb89e8308413943de6
[ "BSD-2-Clause" ]
23
2019-08-03T14:16:47.000Z
2019-10-22T10:15:10.000Z
deliravision/torch/models/gans/relativistic/__init__.py
delira-dev/vision_torch
d944aa67d319bd63a2add5cb89e8308413943de6
[ "BSD-2-Clause" ]
null
null
null
from deliravision.models.gans.relativistic.rel_gan import RelativisticGAN
37
73
0.891892
9
74
7.222222
1
0
0
0
0
0
0
0
0
0
0
0
0.054054
74
1
74
74
0.928571
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
aecad4f47c4163264880a45629e5599da043c22f
93
py
Python
wrench/metalearning/__init__.py
Stranger469/ARS2
b6d62b66997180abe01b676d5359c20daa42b7ad
[ "Apache-2.0" ]
null
null
null
wrench/metalearning/__init__.py
Stranger469/ARS2
b6d62b66997180abe01b676d5359c20daa42b7ad
[ "Apache-2.0" ]
null
null
null
wrench/metalearning/__init__.py
Stranger469/ARS2
b6d62b66997180abe01b676d5359c20daa42b7ad
[ "Apache-2.0" ]
null
null
null
from .learn_to_reweight import LearningToReweight from .meta_weight_net import MetaWeightNet
31
49
0.892473
12
93
6.583333
0.833333
0
0
0
0
0
0
0
0
0
0
0
0.086022
93
2
50
46.5
0.929412
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
aed224304581d3e0ad8c5c981c9126477a356bf6
94
py
Python
request_manager/exceptions.py
renatolipi/request-manager
98a8d66a9a663f2e0aad2d2e366e93b071936394
[ "MIT" ]
4
2018-09-23T12:44:43.000Z
2020-09-01T23:16:41.000Z
request_manager/exceptions.py
renatolipi/request-manager
98a8d66a9a663f2e0aad2d2e366e93b071936394
[ "MIT" ]
null
null
null
request_manager/exceptions.py
renatolipi/request-manager
98a8d66a9a663f2e0aad2d2e366e93b071936394
[ "MIT" ]
1
2018-07-08T13:22:36.000Z
2018-07-08T13:22:36.000Z
class MaxRetriesExceeded(Exception): pass class HTTPMethodNotFound(Exception): pass
13.428571
36
0.765957
8
94
9
0.625
0.361111
0
0
0
0
0
0
0
0
0
0
0.170213
94
6
37
15.666667
0.923077
0
0
0.5
0
0
0
0
0
0
0
0
0
1
0
true
0.5
0
0
0.5
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
1
0
0
0
0
0
5
4e1b05965252a6cd8e4600f9a229051edbfe52dd
146
py
Python
OpenGLCffi/EGL/EXT/ANDROID/presentation_time.py
cydenix/OpenGLCffi
c78f51ae5e6b655eb2ea98f072771cf69e2197f3
[ "MIT" ]
null
null
null
OpenGLCffi/EGL/EXT/ANDROID/presentation_time.py
cydenix/OpenGLCffi
c78f51ae5e6b655eb2ea98f072771cf69e2197f3
[ "MIT" ]
null
null
null
OpenGLCffi/EGL/EXT/ANDROID/presentation_time.py
cydenix/OpenGLCffi
c78f51ae5e6b655eb2ea98f072771cf69e2197f3
[ "MIT" ]
null
null
null
from OpenGLCffi.EGL import params @params(api='egl', prms=['dpy', 'surface', 'time']) def eglPresentationTimeANDROID(dpy, surface, time): pass
20.857143
51
0.726027
18
146
5.888889
0.722222
0.188679
0.264151
0
0
0
0
0
0
0
0
0
0.109589
146
6
52
24.333333
0.815385
0
0
0
0
0
0.118056
0
0
0
0
0
0
1
0.25
false
0.25
0.25
0
0.5
0
1
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
1
0
0
0
0
0
5
4e36299221734b3b7fe88c90eb06809a4a8acf5d
59
py
Python
scripts/test10.py
spencerparkin/MathTree
4aa286248c2dc6a34ad2ef3e56d48b60838f3b72
[ "MIT" ]
null
null
null
scripts/test10.py
spencerparkin/MathTree
4aa286248c2dc6a34ad2ef3e56d48b60838f3b72
[ "MIT" ]
null
null
null
scripts/test10.py
spencerparkin/MathTree
4aa286248c2dc6a34ad2ef3e56d48b60838f3b72
[ "MIT" ]
null
null
null
# test10.py a = _n('a') b = _n('b') root = (a^b)*inv(a^b)
9.833333
21
0.457627
14
59
1.785714
0.5
0.24
0
0
0
0
0
0
0
0
0
0.042553
0.20339
59
6
21
9.833333
0.489362
0.152542
0
0
0
0
0.040816
0
0
0
0
0
0
1
0
false
0
0
0
0
0
1
0
1
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
1
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
4e3b904fab583f93878460c64793e8e20fdb4054
147
py
Python
server-py/core/dto/__init__.py
celiaxiao/cyberbrick
0c5e0819560fdf436b87ce809c8d44eaaf75190d
[ "Apache-2.0" ]
null
null
null
server-py/core/dto/__init__.py
celiaxiao/cyberbrick
0c5e0819560fdf436b87ce809c8d44eaaf75190d
[ "Apache-2.0" ]
null
null
null
server-py/core/dto/__init__.py
celiaxiao/cyberbrick
0c5e0819560fdf436b87ce809c8d44eaaf75190d
[ "Apache-2.0" ]
null
null
null
""" @author Jacob Xie @time 9/3/2021 """ from .table import CyberbrickType, CyberbrickColumn, CyberbrickTable from .fn import to_column, to_table
18.375
68
0.768707
20
147
5.55
0.8
0
0
0
0
0
0
0
0
0
0
0.046875
0.129252
147
7
69
21
0.820313
0.217687
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
9d72e2eaaaabb739e9fea5be14075d01395a7b6e
186
py
Python
wormholeclient/utils/__init__.py
HybridF5/hybrid-jacket
99ad667e822c1e998d952af0cab6a78cf5063256
[ "Apache-2.0" ]
null
null
null
wormholeclient/utils/__init__.py
HybridF5/hybrid-jacket
99ad667e822c1e998d952af0cab6a78cf5063256
[ "Apache-2.0" ]
null
null
null
wormholeclient/utils/__init__.py
HybridF5/hybrid-jacket
99ad667e822c1e998d952af0cab6a78cf5063256
[ "Apache-2.0" ]
null
null
null
from .utils import ( create_container_config, restart_container_config, start_container_config, inject_file_config, admin_password_config, create_image_config, )
20.666667
29
0.763441
21
186
6.190476
0.619048
0.346154
0
0
0
0
0
0
0
0
0
0
0.188172
186
8
30
23.25
0.860927
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0.125
0.125
0
0.125
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
1
0
0
0
0
0
5
9d9d831e275bdeaac3620ba0043db8f93f1f2dd8
104
py
Python
deflearning.py
ranjithvbr/test
37cb7a876c402fc68e4624071924b2851ab7b1c4
[ "MIT" ]
1
2018-07-15T13:36:22.000Z
2018-07-15T13:36:22.000Z
deflearning.py
ranjithvbr/test
37cb7a876c402fc68e4624071924b2851ab7b1c4
[ "MIT" ]
null
null
null
deflearning.py
ranjithvbr/test
37cb7a876c402fc68e4624071924b2851ab7b1c4
[ "MIT" ]
1
2018-07-15T13:39:05.000Z
2018-07-15T13:39:05.000Z
def printme( str ): "This prints a passed string into this function" print str return printme('ran')
17.333333
49
0.730769
16
104
4.75
0.8125
0
0
0
0
0
0
0
0
0
0
0
0.182692
104
5
50
20.8
0.894118
0
0
0
0
0
0.471154
0
0
0
0
0
0
0
null
null
0.2
0
null
null
0.8
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
1
0
0
1
0
0
0
1
0
5
9dba93c8973cd68021f6b36ee4bb72c596baf41a
2,332
py
Python
Forward_search.py
alvcorcas/PDDL
4b3ff61c7e2793a6f3e78835e5617a2b283fa95e
[ "MIT" ]
null
null
null
Forward_search.py
alvcorcas/PDDL
4b3ff61c7e2793a6f3e78835e5617a2b283fa95e
[ "MIT" ]
null
null
null
Forward_search.py
alvcorcas/PDDL
4b3ff61c7e2793a6f3e78835e5617a2b283fa95e
[ "MIT" ]
null
null
null
import Heuristics as heur no_path = 'There is no path from initial state to target' def forward_search_prego(initial_state, target, actions): return forward_search_prego_aux([], [], initial_state, target, actions) def forward_search_prego_aux(path, visiteds, current, target, actions): if current.satisfy(target): return path applicable = [action for action in actions if current.satisfy_preconditions(action) and current.apply(action) not in visiteds] sorted_applicable = sorted(applicable, key=lambda a: heur.prego( current.apply(a), target.literals, actions)) for action in sorted_applicable: e = current.apply(action) result = forward_search_prego_aux( path + [action], visiteds + [e], e, target, actions) if result != no_path: return result return no_path def forward_search_delta0(initial_state, target, actions): return forward_search_delta0_aux([], [], initial_state, target, actions) def forward_search_delta0_aux(path, visiteds, current, target, actions): if current.satisfy(target): return path applicable = [action for action in actions if current.satisfy_preconditions(action) and current.apply(action) not in visiteds] sorted_applicable = sorted(applicable, key=lambda a: heur.delta0( current.apply(a), target.literals, actions)) for action in sorted_applicable: e = current.apply(action) result = forward_search_delta0_aux( path + [action], visiteds + [e], e, target, actions) if result != no_path: return result return no_path def forward_search_blind(initial_state, target, actions): return forward_search_blind_aux([], [], initial_state, target, actions) def forward_search_blind_aux(path, visiteds, current, target, actions): if current.satisfy(target): return path applicable = [action for action in actions if current.satisfy_preconditions(action) and current.apply(action) not in visiteds] for action in applicable: e = current.apply(action) result = forward_search_blind_aux( path + [action], visiteds + [e], e, target, actions) if result != no_path: return result return no_path
32.388889
98
0.680103
287
2,332
5.341463
0.142857
0.101761
0.062622
0.097847
0.911937
0.891063
0.891063
0.804958
0.687541
0.687541
0
0.002798
0.233705
2,332
71
99
32.84507
0.855064
0
0
0.645833
0
0
0.019322
0
0
0
0
0
0
1
0.125
false
0
0.020833
0.0625
0.395833
0
0
0
0
null
0
0
0
1
1
1
1
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
9dbd7c8f50ac87f3f8b27daa03fa7b7e03276f4a
10
py
Python
clases/06.py
mallimuondu/python-homworks
352721a8e77d0b3bdb7a8a54197b6a04e1aec3c0
[ "MIT" ]
null
null
null
clases/06.py
mallimuondu/python-homworks
352721a8e77d0b3bdb7a8a54197b6a04e1aec3c0
[ "MIT" ]
null
null
null
clases/06.py
mallimuondu/python-homworks
352721a8e77d0b3bdb7a8a54197b6a04e1aec3c0
[ "MIT" ]
null
null
null
p1.age = 9
10
10
0.6
3
10
2
1
0
0
0
0
0
0
0
0
0
0
0.25
0.2
10
1
10
10
0.5
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0
0
0
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
1
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
5
d181394605421db97d0d5759f513f8dee6e3d5b2
141
py
Python
src/aiida_shell/engine/__init__.py
sphuber/aiida-shell
1a217eef3e3d3722070e0e6f4edbbbc40ca18a47
[ "MIT" ]
null
null
null
src/aiida_shell/engine/__init__.py
sphuber/aiida-shell
1a217eef3e3d3722070e0e6f4edbbbc40ca18a47
[ "MIT" ]
null
null
null
src/aiida_shell/engine/__init__.py
sphuber/aiida-shell
1a217eef3e3d3722070e0e6f4edbbbc40ca18a47
[ "MIT" ]
null
null
null
# -*- coding: utf-8 -*- """Module for :mod:`aiida_shell.engine`.""" from .launchers import launch_shell_job __all__ = ('launch_shell_job',)
23.5
43
0.687943
19
141
4.631579
0.789474
0.25
0.318182
0
0
0
0
0
0
0
0
0.008
0.113475
141
5
44
28.2
0.696
0.425532
0
0
0
0
0.213333
0
0
0
0
0
0
1
0
false
0
0.5
0
0.5
0
1
0
0
null
1
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
0
0
0
5
d1a540b0e8bd1a507c95ccf432bf1577094da870
29,382
py
Python
src/storage/s3v4OS.py
fgeorgatos/firecrest
238cb963724400d5c2c6164a6d13ed835abd2856
[ "BSD-3-Clause" ]
null
null
null
src/storage/s3v4OS.py
fgeorgatos/firecrest
238cb963724400d5c2c6164a6d13ed835abd2856
[ "BSD-3-Clause" ]
null
null
null
src/storage/s3v4OS.py
fgeorgatos/firecrest
238cb963724400d5c2c6164a6d13ed835abd2856
[ "BSD-3-Clause" ]
null
null
null
# # Copyright (c) 2019-2021, ETH Zurich. All rights reserved. # # Please, refer to the LICENSE file in the root directory. # SPDX-License-Identifier: BSD-3-Clause # from xml.etree import ElementTree from io import StringIO, BytesIO import urllib.request, urllib.parse, urllib.error from objectstorage import ObjectStorage import requests import logging import time import base64 import hmac import hashlib from _datetime import datetime, timedelta import json class S3v4(ObjectStorage): def __init__(self, url, user, passwd): self.user = user self.passwd = passwd self.url = url def get_object_storage(self): return "Amazon S3 - Signature v4" def sign(self,key, msg): return hmac.new(key, msg.encode('utf-8'), hashlib.sha256).digest() def getSignatureKey(self,key, dateStamp, regionName, serviceName): kDate = self.sign(('AWS4' + key).encode('utf-8'), dateStamp) kRegion = self.sign(kDate, regionName) kService = self.sign(kRegion, serviceName) kSigning = self.sign(kService, 'aws4_request') return kSigning def create_container(self, containername): ttl = 120 httpVerb = "PUT" algorithm = 'AWS4-HMAC-SHA256' service = "s3" aws_request = "aws4_request" aws_access_key_id = self.user aws_secret_access_key = self.passwd endpoint_url = self.url host = self.url.split("/")[-1] region = "us-east-1" # Create a date for headers and the credential string t = datetime.utcnow() amzdate = t.strftime('%Y%m%dT%H%M%SZ') datestamp = t.strftime('%Y%m%d') # Date w/o time, used in credential scope canonical_uri = "/" + containername canonical_headers = 'host:' + host + "\n" # + "x-amz-date:"+ amzdate + "\n" signed_headers = "host" # "host;x-amz-content-sha256;x-amz-date" credential_scope = datestamp + '/' + region + '/' + service + '/' + aws_request # canonical_querystring = bucket_name+"/"+object_name canonical_querystring = 'X-Amz-Algorithm=AWS4-HMAC-SHA256' canonical_querystring += '&X-Amz-Credential=' + urllib.parse.quote_plus( aws_access_key_id + '/' + credential_scope) canonical_querystring += '&X-Amz-Date=' + amzdate canonical_querystring += '&X-Amz-Expires=' + str(ttl) canonical_querystring += '&X-Amz-SignedHeaders=' + signed_headers payload_hash = "UNSIGNED-PAYLOAD" # ???????? hashlib.sha256(("").encode("utf-8")).hexdigest() canonical_request = httpVerb + "\n" + canonical_uri + "\n" + canonical_querystring + "\n" + canonical_headers + '\n' + signed_headers + "\n" + payload_hash string_to_sign = algorithm + "\n" + amzdate + "\n" + credential_scope + "\n" + hashlib.sha256( canonical_request.encode("utf-8")).hexdigest() # Create the signing key signing_key = self.getSignatureKey(aws_secret_access_key, datestamp, region, service) # Sign the string_to_sign using the signing_key signature = hmac.new(signing_key, (string_to_sign).encode("utf-8"), hashlib.sha256).hexdigest() canonical_querystring += '&X-Amz-Signature=' + signature # print(f"Canonical request: \n{canonical_request}") # print(f"String to Sign: \n{string_to_sign}") url = endpoint_url + canonical_uri + "?" + canonical_querystring logging.info("Deleting {}".format(containername)) logging.info("URL: {}".format(url)) try: resp = requests.put(url) print(resp.status_code) print(resp.text) if resp.ok: logging.info("Container created succesfully") return 0 logging.error("Container couldn't be created") return -1 except Exception as e: logging.error(e) logging.error("Container couldn't be created") return -1 def is_container_created(self, containername): httpVerb = "HEAD" algorithm = 'AWS4-HMAC-SHA256' service = "s3" aws_request = "aws4_request" aws_access_key_id = self.user # aws_secret_access_key = self.passwd # endpoint_url = self.url # host = self.url.split("/")[-1] # region = "us-east-1" # Create a date for headers and the credential string t = datetime.utcnow() amzdate = t.strftime('%Y%m%dT%H%M%SZ') datestamp = t.strftime('%Y%m%d') # Date w/o time, used in credential scope canonical_uri = "/" + containername canonical_headers = 'host:' + host + "\n" # + "x-amz-date:"+ amzdate + "\n" signed_headers = "host" # "host;x-amz-content-sha256;x-amz-date" credential_scope = datestamp + '/' + region + '/' + service + '/' + aws_request # canonical_querystring = bucket_name+"/"+object_name canonical_querystring = 'X-Amz-Algorithm=AWS4-HMAC-SHA256' canonical_querystring += '&X-Amz-Credential=' + urllib.parse.quote_plus( aws_access_key_id + '/' + credential_scope) canonical_querystring += '&X-Amz-Date=' + amzdate canonical_querystring += '&X-Amz-Expires=' + str(120) canonical_querystring += '&X-Amz-SignedHeaders=' + signed_headers payload_hash = "UNSIGNED-PAYLOAD" # ???????? hashlib.sha256(("").encode("utf-8")).hexdigest() canonical_request = httpVerb + "\n" + canonical_uri + "\n" + canonical_querystring + "\n" + canonical_headers + '\n' + signed_headers + "\n" + payload_hash string_to_sign = algorithm + "\n" + amzdate + "\n" + credential_scope + "\n" + hashlib.sha256( canonical_request.encode("utf-8")).hexdigest() # Create the signing key signing_key = self.getSignatureKey(aws_secret_access_key, datestamp, region, service) # Sign the string_to_sign using the signing_key signature = hmac.new(signing_key, (string_to_sign).encode("utf-8"), hashlib.sha256).hexdigest() canonical_querystring += '&X-Amz-Signature=' + signature # print(f"Canonical request: \n{canonical_request}") # print(f"String to Sign: \n{string_to_sign}") url = endpoint_url + canonical_uri + "?" + canonical_querystring try: response = requests.head(url) if response.ok: return True return False except requests.exceptions.ConnectionError as ce: logging.error(ce.strerror) return False def get_users(self): httpVerb = "GET" algorithm = 'AWS4-HMAC-SHA256' service = "s3" aws_request = "aws4_request" aws_access_key_id = self.user # aws_secret_access_key = self.passwd # endpoint_url = self.url # host = self.url.split("/")[-1] # region = "us-east-1" # Create a date for headers and the credential string t = datetime.utcnow() amzdate = t.strftime('%Y%m%dT%H%M%SZ') datestamp = t.strftime('%Y%m%d') # Date w/o time, used in credential scope canonical_uri = "/" canonical_headers = 'host:' + host + "\n" # + "x-amz-date:"+ amzdate + "\n" signed_headers = "host" # "host;x-amz-content-sha256;x-amz-date" credential_scope = datestamp + '/' + region + '/' + service + '/' + aws_request # canonical_querystring = bucket_name+"/"+object_name canonical_querystring = 'X-Amz-Algorithm=AWS4-HMAC-SHA256' canonical_querystring += '&X-Amz-Credential=' + urllib.parse.quote_plus( aws_access_key_id + '/' + credential_scope) canonical_querystring += '&X-Amz-Date=' + amzdate canonical_querystring += '&X-Amz-Expires=' + str(120) canonical_querystring += '&X-Amz-SignedHeaders=' + signed_headers payload_hash = "UNSIGNED-PAYLOAD" # ???????? hashlib.sha256(("").encode("utf-8")).hexdigest() canonical_request = httpVerb + "\n" + canonical_uri + "\n" + canonical_querystring + "\n" + canonical_headers + '\n' + signed_headers + "\n" + payload_hash string_to_sign = algorithm + "\n" + amzdate + "\n" + credential_scope + "\n" + hashlib.sha256( canonical_request.encode("utf-8")).hexdigest() # Create the signing key signing_key = self.getSignatureKey(aws_secret_access_key, datestamp, region, service) # Sign the string_to_sign using the signing_key signature = hmac.new(signing_key, (string_to_sign).encode("utf-8"), hashlib.sha256).hexdigest() canonical_querystring += '&X-Amz-Signature=' + signature # print(f"Canonical request: \n{canonical_request}") # print(f"String to Sign: \n{string_to_sign}") url = endpoint_url + canonical_uri + "?" + canonical_querystring try: resp = requests.get(url) # logging.info(response.text) if resp.ok: # logging.info(resp.content) root = ElementTree.fromstring(resp.content) for _, nsvalue in ElementTree.iterparse(BytesIO(resp.content), events=['start-ns']): namespace = nsvalue[1] bucket_list = [] # response format: # <ListAllMyBucketsResult xmlns="http://s3.amazonaws.com/doc/2006-03-01/"> # <Owner> # <ID>firecrest:jdorsch</ID> # <DisplayName>firecrest:jdorsch</DisplayName> # </Owner> # <Buckets> # <Bucket> # <Name>5497558138880</Name> # <CreationDate>2009-02-03T16:45:09.000Z</CreationDate> # </Bucket> # the tag syntax is formatted by a namespace, ie: # {http://s3.amazonaws.com/doc/2006-03-01/}Buckets for buckets in root.findall("{{{}}}Buckets".format(namespace)): for bucket in buckets.findall("{{{}}}Bucket".format(namespace)): name = bucket.find("{{{}}}Name".format(namespace)).text bucket_list.append(name) return bucket_list return None except requests.exceptions.ConnectionError as ce: logging.error(ce.strerror) return None except Exception as e: logging.error("Error: {}".format(e)) logging.error("Error: {}".format(type(e))) return None def is_object_created(self, containername, prefix, objectname): httpVerb = "HEAD" algorithm = 'AWS4-HMAC-SHA256' service = "s3" aws_request = "aws4_request" aws_access_key_id = self.user # "storage_access_key" aws_secret_access_key = self.passwd # "storage_secret_key" endpoint_url = self.url # "http://192.168.220.19:9000" host = self.url.split("/")[-1] # 192.168.220.19:9000" region = "us-east-1" # Create a date for headers and the credential string t = datetime.utcnow() amzdate = t.strftime('%Y%m%dT%H%M%SZ') datestamp = t.strftime('%Y%m%d') # Date w/o time, used in credential scope canonical_uri = "/" + containername + "/" + prefix + "/" + objectname canonical_headers = 'host:' + host + "\n" # + "x-amz-date:"+ amzdate + "\n" signed_headers = "host" # "host;x-amz-content-sha256;x-amz-date" credential_scope = datestamp + '/' + region + '/' + service + '/' + aws_request # canonical_querystring = bucket_name+"/"+object_name canonical_querystring = 'X-Amz-Algorithm=AWS4-HMAC-SHA256' canonical_querystring += '&X-Amz-Credential=' + urllib.parse.quote_plus( aws_access_key_id + '/' + credential_scope) canonical_querystring += '&X-Amz-Date=' + amzdate canonical_querystring += '&X-Amz-Expires=' + str(120) canonical_querystring += '&X-Amz-SignedHeaders=' + signed_headers payload_hash = "UNSIGNED-PAYLOAD" # ???????? hashlib.sha256(("").encode("utf-8")).hexdigest() canonical_request = httpVerb + "\n" + canonical_uri + "\n" + canonical_querystring + "\n" + canonical_headers + '\n' + signed_headers + "\n" + payload_hash string_to_sign = algorithm + "\n" + amzdate + "\n" + credential_scope + "\n" + hashlib.sha256( canonical_request.encode("utf-8")).hexdigest() # Create the signing key signing_key = self.getSignatureKey(aws_secret_access_key, datestamp, region, service) # Sign the string_to_sign using the signing_key signature = hmac.new(signing_key, (string_to_sign).encode("utf-8"), hashlib.sha256).hexdigest() canonical_querystring += '&X-Amz-Signature=' + signature # print(f"Canonical request: \n{canonical_request}") # print(f"String to Sign: \n{string_to_sign}") url = endpoint_url + canonical_uri + "?" + canonical_querystring try: response = requests.head(url) if response.ok: return True return False except requests.exceptions.ConnectionError as ce: logging.error(ce.strerror) return False def authenticate(self, user, passwd): return True def is_token_valid(self): return True def create_upload_form(self, sourcepath, containername, prefix, ttl, max_file_size): httpVerb = "POST" algorithm = 'AWS4-HMAC-SHA256' service = "s3" aws_request = "aws4_request" # aws_access_key_id = self.user aws_secret_access_key = self.passwd endpoint_url = self.url # "http://ip[:port]" # host = self.url.split("/")[-1] # ip[:port[" region = "us-east-1" objectname = sourcepath.split("/")[-1] # Create a date for headers and the credential string t = datetime.utcnow() amzdate = t.strftime('%Y%m%dT%H%M%SZ') datestamp = t.strftime('%Y%m%d') # Date w/o time, used in credential scope credentials = f"{self.user}/{datestamp}/{region}/{service}/{aws_request}" policy = { "expiration": (datetime.now() + timedelta(seconds=ttl)).strftime('%Y-%m-%dT%H:%M:%SZ'), "conditions":[ {"bucket": containername}, {"key": prefix+"/"+objectname}, {"x-amz-algorithm": algorithm}, {"x-amz-credential": credentials}, {"x-amz-date": amzdate} ] } base64Policy = base64.b64encode(json.dumps(policy).encode('utf-8')).decode('utf-8') datestamp = t.strftime('%Y%m%d') # Date w/o time, used in credential scope signing_key = self.getSignatureKey(aws_secret_access_key,datestamp,region,service) signature = hmac.new(signing_key, base64Policy.encode('utf-8'), hashlib.sha256).hexdigest() retval = {} retval["parameters"] = { "method": httpVerb, "url": f"{endpoint_url}/{containername}", "data": { "key": prefix + "/" + objectname, "x-amz-algorithm": algorithm, "x-amz-credential": credentials, "x-amz-date": amzdate, "policy": base64Policy, "x-amz-signature" : signature }, "files": sourcepath, "json" : {}, "params": {}, "headers": {} } command = f"curl --show-error -s -i -X {httpVerb} {endpoint_url}/{containername}" for k,v in retval["parameters"]["data"].items(): command += f" -F '{k}={v}'" command+=f" -F file=@{retval['parameters']['files']}" retval["command"] = command return retval def create_temp_url(self, containername, prefix, objectname, ttl): httpVerb = "GET" algorithm = 'AWS4-HMAC-SHA256' service = "s3" aws_request = "aws4_request" aws_access_key_id = self.user aws_secret_access_key = self.passwd endpoint_url = self.url host = self.url.split("/")[-1] region = "us-east-1" # Create a date for headers and the credential string t = datetime.utcnow() amzdate = t.strftime('%Y%m%dT%H%M%SZ') datestamp = t.strftime('%Y%m%d') # Date w/o time, used in credential scope canonical_uri = "/" + containername + "/" + prefix + "/" + objectname canonical_headers = 'host:' + host + "\n" # + "x-amz-date:"+ amzdate + "\n" signed_headers = "host" # "host;x-amz-content-sha256;x-amz-date" credential_scope = datestamp + '/' + region + '/' + service + '/' + aws_request # canonical_querystring = bucket_name+"/"+object_name canonical_querystring = 'X-Amz-Algorithm=AWS4-HMAC-SHA256' canonical_querystring += '&X-Amz-Credential=' + urllib.parse.quote_plus( aws_access_key_id + '/' + credential_scope) canonical_querystring += '&X-Amz-Date=' + amzdate canonical_querystring += '&X-Amz-Expires=' + str(ttl) canonical_querystring += '&X-Amz-SignedHeaders=' + signed_headers payload_hash = "UNSIGNED-PAYLOAD" # ???????? hashlib.sha256(("").encode("utf-8")).hexdigest() canonical_request = httpVerb + "\n" + canonical_uri + "\n" + canonical_querystring + "\n" + canonical_headers + '\n' + signed_headers + "\n" + payload_hash string_to_sign = algorithm + "\n" + amzdate + "\n" + credential_scope + "\n" + hashlib.sha256( canonical_request.encode("utf-8")).hexdigest() # Create the signing key signing_key = self.getSignatureKey(aws_secret_access_key, datestamp, region, service) # Sign the string_to_sign using the signing_key signature = hmac.new(signing_key, (string_to_sign).encode("utf-8"), hashlib.sha256).hexdigest() canonical_querystring += '&X-Amz-Signature=' + signature url = endpoint_url + canonical_uri + "?" + canonical_querystring return url def list_objects(self,containername,prefix=None): httpVerb = "GET" algorithm = 'AWS4-HMAC-SHA256' service = "s3" aws_request = "aws4_request" aws_access_key_id = self.user aws_secret_access_key = self.passwd endpoint_url = self.url host = self.url.split("/")[-1] region = "us-east-1" # Create a date for headers and the credential string t = datetime.utcnow() amzdate = t.strftime('%Y%m%dT%H%M%SZ') datestamp = t.strftime('%Y%m%d') # Date w/o time, used in credential scope canonical_uri = f"/{containername}" canonical_headers = 'host:' + host + "\n" # + "x-amz-date:"+ amzdate + "\n" signed_headers = "host" # "host;x-amz-content-sha256;x-amz-date" credential_scope = datestamp + '/' + region + '/' + service + '/' + aws_request # canonical_querystring = bucket_name+"/"+object_name canonical_querystring = 'X-Amz-Algorithm=AWS4-HMAC-SHA256' canonical_querystring += '&X-Amz-Credential=' + urllib.parse.quote_plus( aws_access_key_id + '/' + credential_scope) canonical_querystring += '&X-Amz-Date=' + amzdate canonical_querystring += '&X-Amz-Expires=' + str(120) canonical_querystring += '&X-Amz-SignedHeaders=' + signed_headers payload_hash = "UNSIGNED-PAYLOAD" # ???????? hashlib.sha256(("").encode("utf-8")).hexdigest() canonical_request = httpVerb + "\n" + canonical_uri + "\n" + canonical_querystring + "\n" + canonical_headers + '\n' + signed_headers + "\n" + payload_hash string_to_sign = algorithm + "\n" + amzdate + "\n" + credential_scope + "\n" + hashlib.sha256( canonical_request.encode("utf-8")).hexdigest() # Create the signing key signing_key = self.getSignatureKey(aws_secret_access_key, datestamp, region, service) # Sign the string_to_sign using the signing_key signature = hmac.new(signing_key, (string_to_sign).encode("utf-8"), hashlib.sha256).hexdigest() canonical_querystring += '&X-Amz-Signature=' + signature url = endpoint_url + canonical_uri + "?" + canonical_querystring try: resp = requests.get(url) if resp.ok: # logging.info(resp.content) root = ElementTree.fromstring(resp.content) for _, nsvalue in ElementTree.iterparse(BytesIO(resp.content), events=['start-ns']): namespace = nsvalue[1] object_list = [] for contents in root.findall("{{{}}}Contents".format(namespace)): key = contents.find("{{{}}}Key".format(namespace)).text if prefix != None: sep = key.split("/") if prefix == sep[0]: name = key.split("/")[-1] object_list.append(name) continue object_list.append(key) return object_list else: return None except requests.exceptions.ConnectionError as ce: logging.error(ce.strerror) return None except Exception as e: logging.error("Error: {}".format(e)) logging.error("Error: {}".format(type(e))) return None def _prepare_xml(self,prefix, expiration_date_value): lc_root = ElementTree.Element("LifecycleConfiguration", {'xmlns': "http://s3.amazonaws.com/doc/2006-03-01/"}) rule_branch = ElementTree.SubElement(lc_root,"Rule") rule_status = ElementTree.SubElement(rule_branch,"Status") rule_status.text = "Enabled" rule_expiration = ElementTree.SubElement(rule_branch, "Expiration") expiration_date = ElementTree.SubElement(rule_expiration, "Date") expiration_date.text = expiration_date_value rule_filter = ElementTree.SubElement(rule_branch, "Filter") filter_prefix = ElementTree.SubElement(rule_filter, "Prefix") filter_prefix.text = f"{prefix}/" rule_id = ElementTree.SubElement(rule_branch,"ID") rule_id.text= prefix import io body_data = io.BytesIO() ElementTree.ElementTree(lc_root).write(body_data, encoding=None, xml_declaration=False) body = body_data.getvalue() import hashlib hasher = hashlib.md5() hasher.update(body) import base64 md5sum = base64.b64encode(hasher.digest()) md5sum_decoded = md5sum.decode() hash256 = hashlib.sha256() hash256.update(body) sha256sum = hash256.hexdigest() # sha256sum_decoded = sha256sum.decode() return body, md5sum_decoded, sha256sum # For S3v4 delete_at only works at midnight UTC (from http://docs.aws.amazon.com/AmazonS3/latest/API/RESTBucketPUTlifecycle.html) # "The date value must conform to the ISO 8601 format. The time is always midnight UTC." # # therefore the expiration time will be managed to the midnigt of the next day and timezone is Z (UTC+0) def delete_object_after(self,containername,prefix,objectname,ttl): httpVerb = "PUT" algorithm = 'AWS4-HMAC-SHA256' service = "s3" aws_request = "aws4_request" aws_access_key_id = self.user aws_secret_access_key = self.passwd endpoint_url = self.url host = self.url.split("/")[-1] region = "us-east-1" # Create a date for headers and the credential string t = datetime.utcnow() amzdate = t.strftime('%Y%m%dT%H%M%SZ') datestamp = t.strftime('%Y%m%d') # Date w/o time, used in credential scope # since only midnight is allowed, deleting T%H:%M:%S d1_str = datetime.utcfromtimestamp(ttl).strftime("%Y-%m-%d") d1 = datetime.strptime(d1_str,"%Y-%m-%d") # convert to datetime d2 = d1 + timedelta(days=1) # add 1 day _delete_at_iso = d2.strftime("%Y-%m-%dT%H:%M:%SZ") # after adding 1 day, reconvert to str [body, content_md5, content_sha256] = self._prepare_xml(prefix, _delete_at_iso) canonical_uri = "/" + containername canonical_headers = f"content-md5:{content_md5}\nhost:{host}\nx-amz-content-sha256:{content_sha256}\nx-amz-date:{amzdate}" signed_headers = "content-md5;host;x-amz-content-sha256;x-amz-date" credential_scope = datestamp + '/' + region + '/' + service + '/' + aws_request canonical_querystring = "lifecycle=" headers = { "Content-MD5": content_md5, "Host": host, "X-Amz-Content-Sha256": content_sha256, "X-Amz-Date": amzdate} canonical_request = httpVerb + "\n" + canonical_uri + "\n" + canonical_querystring + "\n" + canonical_headers + '\n\n' + signed_headers + "\n" + content_sha256 canonical_request_hash = hashlib.sha256(canonical_request.encode("utf-8")).hexdigest() string_to_sign = f"{algorithm}\n{amzdate}\n{credential_scope}\n{canonical_request_hash}" # Create the signing key signing_key = self.getSignatureKey(aws_secret_access_key, datestamp, region, service) # Sign the string_to_sign using the signing_key signature = hmac.new(signing_key, (string_to_sign).encode("utf-8"), hashlib.sha256).hexdigest() headers["Authorization"] = f"AWS4-HMAC-SHA256 Credential={aws_access_key_id}/{credential_scope}, SignedHeaders={signed_headers}, Signature={signature}" url = endpoint_url + canonical_uri +"?"+ canonical_querystring try: resp = requests.put(url, data=body, headers=headers) if resp.ok: logging.info(f"Object was marked as to be deleted at {_delete_at_iso}") return 0 logging.error("Object couldn't be marked as delete-at") logging.error(resp.content) logging.error(resp.headers) return -1 except Exception as e: logging.error(e) logging.error("Object couldn't be marked as delete-at") return -1 def delete_object(self,containername,prefix,objectname): ttl = 120 httpVerb = "DELETE" algorithm = 'AWS4-HMAC-SHA256' service = "s3" aws_request = "aws4_request" aws_access_key_id = self.user aws_secret_access_key = self.passwd endpoint_url = self.url host = self.url.split("/")[-1] region = "us-east-1" # Create a date for headers and the credential string t = datetime.utcnow() amzdate = t.strftime('%Y%m%dT%H%M%SZ') datestamp = t.strftime('%Y%m%d') # Date w/o time, used in credential scope canonical_uri = "/" + containername + "/" + prefix + "/" + objectname canonical_headers = 'host:' + host + "\n" # + "x-amz-date:"+ amzdate + "\n" signed_headers = "host" # "host;x-amz-content-sha256;x-amz-date" credential_scope = datestamp + '/' + region + '/' + service + '/' + aws_request # canonical_querystring = bucket_name+"/"+object_name canonical_querystring = 'X-Amz-Algorithm=AWS4-HMAC-SHA256' canonical_querystring += '&X-Amz-Credential=' + urllib.parse.quote_plus( aws_access_key_id + '/' + credential_scope) canonical_querystring += '&X-Amz-Date=' + amzdate canonical_querystring += '&X-Amz-Expires=' + str(ttl) canonical_querystring += '&X-Amz-SignedHeaders=' + signed_headers payload_hash = "UNSIGNED-PAYLOAD" # ???????? hashlib.sha256(("").encode("utf-8")).hexdigest() canonical_request = httpVerb + "\n" + canonical_uri + "\n" + canonical_querystring + "\n" + canonical_headers + '\n' + signed_headers + "\n" + payload_hash string_to_sign = algorithm + "\n" + amzdate + "\n" + credential_scope + "\n" + hashlib.sha256( canonical_request.encode("utf-8")).hexdigest() # Create the signing key signing_key = self.getSignatureKey(aws_secret_access_key, datestamp, region, service) # Sign the string_to_sign using the signing_key signature = hmac.new(signing_key, (string_to_sign).encode("utf-8"), hashlib.sha256).hexdigest() canonical_querystring += '&X-Amz-Signature=' + signature url = endpoint_url + canonical_uri + "?" + canonical_querystring logging.info(f"Deleting {canonical_uri}") logging.info("URL: {}".format(url)) try: resp = requests.delete(url) if resp.ok: logging.info("Object deleted succesfully") return 0 logging.error("Object couldn't be deleted") return -1 except Exception as e: logging.error(e) logging.error("Object couldn't be deleted") return -1
39.071809
167
0.594582
3,299
29,382
5.131555
0.099121
0.017485
0.0521
0.059543
0.751964
0.730403
0.716522
0.712623
0.702759
0.690531
0
0.021234
0.273909
29,382
751
168
39.123835
0.772288
0.15067
0
0.67957
0
0.002151
0.135022
0.034752
0
0
0
0
0
1
0.034409
false
0.025806
0.032258
0.008602
0.135484
0.004301
0
0
0
null
0
0
0
0
1
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
d1c1ec7522dda7513b587eea466e4c9ac8260ad5
73
py
Python
adaptive_alerting_detector_build/detectors/quartiles.py
brett-miller/adaptive-alerting-detector-build
eec9f514feb4f65586c408fae36176ebcd8989ae
[ "Apache-2.0" ]
null
null
null
adaptive_alerting_detector_build/detectors/quartiles.py
brett-miller/adaptive-alerting-detector-build
eec9f514feb4f65586c408fae36176ebcd8989ae
[ "Apache-2.0" ]
null
null
null
adaptive_alerting_detector_build/detectors/quartiles.py
brett-miller/adaptive-alerting-detector-build
eec9f514feb4f65586c408fae36176ebcd8989ae
[ "Apache-2.0" ]
null
null
null
from adaptive_alerting_detector_build.detectors.base import BaseDetector
36.5
72
0.917808
9
73
7.111111
1
0
0
0
0
0
0
0
0
0
0
0
0.054795
73
1
73
73
0.927536
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
d1d6609c09f106e6e755176a750dc50b2bf69755
19
py
Python
quantstats/version.py
Amirnajafi/quantstats
b1051dd43663ddc795355dc05c0146319a22ec3e
[ "Apache-2.0" ]
null
null
null
quantstats/version.py
Amirnajafi/quantstats
b1051dd43663ddc795355dc05c0146319a22ec3e
[ "Apache-2.0" ]
null
null
null
quantstats/version.py
Amirnajafi/quantstats
b1051dd43663ddc795355dc05c0146319a22ec3e
[ "Apache-2.0" ]
null
null
null
version = "0.0.50"
9.5
18
0.578947
4
19
2.75
0.75
0
0
0
0
0
0
0
0
0
0
0.25
0.157895
19
1
19
19
0.4375
0
0
0
0
0
0.315789
0
0
0
0
0
0
1
0
false
0
0
0
0
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
1
0
0
1
0
0
1
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
d1d8ae1f41bdb41e7d29727dc4f5b6a469563ef4
16
py
Python
flask_rabbitmq/exception/__init__.py
NimzyMaina/flask-rabbitmq
0005577f9ad2ec4a692d117b25c01246862437bd
[ "MIT" ]
55
2018-12-29T13:36:01.000Z
2022-01-13T09:49:44.000Z
schemas/__init__.py
pushyzheng/docker-oj-web
119abae3763cd2e53c686a320af7f4f5af1f16ca
[ "MIT" ]
3
2019-04-25T14:57:42.000Z
2020-03-29T09:27:42.000Z
flask_rabbitmq/exception/__init__.py
PushyZqin/flask-rabbitmq
5d6f4b16e56dcd818953ba875ab838bfb1fc5529
[ "MIT" ]
14
2019-02-12T12:38:50.000Z
2020-11-29T09:23:32.000Z
# encoding:utf-8
16
16
0.75
3
16
4
1
0
0
0
0
0
0
0
0
0
0
0.066667
0.0625
16
1
16
16
0.733333
0.875
0
null
0
null
0
0
null
0
0
0
null
1
null
true
0
0
null
null
null
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
5
ae06ae249c10eb15bac9dd491f59f741dd6af2ea
1,109
py
Python
setup.py
lxl0928/timi_pinyin
88713c6bb93a09fdca1b505f5bbfdd939892b5c0
[ "MIT" ]
2
2019-08-07T05:18:35.000Z
2019-08-07T05:19:16.000Z
setup.py
lxl0928/timi_pinyin
88713c6bb93a09fdca1b505f5bbfdd939892b5c0
[ "MIT" ]
null
null
null
setup.py
lxl0928/timi_pinyin
88713c6bb93a09fdca1b505f5bbfdd939892b5c0
[ "MIT" ]
null
null
null
from setuptools import setup setup( name="timi-pinyin", version="1.1.0", url='http://github.com/lxl0928/timi_pinyin', author='Timi long', author_email='lixiaolong@smuer.cn', description='根据传入的input_str="费家村设备01", 返回该字符串的所有字符的拼音首字目组成的字符串: "fjcsb01".', long_description="""文档: https://github.com/lxl0928/timi_pinyin/blob/master/README.md""", packages=['timi_pinyin'], classifiers=[ 'Development Status :: 5 - Production/Stable', 'Intended Audience :: Developers', 'License :: OSI Approved :: BSD License', 'Operating System :: OS Independent', 'Programming Language :: Python', 'Programming Language :: Python :: 2.6', 'Programming Language :: Python :: 2.7', 'Programming Language :: Python :: 3.3', 'Programming Language :: Python :: 3.4', 'Programming Language :: Python :: 3.5', 'Programming Language :: Python :: 3.6', 'Programming Language :: Python :: 3.7', ], extras_require={ "pypinyin": ["pypinyin"], }, install_requires=["pypinyin==0.35.4"] )
35.774194
92
0.612263
115
1,109
5.834783
0.565217
0.226528
0.298063
0.193741
0.077496
0
0
0
0
0
0
0.039581
0.225428
1,109
30
93
36.966667
0.74156
0
0
0
0
0
0.616772
0.044184
0
0
0
0
0
1
0
true
0
0.034483
0
0.034483
0
0
0
0
null
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
5
ae0c21a3ba924ba33c6ef1704981b982b276abe5
83
py
Python
pythoncalculator/__init__.py
DrPSmart/python-calculator
f9395bf35d23d9db5b16f0f2316728895456a2bf
[ "MIT" ]
null
null
null
pythoncalculator/__init__.py
DrPSmart/python-calculator
f9395bf35d23d9db5b16f0f2316728895456a2bf
[ "MIT" ]
4
2021-10-01T14:29:11.000Z
2021-10-01T15:22:28.000Z
pythoncalculator/__init__.py
DrPSmart/python-calculator
f9395bf35d23d9db5b16f0f2316728895456a2bf
[ "MIT" ]
null
null
null
from .add import add from .multiply import multiply from .divide import divide
16.6
31
0.771084
12
83
5.333333
0.416667
0
0
0
0
0
0
0
0
0
0
0
0.192771
83
4
32
20.75
0.955224
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
8822d4c9e411785f85e48031d307cc0f86e0d22d
85,619
py
Python
duke-cs671-fall21-coupon-recommendation/outputs/rules/ID3/10_features/maxdepth_5/2/rules.py
apcarrik/kaggle
6e2d4db58017323e7ba5510bcc2598e01a4ee7bf
[ "MIT" ]
null
null
null
duke-cs671-fall21-coupon-recommendation/outputs/rules/ID3/10_features/maxdepth_5/2/rules.py
apcarrik/kaggle
6e2d4db58017323e7ba5510bcc2598e01a4ee7bf
[ "MIT" ]
null
null
null
duke-cs671-fall21-coupon-recommendation/outputs/rules/ID3/10_features/maxdepth_5/2/rules.py
apcarrik/kaggle
6e2d4db58017323e7ba5510bcc2598e01a4ee7bf
[ "MIT" ]
null
null
null
def findDecision(obj): #obj[0]: Passanger, obj[1]: Time, obj[2]: Coupon, obj[3]: Education, obj[4]: Occupation, obj[5]: Bar, obj[6]: Coffeehouse, obj[7]: Restaurant20to50, obj[8]: Direction_same, obj[9]: Distance # {"feature": "Coupon", "instances": 8147, "metric_value": 0.4734, "depth": 1} if obj[2]>1: # {"feature": "Coffeehouse", "instances": 5886, "metric_value": 0.4595, "depth": 2} if obj[6]<=1.0: # {"feature": "Distance", "instances": 3041, "metric_value": 0.4864, "depth": 3} if obj[9]<=2: # {"feature": "Passanger", "instances": 2734, "metric_value": 0.4834, "depth": 4} if obj[0]<=1: # {"feature": "Restaurant20to50", "instances": 1643, "metric_value": 0.4939, "depth": 5} if obj[7]<=2.0: # {"feature": "Bar", "instances": 1593, "metric_value": 0.4964, "depth": 6} if obj[5]<=3.0: # {"feature": "Time", "instances": 1573, "metric_value": 0.4961, "depth": 7} if obj[1]<=1: # {"feature": "Direction_same", "instances": 980, "metric_value": 0.4935, "depth": 8} if obj[8]>0: # {"feature": "Occupation", "instances": 519, "metric_value": 0.4874, "depth": 9} if obj[4]<=20.475751648290952: # {"feature": "Education", "instances": 486, "metric_value": 0.4896, "depth": 10} if obj[3]>0: return 'True' elif obj[3]<=0: return 'True' else: return 'True' elif obj[4]>20.475751648290952: # {"feature": "Education", "instances": 33, "metric_value": 0.2974, "depth": 10} if obj[3]<=3: return 'True' elif obj[3]>3: return 'False' else: return 'False' else: return 'True' elif obj[8]<=0: # {"feature": "Occupation", "instances": 461, "metric_value": 0.4964, "depth": 9} if obj[4]<=7.559652928416486: # {"feature": "Education", "instances": 285, "metric_value": 0.4981, "depth": 10} if obj[3]<=4: return 'False' elif obj[3]>4: return 'False' else: return 'False' elif obj[4]>7.559652928416486: # {"feature": "Education", "instances": 176, "metric_value": 0.4873, "depth": 10} if obj[3]<=3: return 'False' elif obj[3]>3: return 'True' else: return 'True' else: return 'False' else: return 'False' elif obj[1]>1: # {"feature": "Occupation", "instances": 593, "metric_value": 0.4873, "depth": 8} if obj[4]<=7.716694772344013: # {"feature": "Direction_same", "instances": 375, "metric_value": 0.4759, "depth": 9} if obj[8]<=0: # {"feature": "Education", "instances": 288, "metric_value": 0.4679, "depth": 10} if obj[3]<=3: return 'True' elif obj[3]>3: return 'True' else: return 'True' elif obj[8]>0: # {"feature": "Education", "instances": 87, "metric_value": 0.4778, "depth": 10} if obj[3]>0: return 'False' elif obj[3]<=0: return 'True' else: return 'True' else: return 'True' elif obj[4]>7.716694772344013: # {"feature": "Education", "instances": 218, "metric_value": 0.4964, "depth": 9} if obj[3]>1: # {"feature": "Direction_same", "instances": 120, "metric_value": 0.4963, "depth": 10} if obj[8]<=0: return 'False' elif obj[8]>0: return 'False' else: return 'False' elif obj[3]<=1: # {"feature": "Direction_same", "instances": 98, "metric_value": 0.4938, "depth": 10} if obj[8]<=0: return 'True' elif obj[8]>0: return 'False' else: return 'False' else: return 'True' else: return 'True' else: return 'True' elif obj[5]>3.0: # {"feature": "Time", "instances": 20, "metric_value": 0.4088, "depth": 7} if obj[1]<=2: # {"feature": "Education", "instances": 13, "metric_value": 0.4231, "depth": 8} if obj[3]<=2: # {"feature": "Occupation", "instances": 9, "metric_value": 0.4333, "depth": 9} if obj[4]>2: # {"feature": "Direction_same", "instances": 5, "metric_value": 0.3, "depth": 10} if obj[8]<=0: return 'False' elif obj[8]>0: return 'True' else: return 'True' elif obj[4]<=2: # {"feature": "Direction_same", "instances": 4, "metric_value": 0.25, "depth": 10} if obj[8]<=0: return 'True' elif obj[8]>0: return 'False' else: return 'False' else: return 'False' elif obj[3]>2: # {"feature": "Occupation", "instances": 4, "metric_value": 0.375, "depth": 9} if obj[4]<=2: # {"feature": "Direction_same", "instances": 4, "metric_value": 0.375, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[1]>2: # {"feature": "Occupation", "instances": 7, "metric_value": 0.2143, "depth": 8} if obj[4]<=2: # {"feature": "Education", "instances": 4, "metric_value": 0.3333, "depth": 9} if obj[3]<=2: # {"feature": "Direction_same", "instances": 3, "metric_value": 0.3333, "depth": 10} if obj[8]<=0: return 'False' elif obj[8]>0: return 'False' else: return 'False' elif obj[3]>2: return 'False' else: return 'False' elif obj[4]>2: return 'False' else: return 'False' else: return 'False' else: return 'False' elif obj[7]>2.0: # {"feature": "Time", "instances": 50, "metric_value": 0.3467, "depth": 6} if obj[1]>0: # {"feature": "Occupation", "instances": 39, "metric_value": 0.404, "depth": 7} if obj[4]<=9: # {"feature": "Bar", "instances": 33, "metric_value": 0.3862, "depth": 8} if obj[5]>0.0: # {"feature": "Education", "instances": 19, "metric_value": 0.2915, "depth": 9} if obj[3]<=2: # {"feature": "Direction_same", "instances": 13, "metric_value": 0.3932, "depth": 10} if obj[8]<=0: return 'True' elif obj[8]>0: return 'True' else: return 'True' elif obj[3]>2: return 'True' else: return 'True' elif obj[5]<=0.0: # {"feature": "Direction_same", "instances": 14, "metric_value": 0.4317, "depth": 9} if obj[8]<=0: # {"feature": "Education", "instances": 9, "metric_value": 0.4938, "depth": 10} if obj[3]<=4: return 'True' else: return 'True' elif obj[8]>0: # {"feature": "Education", "instances": 5, "metric_value": 0.32, "depth": 10} if obj[3]<=4: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[4]>9: # {"feature": "Education", "instances": 6, "metric_value": 0.2222, "depth": 8} if obj[3]>0: return 'False' elif obj[3]<=0: # {"feature": "Bar", "instances": 3, "metric_value": 0.0, "depth": 9} if obj[5]<=0.0: return 'True' elif obj[5]>0.0: return 'False' else: return 'False' else: return 'True' else: return 'False' elif obj[1]<=0: return 'True' else: return 'True' else: return 'True' elif obj[0]>1: # {"feature": "Education", "instances": 1091, "metric_value": 0.461, "depth": 5} if obj[3]>1: # {"feature": "Time", "instances": 569, "metric_value": 0.4738, "depth": 6} if obj[1]>0: # {"feature": "Restaurant20to50", "instances": 439, "metric_value": 0.486, "depth": 7} if obj[7]>0.0: # {"feature": "Occupation", "instances": 331, "metric_value": 0.4951, "depth": 8} if obj[4]>1: # {"feature": "Bar", "instances": 300, "metric_value": 0.4974, "depth": 9} if obj[5]>0.0: # {"feature": "Direction_same", "instances": 157, "metric_value": 0.5, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' elif obj[5]<=0.0: # {"feature": "Direction_same", "instances": 143, "metric_value": 0.4945, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[4]<=1: # {"feature": "Bar", "instances": 31, "metric_value": 0.4356, "depth": 9} if obj[5]>0.0: # {"feature": "Direction_same", "instances": 18, "metric_value": 0.4938, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[5]<=0.0: # {"feature": "Direction_same", "instances": 13, "metric_value": 0.355, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[7]<=0.0: # {"feature": "Bar", "instances": 108, "metric_value": 0.4265, "depth": 8} if obj[5]<=1.0: # {"feature": "Occupation", "instances": 98, "metric_value": 0.4579, "depth": 9} if obj[4]<=20: # {"feature": "Direction_same", "instances": 94, "metric_value": 0.4774, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[4]>20: return 'True' else: return 'True' elif obj[5]>1.0: return 'True' else: return 'True' else: return 'True' elif obj[1]<=0: # {"feature": "Occupation", "instances": 130, "metric_value": 0.3967, "depth": 7} if obj[4]<=6: # {"feature": "Restaurant20to50", "instances": 65, "metric_value": 0.3111, "depth": 8} if obj[7]>0.0: # {"feature": "Bar", "instances": 45, "metric_value": 0.3638, "depth": 9} if obj[5]<=2.0: # {"feature": "Direction_same", "instances": 43, "metric_value": 0.3807, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[5]>2.0: return 'True' else: return 'True' elif obj[7]<=0.0: # {"feature": "Bar", "instances": 20, "metric_value": 0.1765, "depth": 9} if obj[5]<=1.0: # {"feature": "Direction_same", "instances": 17, "metric_value": 0.2076, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[5]>1.0: return 'True' else: return 'True' else: return 'True' elif obj[4]>6: # {"feature": "Bar", "instances": 65, "metric_value": 0.4649, "depth": 8} if obj[5]<=2.0: # {"feature": "Restaurant20to50", "instances": 58, "metric_value": 0.4582, "depth": 9} if obj[7]<=1.0: # {"feature": "Direction_same", "instances": 47, "metric_value": 0.4726, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[7]>1.0: # {"feature": "Direction_same", "instances": 11, "metric_value": 0.3967, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[5]>2.0: # {"feature": "Restaurant20to50", "instances": 7, "metric_value": 0.4857, "depth": 9} if obj[7]>1.0: # {"feature": "Direction_same", "instances": 5, "metric_value": 0.48, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' elif obj[7]<=1.0: # {"feature": "Direction_same", "instances": 2, "metric_value": 0.5, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' else: return 'False' else: return 'True' else: return 'True' elif obj[3]<=1: # {"feature": "Bar", "instances": 522, "metric_value": 0.4308, "depth": 6} if obj[5]<=0.0: # {"feature": "Time", "instances": 283, "metric_value": 0.453, "depth": 7} if obj[1]<=2: # {"feature": "Occupation", "instances": 163, "metric_value": 0.4846, "depth": 8} if obj[4]<=12: # {"feature": "Restaurant20to50", "instances": 143, "metric_value": 0.4836, "depth": 9} if obj[7]<=1.0: # {"feature": "Direction_same", "instances": 122, "metric_value": 0.4966, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' elif obj[7]>1.0: # {"feature": "Direction_same", "instances": 21, "metric_value": 0.4082, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[4]>12: # {"feature": "Restaurant20to50", "instances": 20, "metric_value": 0.3158, "depth": 9} if obj[7]>0.0: # {"feature": "Direction_same", "instances": 19, "metric_value": 0.3324, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[7]<=0.0: return 'False' else: return 'False' else: return 'True' elif obj[1]>2: # {"feature": "Restaurant20to50", "instances": 120, "metric_value": 0.3772, "depth": 8} if obj[7]<=1.0: # {"feature": "Occupation", "instances": 98, "metric_value": 0.4058, "depth": 9} if obj[4]>1: # {"feature": "Direction_same", "instances": 71, "metric_value": 0.4642, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[4]<=1: # {"feature": "Direction_same", "instances": 27, "metric_value": 0.2524, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[7]>1.0: # {"feature": "Occupation", "instances": 22, "metric_value": 0.1591, "depth": 9} if obj[4]<=7: # {"feature": "Direction_same", "instances": 16, "metric_value": 0.2188, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[4]>7: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[5]>0.0: # {"feature": "Restaurant20to50", "instances": 239, "metric_value": 0.3741, "depth": 7} if obj[7]>-1.0: # {"feature": "Time", "instances": 232, "metric_value": 0.3655, "depth": 8} if obj[1]<=3: # {"feature": "Occupation", "instances": 168, "metric_value": 0.3333, "depth": 9} if obj[4]<=19: # {"feature": "Direction_same", "instances": 162, "metric_value": 0.3457, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[4]>19: return 'True' else: return 'True' elif obj[1]>3: # {"feature": "Occupation", "instances": 64, "metric_value": 0.4176, "depth": 9} if obj[4]>1: # {"feature": "Direction_same", "instances": 53, "metric_value": 0.4699, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[4]<=1: # {"feature": "Direction_same", "instances": 11, "metric_value": 0.1653, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[7]<=-1.0: # {"feature": "Time", "instances": 7, "metric_value": 0.4048, "depth": 8} if obj[1]<=2: # {"feature": "Occupation", "instances": 4, "metric_value": 0.375, "depth": 9} if obj[4]<=5: # {"feature": "Direction_same", "instances": 4, "metric_value": 0.375, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' elif obj[1]>2: # {"feature": "Occupation", "instances": 3, "metric_value": 0.4444, "depth": 9} if obj[4]<=5: # {"feature": "Direction_same", "instances": 3, "metric_value": 0.4444, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' else: return 'True' else: return 'False' else: return 'True' else: return 'True' else: return 'True' elif obj[9]>2: # {"feature": "Time", "instances": 307, "metric_value": 0.454, "depth": 4} if obj[1]>0: # {"feature": "Education", "instances": 255, "metric_value": 0.4745, "depth": 5} if obj[3]<=2: # {"feature": "Bar", "instances": 207, "metric_value": 0.4639, "depth": 6} if obj[5]<=0.0: # {"feature": "Occupation", "instances": 109, "metric_value": 0.495, "depth": 7} if obj[4]>0: # {"feature": "Restaurant20to50", "instances": 105, "metric_value": 0.4957, "depth": 8} if obj[7]<=1.0: # {"feature": "Passanger", "instances": 87, "metric_value": 0.4999, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 87, "metric_value": 0.4999, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[7]>1.0: # {"feature": "Passanger", "instances": 18, "metric_value": 0.4753, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 18, "metric_value": 0.4753, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' else: return 'False' elif obj[4]<=0: # {"feature": "Restaurant20to50", "instances": 4, "metric_value": 0.0, "depth": 8} if obj[7]<=1.0: return 'False' elif obj[7]>1.0: return 'True' else: return 'True' else: return 'False' elif obj[5]>0.0: # {"feature": "Occupation", "instances": 98, "metric_value": 0.3936, "depth": 7} if obj[4]>1: # {"feature": "Restaurant20to50", "instances": 83, "metric_value": 0.3681, "depth": 8} if obj[7]<=1.0: # {"feature": "Passanger", "instances": 58, "metric_value": 0.3282, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 58, "metric_value": 0.3282, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' elif obj[7]>1.0: # {"feature": "Passanger", "instances": 25, "metric_value": 0.4608, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 25, "metric_value": 0.4608, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' else: return 'False' elif obj[4]<=1: # {"feature": "Restaurant20to50", "instances": 15, "metric_value": 0.4286, "depth": 8} if obj[7]>0.0: # {"feature": "Passanger", "instances": 14, "metric_value": 0.4592, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 14, "metric_value": 0.4592, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[7]<=0.0: return 'False' else: return 'False' else: return 'True' else: return 'False' elif obj[3]>2: # {"feature": "Occupation", "instances": 48, "metric_value": 0.407, "depth": 6} if obj[4]>4: # {"feature": "Restaurant20to50", "instances": 29, "metric_value": 0.4803, "depth": 7} if obj[7]>-1.0: # {"feature": "Bar", "instances": 28, "metric_value": 0.4864, "depth": 8} if obj[5]<=0.0: # {"feature": "Passanger", "instances": 15, "metric_value": 0.4978, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 15, "metric_value": 0.4978, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' elif obj[5]>0.0: # {"feature": "Passanger", "instances": 13, "metric_value": 0.4734, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 13, "metric_value": 0.4734, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[7]<=-1.0: return 'False' else: return 'False' elif obj[4]<=4: # {"feature": "Bar", "instances": 19, "metric_value": 0.2469, "depth": 7} if obj[5]<=0.0: # {"feature": "Restaurant20to50", "instances": 12, "metric_value": 0.1429, "depth": 8} if obj[7]>0.0: # {"feature": "Passanger", "instances": 7, "metric_value": 0.2449, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 7, "metric_value": 0.2449, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[7]<=0.0: return 'True' else: return 'True' elif obj[5]>0.0: # {"feature": "Restaurant20to50", "instances": 7, "metric_value": 0.1905, "depth": 8} if obj[7]>0.0: return 'True' elif obj[7]<=0.0: # {"feature": "Passanger", "instances": 3, "metric_value": 0.4444, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 3, "metric_value": 0.4444, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' else: return 'False' else: return 'True' else: return 'True' else: return 'True' elif obj[1]<=0: # {"feature": "Passanger", "instances": 52, "metric_value": 0.1399, "depth": 5} if obj[0]>0: # {"feature": "Occupation", "instances": 46, "metric_value": 0.1118, "depth": 6} if obj[4]>1: # {"feature": "Education", "instances": 36, "metric_value": 0.0509, "depth": 7} if obj[3]>0: return 'False' elif obj[3]<=0: # {"feature": "Bar", "instances": 12, "metric_value": 0.1389, "depth": 8} if obj[5]>0.0: return 'False' elif obj[5]<=0.0: # {"feature": "Restaurant20to50", "instances": 6, "metric_value": 0.2222, "depth": 9} if obj[7]>0.0: # {"feature": "Direction_same", "instances": 3, "metric_value": 0.4444, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' elif obj[7]<=0.0: return 'False' else: return 'False' else: return 'False' else: return 'False' elif obj[4]<=1: # {"feature": "Education", "instances": 10, "metric_value": 0.2857, "depth": 7} if obj[3]<=2: # {"feature": "Restaurant20to50", "instances": 7, "metric_value": 0.381, "depth": 8} if obj[7]<=1.0: # {"feature": "Bar", "instances": 6, "metric_value": 0.4444, "depth": 9} if obj[5]<=0.0: # {"feature": "Direction_same", "instances": 3, "metric_value": 0.4444, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' elif obj[5]>0.0: # {"feature": "Direction_same", "instances": 3, "metric_value": 0.4444, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' elif obj[7]>1.0: return 'False' else: return 'False' elif obj[3]>2: return 'False' else: return 'False' else: return 'False' elif obj[0]<=0: # {"feature": "Occupation", "instances": 6, "metric_value": 0.0, "depth": 6} if obj[4]>1: return 'True' elif obj[4]<=1: return 'False' else: return 'False' else: return 'True' else: return 'False' else: return 'False' elif obj[6]>1.0: # {"feature": "Distance", "instances": 2845, "metric_value": 0.4173, "depth": 3} if obj[9]<=2: # {"feature": "Passanger", "instances": 2564, "metric_value": 0.4036, "depth": 4} if obj[0]<=2: # {"feature": "Occupation", "instances": 1682, "metric_value": 0.433, "depth": 5} if obj[4]<=18.296160208955353: # {"feature": "Education", "instances": 1558, "metric_value": 0.4422, "depth": 6} if obj[3]<=3: # {"feature": "Bar", "instances": 1454, "metric_value": 0.4466, "depth": 7} if obj[5]<=1.0: # {"feature": "Time", "instances": 884, "metric_value": 0.4332, "depth": 8} if obj[1]<=2: # {"feature": "Direction_same", "instances": 618, "metric_value": 0.4202, "depth": 9} if obj[8]<=0: # {"feature": "Restaurant20to50", "instances": 363, "metric_value": 0.4389, "depth": 10} if obj[7]>-1.0: return 'True' elif obj[7]<=-1.0: return 'True' else: return 'True' elif obj[8]>0: # {"feature": "Restaurant20to50", "instances": 255, "metric_value": 0.3906, "depth": 10} if obj[7]>-1.0: return 'True' elif obj[7]<=-1.0: return 'True' else: return 'True' else: return 'True' elif obj[1]>2: # {"feature": "Direction_same", "instances": 266, "metric_value": 0.4542, "depth": 9} if obj[8]<=0: # {"feature": "Restaurant20to50", "instances": 206, "metric_value": 0.4415, "depth": 10} if obj[7]<=1.0: return 'True' elif obj[7]>1.0: return 'True' else: return 'True' elif obj[8]>0: # {"feature": "Restaurant20to50", "instances": 60, "metric_value": 0.4727, "depth": 10} if obj[7]<=2.0: return 'True' elif obj[7]>2.0: return 'False' else: return 'False' else: return 'True' else: return 'True' elif obj[5]>1.0: # {"feature": "Direction_same", "instances": 570, "metric_value": 0.4625, "depth": 8} if obj[8]<=0: # {"feature": "Time", "instances": 357, "metric_value": 0.4629, "depth": 9} if obj[1]>1: # {"feature": "Restaurant20to50", "instances": 196, "metric_value": 0.4303, "depth": 10} if obj[7]<=3.0: return 'True' elif obj[7]>3.0: return 'True' else: return 'True' elif obj[1]<=1: # {"feature": "Restaurant20to50", "instances": 161, "metric_value": 0.4861, "depth": 10} if obj[7]<=2.0: return 'True' elif obj[7]>2.0: return 'False' else: return 'False' else: return 'True' elif obj[8]>0: # {"feature": "Time", "instances": 213, "metric_value": 0.4254, "depth": 9} if obj[1]<=1: # {"feature": "Restaurant20to50", "instances": 166, "metric_value": 0.397, "depth": 10} if obj[7]<=1.0: return 'True' elif obj[7]>1.0: return 'True' else: return 'True' elif obj[1]>1: # {"feature": "Restaurant20to50", "instances": 47, "metric_value": 0.4928, "depth": 10} if obj[7]<=2.0: return 'True' elif obj[7]>2.0: return 'False' else: return 'False' else: return 'True' else: return 'True' else: return 'True' elif obj[3]>3: # {"feature": "Bar", "instances": 104, "metric_value": 0.356, "depth": 7} if obj[5]<=3.0: # {"feature": "Time", "instances": 86, "metric_value": 0.3185, "depth": 8} if obj[1]<=3: # {"feature": "Restaurant20to50", "instances": 68, "metric_value": 0.3611, "depth": 9} if obj[7]<=1.0: # {"feature": "Direction_same", "instances": 50, "metric_value": 0.4184, "depth": 10} if obj[8]<=0: return 'True' elif obj[8]>0: return 'True' else: return 'True' elif obj[7]>1.0: # {"feature": "Direction_same", "instances": 18, "metric_value": 0.1818, "depth": 10} if obj[8]<=0: return 'True' elif obj[8]>0: return 'True' else: return 'True' else: return 'True' elif obj[1]>3: # {"feature": "Restaurant20to50", "instances": 18, "metric_value": 0.0926, "depth": 9} if obj[7]<=2.0: return 'True' elif obj[7]>2.0: # {"feature": "Direction_same", "instances": 6, "metric_value": 0.2778, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[5]>3.0: # {"feature": "Direction_same", "instances": 18, "metric_value": 0.4008, "depth": 8} if obj[8]<=0: # {"feature": "Time", "instances": 14, "metric_value": 0.3393, "depth": 9} if obj[1]<=1: # {"feature": "Restaurant20to50", "instances": 8, "metric_value": 0.2188, "depth": 10} if obj[7]<=4.0: return 'True' else: return 'True' elif obj[1]>1: # {"feature": "Restaurant20to50", "instances": 6, "metric_value": 0.5, "depth": 10} if obj[7]<=4.0: return 'True' else: return 'True' else: return 'True' elif obj[8]>0: # {"feature": "Time", "instances": 4, "metric_value": 0.3333, "depth": 9} if obj[1]>0: # {"feature": "Restaurant20to50", "instances": 3, "metric_value": 0.4444, "depth": 10} if obj[7]<=4.0: return 'False' else: return 'False' elif obj[1]<=0: return 'False' else: return 'False' else: return 'False' else: return 'True' else: return 'True' elif obj[4]>18.296160208955353: # {"feature": "Bar", "instances": 124, "metric_value": 0.2946, "depth": 6} if obj[5]<=2.0: # {"feature": "Time", "instances": 102, "metric_value": 0.258, "depth": 7} if obj[1]<=1: # {"feature": "Direction_same", "instances": 65, "metric_value": 0.3107, "depth": 8} if obj[8]>0: # {"feature": "Education", "instances": 36, "metric_value": 0.2118, "depth": 9} if obj[3]<=2: # {"feature": "Restaurant20to50", "instances": 22, "metric_value": 0.0844, "depth": 10} if obj[7]<=1.0: return 'True' elif obj[7]>1.0: return 'True' else: return 'True' elif obj[3]>2: # {"feature": "Restaurant20to50", "instances": 14, "metric_value": 0.3673, "depth": 10} if obj[7]<=1.0: return 'True' elif obj[7]>1.0: return 'True' else: return 'True' else: return 'True' elif obj[8]<=0: # {"feature": "Restaurant20to50", "instances": 29, "metric_value": 0.382, "depth": 9} if obj[7]<=2.0: # {"feature": "Education", "instances": 26, "metric_value": 0.3964, "depth": 10} if obj[3]<=2: return 'True' elif obj[3]>2: return 'True' else: return 'True' elif obj[7]>2.0: return 'True' else: return 'True' else: return 'True' elif obj[1]>1: # {"feature": "Education", "instances": 37, "metric_value": 0.142, "depth": 8} if obj[3]<=2: # {"feature": "Restaurant20to50", "instances": 25, "metric_value": 0.06, "depth": 9} if obj[7]>0.0: return 'True' elif obj[7]<=0.0: # {"feature": "Direction_same", "instances": 4, "metric_value": 0.375, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[3]>2: # {"feature": "Direction_same", "instances": 12, "metric_value": 0.2333, "depth": 9} if obj[8]<=0: # {"feature": "Restaurant20to50", "instances": 10, "metric_value": 0.175, "depth": 10} if obj[7]>1.0: return 'True' elif obj[7]<=1.0: return 'True' else: return 'True' elif obj[8]>0: # {"feature": "Restaurant20to50", "instances": 2, "metric_value": 0.5, "depth": 10} if obj[7]<=1.0: return 'True' else: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[5]>2.0: # {"feature": "Time", "instances": 22, "metric_value": 0.2871, "depth": 7} if obj[1]<=3: # {"feature": "Restaurant20to50", "instances": 19, "metric_value": 0.2679, "depth": 8} if obj[7]>1.0: # {"feature": "Direction_same", "instances": 11, "metric_value": 0.3117, "depth": 9} if obj[8]>0: # {"feature": "Education", "instances": 7, "metric_value": 0.4762, "depth": 10} if obj[3]>0: return 'False' elif obj[3]<=0: return 'False' else: return 'False' elif obj[8]<=0: return 'True' else: return 'True' elif obj[7]<=1.0: return 'True' else: return 'True' elif obj[1]>3: return 'False' else: return 'False' else: return 'True' else: return 'True' elif obj[0]>2: # {"feature": "Time", "instances": 882, "metric_value": 0.3365, "depth": 5} if obj[1]<=2: # {"feature": "Bar", "instances": 545, "metric_value": 0.2856, "depth": 6} if obj[5]<=3.0: # {"feature": "Occupation", "instances": 507, "metric_value": 0.2689, "depth": 7} if obj[4]<=17.929550223445236: # {"feature": "Education", "instances": 475, "metric_value": 0.2809, "depth": 8} if obj[3]<=3: # {"feature": "Restaurant20to50", "instances": 449, "metric_value": 0.2917, "depth": 9} if obj[7]<=2.0: # {"feature": "Direction_same", "instances": 419, "metric_value": 0.2846, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[7]>2.0: # {"feature": "Direction_same", "instances": 30, "metric_value": 0.3911, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[3]>3: # {"feature": "Restaurant20to50", "instances": 26, "metric_value": 0.071, "depth": 9} if obj[7]>0.0: # {"feature": "Direction_same", "instances": 13, "metric_value": 0.142, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[7]<=0.0: return 'True' else: return 'True' else: return 'True' elif obj[4]>17.929550223445236: # {"feature": "Restaurant20to50", "instances": 32, "metric_value": 0.0556, "depth": 8} if obj[7]<=1.0: return 'True' elif obj[7]>1.0: # {"feature": "Education", "instances": 9, "metric_value": 0.1778, "depth": 9} if obj[3]>0: # {"feature": "Direction_same", "instances": 5, "metric_value": 0.32, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[3]<=0: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[5]>3.0: # {"feature": "Restaurant20to50", "instances": 38, "metric_value": 0.4369, "depth": 7} if obj[7]>1.0: # {"feature": "Occupation", "instances": 22, "metric_value": 0.3463, "depth": 8} if obj[4]<=14: # {"feature": "Education", "instances": 21, "metric_value": 0.3602, "depth": 9} if obj[3]<=0: # {"feature": "Direction_same", "instances": 11, "metric_value": 0.3967, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[3]>0: # {"feature": "Direction_same", "instances": 10, "metric_value": 0.32, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[4]>14: return 'False' else: return 'False' elif obj[7]<=1.0: # {"feature": "Occupation", "instances": 16, "metric_value": 0.4875, "depth": 8} if obj[4]>5: # {"feature": "Education", "instances": 10, "metric_value": 0.48, "depth": 9} if obj[3]<=0: # {"feature": "Direction_same", "instances": 10, "metric_value": 0.48, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' elif obj[4]<=5: # {"feature": "Education", "instances": 6, "metric_value": 0.4, "depth": 9} if obj[3]>0: # {"feature": "Direction_same", "instances": 5, "metric_value": 0.48, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' elif obj[3]<=0: return 'True' else: return 'True' else: return 'True' else: return 'False' else: return 'True' elif obj[1]>2: # {"feature": "Education", "instances": 337, "metric_value": 0.4009, "depth": 6} if obj[3]<=2: # {"feature": "Restaurant20to50", "instances": 238, "metric_value": 0.3702, "depth": 7} if obj[7]<=1.0: # {"feature": "Occupation", "instances": 144, "metric_value": 0.3955, "depth": 8} if obj[4]<=17.939269481700965: # {"feature": "Bar", "instances": 133, "metric_value": 0.4096, "depth": 9} if obj[5]<=2.0: # {"feature": "Direction_same", "instances": 111, "metric_value": 0.4318, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[5]>2.0: # {"feature": "Direction_same", "instances": 22, "metric_value": 0.2975, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[4]>17.939269481700965: # {"feature": "Bar", "instances": 11, "metric_value": 0.1455, "depth": 9} if obj[5]>0.0: return 'True' elif obj[5]<=0.0: # {"feature": "Direction_same", "instances": 5, "metric_value": 0.32, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[7]>1.0: # {"feature": "Occupation", "instances": 94, "metric_value": 0.3048, "depth": 8} if obj[4]<=19: # {"feature": "Bar", "instances": 89, "metric_value": 0.2919, "depth": 9} if obj[5]<=2.0: # {"feature": "Direction_same", "instances": 74, "metric_value": 0.2717, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[5]>2.0: # {"feature": "Direction_same", "instances": 15, "metric_value": 0.3911, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[4]>19: # {"feature": "Bar", "instances": 5, "metric_value": 0.4, "depth": 9} if obj[5]<=2.0: # {"feature": "Direction_same", "instances": 4, "metric_value": 0.5, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[5]>2.0: return 'False' else: return 'False' else: return 'False' else: return 'True' elif obj[3]>2: # {"feature": "Bar", "instances": 99, "metric_value": 0.4415, "depth": 7} if obj[5]>0.0: # {"feature": "Occupation", "instances": 72, "metric_value": 0.463, "depth": 8} if obj[4]<=16: # {"feature": "Restaurant20to50", "instances": 60, "metric_value": 0.4911, "depth": 9} if obj[7]<=3.0: # {"feature": "Direction_same", "instances": 56, "metric_value": 0.4994, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[7]>3.0: # {"feature": "Direction_same", "instances": 4, "metric_value": 0.375, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' elif obj[4]>16: # {"feature": "Restaurant20to50", "instances": 12, "metric_value": 0.2593, "depth": 9} if obj[7]<=2.0: # {"feature": "Direction_same", "instances": 9, "metric_value": 0.3457, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[7]>2.0: return 'True' else: return 'True' else: return 'True' elif obj[5]<=0.0: # {"feature": "Occupation", "instances": 27, "metric_value": 0.2822, "depth": 8} if obj[4]<=7: # {"feature": "Restaurant20to50", "instances": 21, "metric_value": 0.3305, "depth": 9} if obj[7]<=1.0: # {"feature": "Direction_same", "instances": 17, "metric_value": 0.2907, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[7]>1.0: # {"feature": "Direction_same", "instances": 4, "metric_value": 0.5, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[4]>7: return 'True' else: return 'True' else: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[9]>2: # {"feature": "Education", "instances": 281, "metric_value": 0.4772, "depth": 4} if obj[3]>0: # {"feature": "Occupation", "instances": 199, "metric_value": 0.4775, "depth": 5} if obj[4]<=12.347496012949087: # {"feature": "Passanger", "instances": 175, "metric_value": 0.4663, "depth": 6} if obj[0]>0: # {"feature": "Restaurant20to50", "instances": 170, "metric_value": 0.4633, "depth": 7} if obj[7]<=2.0: # {"feature": "Bar", "instances": 150, "metric_value": 0.4886, "depth": 8} if obj[5]>-1.0: # {"feature": "Time", "instances": 149, "metric_value": 0.4896, "depth": 9} if obj[1]>0: # {"feature": "Direction_same", "instances": 129, "metric_value": 0.4949, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' elif obj[1]<=0: # {"feature": "Direction_same", "instances": 20, "metric_value": 0.455, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' elif obj[5]<=-1.0: return 'False' else: return 'False' elif obj[7]>2.0: # {"feature": "Time", "instances": 20, "metric_value": 0.075, "depth": 8} if obj[1]<=1: return 'False' elif obj[1]>1: # {"feature": "Bar", "instances": 4, "metric_value": 0.0, "depth": 9} if obj[5]>1.0: return 'True' elif obj[5]<=1.0: return 'False' else: return 'False' else: return 'True' else: return 'False' elif obj[0]<=0: return 'True' else: return 'True' elif obj[4]>12.347496012949087: # {"feature": "Bar", "instances": 24, "metric_value": 0.3843, "depth": 6} if obj[5]<=2.0: # {"feature": "Time", "instances": 18, "metric_value": 0.3333, "depth": 7} if obj[1]>0: # {"feature": "Restaurant20to50", "instances": 16, "metric_value": 0.3571, "depth": 8} if obj[7]<=2.0: # {"feature": "Passanger", "instances": 14, "metric_value": 0.4082, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 14, "metric_value": 0.4082, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[7]>2.0: return 'True' else: return 'True' elif obj[1]<=0: return 'True' else: return 'True' elif obj[5]>2.0: # {"feature": "Time", "instances": 6, "metric_value": 0.4, "depth": 7} if obj[1]>0: # {"feature": "Restaurant20to50", "instances": 5, "metric_value": 0.3, "depth": 8} if obj[7]<=1.0: # {"feature": "Passanger", "instances": 4, "metric_value": 0.375, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 4, "metric_value": 0.375, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[7]>1.0: return 'False' else: return 'False' elif obj[1]<=0: return 'False' else: return 'False' else: return 'True' else: return 'True' elif obj[3]<=0: # {"feature": "Occupation", "instances": 82, "metric_value": 0.4027, "depth": 5} if obj[4]>4: # {"feature": "Restaurant20to50", "instances": 62, "metric_value": 0.4622, "depth": 6} if obj[7]<=3.0: # {"feature": "Bar", "instances": 61, "metric_value": 0.4638, "depth": 7} if obj[5]<=2.0: # {"feature": "Time", "instances": 51, "metric_value": 0.4487, "depth": 8} if obj[1]>0: # {"feature": "Passanger", "instances": 38, "metric_value": 0.4321, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 38, "metric_value": 0.4321, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[1]<=0: # {"feature": "Passanger", "instances": 13, "metric_value": 0.4573, "depth": 9} if obj[0]>0: # {"feature": "Direction_same", "instances": 9, "metric_value": 0.4938, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' elif obj[0]<=0: # {"feature": "Direction_same", "instances": 4, "metric_value": 0.375, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[5]>2.0: # {"feature": "Time", "instances": 10, "metric_value": 0.4444, "depth": 8} if obj[1]>0: # {"feature": "Passanger", "instances": 9, "metric_value": 0.4938, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 9, "metric_value": 0.4938, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' elif obj[1]<=0: return 'True' else: return 'True' else: return 'True' elif obj[7]>3.0: return 'False' else: return 'False' elif obj[4]<=4: # {"feature": "Time", "instances": 20, "metric_value": 0.1608, "depth": 6} if obj[1]<=1: # {"feature": "Restaurant20to50", "instances": 17, "metric_value": 0.0941, "depth": 7} if obj[7]>0.0: return 'True' elif obj[7]<=0.0: # {"feature": "Bar", "instances": 5, "metric_value": 0.2, "depth": 8} if obj[5]<=0.0: return 'True' elif obj[5]>0.0: # {"feature": "Passanger", "instances": 2, "metric_value": 0.5, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 2, "metric_value": 0.5, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' else: return 'False' else: return 'True' elif obj[1]>1: # {"feature": "Restaurant20to50", "instances": 3, "metric_value": 0.3333, "depth": 7} if obj[7]<=1.0: # {"feature": "Passanger", "instances": 2, "metric_value": 0.5, "depth": 8} if obj[0]<=1: # {"feature": "Bar", "instances": 2, "metric_value": 0.5, "depth": 9} if obj[5]<=0.0: # {"feature": "Direction_same", "instances": 2, "metric_value": 0.5, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[7]>1.0: return 'True' else: return 'True' else: return 'True' else: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[2]<=1: # {"feature": "Bar", "instances": 2261, "metric_value": 0.4547, "depth": 2} if obj[5]>0.0: # {"feature": "Passanger", "instances": 1286, "metric_value": 0.4891, "depth": 3} if obj[0]<=2: # {"feature": "Time", "instances": 1095, "metric_value": 0.4916, "depth": 4} if obj[1]>0: # {"feature": "Restaurant20to50", "instances": 757, "metric_value": 0.4869, "depth": 5} if obj[7]<=2.0: # {"feature": "Education", "instances": 686, "metric_value": 0.4848, "depth": 6} if obj[3]>1: # {"feature": "Coffeehouse", "instances": 406, "metric_value": 0.4662, "depth": 7} if obj[6]>1.0: # {"feature": "Occupation", "instances": 220, "metric_value": 0.4904, "depth": 8} if obj[4]<=20: # {"feature": "Distance", "instances": 218, "metric_value": 0.4943, "depth": 9} if obj[9]<=2: # {"feature": "Direction_same", "instances": 161, "metric_value": 0.4966, "depth": 10} if obj[8]<=0: return 'False' elif obj[8]>0: return 'False' else: return 'False' elif obj[9]>2: # {"feature": "Direction_same", "instances": 57, "metric_value": 0.4875, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' elif obj[4]>20: return 'False' else: return 'False' elif obj[6]<=1.0: # {"feature": "Occupation", "instances": 186, "metric_value": 0.4246, "depth": 8} if obj[4]>5: # {"feature": "Distance", "instances": 131, "metric_value": 0.3936, "depth": 9} if obj[9]<=2: # {"feature": "Direction_same", "instances": 101, "metric_value": 0.3725, "depth": 10} if obj[8]<=0: return 'False' elif obj[8]>0: return 'False' else: return 'False' elif obj[9]>2: # {"feature": "Direction_same", "instances": 30, "metric_value": 0.4644, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' elif obj[4]<=5: # {"feature": "Direction_same", "instances": 55, "metric_value": 0.4574, "depth": 9} if obj[8]<=0: # {"feature": "Distance", "instances": 47, "metric_value": 0.4936, "depth": 10} if obj[9]<=2: return 'True' elif obj[9]>2: return 'False' else: return 'False' elif obj[8]>0: # {"feature": "Distance", "instances": 8, "metric_value": 0.2, "depth": 10} if obj[9]>1: return 'False' elif obj[9]<=1: return 'False' else: return 'False' else: return 'False' else: return 'False' else: return 'False' elif obj[3]<=1: # {"feature": "Occupation", "instances": 280, "metric_value": 0.4946, "depth": 7} if obj[4]>0: # {"feature": "Coffeehouse", "instances": 277, "metric_value": 0.4954, "depth": 8} if obj[6]<=3.0: # {"feature": "Distance", "instances": 251, "metric_value": 0.4987, "depth": 9} if obj[9]<=2: # {"feature": "Direction_same", "instances": 176, "metric_value": 0.4999, "depth": 10} if obj[8]<=0: return 'False' elif obj[8]>0: return 'False' else: return 'False' elif obj[9]>2: # {"feature": "Direction_same", "instances": 75, "metric_value": 0.4956, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[6]>3.0: # {"feature": "Distance", "instances": 26, "metric_value": 0.3546, "depth": 9} if obj[9]<=2: # {"feature": "Direction_same", "instances": 21, "metric_value": 0.3361, "depth": 10} if obj[8]<=0: return 'False' elif obj[8]>0: return 'False' else: return 'False' elif obj[9]>2: # {"feature": "Direction_same", "instances": 5, "metric_value": 0.32, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' else: return 'False' elif obj[4]<=0: return 'True' else: return 'True' else: return 'False' elif obj[7]>2.0: # {"feature": "Occupation", "instances": 71, "metric_value": 0.4231, "depth": 6} if obj[4]<=14: # {"feature": "Education", "instances": 59, "metric_value": 0.4027, "depth": 7} if obj[3]<=3: # {"feature": "Distance", "instances": 43, "metric_value": 0.4156, "depth": 8} if obj[9]<=2: # {"feature": "Coffeehouse", "instances": 31, "metric_value": 0.3766, "depth": 9} if obj[6]<=2.0: # {"feature": "Direction_same", "instances": 16, "metric_value": 0.4271, "depth": 10} if obj[8]<=0: return 'True' elif obj[8]>0: return 'True' else: return 'True' elif obj[6]>2.0: # {"feature": "Direction_same", "instances": 15, "metric_value": 0.3077, "depth": 10} if obj[8]<=0: return 'True' elif obj[8]>0: return 'True' else: return 'True' else: return 'True' elif obj[9]>2: # {"feature": "Coffeehouse", "instances": 12, "metric_value": 0.4, "depth": 9} if obj[6]<=3.0: # {"feature": "Direction_same", "instances": 10, "metric_value": 0.48, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[6]>3.0: return 'False' else: return 'False' else: return 'True' elif obj[3]>3: # {"feature": "Distance", "instances": 16, "metric_value": 0.1875, "depth": 8} if obj[9]>1: return 'True' elif obj[9]<=1: # {"feature": "Direction_same", "instances": 6, "metric_value": 0.25, "depth": 9} if obj[8]<=0: # {"feature": "Coffeehouse", "instances": 4, "metric_value": 0.3333, "depth": 10} if obj[6]>3.0: return 'True' elif obj[6]<=3.0: return 'True' else: return 'True' elif obj[8]>0: return 'False' else: return 'False' else: return 'True' else: return 'True' elif obj[4]>14: # {"feature": "Education", "instances": 12, "metric_value": 0.3125, "depth": 7} if obj[3]<=2: # {"feature": "Coffeehouse", "instances": 8, "metric_value": 0.1875, "depth": 8} if obj[6]<=1.0: # {"feature": "Distance", "instances": 4, "metric_value": 0.0, "depth": 9} if obj[9]<=2: return 'False' elif obj[9]>2: return 'True' else: return 'True' elif obj[6]>1.0: return 'True' else: return 'True' elif obj[3]>2: return 'False' else: return 'False' else: return 'False' else: return 'True' elif obj[1]<=0: # {"feature": "Distance", "instances": 338, "metric_value": 0.4678, "depth": 5} if obj[9]>1: # {"feature": "Direction_same", "instances": 182, "metric_value": 0.485, "depth": 6} if obj[8]<=0: # {"feature": "Coffeehouse", "instances": 171, "metric_value": 0.4889, "depth": 7} if obj[6]>0.0: # {"feature": "Restaurant20to50", "instances": 133, "metric_value": 0.4942, "depth": 8} if obj[7]>0.0: # {"feature": "Education", "instances": 121, "metric_value": 0.4889, "depth": 9} if obj[3]<=3: # {"feature": "Occupation", "instances": 115, "metric_value": 0.492, "depth": 10} if obj[4]>1: return 'True' elif obj[4]<=1: return 'False' else: return 'False' elif obj[3]>3: # {"feature": "Occupation", "instances": 6, "metric_value": 0.2222, "depth": 10} if obj[4]<=9: return 'True' elif obj[4]>9: return 'True' else: return 'True' else: return 'True' elif obj[7]<=0.0: # {"feature": "Occupation", "instances": 12, "metric_value": 0.3636, "depth": 9} if obj[4]<=21: # {"feature": "Education", "instances": 11, "metric_value": 0.3377, "depth": 10} if obj[3]<=0: return 'False' elif obj[3]>0: return 'False' else: return 'False' elif obj[4]>21: return 'True' else: return 'True' else: return 'False' elif obj[6]<=0.0: # {"feature": "Restaurant20to50", "instances": 38, "metric_value": 0.4133, "depth": 8} if obj[7]<=1.0: # {"feature": "Occupation", "instances": 25, "metric_value": 0.428, "depth": 9} if obj[4]>4: # {"feature": "Education", "instances": 20, "metric_value": 0.4118, "depth": 10} if obj[3]<=2: return 'True' elif obj[3]>2: return 'True' else: return 'True' elif obj[4]<=4: # {"feature": "Education", "instances": 5, "metric_value": 0.2667, "depth": 10} if obj[3]<=2: return 'False' elif obj[3]>2: return 'False' else: return 'False' else: return 'False' elif obj[7]>1.0: # {"feature": "Occupation", "instances": 13, "metric_value": 0.241, "depth": 9} if obj[4]>6: # {"feature": "Education", "instances": 10, "metric_value": 0.1, "depth": 10} if obj[3]>0: return 'True' elif obj[3]<=0: return 'True' else: return 'True' elif obj[4]<=6: # {"feature": "Education", "instances": 3, "metric_value": 0.0, "depth": 10} if obj[3]<=0: return 'True' elif obj[3]>0: return 'False' else: return 'False' else: return 'True' else: return 'True' else: return 'True' elif obj[8]>0: # {"feature": "Occupation", "instances": 11, "metric_value": 0.2424, "depth": 7} if obj[4]<=6: # {"feature": "Coffeehouse", "instances": 6, "metric_value": 0.3333, "depth": 8} if obj[6]>1.0: # {"feature": "Education", "instances": 4, "metric_value": 0.3333, "depth": 9} if obj[3]>0: # {"feature": "Restaurant20to50", "instances": 3, "metric_value": 0.3333, "depth": 10} if obj[7]>0.0: return 'False' elif obj[7]<=0.0: return 'False' else: return 'False' elif obj[3]<=0: return 'True' else: return 'True' elif obj[6]<=1.0: return 'False' else: return 'False' elif obj[4]>6: return 'False' else: return 'False' else: return 'False' elif obj[9]<=1: # {"feature": "Direction_same", "instances": 156, "metric_value": 0.4105, "depth": 6} if obj[8]>0: # {"feature": "Restaurant20to50", "instances": 146, "metric_value": 0.3926, "depth": 7} if obj[7]<=1.0: # {"feature": "Education", "instances": 92, "metric_value": 0.4484, "depth": 8} if obj[3]<=3: # {"feature": "Coffeehouse", "instances": 88, "metric_value": 0.4622, "depth": 9} if obj[6]>-1.0: # {"feature": "Occupation", "instances": 86, "metric_value": 0.4688, "depth": 10} if obj[4]<=17.32936349277302: return 'True' elif obj[4]>17.32936349277302: return 'True' else: return 'True' elif obj[6]<=-1.0: return 'True' else: return 'True' elif obj[3]>3: return 'True' else: return 'True' elif obj[7]>1.0: # {"feature": "Education", "instances": 54, "metric_value": 0.2516, "depth": 8} if obj[3]<=4: # {"feature": "Occupation", "instances": 53, "metric_value": 0.2478, "depth": 9} if obj[4]<=20: # {"feature": "Coffeehouse", "instances": 47, "metric_value": 0.2188, "depth": 10} if obj[6]>0.0: return 'True' elif obj[6]<=0.0: return 'True' else: return 'True' elif obj[4]>20: # {"feature": "Coffeehouse", "instances": 6, "metric_value": 0.2222, "depth": 10} if obj[6]>1.0: return 'True' elif obj[6]<=1.0: return 'False' else: return 'False' else: return 'True' elif obj[3]>4: return 'False' else: return 'False' else: return 'True' elif obj[8]<=0: # {"feature": "Coffeehouse", "instances": 10, "metric_value": 0.3, "depth": 7} if obj[6]>0.0: # {"feature": "Occupation", "instances": 6, "metric_value": 0.25, "depth": 8} if obj[4]<=9: # {"feature": "Education", "instances": 4, "metric_value": 0.3333, "depth": 9} if obj[3]>0: # {"feature": "Restaurant20to50", "instances": 3, "metric_value": 0.3333, "depth": 10} if obj[7]<=1.0: return 'False' elif obj[7]>1.0: return 'True' else: return 'True' elif obj[3]<=0: return 'True' else: return 'True' elif obj[4]>9: return 'False' else: return 'False' elif obj[6]<=0.0: return 'False' else: return 'False' else: return 'False' else: return 'True' else: return 'True' elif obj[0]>2: # {"feature": "Time", "instances": 191, "metric_value": 0.4082, "depth": 4} if obj[1]>2: # {"feature": "Occupation", "instances": 148, "metric_value": 0.3544, "depth": 5} if obj[4]<=7.54054054054054: # {"feature": "Coffeehouse", "instances": 92, "metric_value": 0.4397, "depth": 6} if obj[6]>1.0: # {"feature": "Education", "instances": 54, "metric_value": 0.3852, "depth": 7} if obj[3]<=2: # {"feature": "Restaurant20to50", "instances": 43, "metric_value": 0.3477, "depth": 8} if obj[7]<=2.0: # {"feature": "Distance", "instances": 35, "metric_value": 0.3197, "depth": 9} if obj[9]>1: # {"feature": "Direction_same", "instances": 26, "metric_value": 0.3107, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[9]<=1: # {"feature": "Direction_same", "instances": 9, "metric_value": 0.3457, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[7]>2.0: # {"feature": "Direction_same", "instances": 8, "metric_value": 0.4688, "depth": 9} if obj[8]<=0: # {"feature": "Distance", "instances": 8, "metric_value": 0.4688, "depth": 10} if obj[9]<=2: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[3]>2: # {"feature": "Restaurant20to50", "instances": 11, "metric_value": 0.3636, "depth": 8} if obj[7]<=3.0: # {"feature": "Distance", "instances": 9, "metric_value": 0.4167, "depth": 9} if obj[9]>1: # {"feature": "Direction_same", "instances": 8, "metric_value": 0.4688, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[9]<=1: return 'True' else: return 'True' elif obj[7]>3.0: return 'False' else: return 'False' else: return 'True' elif obj[6]<=1.0: # {"feature": "Education", "instances": 38, "metric_value": 0.4099, "depth": 7} if obj[3]>0: # {"feature": "Restaurant20to50", "instances": 26, "metric_value": 0.3851, "depth": 8} if obj[7]<=1.0: # {"feature": "Distance", "instances": 17, "metric_value": 0.4824, "depth": 9} if obj[9]>1: # {"feature": "Direction_same", "instances": 15, "metric_value": 0.48, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[9]<=1: # {"feature": "Direction_same", "instances": 2, "metric_value": 0.5, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[7]>1.0: # {"feature": "Distance", "instances": 9, "metric_value": 0.1778, "depth": 9} if obj[9]>1: # {"feature": "Direction_same", "instances": 5, "metric_value": 0.32, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[9]<=1: return 'True' else: return 'True' else: return 'True' elif obj[3]<=0: # {"feature": "Distance", "instances": 12, "metric_value": 0.3333, "depth": 8} if obj[9]>1: # {"feature": "Restaurant20to50", "instances": 9, "metric_value": 0.4167, "depth": 9} if obj[7]>0.0: # {"feature": "Direction_same", "instances": 8, "metric_value": 0.4688, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' elif obj[7]<=0.0: return 'False' else: return 'False' elif obj[9]<=1: return 'False' else: return 'False' else: return 'False' else: return 'True' elif obj[4]>7.54054054054054: # {"feature": "Coffeehouse", "instances": 56, "metric_value": 0.1676, "depth": 6} if obj[6]<=3.0: # {"feature": "Education", "instances": 52, "metric_value": 0.1363, "depth": 7} if obj[3]>0: # {"feature": "Restaurant20to50", "instances": 35, "metric_value": 0.1977, "depth": 8} if obj[7]<=2.0: # {"feature": "Distance", "instances": 31, "metric_value": 0.1725, "depth": 9} if obj[9]>1: # {"feature": "Direction_same", "instances": 25, "metric_value": 0.1472, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[9]<=1: # {"feature": "Direction_same", "instances": 6, "metric_value": 0.2778, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' else: return 'True' elif obj[7]>2.0: # {"feature": "Direction_same", "instances": 4, "metric_value": 0.375, "depth": 9} if obj[8]<=0: # {"feature": "Distance", "instances": 4, "metric_value": 0.375, "depth": 10} if obj[9]<=2: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[3]<=0: return 'True' else: return 'True' elif obj[6]>3.0: # {"feature": "Education", "instances": 4, "metric_value": 0.3333, "depth": 7} if obj[3]>0: # {"feature": "Restaurant20to50", "instances": 3, "metric_value": 0.0, "depth": 8} if obj[7]>1.0: return 'False' elif obj[7]<=1.0: return 'True' else: return 'True' elif obj[3]<=0: return 'True' else: return 'True' else: return 'False' else: return 'True' elif obj[1]<=2: # {"feature": "Occupation", "instances": 43, "metric_value": 0.4394, "depth": 5} if obj[4]<=12: # {"feature": "Restaurant20to50", "instances": 35, "metric_value": 0.4554, "depth": 6} if obj[7]>0.0: # {"feature": "Education", "instances": 32, "metric_value": 0.4453, "depth": 7} if obj[3]>1: # {"feature": "Coffeehouse", "instances": 24, "metric_value": 0.4398, "depth": 8} if obj[6]>1.0: # {"feature": "Direction_same", "instances": 18, "metric_value": 0.4938, "depth": 9} if obj[8]<=0: # {"feature": "Distance", "instances": 18, "metric_value": 0.4938, "depth": 10} if obj[9]<=2: return 'False' else: return 'False' else: return 'False' elif obj[6]<=1.0: # {"feature": "Direction_same", "instances": 6, "metric_value": 0.2778, "depth": 9} if obj[8]<=0: # {"feature": "Distance", "instances": 6, "metric_value": 0.2778, "depth": 10} if obj[9]<=2: return 'False' else: return 'False' else: return 'False' else: return 'False' elif obj[3]<=1: # {"feature": "Coffeehouse", "instances": 8, "metric_value": 0.3333, "depth": 8} if obj[6]<=2.0: # {"feature": "Direction_same", "instances": 6, "metric_value": 0.2778, "depth": 9} if obj[8]<=0: # {"feature": "Distance", "instances": 6, "metric_value": 0.2778, "depth": 10} if obj[9]<=2: return 'True' else: return 'True' else: return 'True' elif obj[6]>2.0: # {"feature": "Direction_same", "instances": 2, "metric_value": 0.5, "depth": 9} if obj[8]<=0: # {"feature": "Distance", "instances": 2, "metric_value": 0.5, "depth": 10} if obj[9]<=2: return 'False' else: return 'False' else: return 'False' else: return 'False' else: return 'True' elif obj[7]<=0.0: return 'False' else: return 'False' elif obj[4]>12: # {"feature": "Restaurant20to50", "instances": 8, "metric_value": 0.125, "depth": 6} if obj[7]<=1.0: return 'True' elif obj[7]>1.0: # {"feature": "Education", "instances": 2, "metric_value": 0.0, "depth": 7} if obj[3]>2: return 'True' elif obj[3]<=2: return 'False' else: return 'False' else: return 'True' else: return 'True' else: return 'True' else: return 'True' elif obj[5]<=0.0: # {"feature": "Distance", "instances": 975, "metric_value": 0.3929, "depth": 3} if obj[9]<=2: # {"feature": "Education", "instances": 797, "metric_value": 0.4115, "depth": 4} if obj[3]>0: # {"feature": "Coffeehouse", "instances": 516, "metric_value": 0.3787, "depth": 5} if obj[6]<=2.0: # {"feature": "Time", "instances": 432, "metric_value": 0.41, "depth": 6} if obj[1]>0: # {"feature": "Occupation", "instances": 290, "metric_value": 0.3772, "depth": 7} if obj[4]<=12.422354984562588: # {"feature": "Direction_same", "instances": 253, "metric_value": 0.3583, "depth": 8} if obj[8]<=0: # {"feature": "Passanger", "instances": 216, "metric_value": 0.3772, "depth": 9} if obj[0]<=1: # {"feature": "Restaurant20to50", "instances": 123, "metric_value": 0.4057, "depth": 10} if obj[7]>0.0: return 'False' elif obj[7]<=0.0: return 'False' else: return 'False' elif obj[0]>1: # {"feature": "Restaurant20to50", "instances": 93, "metric_value": 0.3346, "depth": 10} if obj[7]>0.0: return 'False' elif obj[7]<=0.0: return 'False' else: return 'False' else: return 'False' elif obj[8]>0: # {"feature": "Passanger", "instances": 37, "metric_value": 0.0956, "depth": 9} if obj[0]<=1: # {"feature": "Restaurant20to50", "instances": 32, "metric_value": 0.0556, "depth": 10} if obj[7]>0.0: return 'False' elif obj[7]<=0.0: return 'False' else: return 'False' elif obj[0]>1: # {"feature": "Restaurant20to50", "instances": 5, "metric_value": 0.2, "depth": 10} if obj[7]>1.0: return 'True' elif obj[7]<=1.0: return 'False' else: return 'False' else: return 'True' else: return 'False' elif obj[4]>12.422354984562588: # {"feature": "Passanger", "instances": 37, "metric_value": 0.4376, "depth": 8} if obj[0]<=2: # {"feature": "Direction_same", "instances": 30, "metric_value": 0.4198, "depth": 9} if obj[8]<=0: # {"feature": "Restaurant20to50", "instances": 27, "metric_value": 0.4605, "depth": 10} if obj[7]<=1.0: return 'False' elif obj[7]>1.0: return 'True' else: return 'True' elif obj[8]>0: return 'False' else: return 'False' elif obj[0]>2: # {"feature": "Restaurant20to50", "instances": 7, "metric_value": 0.3429, "depth": 9} if obj[7]>0.0: # {"feature": "Direction_same", "instances": 5, "metric_value": 0.48, "depth": 10} if obj[8]<=0: return 'True' else: return 'True' elif obj[7]<=0.0: return 'True' else: return 'True' else: return 'True' else: return 'False' elif obj[1]<=0: # {"feature": "Restaurant20to50", "instances": 142, "metric_value": 0.4467, "depth": 7} if obj[7]>0.0: # {"feature": "Occupation", "instances": 101, "metric_value": 0.4682, "depth": 8} if obj[4]>4: # {"feature": "Passanger", "instances": 66, "metric_value": 0.4923, "depth": 9} if obj[0]<=2: # {"feature": "Direction_same", "instances": 65, "metric_value": 0.4988, "depth": 10} if obj[8]<=0: return 'False' elif obj[8]>0: return 'True' else: return 'True' elif obj[0]>2: return 'True' else: return 'True' elif obj[4]<=4: # {"feature": "Passanger", "instances": 35, "metric_value": 0.3966, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 22, "metric_value": 0.3481, "depth": 10} if obj[8]>0: return 'False' elif obj[8]<=0: return 'False' else: return 'False' elif obj[0]>1: # {"feature": "Direction_same", "instances": 13, "metric_value": 0.4685, "depth": 10} if obj[8]<=0: return 'False' elif obj[8]>0: return 'True' else: return 'True' else: return 'False' else: return 'False' elif obj[7]<=0.0: # {"feature": "Occupation", "instances": 41, "metric_value": 0.3305, "depth": 8} if obj[4]>4: # {"feature": "Passanger", "instances": 30, "metric_value": 0.3753, "depth": 9} if obj[0]<=1: # {"feature": "Direction_same", "instances": 27, "metric_value": 0.4148, "depth": 10} if obj[8]>0: return 'False' elif obj[8]<=0: return 'False' else: return 'False' elif obj[0]>1: return 'False' else: return 'False' elif obj[4]<=4: # {"feature": "Passanger", "instances": 11, "metric_value": 0.0, "depth": 9} if obj[0]<=1: return 'False' elif obj[0]>1: return 'True' else: return 'True' else: return 'False' else: return 'False' else: return 'False' elif obj[6]>2.0: # {"feature": "Direction_same", "instances": 84, "metric_value": 0.1859, "depth": 6} if obj[8]<=0: # {"feature": "Occupation", "instances": 64, "metric_value": 0.1349, "depth": 7} if obj[4]<=7: # {"feature": "Passanger", "instances": 49, "metric_value": 0.0748, "depth": 8} if obj[0]>0: # {"feature": "Time", "instances": 42, "metric_value": 0.0455, "depth": 9} if obj[1]>2: # {"feature": "Restaurant20to50", "instances": 23, "metric_value": 0.0821, "depth": 10} if obj[7]<=1.0: return 'False' elif obj[7]>1.0: return 'False' else: return 'False' elif obj[1]<=2: return 'False' else: return 'False' elif obj[0]<=0: # {"feature": "Time", "instances": 7, "metric_value": 0.1905, "depth": 9} if obj[1]<=2: return 'False' elif obj[1]>2: # {"feature": "Restaurant20to50", "instances": 3, "metric_value": 0.4444, "depth": 10} if obj[7]<=1.0: return 'False' else: return 'False' else: return 'False' else: return 'False' elif obj[4]>7: # {"feature": "Time", "instances": 15, "metric_value": 0.2545, "depth": 8} if obj[1]>1: # {"feature": "Passanger", "instances": 11, "metric_value": 0.0909, "depth": 9} if obj[0]>0: return 'False' elif obj[0]<=0: # {"feature": "Restaurant20to50", "instances": 2, "metric_value": 0.5, "depth": 10} if obj[7]<=1.0: return 'False' else: return 'False' else: return 'False' elif obj[1]<=1: # {"feature": "Passanger", "instances": 4, "metric_value": 0.3333, "depth": 9} if obj[0]<=1: # {"feature": "Restaurant20to50", "instances": 3, "metric_value": 0.3333, "depth": 10} if obj[7]>1.0: return 'True' elif obj[7]<=1.0: return 'True' else: return 'True' elif obj[0]>1: return 'False' else: return 'False' else: return 'True' else: return 'False' elif obj[8]>0: # {"feature": "Occupation", "instances": 20, "metric_value": 0.275, "depth": 7} if obj[4]>1: # {"feature": "Time", "instances": 16, "metric_value": 0.2045, "depth": 8} if obj[1]<=0: # {"feature": "Passanger", "instances": 11, "metric_value": 0.2525, "depth": 9} if obj[0]<=1: # {"feature": "Restaurant20to50", "instances": 9, "metric_value": 0.1905, "depth": 10} if obj[7]<=1.0: return 'False' elif obj[7]>1.0: return 'False' else: return 'False' elif obj[0]>1: # {"feature": "Restaurant20to50", "instances": 2, "metric_value": 0.5, "depth": 10} if obj[7]<=1.0: return 'True' else: return 'True' else: return 'True' elif obj[1]>0: return 'False' else: return 'False' elif obj[4]<=1: # {"feature": "Passanger", "instances": 4, "metric_value": 0.3333, "depth": 8} if obj[0]<=1: # {"feature": "Time", "instances": 3, "metric_value": 0.0, "depth": 9} if obj[1]<=0: return 'False' elif obj[1]>0: return 'True' else: return 'True' elif obj[0]>1: return 'True' else: return 'True' else: return 'True' else: return 'False' else: return 'False' elif obj[3]<=0: # {"feature": "Restaurant20to50", "instances": 281, "metric_value": 0.4271, "depth": 5} if obj[7]<=2.0: # {"feature": "Occupation", "instances": 267, "metric_value": 0.4247, "depth": 6} if obj[4]<=10: # {"feature": "Coffeehouse", "instances": 221, "metric_value": 0.4503, "depth": 7} if obj[6]>-1.0: # {"feature": "Passanger", "instances": 216, "metric_value": 0.4502, "depth": 8} if obj[0]<=1: # {"feature": "Time", "instances": 150, "metric_value": 0.4624, "depth": 9} if obj[1]<=2: # {"feature": "Direction_same", "instances": 106, "metric_value": 0.4448, "depth": 10} if obj[8]<=0: return 'False' elif obj[8]>0: return 'False' else: return 'False' elif obj[1]>2: # {"feature": "Direction_same", "instances": 44, "metric_value": 0.4817, "depth": 10} if obj[8]<=0: return 'False' elif obj[8]>0: return 'True' else: return 'True' else: return 'False' elif obj[0]>1: # {"feature": "Time", "instances": 66, "metric_value": 0.3866, "depth": 9} if obj[1]<=3: # {"feature": "Direction_same", "instances": 48, "metric_value": 0.4521, "depth": 10} if obj[8]<=0: return 'False' elif obj[8]>0: return 'False' else: return 'False' elif obj[1]>3: # {"feature": "Direction_same", "instances": 18, "metric_value": 0.1975, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' else: return 'False' elif obj[6]<=-1.0: # {"feature": "Passanger", "instances": 5, "metric_value": 0.2, "depth": 8} if obj[0]<=0: return 'True' elif obj[0]>0: # {"feature": "Time", "instances": 2, "metric_value": 0.5, "depth": 9} if obj[1]<=4: # {"feature": "Direction_same", "instances": 2, "metric_value": 0.5, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' else: return 'False' else: return 'True' elif obj[4]>10: # {"feature": "Coffeehouse", "instances": 46, "metric_value": 0.2356, "depth": 7} if obj[6]>0.0: # {"feature": "Direction_same", "instances": 31, "metric_value": 0.33, "depth": 8} if obj[8]<=0: # {"feature": "Time", "instances": 26, "metric_value": 0.3414, "depth": 9} if obj[1]>1: # {"feature": "Passanger", "instances": 21, "metric_value": 0.2921, "depth": 10} if obj[0]>0: return 'False' elif obj[0]<=0: return 'False' else: return 'False' elif obj[1]<=1: # {"feature": "Passanger", "instances": 5, "metric_value": 0.3, "depth": 10} if obj[0]>0: return 'True' elif obj[0]<=0: return 'False' else: return 'False' else: return 'True' elif obj[8]>0: return 'False' else: return 'False' elif obj[6]<=0.0: return 'False' else: return 'False' else: return 'False' elif obj[7]>2.0: # {"feature": "Coffeehouse", "instances": 14, "metric_value": 0.1714, "depth": 6} if obj[6]<=2.0: return 'True' elif obj[6]>2.0: # {"feature": "Passanger", "instances": 5, "metric_value": 0.2667, "depth": 7} if obj[0]<=2: # {"feature": "Direction_same", "instances": 3, "metric_value": 0.0, "depth": 8} if obj[8]<=0: return 'False' elif obj[8]>0: return 'True' else: return 'True' elif obj[0]>2: return 'True' else: return 'True' else: return 'True' else: return 'True' else: return 'False' elif obj[9]>2: # {"feature": "Education", "instances": 178, "metric_value": 0.2796, "depth": 4} if obj[3]<=4: # {"feature": "Occupation", "instances": 176, "metric_value": 0.2721, "depth": 5} if obj[4]<=11.790657263862823: # {"feature": "Passanger", "instances": 150, "metric_value": 0.2309, "depth": 6} if obj[0]<=1: # {"feature": "Time", "instances": 149, "metric_value": 0.229, "depth": 7} if obj[1]<=1: # {"feature": "Coffeehouse", "instances": 136, "metric_value": 0.2477, "depth": 8} if obj[6]>0.0: # {"feature": "Restaurant20to50", "instances": 92, "metric_value": 0.2071, "depth": 9} if obj[7]<=1.0: # {"feature": "Direction_same", "instances": 60, "metric_value": 0.255, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' elif obj[7]>1.0: # {"feature": "Direction_same", "instances": 32, "metric_value": 0.1172, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' else: return 'False' elif obj[6]<=0.0: # {"feature": "Restaurant20to50", "instances": 44, "metric_value": 0.3193, "depth": 9} if obj[7]>-1.0: # {"feature": "Direction_same", "instances": 41, "metric_value": 0.3427, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' elif obj[7]<=-1.0: return 'False' else: return 'False' else: return 'False' elif obj[1]>1: return 'False' else: return 'False' elif obj[0]>1: return 'True' else: return 'True' elif obj[4]>11.790657263862823: # {"feature": "Restaurant20to50", "instances": 26, "metric_value": 0.3814, "depth": 6} if obj[7]<=2.0: # {"feature": "Coffeehouse", "instances": 24, "metric_value": 0.3889, "depth": 7} if obj[6]>-1.0: # {"feature": "Passanger", "instances": 21, "metric_value": 0.4, "depth": 8} if obj[0]<=1: # {"feature": "Time", "instances": 20, "metric_value": 0.4105, "depth": 9} if obj[1]>0: # {"feature": "Direction_same", "instances": 19, "metric_value": 0.4321, "depth": 10} if obj[8]<=0: return 'False' else: return 'False' elif obj[1]<=0: return 'False' else: return 'False' elif obj[0]>1: return 'True' else: return 'True' elif obj[6]<=-1.0: return 'False' else: return 'False' elif obj[7]>2.0: return 'True' else: return 'True' else: return 'False' elif obj[3]>4: return 'True' else: return 'True' else: return 'False' else: return 'False' else: return 'False'
40.102576
212
0.497915
10,677
85,619
3.935469
0.050108
0.125134
0.13651
0.128037
0.919536
0.843071
0.812466
0.714367
0.644923
0.593731
0
0.109166
0.311625
85,619
2,134
213
40.121368
0.60377
0.448405
0
0.971618
0
0
0.078378
0
0
0
0
0
0
1
0.000604
false
0
0
0
0.211957
0
0
0
0
null
0
0
0
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
8828cd78b795949cf0895a930649a58730a21683
355
py
Python
numpyro/contrib/nn/__init__.py
ibab/numpyro
076bb2a15026734a41abf4eb39ce384ab68c297f
[ "Apache-2.0" ]
1
2020-11-30T23:51:45.000Z
2020-11-30T23:51:45.000Z
numpyro/contrib/nn/__init__.py
ibab/numpyro
076bb2a15026734a41abf4eb39ce384ab68c297f
[ "Apache-2.0" ]
null
null
null
numpyro/contrib/nn/__init__.py
ibab/numpyro
076bb2a15026734a41abf4eb39ce384ab68c297f
[ "Apache-2.0" ]
1
2020-11-30T23:52:33.000Z
2020-11-30T23:52:33.000Z
# Copyright Contributors to the Pyro project. # SPDX-License-Identifier: Apache-2.0 from numpyro.contrib.nn.auto_reg_nn import AutoregressiveNN from numpyro.contrib.nn.block_neural_arn import BlockNeuralAutoregressiveNN from numpyro.contrib.nn.masked_dense import MaskedDense __all__ = ['MaskedDense', 'AutoregressiveNN', 'BlockNeuralAutoregressiveNN']
39.444444
76
0.839437
42
355
6.880952
0.666667
0.114187
0.186851
0.207612
0
0
0
0
0
0
0
0.006135
0.08169
355
8
77
44.375
0.880368
0.222535
0
0
0
0
0.197802
0.098901
0
0
0
0
0
1
0
false
0
0.75
0
0.75
0
0
0
0
null
0
1
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
5
884cd1ea2ea22768e90b6f38d5cf498a68124fbe
46
py
Python
game/apps/chat/signals.py
alviproject/birdstorm
439ff97ee40c3dd93b8fa8bfca557bdee9c036e1
[ "MIT" ]
null
null
null
game/apps/chat/signals.py
alviproject/birdstorm
439ff97ee40c3dd93b8fa8bfca557bdee9c036e1
[ "MIT" ]
null
null
null
game/apps/chat/signals.py
alviproject/birdstorm
439ff97ee40c3dd93b8fa8bfca557bdee9c036e1
[ "MIT" ]
null
null
null
message = 'game.apps.chat.signals.message.%s'
23
45
0.73913
7
46
4.857143
0.857143
0
0
0
0
0
0
0
0
0
0
0
0.065217
46
1
46
46
0.790698
0
0
0
0
0
0.717391
0.717391
0
0
0
0
0
1
0
false
0
0
0
0
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
1
1
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
886e1c21412140e87a5f5e24df44de15cdbf75a3
31
py
Python
model/unets1/__init__.py
LK-Peng/CNN-based-Cloud-Detection-Methods
1393a6886e62f1ed5a612d57c5a725c763a6b2cc
[ "MIT" ]
2
2022-02-16T03:30:19.000Z
2022-03-18T08:02:39.000Z
model/unets1/__init__.py
LK-Peng/CNN-based-Cloud-Detection-Methods
1393a6886e62f1ed5a612d57c5a725c763a6b2cc
[ "MIT" ]
null
null
null
model/unets1/__init__.py
LK-Peng/CNN-based-Cloud-Detection-Methods
1393a6886e62f1ed5a612d57c5a725c763a6b2cc
[ "MIT" ]
1
2022-02-16T03:30:20.000Z
2022-02-16T03:30:20.000Z
from .unet_model import UNetS1
15.5
30
0.83871
5
31
5
1
0
0
0
0
0
0
0
0
0
0
0.037037
0.129032
31
1
31
31
0.888889
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
8891602abdb735c5836421edcd4936ac2b8346de
132
py
Python
src/constants.py
ychnlgy/LipoWithGradients
4fe5228a3dae8bf5d457eef6191ba29314421f6b
[ "MIT" ]
null
null
null
src/constants.py
ychnlgy/LipoWithGradients
4fe5228a3dae8bf5d457eef6191ba29314421f6b
[ "MIT" ]
null
null
null
src/constants.py
ychnlgy/LipoWithGradients
4fe5228a3dae8bf5d457eef6191ba29314421f6b
[ "MIT" ]
null
null
null
import os DIR = os.path.dirname(__file__) DATA_ROOT = os.path.join(DIR, "..", "data") RESULTS = os.path.join(DIR, "..", "results")
22
44
0.643939
20
132
4
0.5
0.225
0.25
0.325
0
0
0
0
0
0
0
0
0.121212
132
5
45
26.4
0.689655
0
0
0
0
0
0.113636
0
0
0
0
0
0
1
0
false
0
0.25
0
0.25
0
1
0
0
null
1
1
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
ee2a200cd969a41556f38badd1fc3827762b0edc
62
py
Python
env/lib/python3.10/site-packages/livesync/asyncserver/__init__.py
hmabubakar313/admin_panel_theme
5016adbc88088bbadfdb6ac107b68da891cdb4a4
[ "Apache-2.0" ]
null
null
null
env/lib/python3.10/site-packages/livesync/asyncserver/__init__.py
hmabubakar313/admin_panel_theme
5016adbc88088bbadfdb6ac107b68da891cdb4a4
[ "Apache-2.0" ]
null
null
null
env/lib/python3.10/site-packages/livesync/asyncserver/__init__.py
hmabubakar313/admin_panel_theme
5016adbc88088bbadfdb6ac107b68da891cdb4a4
[ "Apache-2.0" ]
null
null
null
from .server import LiveSyncSocketServer from .hub import Hub
20.666667
40
0.83871
8
62
6.5
0.625
0
0
0
0
0
0
0
0
0
0
0
0.129032
62
2
41
31
0.962963
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
ee30145da0dbc5b42b54cee3e372c6e784aa5827
30
py
Python
ATMEGA328P Mixer/Version 1.0 - ESP12 - SWSerial/Code/ESP8266 Sketches/MciroPython/boot.py
ZackWalsh57/WinHardMix---V2.0
2c19ba26f7f23b0e363b35537416b71f20ba6800
[ "MIT" ]
2
2018-10-11T04:43:04.000Z
2018-10-11T12:40:50.000Z
ATMEGA328P Mixer/Version 1.0 - ESP12 - SWSerial/Code/ESP8266 Sketches/MciroPython/boot.py
ZackWalsh57/WinHardMix---V2.0
2c19ba26f7f23b0e363b35537416b71f20ba6800
[ "MIT" ]
null
null
null
ATMEGA328P Mixer/Version 1.0 - ESP12 - SWSerial/Code/ESP8266 Sketches/MciroPython/boot.py
ZackWalsh57/WinHardMix---V2.0
2c19ba26f7f23b0e363b35537416b71f20ba6800
[ "MIT" ]
1
2020-02-02T15:09:57.000Z
2020-02-02T15:09:57.000Z
import esp esp.osdebug(None)
15
17
0.766667
5
30
4.6
0.8
0
0
0
0
0
0
0
0
0
0
0
0.133333
30
2
17
15
0.884615
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.5
0
0.5
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
ee48b252c4b0a09f1010e9a97e81f10b16262380
20,609
py
Python
Protheus_WebApp/Modules/SIGAFIN/FINA040TESTCASE.py
98llm/tir-script-samples
0bff8393b79356aa562e9e6512c11ee6e039b177
[ "MIT" ]
17
2018-09-24T17:27:08.000Z
2021-09-16T19:09:46.000Z
Protheus_WebApp/Modules/SIGAFIN/FINA040TESTCASE.py
98llm/tir-script-samples
0bff8393b79356aa562e9e6512c11ee6e039b177
[ "MIT" ]
4
2018-09-24T17:30:32.000Z
2022-01-03T11:39:30.000Z
Protheus_WebApp/Modules/SIGAFIN/FINA040TESTCASE.py
98llm/tir-script-samples
0bff8393b79356aa562e9e6512c11ee6e039b177
[ "MIT" ]
18
2019-06-07T17:41:34.000Z
2022-01-31T18:17:31.000Z
from tir import Webapp import unittest from datetime import datetime DateSystem = datetime.today().strftime('%d/%m/%Y') """------------------------------------------------------------------- /*/{Protheus.doc} FINA040TestCase TIR - Casos de testes da rotina contas a receber @author Marcelo Ferreira @since 09/11/2018 @version 12 -------------------------------------------------------------------""" indice1 = "Filial+prefixo + No. Titulo + Parce..." class FINA040(unittest.TestCase): #------------------------------------------- # Inicialiação setUpClass para TIR - FINA040 #------------------------------------------- @classmethod def setUpClass(inst): inst.oHelper = Webapp() inst.oHelper.Setup("SIGAFIN",DateSystem,"T1","D MG 01 ","06") inst.oHelper.Program('FINA040') #------------------------------------------- # Inicio dos casos de testes TIR - FINA040 #------------------------------------------- """------------------------------------------------------------------- /*/{Protheus.doc} TEST_FINA040_CT001 TIR - Casos de testes da rotina contas a receber Inclusão de títulos com ISS e verificação da aba impostos @author Marcelo Ferreira @since 09/11/2018 @version 12 -------------------------------------------------------------------""" def test_FINA040_CT001(self): self.oHelper.WaitShow("Contas a Receber") self.oHelper.SetKey("F12") self.oHelper.SetValue("Mostra Lanc Contab ?" ,"Nao") self.oHelper.SetValue("Contabiliza on line ?" ,"Nao") self.oHelper.SetValue("Contab.Tit.Provisor ?" ,"Nao") self.oHelper.SetValue("Rateia Valor ?" ,"Bruto") self.oHelper.SetValue("Valores Acessórios Inclusão ?" ,"Não") self.oHelper.SetButton("Ok") self.oHelper.SetButton('Incluir') self.oHelper.SetBranch('D MG 01') self.oHelper.SetValue('E1_PREFIXO', "FIN") self.oHelper.SetValue('E1_NUM','FINA40133') self.oHelper.SetValue('E1_TIPO','NF') self.oHelper.SetValue('E1_NATUREZ','FINA040133') self.oHelper.SetValue('E1_CLIENTE','FIN184') self.oHelper.SetValue('E1_LOJA','01') self.oHelper.SetValue('E1_EMISSAO','10/10/2018') self.oHelper.SetValue('E1_VENCTO','10/10/2018') self.oHelper.SetValue('E1_VENCREA','10/10/2018') self.oHelper.SetValue('E1_VALOR','10.000,00') self.oHelper.ClickFolder('Impostos') self.oHelper.SetButton('Salvar') self.oHelper.SetButton('Cancelar') self.oHelper.AssertTrue() """------------------------------------------------------------------- /*/{Protheus.doc} TEST_FINA040_CT002 TIR - Casos de testes da rotina contas a receber Simulação da inclusão de título sem impostos @author Rodrigo Oliveira @since 03/06/2019 @version 12 -------------------------------------------------------------------""" def test_FINA040_CT002(self): titulo = 'NFTIR001' self.oHelper.WaitShow("Contas a Receber") self.oHelper.SetButton('Incluir') self.oHelper.SetBranch('D MG 01') self.oHelper.ClickFolder('Dados Gerais') self.oHelper.SetValue('E1_NUM', titulo) self.oHelper.SetValue('E1_TIPO','NF') self.oHelper.F3(field='E1_NATUREZ', name_attr=True) self.oHelper.SearchBrowse(f'DINHEIRO', 'Código') self.oHelper.SetButton('Ok') self.oHelper.SetValue('E1_CLIENTE','000001') self.oHelper.SetValue('E1_LOJA','01') self.oHelper.SetValue('E1_EMISSAO','25/04/2019') self.oHelper.SetValue('E1_VENCTO','25/04/2019') self.oHelper.SetValue('E1_VENCREA','25/04/2019') self.oHelper.SetValue('E1_VALOR','10.000,00') self.oHelper.SetButton('Cancelar') self.oHelper.AssertTrue() """------------------------------------------------------------------- /*/{Protheus.doc} TEST_FINA040_CT003 TIR - Casos de testes da rotina contas a receber Inclusão de Títulos com Múltiplas Naturezas @author santos.renato @since 21/08/2019 @version 12 @See https://jiraproducao.totvs.com.br/secure/Tests.jspa#/project/10231/testCase?folderId=2585 -------------------------------------------------------------------""" def test_FINA040_CT003(self): self.oHelper.AddParameter("MV_MULNATR","",".T.",".T.",".T.") self.oHelper.SetParameters() prefixo = 'AUT' titulo = 'FIN000001' parcela = '' tipo = 'NF' self.oHelper.WaitShow("Contas a Receber") self.oHelper.SetButton('Incluir') self.oHelper.SetBranch('D MG 01') self.oHelper.ClickFolder('Dados Gerais') self.oHelper.SetValue('E1_PREFIXO', prefixo) self.oHelper.SetValue('E1_NUM', titulo) self.oHelper.SetValue('E1_PARCELA', parcela) self.oHelper.SetValue('E1_TIPO', tipo) self.oHelper.F3(field='E1_NATUREZ', name_attr=True) self.oHelper.SearchBrowse(f'AUT0000001', 'Código') self.oHelper.SetButton('Ok') self.oHelper.SetValue('E1_CLIENTE','FIN001') self.oHelper.SetValue('E1_LOJA','01') self.oHelper.SetValue('E1_EMISSAO',DateSystem) self.oHelper.SetValue('E1_VENCTO',DateSystem) self.oHelper.SetValue('E1_VALOR','10000,00') self.oHelper.ClickFolder('Administrativo') self.oHelper.SetValue('E1_MULTNAT', '1') self.oHelper.SetButton('Salvar') self.oHelper.SetValue('EV_NATUREZ', 'AUT0000003', grid=True) self.oHelper.SetValue('EV_VALOR', '5000,00', grid=True) self.oHelper.LoadGrid() self.oHelper.SetKey("DOWN", grid=True) self.oHelper.SetValue('EV_NATUREZ', 'AUT0000002', grid=True) self.oHelper.SetValue('EV_VALOR', '5000,00', grid=True) self.oHelper.SetValue('EV_RATEICC', '1', grid=True) self.oHelper.LoadGrid() self.oHelper.SetValue('EZ_CCUSTO', '002', grid=True) self.oHelper.SetValue('EZ_VALOR', '2500,00', grid=True) self.oHelper.SetKey("DOWN", grid=True) self.oHelper.SetValue('EZ_CCUSTO', '003', grid=True) self.oHelper.SetValue('EZ_VALOR', '2500,00', grid=True) self.oHelper.LoadGrid() self.oHelper.SetButton('Salvar') self.oHelper.SetButton('Confirmar') self.oHelper.SetButton('Cancelar') self.oHelper.WaitShow("Contas a Receber") self.oHelper.SearchBrowse("D MG 01 AUTFIN000001 NF ", indice1) self.oHelper.SetButton("Outras Ações", "Excluir") self.oHelper.CheckResult('E1_PREFIXO', prefixo) self.oHelper.CheckResult('E1_NUM', titulo) self.oHelper.CheckResult('E1_PARCELA', parcela) self.oHelper.CheckResult('E1_TIPO', tipo) self.oHelper.CheckResult("E1_NATUREZ", "AUT0000001") self.oHelper.CheckResult("E1_VALOR", "10.000,00") self.oHelper.SetButton('Confirmar') self.oHelper.AssertTrue() self.oHelper.RestoreParameters() """------------------------------------------------------------------- /*/{Protheus.doc} TEST_FINA040_CT074 TIR - Casos de testes da rotina contas a receber Substituir títulos a receber provisorios(sem impostos) @author santos.renato @since 21/08/2019 @version 12 @See https://jiraproducao.totvs.com.br/secure/Tests.jspa#/testCase/GTSER-T12054 -------------------------------------------------------------------""" def test_FINA040_CT074(self): prefixo = 'FIN' titulo = 'FINA04017' parcela = '' tipo = 'NF' cliente = '000022' loja = '01' self.oHelper.WaitShow("Contas a Receber") self.oHelper.SetButton("Outras Ações", "Substituir") self.oHelper.SetValue('cCodigo ', cliente, name_attr=True) self.oHelper.SetValue('cLoja', loja, name_attr=True) self.oHelper.SetButton('Ok') self.oHelper.ClickBox("No. Titulo", "FINA04014") self.oHelper.ClickBox("No. Titulo", "FINA04015") self.oHelper.SetButton('Confirmar') self.oHelper.ClickFolder('Dados Gerais') self.oHelper.SetValue('E1_PREFIXO', prefixo) self.oHelper.SetValue('E1_NUM', titulo) self.oHelper.SetValue('E1_PARCELA', parcela) self.oHelper.SetValue('E1_TIPO', tipo) self.oHelper.F3(field='E1_NATUREZ', name_attr=True) self.oHelper.SearchBrowse(f'001', 'Código') self.oHelper.SetButton('Ok') self.oHelper.SetValue('E1_EMISSAO',DateSystem) self.oHelper.SetValue('E1_VENCTO',DateSystem) self.oHelper.SetValue('E1_VENCREA',DateSystem) self.oHelper.SetButton('Confirmar') self.oHelper.AssertTrue() """------------------------------------------------------------------- /*/{Protheus.doc} TEST_FINA040_CT103 TIR - Casos de testes da rotina contas a receber Inclusão de título a receber já inserindo valor acessório vinculado @author Renato.ito @since 12/08/2019 @version 12 @See https://jiraproducao.totvs.com.br/secure/Tests.jspa#/testCase/GTSER-T19269 -------------------------------------------------------------------""" def test_FINA040_CT103(self): prefixo = 'VA' titulo = 'FIN000307' parcela = '' tipo = 'NF' self.oHelper.WaitShow("Contas a Receber") self.oHelper.SetKey("F12") self.oHelper.SetValue("Valores Acessórios Inclusão ?", "Sim") self.oHelper.SetButton('Ok') self.oHelper.SetButton('Incluir') self.oHelper.SetBranch('D MG 01') self.oHelper.ClickFolder('Dados Gerais') self.oHelper.SetValue('E1_PREFIXO', prefixo) self.oHelper.SetValue('E1_NUM', titulo) self.oHelper.SetValue('E1_PARCELA', parcela) self.oHelper.SetValue('E1_TIPO', tipo) self.oHelper.F3(field='E1_NATUREZ', name_attr=True) self.oHelper.SearchBrowse(f'000001', 'Código') self.oHelper.SetButton('Ok') self.oHelper.SetValue('E1_CLIENTE','FIN168') self.oHelper.SetValue('E1_LOJA','01') self.oHelper.SetValue('E1_EMISSAO','25/04/2019') self.oHelper.SetValue('E1_VENCTO','25/04/2019') self.oHelper.SetValue('E1_VENCREA','25/04/2019') self.oHelper.SetValue('E1_VALOR','1.000,00') self.oHelper.SetButton('Salvar') self.oHelper.WaitShow("Deseja cadastrar os valores acessórios deste título agora?") self.oHelper.SetButton('Sim') self.oHelper.SetValue('FKD_CODIGO','VA0001', grid=True) self.oHelper.SetValue('FKD_VALOR','15,00', grid=True) self.oHelper.LoadGrid() self.oHelper.SetButton('Confirmar') self.oHelper.CheckHelp('Registro alterado com sucesso.','Fechar') self.oHelper.SetButton('Cancelar') self.oHelper.WaitShow("Contas a Receber") self.oHelper.SetKey("F12") self.oHelper.SetValue("Valores Acessórios Inclusão ?", "Não") self.oHelper.SetButton('Ok') self.oHelper.AssertTrue() """------------------------------------------------------------------- /*/{Protheus.doc} TEST_FINA040_CT110 TIR - Casos de testes da rotina contas a receber Inclusão de RA com impostos na baixa @author santos.renato @since 21/08/2019 @version 12 @See https://jiraproducao.totvs.com.br/secure/Tests.jspa#/testCase/GTSER-T19405 -------------------------------------------------------------------""" def test_FINA040_CT110(self): self.oHelper.AddParameter("MV_RARTIMP","","1","1","1") self.oHelper.AddParameter("MV_BQ10925","","2","2","2") self.oHelper.AddParameter("MV_BR10925","","1","1","1") self.oHelper.SetParameters() prefixo = '' titulo = 'FIN000313' parcela = '' tipo = 'RA' banco = '241' agencia = '07891' conta = '0001000222' hist = 'Teste|com|pipe' self.oHelper.WaitShow("Contas a Receber") self.oHelper.SetButton('Incluir') self.oHelper.SetBranch('D MG 01') self.oHelper.ClickFolder('Dados Gerais') self.oHelper.SetValue('E1_PREFIXO', prefixo) self.oHelper.SetValue('E1_NUM', titulo) self.oHelper.SetValue('E1_PARCELA', parcela) self.oHelper.SetValue('E1_TIPO', tipo) self.oHelper.SetValue('cBancoAdt', banco, name_attr=True) self.oHelper.SetValue('cAgenciaAdt', agencia, name_attr=True) self.oHelper.SetValue('cNumCon', conta, name_attr=True) self.oHelper.SetButton("Ok") self.oHelper.SetValue('E1_NATUREZ', 'FIN4000000') self.oHelper.SetValue('E1_CLIENTE','FIN183') self.oHelper.SetValue('E1_LOJA','01') self.oHelper.SetValue('E1_EMISSAO',DateSystem) self.oHelper.SetValue('E1_VENCTO',DateSystem) self.oHelper.SetValue('E1_VENCREA',DateSystem) self.oHelper.SetValue('E1_VALOR','10000,00') self.oHelper.SetValue('E1_HIST', hist) self.oHelper.ClickFolder('Impostos') self.oHelper.CheckResult('E1_BASEIRF', '10.000,00') self.oHelper.CheckResult('E1_IRRF ' , '150,00') self.oHelper.CheckResult('E1_CSLL' , '100,00') self.oHelper.CheckResult('E1_COFINS' , '300,00') self.oHelper.CheckResult('E1_PIS' , '65,00') self.oHelper.SetButton('Salvar') self.oHelper.SetButton('Cancelar') self.oHelper.AssertTrue() self.oHelper.RestoreParameters() """------------------------------------------------------------------- /*/{Protheus.doc} TEST_FINA040_CT154 TIR - Casos de testes da rotina contas a receber Inclusão de título a receber com desdobramento e imposto (PCC + IR) @author Renato.ito @since 12/08/2019 @version 12 @See https://jiraproducao.totvs.com.br/secure/Tests.jspa#/testCase/GTSER-T37961 -------------------------------------------------------------------""" def test_FINA040_CT154(self): prefixo = 'FIN' titulo = 'FINDSDB01' parcela = '' tipo = 'NF' self.oHelper.WaitShow("Contas a Receber") self.oHelper.SetButton('Incluir') self.oHelper.SetBranch('D MG 01') self.oHelper.ClickFolder('Dados Gerais') self.oHelper.SetValue('E1_PREFIXO', prefixo) self.oHelper.SetValue('E1_NUM', titulo) self.oHelper.SetValue('E1_PARCELA', parcela) self.oHelper.SetValue('E1_TIPO', tipo) self.oHelper.F3(field='E1_NATUREZ', name_attr=True) self.oHelper.SearchBrowse(f'FIN0000088', 'Código') self.oHelper.SetButton('Ok') self.oHelper.SetValue('E1_CLIENTE','FIN259') self.oHelper.SetValue('E1_LOJA','01') self.oHelper.SetValue('E1_EMISSAO',DateSystem) self.oHelper.SetValue('E1_VENCTO',DateSystem) self.oHelper.SetValue('E1_VENCREA',DateSystem) self.oHelper.SetValue('E1_VALOR','11.000,00') self.oHelper.ClickFolder('Administrativo') self.oHelper.SetValue('E1_DESDOBR','1') self.oHelper.SetValue('Número de Parcelas','5') self.oHelper.SetValue('Periodo de Vencto. (em dias)','30') self.oHelper.SetButton('Ok') self.oHelper.ClickFolder('Dados Gerais') self.oHelper.SetValue('E1_VALOR','10.000,00') self.oHelper.SetButton('Salvar') self.oHelper.SetButton('Cancelar') self.oHelper.AssertTrue() # Exlusão self.oHelper.SetButton("Outras Ações", "Excluir") self.oHelper.WaitShow("DESDOBRAD") self.oHelper.CheckHelp('DESDOBRAD','Fechar') self.oHelper.SetButton("Outras Ações", "Canc.Desdobr.") self.oHelper.SetButton('Confirmar') self.oHelper.SetButton('Sim') self.oHelper.AssertTrue() """------------------------------------------------------------------- /*/{Protheus.doc} TEST_FINA040_CT161 TIR - Casos de testes da rotina contas a receber Validar a inclusão de abatimento (AB-) para um título que possui outro com o mesmo prefixo numero e parcela @author Renato.ito @since 12/08/2019 @version 12 @See https://jiraproducao.totvs.com.br/secure/Tests.jspa#/testCase/GTSER-T42027 -------------------------------------------------------------------""" def test_FINA040_CT161(self): prefixo = 'TIR' titulo = '1' parcela = '1' tipo = 'NF' self.oHelper.WaitShow("Contas a Receber") self.oHelper.SetKey("F12") self.oHelper.SetValue("Mostra Lanc Contab ?" ,"Nao") self.oHelper.SetValue("Contabiliza on line ?" ,"Nao") self.oHelper.SetValue("Contab.Tit.Provisor ?" ,"Nao") self.oHelper.SetValue("Rateia Valor ?" ,"Bruto") self.oHelper.SetValue("Valores Acessórios Inclusão ?" ,"Não") self.oHelper.SetButton("Ok") self.oHelper.WaitShow("Contas a Receber") self.oHelper.SetButton('Incluir') self.oHelper.SetBranch('D MG 01') self.oHelper.ClickFolder('Dados Gerais') self.oHelper.SetValue('E1_PREFIXO', prefixo) self.oHelper.SetValue('E1_NUM', titulo) self.oHelper.SetValue('E1_PARCELA', parcela) self.oHelper.SetValue('E1_TIPO', tipo) self.oHelper.F3(field='E1_NATUREZ', name_attr=True) self.oHelper.SearchBrowse(f'001', 'Código') self.oHelper.SetButton('Ok') self.oHelper.SetValue('E1_CLIENTE','FIN259') self.oHelper.SetValue('E1_LOJA','01') self.oHelper.SetValue('E1_EMISSAO',DateSystem) self.oHelper.SetValue('E1_VENCTO',DateSystem) self.oHelper.SetValue('E1_VENCREA',DateSystem) self.oHelper.SetValue('E1_VALOR','1,00') self.oHelper.SetButton('Salvar') tipo = 'DP' self.oHelper.SetValue('E1_PREFIXO', prefixo) self.oHelper.SetValue('E1_NUM', titulo) self.oHelper.SetValue('E1_PARCELA', parcela) self.oHelper.SetValue('E1_TIPO', tipo) self.oHelper.F3(field='E1_NATUREZ', name_attr=True) self.oHelper.SearchBrowse(f'001', 'Código') self.oHelper.SetButton('Ok') self.oHelper.SetValue('E1_CLIENTE','FIN259') self.oHelper.SetValue('E1_LOJA','01') self.oHelper.SetValue('E1_EMISSAO',DateSystem) self.oHelper.SetValue('E1_VENCTO',DateSystem) self.oHelper.SetValue('E1_VENCREA',DateSystem) self.oHelper.SetValue('E1_VALOR','10.000,00') self.oHelper.SetButton('Salvar') tipo = 'AB-' self.oHelper.SetValue('E1_PREFIXO', prefixo) self.oHelper.SetValue('E1_NUM', titulo) self.oHelper.SetValue('E1_PARCELA', parcela) self.oHelper.SetValue('E1_TIPO', tipo) self.oHelper.SetValue('E1_VALOR','550,00') self.oHelper.SetButton('Salvar') self.oHelper.ClickGridCell("Tipo",row=1) self.oHelper.SetButton('Ok') self.oHelper.SetButton('Cancelar') self.oHelper.AssertTrue() """------------------------------------------------------------------- /*/{Protheus.doc} test_FINA040_CT205 TIR - Casos de testes da rotina contas a receber Alteração do valor do tí­tulo em CNAB e acessando a rotina no menu ações relacionadas Instruções. @author Rafael Riego @since 25/08/2020 @version 12.1.027 @See https://jiraproducao.totvs.com.br/secure/Tests.jspa#/testCase/GTSER-T53777 /*/ -------------------------------------------------------------------""" def test_FINA040_CT205(self): chaveTitulo = "D MG 01 " + "FIN" + "TIR000205" + "1" + "NF " self.oHelper.WaitShow("Contas a Receber") self.oHelper.SearchBrowse(chaveTitulo, indice1) self.oHelper.SetButton("Alterar") self.oHelper.ClickFolder("Dados Gerais") self.oHelper.SetValue("E1_VALOR", "3.500,00") self.oHelper.SetButton("Outras Ações", "Instruções") self.oHelper.SetValue('Ocorrencia', "14", grid=True, grid_number=1, ignore_case = True, row=1) self.oHelper.LoadGrid() self.oHelper.SetButton('Salvar') self.oHelper.WaitShow("Confirma ocorrências?") self.oHelper.SetButton("Sim") self.oHelper.SetButton('Salvar') self.oHelper.AssertTrue() """------------------------------------------------------------------- /*/{Protheus.doc} test_FINA040_CT207 TIR - Casos de testes da rotina contas a receber Exclusão de tí­tulo com pendências de contabilização. @author Rafael Riego @since 31/08/2020 @version 12.1.027 @See https://jiraproducao.totvs.com.br/secure/Tests.jspa#/testCase/GTSER-T54080 /*/ -------------------------------------------------------------------""" def test_FINA040_CT207(self): prefixo = "FIN" titulo = "TIRCT0207" parcela = "1" tipo = "NF " self.oHelper.WaitShow("Contas a Receber") self.oHelper.SearchBrowse("D MG 01 " + prefixo + titulo + parcela + tipo, indice1) self.oHelper.SetButton("Outras Ações", "Excluir") self.oHelper.CheckResult('E1_PREFIXO', prefixo) self.oHelper.CheckResult('E1_NUM', titulo) self.oHelper.CheckResult('E1_PARCELA', parcela) self.oHelper.CheckResult('E1_TIPO', tipo) self.oHelper.SetButton('Confirmar') self.oHelper.WaitShow("Foram encontrados movimentos pendentes de contabilização.") self.oHelper.SetButton("Cancela") self.oHelper.AssertTrue() """------------------------------------------------------------------- /*/{Protheus.doc} test_FINA040_CT215 TIR - Não deletar cheque - Mensagem @author rafael rondon @since 28//12/2020 @version 12.1.027 @See https://jiraproducao.totvs.com.br/secure/Tests.jspa#/project/10231/testCase?folderId=2585 /*/ -------------------------------------------------------------------""" def test_FINA040_CT215(self): prefixo = "FIN" titulo = "FIN070CHQ" parcela = " " tipo = "NF " self.oHelper.SearchBrowse("D MG 01 " + prefixo + titulo + parcela + tipo, indice1) self.oHelper.SetButton("Alterar") self.oHelper.SetButton("Outras Ações", "Cheques") self.oHelper.SetValue("Valor ref. baixa", "2000,00", grid=True, row=1) self.oHelper.LoadGrid() self.oHelper.SetKey("DELETE", grid=True, grid_number=1) self.oHelper.LoadGrid() self.oHelper.CheckHelp(text='TOTVS',button='Fechar') self.oHelper.SetButton("Cancelar") self.oHelper.SetButton("Cancelar") self.oHelper.AssertTrue() #------------------------------------------- # Fim dos casos de testes TIR - FINA040 #------------------------------------------- #------------------------------------------- # Encerramento class para TIR - FINA040 #------------------------------------------- @classmethod def tearDownClass(inst): inst.oHelper.TearDown() if __name__ == '__main__': unittest.main()
35.532759
108
0.653016
2,469
20,609
5.371
0.143378
0.248021
0.181962
0.150441
0.801297
0.749189
0.710203
0.663449
0.645879
0.585778
0
0.051692
0.108254
20,609
580
109
35.532759
0.669768
0.025038
0
0.665761
0
0
0.231948
0
0.002717
0
0
0
0.032609
1
0.035326
false
0
0.008152
0
0.046196
0
0
0
0
null
1
1
0
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
ee880ba61d4d7d2862f29d515bb7cfbf5ffaae98
166
py
Python
python_lists/lists_methods/insert_and_pop.py
antonarnaudov/python-tigers-2021-02
8af6c121e4d373b7d98bf76dc1777753587262ef
[ "MIT" ]
null
null
null
python_lists/lists_methods/insert_and_pop.py
antonarnaudov/python-tigers-2021-02
8af6c121e4d373b7d98bf76dc1777753587262ef
[ "MIT" ]
null
null
null
python_lists/lists_methods/insert_and_pop.py
antonarnaudov/python-tigers-2021-02
8af6c121e4d373b7d98bf76dc1777753587262ef
[ "MIT" ]
null
null
null
ll = [12, 'exo', '12321', 'exo', 213, 34, 33] # ll.reverse() # print(ll) # # print(ll.count('exo')) print(ll) print(ll.pop()) print(ll) print(ll.pop(2)) print(ll)
11.857143
45
0.572289
29
166
3.275862
0.413793
0.515789
0.378947
0.442105
0.357895
0
0
0
0
0
0
0.105634
0.144578
166
13
46
12.769231
0.56338
0.271084
0
0.5
0
0
0.095652
0
0
0
0
0
0
1
0
false
0
0
0
0
0.833333
1
0
0
null
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
1
0
5
c98f2fbb6184664eb917a7640832e0a6cbb04c87
46
py
Python
main.py
jamesabel/osnaptest
5f46a02bcd12b528e967be9546d406f849200c0c
[ "MIT" ]
null
null
null
main.py
jamesabel/osnaptest
5f46a02bcd12b528e967be9546d406f849200c0c
[ "MIT" ]
null
null
null
main.py
jamesabel/osnaptest
5f46a02bcd12b528e967be9546d406f849200c0c
[ "MIT" ]
null
null
null
from osnaptest import osnaptest osnaptest()
9.2
31
0.804348
5
46
7.4
0.6
0
0
0
0
0
0
0
0
0
0
0
0.152174
46
4
32
11.5
0.948718
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.5
0
0.5
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
c9959f9896be5ebab1ce6dcde4da1af125de5e76
201
py
Python
infra/__init__.py
vusec/instrumentation-infra
91837de91366cd5d6d4aae86920b0ba0fc5971ad
[ "Apache-2.0" ]
12
2019-01-14T10:58:22.000Z
2022-03-16T11:56:34.000Z
infra/__init__.py
vusec/instrumentation-infra
91837de91366cd5d6d4aae86920b0ba0fc5971ad
[ "Apache-2.0" ]
2
2020-03-25T10:11:57.000Z
2020-03-26T10:11:02.000Z
infra/__init__.py
vusec/instrumentation-infra
91837de91366cd5d6d4aae86920b0ba0fc5971ad
[ "Apache-2.0" ]
2
2020-03-25T07:42:18.000Z
2022-03-22T14:37:01.000Z
from .setup import Setup from .command import Command from .package import Package, NoEnvLoad from .target import Target from .instance import Instance from . import packages, targets, instances, util
28.714286
48
0.810945
27
201
6.037037
0.444444
0
0
0
0
0
0
0
0
0
0
0
0.139303
201
6
49
33.5
0.942197
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
c9b6d009b6bd4cb0cc8b5994dbf8cdec132bb54f
44
py
Python
tests/__init__.py
dangilman/lenslikelihood
1490ee9756b4d2ed108a2478977609bbe0ba2e17
[ "MIT" ]
null
null
null
tests/__init__.py
dangilman/lenslikelihood
1490ee9756b4d2ed108a2478977609bbe0ba2e17
[ "MIT" ]
null
null
null
tests/__init__.py
dangilman/lenslikelihood
1490ee9756b4d2ed108a2478977609bbe0ba2e17
[ "MIT" ]
null
null
null
"""Unit test package for lenslikelihood."""
22
43
0.727273
5
44
6.4
1
0
0
0
0
0
0
0
0
0
0
0
0.113636
44
1
44
44
0.820513
0.840909
0
null
0
null
0
0
null
0
0
0
null
1
null
true
0
0
null
null
null
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
5
c9c4780dabc33c0ea91824f13fb95d401efa3abe
95
py
Python
examples/load_generate_tree_key/ord_function.py
Arcensoth/beet
8a20a6fbee8724d8c26fe7e9ade68dffa57406bd
[ "MIT" ]
46
2021-03-09T23:34:52.000Z
2022-03-08T01:30:04.000Z
examples/load_generate_tree_key/ord_function.py
Arcensoth/beet
8a20a6fbee8724d8c26fe7e9ade68dffa57406bd
[ "MIT" ]
127
2021-02-24T00:41:44.000Z
2022-03-31T05:14:31.000Z
examples/load_generate_tree_key/ord_function.py
Arcensoth/beet
8a20a6fbee8724d8c26fe7e9ade68dffa57406bd
[ "MIT" ]
9
2021-03-11T18:18:28.000Z
2022-03-11T20:32:01.000Z
from beet import Context def beet_default(ctx: Context): ctx.template.expose("ord", ord)
15.833333
35
0.726316
14
95
4.857143
0.714286
0
0
0
0
0
0
0
0
0
0
0
0.157895
95
5
36
19
0.85
0
0
0
0
0
0.031579
0
0
0
0
0
0
1
0.333333
false
0
0.333333
0
0.666667
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
1
0
1
0
0
5
c9cde84d960f438e485d884b3ca638b4bbfe8752
73
py
Python
aioecobee/__init__.py
marthoc/aioecobee
22e81c3966a8a5f84468ea237b9d0e4496285b50
[ "MIT" ]
null
null
null
aioecobee/__init__.py
marthoc/aioecobee
22e81c3966a8a5f84468ea237b9d0e4496285b50
[ "MIT" ]
null
null
null
aioecobee/__init__.py
marthoc/aioecobee
22e81c3966a8a5f84468ea237b9d0e4496285b50
[ "MIT" ]
null
null
null
from .const import * from .ecobee import EcobeeAPI from .errors import *
18.25
29
0.767123
10
73
5.6
0.6
0
0
0
0
0
0
0
0
0
0
0
0.164384
73
3
30
24.333333
0.918033
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
a0073d19e95d726671980ef8317862ff19f22c65
431
py
Python
generated-libraries/python/netapp/cifs/cifs_lug_import_op_status.py
radekg/netapp-ontap-lib-get
6445ebb071ec147ea82a486fbe9f094c56c5c40d
[ "MIT" ]
2
2017-03-28T15:31:26.000Z
2018-08-16T22:15:18.000Z
generated-libraries/python/netapp/cifs/cifs_lug_import_op_status.py
radekg/netapp-ontap-lib-get
6445ebb071ec147ea82a486fbe9f094c56c5c40d
[ "MIT" ]
null
null
null
generated-libraries/python/netapp/cifs/cifs_lug_import_op_status.py
radekg/netapp-ontap-lib-get
6445ebb071ec147ea82a486fbe9f094c56c5c40d
[ "MIT" ]
null
null
null
class CifsLugImportOpStatus(basestring): """ Status of the import operation of CIFS local users and groups Possible values: <ul> <li> "unknown" , <li> "success" , <li> "success_with_warnings" , <li> "failed" , <li> "in_progress" </ul> """ @staticmethod def get_api_name(): return "cifs-lug-import-op-status"
23.944444
65
0.512761
42
431
5.142857
0.761905
0.083333
0
0
0
0
0
0
0
0
0
0
0.37355
431
17
66
25.352941
0.8
0.556845
0
0
0
0
0.174825
0.174825
0
0
0
0
0
1
0.25
true
0
0.5
0.25
1.25
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
1
0
1
1
1
0
0
5
a009b5a26a075f5a6315d7e60cb0c67628219538
13,256
py
Python
geokey/users/tests/test_ajax_views.py
universityofsussex/geokey
25e161dbc81841c57c148053dbe99facc81e84b8
[ "Apache-2.0" ]
null
null
null
geokey/users/tests/test_ajax_views.py
universityofsussex/geokey
25e161dbc81841c57c148053dbe99facc81e84b8
[ "Apache-2.0" ]
null
null
null
geokey/users/tests/test_ajax_views.py
universityofsussex/geokey
25e161dbc81841c57c148053dbe99facc81e84b8
[ "Apache-2.0" ]
null
null
null
"""Tests for AJAX views of users.""" import json from django.test import TestCase from django.core.urlresolvers import reverse from rest_framework.test import APIRequestFactory, force_authenticate from rest_framework import status from geokey.projects.tests.model_factories import ProjectFactory from .model_factories import UserFactory, UserGroupFactory from ..views import ( UserGroup, UserGroupUsers, UserGroupSingleUser, ) from ..models import UserGroup as Group class QueryUsersTest(TestCase): def _get(self, query): return self.client.get('/ajax/users/?query=' + query) def setUp(self): UserFactory.create(**{ 'display_name': 'Peter Schmeichel' }) UserFactory.create(**{ 'display_name': 'George Best' }) UserFactory.create(**{ 'display_name': 'Luis Figo' }) UserFactory.create(**{ 'display_name': 'pete23' }) UserFactory.create(**{ 'display_name': 'pet48' }) UserFactory.create(**{ 'display_name': 'Frank Lampard' }) def test_query_pet(self): response = self._get('pet') result_set = json.loads(response.content) self.assertEqual(len(result_set), 3) self.assertContains(response, 'Schmeichel') self.assertContains(response, 'pete23') self.assertContains(response, 'pet48') def test_query_peter(self): response = self._get('peter') result_set = json.loads(response.content) self.assertEqual(len(result_set), 1) self.assertContains(response, 'Schmeichel') def test_query_anonymous(self): response = self._get('anon') result_set = json.loads(response.content) self.assertEqual(len(result_set), 0) def test_no_query(self): response = self.client.get('/ajax/users/') result_set = json.loads(response.content) self.assertEqual(len(result_set), 0) class UserGroupTest(TestCase): def setUp(self): self.factory = APIRequestFactory() self.admin = UserFactory.create() self.contributor = UserFactory.create() self.non_member = UserFactory.create() self.user_to_add = UserFactory.create() self.project = ProjectFactory.create( add_admins=[self.admin] ) self.contributors = UserGroupFactory( add_users=[self.contributor], **{'project': self.project} ) def put(self, user, data): url = reverse('ajax:usergroup', kwargs={ 'project_id': self.project.id, 'usergroup_id': self.contributors.id }) request = self.factory.put( url, json.dumps(data), content_type='application/json') force_authenticate(request, user=user) view = UserGroup.as_view() return view( request, project_id=self.project.id, usergroup_id=self.contributors.id).render() def test_update_with_admin(self): response = self.put(self.admin, {'can_contribute': False}) self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertFalse( Group.objects.get(pk=self.contributors.id).can_contribute, ) def test_when_project_is_locked(self): self.project.islocked = True self.project.save() response = self.put(self.admin, {'can_contribute': False}) self.assertEqual(response.status_code, status.HTTP_400_BAD_REQUEST) self.assertTrue( Group.objects.get(pk=self.contributors.id).can_contribute, ) def test_invalid_update_with_admin(self): response = self.put(self.admin, {'can_contribute': 'Blah'}) self.assertEqual(response.status_code, status.HTTP_400_BAD_REQUEST) self.assertTrue( Group.objects.get(pk=self.contributors.id).can_contribute, ) def test_update_description_with_contributor(self): response = self.put(self.contributor, {'can_contribute': False}) self.assertEqual(response.status_code, status.HTTP_403_FORBIDDEN) self.assertTrue( Group.objects.get(pk=self.contributors.id).can_contribute, ) def test_update_description_with_non_member(self): response = self.put(self.non_member, {'can_contribute': False}) self.assertEqual(response.status_code, status.HTTP_404_NOT_FOUND) self.assertTrue( Group.objects.get(pk=self.contributors.id).can_contribute, ) class UserGroupUsersTest(TestCase): def setUp(self): self.factory = APIRequestFactory() self.admin = UserFactory.create() self.contributor = UserFactory.create() self.non_member = UserFactory.create() self.user_to_add = UserFactory.create() self.project = ProjectFactory.create( add_admins=[self.admin] ) self.contributors = UserGroupFactory( add_users=[self.contributor], **{'project': self.project} ) def test_add_to_not_existing_usergroup(self): request = self.factory.post( '/ajax/projects/%s/usergroups/%s/users/' % (self.project.id, 6545454844545648), {'user_id': self.user_to_add.id} ) force_authenticate(request, user=self.admin) view = UserGroupUsers.as_view() response = view( request, project_id=self.project.id, usergroup_id=6545454844545648 ).render() self.assertEqual(response.status_code, 404) def test_add_not_existing_user(self): request = self.factory.post( '/ajax/projects/%s/usergroups/%s/users/' % (self.project.id, self.contributors.id), {'user_id': 4445468756454} ) force_authenticate(request, user=self.admin) view = UserGroupUsers.as_view() response = view( request, project_id=self.project.id, usergroup_id=self.contributors.id ).render() self.assertEqual(response.status_code, 404) def test_add_on_locked_project(self): self.project.islocked = True self.project.save() request = self.factory.post( '/ajax/projects/%s/usergroups/%s/users/' % (self.project.id, self.contributors.id), {'user_id': self.user_to_add.id} ) force_authenticate(request, user=self.admin) view = UserGroupUsers.as_view() response = view( request, project_id=self.project.id, usergroup_id=self.contributors.id ).render() self.assertEqual(response.status_code, 400) def test_add_contributor_with_admin(self): request = self.factory.post( '/ajax/projects/%s/usergroups/%s/users/' % (self.project.id, self.contributors.id), {'user_id': self.user_to_add.id} ) force_authenticate(request, user=self.admin) view = UserGroupUsers.as_view() response = view( request, project_id=self.project.id, usergroup_id=self.contributors.id ).render() self.assertEqual(response.status_code, 201) self.assertIn( self.user_to_add, self.contributors.users.all() ) def test_add_contributor_with_contributor(self): request = self.factory.post( '/ajax/projects/%s/usergroups/%s/users/' % (self.project.id, self.contributors.id), {'user_id': self.user_to_add.id} ) force_authenticate(request, user=self.contributor) view = UserGroupUsers.as_view() response = view( request, project_id=self.project.id, usergroup_id=self.contributors.id ).render() self.assertEqual(response.status_code, 403) self.assertNotIn( self.user_to_add, self.contributors.users.all() ) def test_add_contributor_with_non_member(self): request = self.factory.post( '/ajax/projects/%s/usergroups/%s/users/' % (self.project.id, self.contributors.id), {'user_id': self.user_to_add.id} ) force_authenticate(request, user=self.non_member) view = UserGroupUsers.as_view() response = view( request, project_id=self.project.id, usergroup_id=self.contributors.id ).render() self.assertEqual(response.status_code, 404) self.assertNotIn( self.user_to_add, self.contributors.users.all() ) class UserGroupSingleUserTest(TestCase): def setUp(self): self.factory = APIRequestFactory() self.admin = UserFactory.create() self.contributor = UserFactory.create() self.non_member = UserFactory.create() self.contrib_to_remove = UserFactory.create() self.project = ProjectFactory.create( add_admins=[self.admin] ) self.contributors = UserGroupFactory( add_users=[self.contributor, self.contrib_to_remove], **{'project': self.project, 'can_contribute': True} ) def test_delete_not_existing_user(self): user = UserFactory.create() request = self.factory.delete( '/ajax/projects/%s/usergroups/%s/users/%s/' % (self.project.id, self.contributors.id, user.id), ) force_authenticate(request, user=self.admin) view = UserGroupSingleUser.as_view() response = view( request, project_id=self.project.id, usergroup_id=self.contributors.id, user_id=user.id ).render() self.assertEqual(response.status_code, 404) def test_delete_from_not_existing_usergroup(self): request = self.factory.delete( '/ajax/projects/%s/usergroups/%s/users/%s/' % (self.project.id, 455646445484545, self.contrib_to_remove.id), ) force_authenticate(request, user=self.admin) view = UserGroupSingleUser.as_view() response = view( request, project_id=self.project.id, usergroup_id=455646445484545, user_id=self.contrib_to_remove.id ).render() self.assertEqual(response.status_code, 404) def test_delete_on_locked_project(self): self.project.islocked = True self.project.save() request = self.factory.delete( '/ajax/projects/%s/usergroups/%s/users/%s/' % (self.project.id, self.contributors.id, self.contrib_to_remove.id), ) force_authenticate(request, user=self.admin) view = UserGroupSingleUser.as_view() response = view( request, project_id=self.project.id, usergroup_id=self.contributors.id, user_id=self.contrib_to_remove.id ).render() self.assertEqual(response.status_code, 400) def test_delete_contributor_with_admin(self): request = self.factory.delete( '/ajax/projects/%s/usergroups/%s/users/%s/' % (self.project.id, self.contributors.id, self.contrib_to_remove.id), ) force_authenticate(request, user=self.admin) view = UserGroupSingleUser.as_view() response = view( request, project_id=self.project.id, usergroup_id=self.contributors.id, user_id=self.contrib_to_remove.id ).render() self.assertEqual(response.status_code, 204) self.assertNotIn( self.contrib_to_remove, self.contributors.users.all() ) def test_delete_contributor_with_contributor(self): request = self.factory.delete( '/ajax/projects/%s/usergroups/%s/users/%s/' % (self.project.id, self.contributors.id, self.contrib_to_remove.id) ) force_authenticate(request, user=self.contributor) view = UserGroupSingleUser.as_view() response = view( request, project_id=self.project.id, usergroup_id=self.contributors.id, user_id=self.contrib_to_remove.id ).render() self.assertEqual(response.status_code, 403) self.assertIn( self.contrib_to_remove, self.contributors.users.all() ) def test_delete_contributor_with_non_member(self): request = self.factory.delete( '/ajax/projects/%s/usergroups/%s/users/%s/' % (self.project.id, self.contributors.id, self.contrib_to_remove.id) ) force_authenticate(request, user=self.non_member) view = UserGroupSingleUser.as_view() response = view( request, project_id=self.project.id, usergroup_id=self.contributors.id, user_id=self.contrib_to_remove.id ).render() self.assertEqual(response.status_code, 404) self.assertIn( self.contrib_to_remove, self.contributors.users.all() )
33.057357
79
0.61459
1,419
13,256
5.548978
0.099366
0.0381
0.061722
0.05588
0.799086
0.786513
0.786513
0.773559
0.762637
0.759589
0
0.014359
0.27497
13,256
400
80
33.14
0.804911
0.002263
0
0.670623
0
0
0.066793
0.035855
0
0
0
0
0.106825
1
0.080119
false
0
0.026706
0.002967
0.124629
0
0
0
0
null
0
0
0
0
1
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
a00e4f377116c131ed5a3f9af68d62f6df103392
87
py
Python
asyncowfs/__init__.py
smurfix/trio-owfs
5e930b7d1b21a49b1eb16bf23340948d892c4c3b
[ "Apache-2.0", "MIT" ]
3
2018-11-04T20:28:31.000Z
2021-06-29T04:09:43.000Z
asyncowfs/__init__.py
smurfix/trio-owfs
5e930b7d1b21a49b1eb16bf23340948d892c4c3b
[ "Apache-2.0", "MIT" ]
1
2022-01-22T19:52:43.000Z
2022-01-23T11:04:01.000Z
asyncowfs/__init__.py
smurfix/trio-owfs
5e930b7d1b21a49b1eb16bf23340948d892c4c3b
[ "Apache-2.0", "MIT" ]
1
2018-09-04T13:29:39.000Z
2018-09-04T13:29:39.000Z
"""Top-level package for Onewire for Trio.""" from .service import OWFS # noqa: F401
21.75
45
0.701149
13
87
4.692308
0.923077
0
0
0
0
0
0
0
0
0
0
0.041667
0.172414
87
3
46
29
0.805556
0.586207
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
4e4285d505da07d20fee5e90926f453a4d122bf4
133
py
Python
python-basics/data-structure/doctest.py
joonjCode/python
92889be7c03ce6d3faa1401d34619295cf5d1ce4
[ "MIT" ]
null
null
null
python-basics/data-structure/doctest.py
joonjCode/python
92889be7c03ce6d3faa1401d34619295cf5d1ce4
[ "MIT" ]
null
null
null
python-basics/data-structure/doctest.py
joonjCode/python
92889be7c03ce6d3faa1401d34619295cf5d1ce4
[ "MIT" ]
null
null
null
class A: def f(self): ''' Function descr, argument types, return type ... ''' print('Hello world') return 'Hello world'
16.625
49
0.609023
17
133
4.764706
0.823529
0.246914
0
0
0
0
0
0
0
0
0
0
0.233083
133
8
50
16.625
0.794118
0.353383
0
0
0
0
0.305556
0
0
0
0
0
0
1
0.25
false
0
0
0
0.75
0.25
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
0
1
0
0
5
4e5fc71b89cfe632b7589082be44c7b6e8fbd95d
187
py
Python
tests/__init__.py
patarapolw/WaniKaniTools
ea1eb9dcaa9362121dd6dd755d04b0e01754c5e3
[ "MIT" ]
8
2018-02-05T18:47:27.000Z
2020-05-10T09:20:47.000Z
tests/__init__.py
patarapolw/WaniKaniTools
ea1eb9dcaa9362121dd6dd755d04b0e01754c5e3
[ "MIT" ]
null
null
null
tests/__init__.py
patarapolw/WaniKaniTools
ea1eb9dcaa9362121dd6dd755d04b0e01754c5e3
[ "MIT" ]
null
null
null
import os from WaniKaniTools.credentials import load_credentials if 'TRAVIS' not in os.environ: load_credentials('/Users/patarapolw/PycharmProjects/WaniKaniTools/credentials.json')
26.714286
88
0.823529
22
187
6.909091
0.681818
0.315789
0
0
0
0
0
0
0
0
0
0
0.096257
187
6
89
31.166667
0.899408
0
0
0
0
0
0.374332
0.342246
0
0
0
0
0
1
0
true
0
0.5
0
0.5
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
4e88ee331b70cc8f700496543bcc50150eabe78c
58
py
Python
problem_6/problem_6.py
oltionzefi/daily-coding-problem
4fe3ec53e1f3c7d299849671fdfead462d548cd3
[ "MIT" ]
null
null
null
problem_6/problem_6.py
oltionzefi/daily-coding-problem
4fe3ec53e1f3c7d299849671fdfead462d548cd3
[ "MIT" ]
null
null
null
problem_6/problem_6.py
oltionzefi/daily-coding-problem
4fe3ec53e1f3c7d299849671fdfead462d548cd3
[ "MIT" ]
null
null
null
def add(element): return def get(index): return
8.285714
17
0.62069
8
58
4.5
0.75
0
0
0
0
0
0
0
0
0
0
0
0.275862
58
7
18
8.285714
0.857143
0
0
0.5
0
0
0
0
0
0
0
0
0
1
0.5
false
0
0
0.5
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
1
1
0
0
5
4e93c8f77672b799556a79a5c422c82b052d5529
94
py
Python
staticassets/exceptions.py
davidelias/django-staticassets
75d937c31f12053f42b8dd5c7742ef1ac125b40d
[ "MIT" ]
null
null
null
staticassets/exceptions.py
davidelias/django-staticassets
75d937c31f12053f42b8dd5c7742ef1ac125b40d
[ "MIT" ]
null
null
null
staticassets/exceptions.py
davidelias/django-staticassets
75d937c31f12053f42b8dd5c7742ef1ac125b40d
[ "MIT" ]
null
null
null
class AssetNotFound(Exception): pass class CircularDependencyError(Exception): pass
13.428571
41
0.765957
8
94
9
0.625
0.361111
0
0
0
0
0
0
0
0
0
0
0.170213
94
6
42
15.666667
0.923077
0
0
0.5
0
0
0
0
0
0
0
0
0
1
0
true
0.5
0
0
0.5
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
1
0
0
0
0
0
5
4ed2266a4d4681d9c4e1fdea8a44a3936a239c5a
187
py
Python
myci/__init__.py
cyraxjoe/myci-demo
81866781c29e91826aa6a2443d95400bbb77a15a
[ "MIT" ]
null
null
null
myci/__init__.py
cyraxjoe/myci-demo
81866781c29e91826aa6a2443d95400bbb77a15a
[ "MIT" ]
null
null
null
myci/__init__.py
cyraxjoe/myci-demo
81866781c29e91826aa6a2443d95400bbb77a15a
[ "MIT" ]
null
null
null
from .workers import get_workers from .change_source import get_change_source from .schedulers import get_schedulers from .builders import get_builders from .services import get_services
31.166667
44
0.86631
27
187
5.740741
0.333333
0.290323
0
0
0
0
0
0
0
0
0
0
0.106952
187
5
45
37.4
0.928144
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
14db3380c13d268d5bf77670fe4f5ff0ff912ffe
304
py
Python
SimPEG/EM/Utils/__init__.py
kimjaed/simpeg
b8d716f86a4ea07ba3085fabb24c2bc974788040
[ "MIT" ]
3
2020-11-27T03:18:28.000Z
2022-03-18T01:29:58.000Z
SimPEG/EM/Utils/__init__.py
kimjaed/simpeg
b8d716f86a4ea07ba3085fabb24c2bc974788040
[ "MIT" ]
1
2020-10-29T11:42:21.000Z
2020-10-29T11:42:21.000Z
SimPEG/EM/Utils/__init__.py
kimjaed/simpeg
b8d716f86a4ea07ba3085fabb24c2bc974788040
[ "MIT" ]
1
2019-12-27T15:58:49.000Z
2019-12-27T15:58:49.000Z
from .EMUtils import omega, k, VTEMFun, TriangleFun, SineFun from .AnalyticUtils import ( MagneticDipoleFields, MagneticDipoleVectorPotential, MagneticLoopVectorPotential, orientationDict ) from .CurrentUtils import ( getSourceTermLineCurrentPolygon, getStraightLineCurrentIntegral )
33.777778
67
0.805921
20
304
12.25
0.8
0
0
0
0
0
0
0
0
0
0
0
0.144737
304
8
68
38
0.942308
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.375
0
0.375
0
1
0
1
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
09437c065d267d830e88df8034bf7e8aa4fa24e4
487
py
Python
aerokit/aero/ThermoKerosen.py
PierreMignerot/aerokit
78717288d840ef5cb3939b44e967cf8f250dc270
[ "MIT" ]
null
null
null
aerokit/aero/ThermoKerosen.py
PierreMignerot/aerokit
78717288d840ef5cb3939b44e967cf8f250dc270
[ "MIT" ]
null
null
null
aerokit/aero/ThermoKerosen.py
PierreMignerot/aerokit
78717288d840ef5cb3939b44e967cf8f250dc270
[ "MIT" ]
null
null
null
# python module: ThermoKerosen import math r_air = 287.04 # constants are computed relative to air "r" constant def Cp(T): return r_air*(4.47659+(8.01994e-3-1.8373e-6*T)*T) def Enthalpy(T): return r_air*(-149.054+(4.47659+(4.00997e-3-6.12432e-7*T)*T)*T) def Phi(T): return (4.47659*math.log(T)+(8.01994e-3 - 9.18648e-7*T)*T)/math.log(10.) def Pc_inf(): return 10300.*4184 def Pc_eff(T): return Pc_inf()+r_air*(1607.2+(-4.47659+(-4.00997e-3+6.12432e-7*T)*T)*T)
23.190476
76
0.648871
100
487
3.09
0.45
0.038835
0.029126
0.071197
0.161812
0.161812
0.161812
0.161812
0.161812
0.161812
0
0.252381
0.137577
487
20
77
24.35
0.483333
0.164271
0
0
0
0
0
0
0
0
0
0
0
1
0.416667
false
0
0.083333
0.416667
0.916667
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
1
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
1
1
0
0
5
11854a6e331ca9c520bc9d5e166d8f18b42e7f7f
246
py
Python
pirates/pirate/HumanAnimationMixer.py
Willy5s/Pirates-Online-Rewritten
7434cf98d9b7c837d57c181e5dabd02ddf98acb7
[ "BSD-3-Clause" ]
81
2018-04-08T18:14:24.000Z
2022-01-11T07:22:15.000Z
pirates/pirate/HumanAnimationMixer.py
Willy5s/Pirates-Online-Rewritten
7434cf98d9b7c837d57c181e5dabd02ddf98acb7
[ "BSD-3-Clause" ]
4
2018-09-13T20:41:22.000Z
2022-01-08T06:57:00.000Z
pirates/pirate/HumanAnimationMixer.py
Willy5s/Pirates-Online-Rewritten
7434cf98d9b7c837d57c181e5dabd02ddf98acb7
[ "BSD-3-Clause" ]
26
2018-05-26T12:49:27.000Z
2021-09-11T09:11:59.000Z
from direct.directnotify import DirectNotifyGlobal from pirates.pirate.BipedAnimationMixer import BipedAnimationMixer class HumanAnimationMixer(BipedAnimationMixer): notify = DirectNotifyGlobal.directNotify.newCategory('HumanAnimationMixer')
49.2
79
0.878049
19
246
11.368421
0.631579
0
0
0
0
0
0
0
0
0
0
0
0.069106
246
5
79
49.2
0.943231
0
0
0
0
0
0.076923
0
0
0
0
0
0
1
0
false
0
0.5
0
1
0
1
0
1
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
5
119db185a1ae440fd2cdb6c7f531331642313c34
568
py
Python
venv/Lib/site-packages/networkx/linalg/__init__.py
amelliaaas/tugastkc4
f442382c72379e911f3780543b95345a3b1c9407
[ "Apache-2.0" ]
10,024
2015-01-01T13:06:43.000Z
2022-03-31T12:45:25.000Z
venv/Lib/site-packages/networkx/linalg/__init__.py
amelliaaas/tugastkc4
f442382c72379e911f3780543b95345a3b1c9407
[ "Apache-2.0" ]
3,191
2015-01-01T18:13:11.000Z
2022-03-31T22:06:00.000Z
venv/Lib/site-packages/networkx/linalg/__init__.py
amelliaaas/tugastkc4
f442382c72379e911f3780543b95345a3b1c9407
[ "Apache-2.0" ]
3,272
2015-01-01T05:04:53.000Z
2022-03-31T17:46:35.000Z
from networkx.linalg.attrmatrix import * from networkx.linalg import attrmatrix from networkx.linalg.spectrum import * from networkx.linalg import spectrum from networkx.linalg.graphmatrix import * from networkx.linalg import graphmatrix from networkx.linalg.laplacianmatrix import * from networkx.linalg import laplacianmatrix from networkx.linalg.algebraicconnectivity import * from networkx.linalg.modularitymatrix import * from networkx.linalg import modularitymatrix from networkx.linalg.bethehessianmatrix import * from networkx.linalg import bethehessianmatrix
40.571429
51
0.860915
65
568
7.523077
0.169231
0.319018
0.478528
0.343558
0.368098
0
0
0
0
0
0
0
0.091549
568
13
52
43.692308
0.947674
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
0
0
0
null
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
11af6d59eb64b6faf6402103b62961896a53a908
152
py
Python
env/lib/python3.6/site-packages/django_filters/rest_framework/__init__.py
anthowen/duplify
846d01c1b21230937fdf0281b0cf8c0b08a8c24e
[ "MIT" ]
84
2019-02-22T08:19:52.000Z
2022-02-08T03:36:32.000Z
env/lib/python3.6/site-packages/django_filters/rest_framework/__init__.py
anthowen/duplify
846d01c1b21230937fdf0281b0cf8c0b08a8c24e
[ "MIT" ]
16
2019-09-06T10:25:40.000Z
2022-02-12T06:37:41.000Z
env/lib/python3.6/site-packages/django_filters/rest_framework/__init__.py
anthowen/duplify
846d01c1b21230937fdf0281b0cf8c0b08a8c24e
[ "MIT" ]
61
2019-03-20T02:29:23.000Z
2021-07-09T08:14:25.000Z
# flake8: noqa from __future__ import absolute_import from .backends import DjangoFilterBackend from .filterset import FilterSet from .filters import *
25.333333
41
0.835526
18
152
6.777778
0.555556
0
0
0
0
0
0
0
0
0
0
0.007519
0.125
152
5
42
30.4
0.909774
0.078947
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
11b664f76db2dd1a7d88f19c65d13a0c6da837a6
417
py
Python
src/mysite/views.py
Sabrigan/mysite
f01290e820c2666d8572d0d2ba2deeb7ff8f350c
[ "Apache-2.0" ]
null
null
null
src/mysite/views.py
Sabrigan/mysite
f01290e820c2666d8572d0d2ba2deeb7ff8f350c
[ "Apache-2.0" ]
null
null
null
src/mysite/views.py
Sabrigan/mysite
f01290e820c2666d8572d0d2ba2deeb7ff8f350c
[ "Apache-2.0" ]
null
null
null
from django.shortcuts import render def home(request): return render(request, 'blog/pages/bio.html') def about(request): return render(request, 'pages/about.html') def contact(request): return render(request, 'pages/contact.html') def handler404(request, exception): return render(request, 'errors/Erreur404.html') def handler500(request): return render(request, 'errors/Erreur500.html')
19.857143
51
0.731415
52
417
5.865385
0.403846
0.196721
0.311475
0.340984
0.203279
0
0
0
0
0
0
0.03352
0.141487
417
20
52
20.85
0.818436
0
0
0
0
0
0.227818
0.100719
0
0
0
0
0
1
0.454545
false
0
0.090909
0.454545
1
0
0
0
0
null
0
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
1
1
0
0
5
eeadafab69bc611650474fbb14706e69fc7ef5d6
69
py
Python
code/abc028_a_02.py
KoyanagiHitoshi/AtCoder
731892543769b5df15254e1f32b756190378d292
[ "MIT" ]
3
2019-08-16T16:55:48.000Z
2021-04-11T10:21:40.000Z
code/abc028_a_02.py
KoyanagiHitoshi/AtCoder
731892543769b5df15254e1f32b756190378d292
[ "MIT" ]
null
null
null
code/abc028_a_02.py
KoyanagiHitoshi/AtCoder
731892543769b5df15254e1f32b756190378d292
[ "MIT" ]
null
null
null
print((["Bad"]*6+["Good"]*3+["Great"]+["Perfect"])[int(input())//10])
69
69
0.521739
10
69
3.6
1
0
0
0
0
0
0
0
0
0
0
0.057971
0
69
1
69
69
0.463768
0
0
0
0
0
0.271429
0
0
0
0
0
0
1
0
true
0
0
0
0
1
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
1
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
1
0
5
e12381001b2d923bee7e3222971790c087ba30d1
85
py
Python
v2/test.py
timm/py
28be3bb63433895e2bcab27ad82cb0b0cc994f37
[ "Unlicense" ]
1
2021-03-31T03:41:06.000Z
2021-03-31T03:41:06.000Z
v2/test.py
timm/py
28be3bb63433895e2bcab27ad82cb0b0cc994f37
[ "Unlicense" ]
null
null
null
v2/test.py
timm/py
28be3bb63433895e2bcab27ad82cb0b0cc994f37
[ "Unlicense" ]
null
null
null
def kk(): class B(A): pass from fred import jj B() jj() class A: pass kk()
8.5
21
0.552941
16
85
2.9375
0.625
0.212766
0
0
0
0
0
0
0
0
0
0
0.294118
85
9
22
9.444444
0.783333
0
0
0
0
0
0
0
0
0
0
0
0
1
0.142857
true
0.285714
0.142857
0
0.571429
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
1
0
0
0
0
0
5
e12e0d97626baddff02c458e92bef923570a9dd1
93
py
Python
api/terminal/terminal/apps/auth/__init__.py
WeBankPartners/wecube-plugins-terminal
25e255e42f4bfe810085a94a81abb4a021aa3163
[ "Apache-2.0" ]
8
2021-05-08T02:00:28.000Z
2021-09-10T10:46:02.000Z
api/terminal/terminal/apps/auth/__init__.py
WeBankPartners/wecube-plugins-terminal
25e255e42f4bfe810085a94a81abb4a021aa3163
[ "Apache-2.0" ]
6
2021-02-02T07:58:00.000Z
2021-08-18T02:30:10.000Z
api/terminal/terminal/apps/auth/__init__.py
WeBankPartners/wecube-plugins-terminal
25e255e42f4bfe810085a94a81abb4a021aa3163
[ "Apache-2.0" ]
1
2022-02-11T13:55:29.000Z
2022-02-11T13:55:29.000Z
# coding=utf-8 from __future__ import absolute_import from terminal.apps.auth import route
15.5
38
0.817204
14
93
5.071429
0.785714
0
0
0
0
0
0
0
0
0
0
0.012346
0.129032
93
5
39
18.6
0.864198
0.129032
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
011828d3c8f41aae6ab0fb31314a68719b87e537
8,271
py
Python
taggit_templatetags/tests/tests.py
oddstr13-openshell-no/django-taggit-templatetags
90d02b48ecddd9e51c6c903ee2a3e338c6635d19
[ "BSD-3-Clause" ]
44
2015-01-08T13:50:24.000Z
2022-03-12T07:11:15.000Z
taggit_templatetags/tests/tests.py
oddstr13-openshell-no/django-taggit-templatetags
90d02b48ecddd9e51c6c903ee2a3e338c6635d19
[ "BSD-3-Clause" ]
7
2016-03-16T04:19:01.000Z
2019-09-20T08:46:44.000Z
taggit_templatetags/tests/tests.py
oddstr13-openshell-no/django-taggit-templatetags
90d02b48ecddd9e51c6c903ee2a3e338c6635d19
[ "BSD-3-Clause" ]
11
2015-02-21T09:38:12.000Z
2021-07-30T23:19:19.000Z
from django.test import TestCase from django.template import Context, Template from django.template.loader import get_template from taggit_templatetags.tests.models import AlphaModel, BetaModel from taggit.tests.tests import BaseTaggingTest from taggit_templatetags.templatetags.taggit_extras import get_weight_fun class SetUpTestCase(): a_model = AlphaModel b_model = BetaModel def setUp(self): a1 = self.a_model.objects.create(name="apple") a2 = self.a_model.objects.create(name="pear") b1 = self.b_model.objects.create(name="dog") b2 = self.b_model.objects.create(name="kitty") a1.tags.add("green") a1.tags.add("sweet") a1.tags.add("fresh") a2.tags.add("yellow") a2.tags.add("sour") b1.tags.add("sweet") b1.tags.add("yellow") b2.tags.add("sweet") b2.tags.add("green") class TestWeightFun(TestCase): def test_one(self): t_min = 1 t_max = 6 f_min = 10 f_max = 20 weight_fun = get_weight_fun(t_min, t_max, f_min, f_max) self.assertEqual(weight_fun(20), 6) self.assertEqual(weight_fun(10), 1) self.assertEqual(weight_fun(15), 3.5) def test_two(self): t_min = 10 t_max = 100 f_min = 5 f_max = 7 weight_fun = get_weight_fun(t_min, t_max, f_min, f_max) self.assertEqual(weight_fun(5), 10) self.assertEqual(weight_fun(7), 100) self.assertEqual(weight_fun(6), 55) class TemplateTagListTestCase(SetUpTestCase, BaseTaggingTest, TestCase): def get_template(self, argument): return """ {%% load taggit_extras %%} {%% get_taglist %s %%} """ % argument def test_project(self): t = Template(self.get_template("as taglist")) c = Context({}) t.render(c) self.assert_tags_equal(c.get("taglist"), ["sweet", "green", "yellow", "fresh", "sour"], False) def test_app(self): t = Template(self.get_template("as taglist for 'tests'")) c = Context({}) t.render(c) self.assert_tags_equal(c.get("taglist"), ["sweet", "green", "yellow", "fresh", "sour"], False) def test_model(self): t = Template(self.get_template("as taglist for 'tests.BetaModel'")) c = Context({}) t.render(c) self.assert_tags_equal(c.get("taglist"), ["sweet", "green", "yellow"], False) class TemplateTagCloudTestCase(SetUpTestCase, BaseTaggingTest, TestCase): def get_template(self, argument): return """ {%% load taggit_extras %%} {%% get_tagcloud %s %%} """ % argument def test_project(self): t = Template(self.get_template("as taglist")) c = Context({}) t.render(c) self.assert_tags_equal(c.get("taglist"), ["fresh", "green", "sour", "sweet", "yellow"], False) self.assertEqual(c.get("taglist")[3].name, "sweet") self.assertEqual(c.get("taglist")[3].weight, 6.0) self.assertEqual(c.get("taglist")[1].name, "green") self.assertEqual(c.get("taglist")[1].weight, 3.5) self.assertEqual(c.get("taglist")[2].name, "sour") self.assertEqual(c.get("taglist")[2].weight, 1.0) def test_app(self): t = Template(self.get_template("as taglist for 'tests'")) c = Context({}) t.render(c) self.assert_tags_equal(c.get("taglist"), ["fresh", "green", "sour", "sweet", "yellow"], False) self.assertEqual(c.get("taglist")[3].name, "sweet") self.assertEqual(c.get("taglist")[3].weight, 6.0) self.assertEqual(c.get("taglist")[1].name, "green") self.assertEqual(c.get("taglist")[1].weight, 3.5) self.assertEqual(c.get("taglist")[2].name, "sour") self.assertEqual(c.get("taglist")[2].weight, 1.0) def test_model(self): t = Template(self.get_template("as taglist for 'tests.BetaModel'")) c = Context({}) t.render(c) self.assert_tags_equal(c.get("taglist"), ["green", "sweet", "yellow"], False) self.assertEqual(c.get("taglist")[0].name, "green") self.assertEqual(c.get("taglist")[0].weight, 1.0) self.assertEqual(c.get("taglist")[1].name, "sweet") self.assertEqual(c.get("taglist")[1].weight, 6.0) self.assertEqual(c.get("taglist")[2].name, "yellow") self.assertEqual(c.get("taglist")[2].weight, 1.0) class TemplateInclusionTagTest(SetUpTestCase, TestCase, BaseTaggingTest): def test_taglist_project(self): t = get_template('taggit_templatetags/taglist_include.html') c = Context({'forvar': None}) t.render(c) self.assert_tags_equal(c.get("tags"), ["sweet", "green", "yellow", "fresh", "sour"], False) def test_taglist_app(self): t = get_template('taggit_templatetags/taglist_include.html') c = Context({'forvar': 'tests'}) t.render(c) self.assert_tags_equal(c.get("tags"), ["sweet", "green", "yellow", "fresh", "sour"], False) def test_taglist_model(self): t = get_template('taggit_templatetags/taglist_include.html') c = Context({'forvar': 'tests.BetaModel'}) t.render(c) self.assert_tags_equal(c.get("tags"), ["sweet", "green", "yellow"], False) def test_tagcloud_project(self): t = get_template('taggit_templatetags/tagcloud_include.html') c = Context({'forvar': None}) t.render(c) self.assert_tags_equal(c.get("tags"), ["fresh", "green", "sour", "sweet", "yellow"], False) def test_tagcloud_app(self): t = get_template('taggit_templatetags/tagcloud_include.html') c = Context({'forvar': 'tests'}) t.render(c) self.assert_tags_equal(c.get("tags"), ["fresh", "green", "sour", "sweet", "yellow"], False) def test_tagcloud_model(self): t = get_template('taggit_templatetags/tagcloud_include.html') c = Context({'forvar': 'tests.BetaModel'}) t.render(c) self.assert_tags_equal(c.get("tags"), ["green", "sweet", "yellow"], False) class AlphaPathologicalCaseTestCase(TestCase, BaseTaggingTest): """ This is a testcase for one tag once. """ a_model = AlphaModel def setUp(self): a1 = self.a_model.objects.create(name="apple") a1.tags.add("green") def test_tagcloud(self): t = get_template('taggit_templatetags/tagcloud_include.html') c = Context({'forvar': None}) t.render(c) self.assert_tags_equal(c.get("tags"), ["green"], False) self.assertEqual(c.get("tags")[0].name, "green") self.assertEqual(c.get("tags")[0].weight, 6.0) class BetaPathologicalCaseTestCase(TestCase, BaseTaggingTest): """ This is a testcase for one tag thrice. """ a_model = AlphaModel b_model = BetaModel def setUp(self): a1 = self.a_model.objects.create(name="apple") a2 = self.a_model.objects.create(name="pear") b1 = self.b_model.objects.create(name="dog") a1.tags.add("green") a2.tags.add("green") b1.tags.add("green") def test_tagcloud(self): t = get_template('taggit_templatetags/tagcloud_include.html') c = Context({'forvar': None}) t.render(c) self.assert_tags_equal(c.get("tags"), ["green"], False) self.assertEqual(c.get("tags")[0].name, "green") self.assertEqual(c.get("tags")[0].weight, 6.0) class GammaPathologicalCaseTestCase(TestCase, BaseTaggingTest): """ This is a pathological testcase for no tag at all. """ a_model = AlphaModel b_model = BetaModel def setUp(self): a1 = self.a_model.objects.create(name="apple") b1 = self.b_model.objects.create(name="dog") def test_tagcloud(self): t = get_template('taggit_templatetags/tagcloud_include.html') c = Context({'forvar': None}) t.render(c) self.assert_tags_equal(c.get("tags"), [], False)
38.291667
102
0.59364
1,032
8,271
4.619186
0.09593
0.031047
0.055381
0.087686
0.787078
0.776589
0.770715
0.749108
0.71974
0.692679
0
0.016072
0.247733
8,271
216
103
38.291667
0.75008
0.015234
0
0.654971
0
0
0.177407
0.045185
0
0
0
0
0.251462
1
0.134503
false
0
0.035088
0.011696
0.269006
0
0
0
0
null
0
0
0
0
1
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
011c0ae1ae1affe065ec2d6bfc71330b1d062dee
37
py
Python
tests/__init__.py
marcua/datools
dc6e6f3b9cad04197872b0e6c6a6288f87e149ca
[ "Apache-2.0" ]
59
2022-02-20T18:12:16.000Z
2022-03-13T13:47:08.000Z
tests/__init__.py
marcua/datools
dc6e6f3b9cad04197872b0e6c6a6288f87e149ca
[ "Apache-2.0" ]
30
2021-05-09T16:50:48.000Z
2022-03-27T16:09:11.000Z
tests/__init__.py
marcua/datools
dc6e6f3b9cad04197872b0e6c6a6288f87e149ca
[ "Apache-2.0" ]
2
2022-02-26T08:12:07.000Z
2022-02-26T23:26:13.000Z
"""Unit test package for datools."""
18.5
36
0.675676
5
37
5
1
0
0
0
0
0
0
0
0
0
0
0
0.135135
37
1
37
37
0.78125
0.810811
0
null
0
null
0
0
null
0
0
0
null
1
null
true
0
0
null
null
null
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
5
011d24868b8702d4d4118f6895ca70b1ab6d08a5
360
py
Python
jiminy/gym/envs/classic_control/__init__.py
sibeshkar/jiminy
7754f86fb0f246e7d039ea0cbfd9950fcae4adfb
[ "MIT" ]
3
2020-03-16T13:50:40.000Z
2021-06-09T05:26:13.000Z
jiminy/gym/envs/classic_control/__init__.py
sibeshkar/jiminy
7754f86fb0f246e7d039ea0cbfd9950fcae4adfb
[ "MIT" ]
null
null
null
jiminy/gym/envs/classic_control/__init__.py
sibeshkar/jiminy
7754f86fb0f246e7d039ea0cbfd9950fcae4adfb
[ "MIT" ]
null
null
null
from jiminy.gym.envs.classic_control.cartpole import CartPoleEnv from jiminy.gym.envs.classic_control.mountain_car import MountainCarEnv from jiminy.gym.envs.classic_control.continuous_mountain_car import Continuous_MountainCarEnv from jiminy.gym.envs.classic_control.pendulum import PendulumEnv from jiminy.gym.envs.classic_control.acrobot import AcrobotEnv
51.428571
93
0.886111
49
360
6.326531
0.346939
0.16129
0.209677
0.274194
0.590323
0.590323
0.290323
0
0
0
0
0
0.058333
360
6
94
60
0.914454
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
0
0
0
null
0
1
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
0165ee063f81a0a1fec5292dd70dd9ba6e8b28e2
130
py
Python
src/code_katas/opposite_number.py
MiM0ulay/code-katas
5a4b7b9e4c7ae257ddd89f95f28e9df23cdd3e88
[ "MIT" ]
5
2019-03-31T16:28:19.000Z
2021-02-19T09:33:04.000Z
src/code_katas/opposite_number.py
MiM0ulay/code-katas
5a4b7b9e4c7ae257ddd89f95f28e9df23cdd3e88
[ "MIT" ]
2
2017-06-14T23:57:48.000Z
2017-06-22T20:21:32.000Z
src/code_katas/opposite_number.py
MiM0ulay/code-katas
5a4b7b9e4c7ae257ddd89f95f28e9df23cdd3e88
[ "MIT" ]
6
2020-02-02T02:10:27.000Z
2022-01-27T16:34:13.000Z
"""Function returns the opposite of an input number.""" def opposite(n): """Return opposite of number.""" return n * -1
18.571429
55
0.638462
18
130
4.611111
0.666667
0.240964
0
0
0
0
0
0
0
0
0
0.009804
0.215385
130
6
56
21.666667
0.803922
0.584615
0
0
0
0
0
0
0
0
0
0
0
1
0.5
false
0
0
0
1
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
0
1
0
0
5
6d76bbc9b9f503de2e322f0b4aed05ba4ab993e4
1,838
py
Python
src/dataGene.py
paloitsingapore/dthok
ce382d868bcb605f921f72eb966dd5046f835089
[ "MIT" ]
1
2021-11-02T16:46:22.000Z
2021-11-02T16:46:22.000Z
src/dataGene.py
paloitsingapore/dthok
ce382d868bcb605f921f72eb966dd5046f835089
[ "MIT" ]
null
null
null
src/dataGene.py
paloitsingapore/dthok
ce382d868bcb605f921f72eb966dd5046f835089
[ "MIT" ]
null
null
null
import platform from src.transpoter import buildJSON, append_to_file, buildXML def dataGene(input_file, num_records, output_fileformat, fileName): fileName = fileName + '_dthok' print("Platform Name : " + platform.system()) print("Given input schema file : " + input_file) print("Required no. of Records : " + num_records) print("Required Output file format : " + output_fileformat) if (output_fileformat == 'csv'): append_to_file(num_records, fileName, input_file) print("Required output file " + fileName + ".csv generated.") elif (output_fileformat == 'json'): buildJSON(num_records, fileName, input_file) print("Required output file " + fileName + ".json generated.") elif (output_fileformat == 'xml'): buildXML(num_records, fileName, input_file) print("Required output file " + fileName + ".xml generated.") return True # if __name__ == '__main__': # input_file = sys.argv[1] # num_records = sys.argv[2] # output_fileformat = sys.argv[3] # # fileName = 'BulkTestData' # print("Platform Name : "+ platform.system()) # print("Given input schema file : " + input_file) # print("Required no. of Records : " + num_records) # print("Required Output file format : " + output_fileformat) # # if(output_fileformat == 'csv'): # append_to_file(num_records, fileName, input_file) # print("Required output file "+ fileName+".csv generated.") # elif(output_fileformat == 'json'): # buildJSON(num_records, fileName, input_file) # print("Required output file " + fileName + ".json generated.") # elif(output_fileformat == 'xml'): # buildXML(num_records, fileName, input_file) # print("Required output file " + fileName + ".xml generated.")
41.772727
72
0.646899
203
1,838
5.635468
0.211823
0.078671
0.097902
0.153846
0.79021
0.79021
0.79021
0.79021
0.79021
0.79021
0
0.002107
0.225245
1,838
43
73
42.744186
0.801264
0.472797
0
0
0
0
0.250264
0
0
0
0
0
0
1
0.055556
false
0
0.111111
0
0.222222
0.388889
0
0
0
null
0
0
0
0
1
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
6d88b5b8c061ad8d3f6db97b6450a90cbf03a5f0
2,066
py
Python
modules/discriminators/discriminator_linear.py
valdersoul/bn-vae
b248193708e28f7314ba8f774d2112f0b7c69ab2
[ "MIT" ]
22
2020-06-01T12:51:47.000Z
2022-01-21T10:46:37.000Z
modules/discriminators/discriminator_linear.py
valdersoul/bn-vae
b248193708e28f7314ba8f774d2112f0b7c69ab2
[ "MIT" ]
6
2020-08-14T06:56:58.000Z
2021-08-17T02:43:04.000Z
modules/discriminators/discriminator_linear.py
valdersoul/bn-vae
b248193708e28f7314ba8f774d2112f0b7c69ab2
[ "MIT" ]
3
2020-11-24T01:06:56.000Z
2021-11-15T10:11:56.000Z
import torch import torch.nn as nn import torch.nn.functional as F from torch.nn.utils.rnn import pad_packed_sequence, pack_padded_sequence class LinearDiscriminator(nn.Module): """docstring for LinearDiscriminator""" def __init__(self, args, encoder): super(LinearDiscriminator, self).__init__() self.args = args self.encoder = encoder if args.freeze_enc: for param in self.encoder.parameters(): param.requires_grad = False self.linear = nn.Linear(args.nz, args.ncluster) self.dropout = nn.Dropout(0.5) self.loss = nn.CrossEntropyLoss(reduction="none") def get_performance(self, batch_data, batch_labels): mu, _ = self.encoder(batch_data) if not self.args.freeze_enc: mu = self.dropout(mu) logits = self.linear(mu) loss = self.loss(logits, batch_labels) _, pred = torch.max(logits, dim=1) correct = torch.eq(pred, batch_labels).float().sum().item() return loss, correct class MLPDiscriminator(nn.Module): """docstring for LinearDiscriminator""" def __init__(self, args, encoder): super(MLPDiscriminator, self).__init__() self.args = args self.encoder = encoder if args.freeze_enc: for param in self.encoder.parameters(): param.requires_grad = False self.feats = nn.Sequential( nn.Linear(args.nz, args.nz), nn.ReLU(), nn.Dropout(0.3), nn.Linear(args.nz, args.nz), nn.ReLU(), nn.Dropout(0.3), nn.Linear(args.nz, args.ncluster), ) self.loss = nn.CrossEntropyLoss(reduction="none") def get_performance(self, batch_data, batch_labels): mu, _ = self.encoder(batch_data) logits = self.feats(mu) loss = self.loss(logits, batch_labels) _, pred = torch.max(logits, dim=1) correct = torch.eq(pred, batch_labels).float().sum().item() return loss, correct
31.30303
72
0.606002
249
2,066
4.863454
0.269076
0.0545
0.039637
0.046243
0.749794
0.749794
0.749794
0.718415
0.718415
0.718415
0
0.005369
0.2788
2,066
65
73
31.784615
0.807383
0.03243
0
0.653061
0
0
0.004024
0
0
0
0
0
0
1
0.081633
false
0
0.081633
0
0.244898
0
0
0
0
null
0
0
0
0
1
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
6d8e04be4a2ef70b00e9076427e4cc29e6fd71e6
1,090
py
Python
tests/test_event_storage.py
SeniorTest/event-dashboard
26b7148031b3801fda466733308c1ac7ed655011
[ "MIT" ]
null
null
null
tests/test_event_storage.py
SeniorTest/event-dashboard
26b7148031b3801fda466733308c1ac7ed655011
[ "MIT" ]
null
null
null
tests/test_event_storage.py
SeniorTest/event-dashboard
26b7148031b3801fda466733308c1ac7ed655011
[ "MIT" ]
null
null
null
import json import random import time from src import es_handler def test_storing_events(es_cleared): # given es = es_handler.connect_elasticsearch() assert es files = [ 'events.json', ] file = files[random.randint(0, len(files) - 1)] print('----> using file ' + file) kafka_events = json.load(open(file)) print(kafka_events) # when for kafka_event in kafka_events: assert es_handler.store_record(es, 'test_index', kafka_event), 'unable to store event' # then time.sleep(1) all_events = es_handler.get_all(es, 'test_index') assert len(kafka_events) == len(all_events) def test_initial_events(): # given es = es_handler.connect_elasticsearch() assert es files = [ 'events.json', ] file = files[random.randint(0, len(files) - 1)] print('----> using file ' + file) kafka_events = json.load(open(file)) print(kafka_events) # when for kafka_event in kafka_events: assert es_handler.store_record(es, 'test_index', kafka_event), 'unable to store event'
24.222222
94
0.651376
147
1,090
4.612245
0.285714
0.113569
0.048673
0.047198
0.728614
0.728614
0.728614
0.728614
0.728614
0.728614
0
0.005974
0.23211
1,090
44
95
24.772727
0.804062
0.023853
0
0.645161
0
0
0.120983
0
0
0
0
0
0.16129
1
0.064516
false
0
0.129032
0
0.193548
0.129032
0
0
0
null
0
0
0
0
1
1
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
6dad3e8011e5d7d5f616ff781fd013ae1af0cbdc
81
py
Python
Code/Python/SalrayProgram/Salary.py
dks1018/CoffeeShopCoding
13ac1700673c86c601eb2758570920620a956e4c
[ "ADSL" ]
null
null
null
Code/Python/SalrayProgram/Salary.py
dks1018/CoffeeShopCoding
13ac1700673c86c601eb2758570920620a956e4c
[ "ADSL" ]
null
null
null
Code/Python/SalrayProgram/Salary.py
dks1018/CoffeeShopCoding
13ac1700673c86c601eb2758570920620a956e4c
[ "ADSL" ]
null
null
null
import math import sys #place holder for salary file and information #Calculate
13.5
45
0.814815
12
81
5.5
0.916667
0
0
0
0
0
0
0
0
0
0
0
0.160494
81
6
46
13.5
0.970588
0.654321
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
6ddc7e43dad81e24cec826664b6aaef4a18b5674
128
py
Python
osoriweb/website/admin.py
HyOsori/Osori-Website
57a2e62f320e5eac15c73416962b5b6cf049250f
[ "MIT" ]
15
2017-04-01T06:17:56.000Z
2018-01-13T13:26:01.000Z
osoriweb/website/admin.py
HyOsori/Osori-Website
57a2e62f320e5eac15c73416962b5b6cf049250f
[ "MIT" ]
7
2019-08-22T07:24:30.000Z
2022-03-11T23:14:38.000Z
osoriweb/website/admin.py
HyOsori/Osori-Website
57a2e62f320e5eac15c73416962b5b6cf049250f
[ "MIT" ]
3
2017-08-25T14:02:28.000Z
2017-09-01T04:18:52.000Z
from django.contrib import admin from .models import Inquiry, History admin.site.register(Inquiry) admin.site.register(History)
25.6
36
0.828125
18
128
5.888889
0.555556
0.169811
0.320755
0
0
0
0
0
0
0
0
0
0.085938
128
5
37
25.6
0.905983
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.5
0
0.5
0
1
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
099bbe81335cc17ea19a07f8d748ca517cfe9a17
95
py
Python
tests/components_to_test/__init__.py
RichardoLuo/ColossalAI
797a9dc5a9e801d7499b8667c3ef039a38aa15ba
[ "Apache-2.0" ]
3
2022-01-20T13:43:10.000Z
2022-02-03T08:00:24.000Z
tests/components_to_test/__init__.py
RichardoLuo/ColossalAI
797a9dc5a9e801d7499b8667c3ef039a38aa15ba
[ "Apache-2.0" ]
null
null
null
tests/components_to_test/__init__.py
RichardoLuo/ColossalAI
797a9dc5a9e801d7499b8667c3ef039a38aa15ba
[ "Apache-2.0" ]
1
2021-12-28T09:39:06.000Z
2021-12-28T09:39:06.000Z
from . import repeated_computed_layer, resnet, nested_model, bert, no_leaf_module, simple_net
47.5
94
0.831579
14
95
5.214286
1
0
0
0
0
0
0
0
0
0
0
0
0.105263
95
1
95
95
0.858824
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
09b43a69014a075b365d04f589464376863a354e
70
py
Python
src/train/abstract_model.py
wxy1224/cs224n_project
6dbd7869622565d0eaa3ac7b1dacc569f33d5a18
[ "MIT" ]
1
2018-05-30T16:16:12.000Z
2018-05-30T16:16:12.000Z
src/train/abstract_model.py
wxy1224/cs224n_project
6dbd7869622565d0eaa3ac7b1dacc569f33d5a18
[ "MIT" ]
7
2020-01-28T22:19:16.000Z
2021-05-21T14:43:03.000Z
src/train/abstract_model.py
wxy1224/cs224n_project
6dbd7869622565d0eaa3ac7b1dacc569f33d5a18
[ "MIT" ]
null
null
null
class BaseModel(object): def get_model(self): return None
17.5
24
0.657143
9
70
5
1
0
0
0
0
0
0
0
0
0
0
0
0.257143
70
3
25
23.333333
0.865385
0
0
0
0
0
0
0
0
0
0
0
0
1
0.333333
false
0
0
0.333333
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
1
1
0
0
5
09cd4271b00d7e3a686a68edd1bfa393e6ec5c4d
134
py
Python
src/grokcore/site/tests/base/utility/local_implementsnone_fixture.py
zopefoundation/grokcore.site
2bd79d64bb661a9e170356cd2cb89189faa8d5e7
[ "ZPL-2.1" ]
null
null
null
src/grokcore/site/tests/base/utility/local_implementsnone_fixture.py
zopefoundation/grokcore.site
2bd79d64bb661a9e170356cd2cb89189faa8d5e7
[ "ZPL-2.1" ]
4
2018-01-10T16:20:32.000Z
2021-04-20T08:51:17.000Z
src/grokcore/site/tests/base/utility/local_implementsnone_fixture.py
zopefoundation/grokcore.site
2bd79d64bb661a9e170356cd2cb89189faa8d5e7
[ "ZPL-2.1" ]
2
2015-04-03T04:58:58.000Z
2018-01-12T06:52:53.000Z
import grokcore.site class Fireplace(object): pass class Cave(grokcore.site.Site): grokcore.site.local_utility(Fireplace)
13.4
42
0.753731
17
134
5.882353
0.588235
0.36
0
0
0
0
0
0
0
0
0
0
0.149254
134
9
43
14.888889
0.877193
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0.2
0.2
0
0.6
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
1
0
0
0
0
0
5
09e14d52bb3be90a68ebf3e1f6de1d4bd2af8159
163
py
Python
src/youtube_dl_web/wsgi.py
lucca-ruhland/youtube-dl-web
fc11012c55f493c54aa5ac92acec1e3dd891df01
[ "MIT" ]
null
null
null
src/youtube_dl_web/wsgi.py
lucca-ruhland/youtube-dl-web
fc11012c55f493c54aa5ac92acec1e3dd891df01
[ "MIT" ]
null
null
null
src/youtube_dl_web/wsgi.py
lucca-ruhland/youtube-dl-web
fc11012c55f493c54aa5ac92acec1e3dd891df01
[ "MIT" ]
null
null
null
from youtube_dl_web import create_app from youtube_dl_web.default_config import Production app = create_app(Production) if __name__ == '__main__': app.run()
20.375
52
0.791411
24
163
4.75
0.583333
0.192982
0.22807
0.280702
0
0
0
0
0
0
0
0
0.134969
163
7
53
23.285714
0.808511
0
0
0
0
0
0.04908
0
0
0
0
0
0
1
0
false
0
0.4
0
0.4
0
1
0
0
null
0
1
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
0
0
0
5
61d42bcb686eccceb0ab7e3ba66431b6c488c8fd
229
py
Python
bandits/__init__.py
vadim0x60/bandits
0d2034cb1f757268a50d85ea66c89ef43d65a4e8
[ "Apache-2.0" ]
null
null
null
bandits/__init__.py
vadim0x60/bandits
0d2034cb1f757268a50d85ea66c89ef43d65a4e8
[ "Apache-2.0" ]
null
null
null
bandits/__init__.py
vadim0x60/bandits
0d2034cb1f757268a50d85ea66c89ef43d65a4e8
[ "Apache-2.0" ]
null
null
null
from .agent import Agent, GradientAgent from .bandit import GaussianBandit from .environment import Environment from .policy import (EpsilonGreedyPolicy, GreedyPolicy, RandomPolicy, UCBPolicy, SoftmaxPolicy)
38.166667
80
0.768559
21
229
8.380952
0.619048
0
0
0
0
0
0
0
0
0
0
0
0.183406
229
5
81
45.8
0.941176
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.8
0
0.8
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
110b26fc5de736ed2485a641053e9a63e6e70b9a
135
py
Python
PIconnect/test/__init__.py
jhvanderven/PIconnect
0f3b92a92419d3315b2ca33575a58317447235b5
[ "MIT" ]
1
2021-11-14T10:01:05.000Z
2021-11-14T10:01:05.000Z
PIconnect/test/__init__.py
jhvanderven/PIconnect
0f3b92a92419d3315b2ca33575a58317447235b5
[ "MIT" ]
null
null
null
PIconnect/test/__init__.py
jhvanderven/PIconnect
0f3b92a92419d3315b2ca33575a58317447235b5
[ "MIT" ]
1
2020-09-06T02:26:50.000Z
2020-09-06T02:26:50.000Z
""" PIconnect.test Main module for the PIconnect.test package. """ import unittest if __name__ == '__main__': unittest.main()
16.875
47
0.688889
16
135
5.3125
0.6875
0.305882
0
0
0
0
0
0
0
0
0
0
0.185185
135
7
48
19.285714
0.772727
0.42963
0
0
0
0
0.123077
0
0
0
0
0
0
1
0
true
0
0.333333
0
0.333333
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
fedbd1e2a7854602662fd984fe0f0b4a6fffa837
139
py
Python
scrapy_jsonschema/__init__.py
zanachka/scrapy-jsonschema
d31895a04632f62a9dad4529e92065206c10b5a5
[ "BSD-3-Clause" ]
43
2017-01-21T09:47:13.000Z
2022-03-26T18:07:38.000Z
scrapy_jsonschema/__init__.py
zanachka/scrapy-jsonschema
d31895a04632f62a9dad4529e92065206c10b5a5
[ "BSD-3-Clause" ]
26
2017-01-20T13:34:03.000Z
2021-03-22T17:17:02.000Z
scrapy_jsonschema/__init__.py
zanachka/scrapy-jsonschema
d31895a04632f62a9dad4529e92065206c10b5a5
[ "BSD-3-Clause" ]
14
2017-01-20T13:30:23.000Z
2021-03-17T15:25:55.000Z
from scrapy_jsonschema.item import JsonSchemaItem from scrapy_jsonschema.pipeline import JsonSchemaValidatePipeline __version__ = "0.5.0"
27.8
65
0.863309
16
139
7.125
0.6875
0.175439
0.350877
0
0
0
0
0
0
0
0
0.023622
0.086331
139
4
66
34.75
0.874016
0
0
0
0
0
0.035971
0
0
0
0
0
0
1
0
false
0
0.666667
0
0.666667
0
1
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
0
0
5
fef5fc51a81d5126b50d12621109e50dfec89baf
182
py
Python
src/artificial_neural_network/output_layer.py
daengdaengLee/mnist-python-numpy
909771bfc802e7031ab84af5776251e66fbc9a63
[ "MIT" ]
null
null
null
src/artificial_neural_network/output_layer.py
daengdaengLee/mnist-python-numpy
909771bfc802e7031ab84af5776251e66fbc9a63
[ "MIT" ]
23
2019-10-26T08:56:28.000Z
2021-06-02T00:37:18.000Z
src/artificial_neural_network/output_layer.py
daengdaengLee/mnist-python-numpy
909771bfc802e7031ab84af5776251e66fbc9a63
[ "MIT" ]
null
null
null
from abc import abstractmethod from artificial_neural_network.layer import Layer class OutputLayer(Layer): @abstractmethod def check_correct(self, y, label): pass
18.2
49
0.752747
22
182
6.090909
0.772727
0
0
0
0
0
0
0
0
0
0
0
0.192308
182
9
50
20.222222
0.911565
0
0
0
0
0
0
0
0
0
0
0
0
1
0.166667
false
0.166667
0.333333
0
0.666667
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
1
1
0
1
0
0
5
3a0c60f4e8cd6ff7278f824e23825e155d99e3b7
30
py
Python
nengo/_vendor/scipy/sparse/__init__.py
Michaeljurado24/nengo
dc0419fbe571374d0a55a7f67309dfcb254a2e88
[ "BSD-2-Clause" ]
762
2015-01-05T13:01:24.000Z
2022-03-26T11:35:38.000Z
nengo/_vendor/scipy/sparse/__init__.py
Michaeljurado24/nengo
dc0419fbe571374d0a55a7f67309dfcb254a2e88
[ "BSD-2-Clause" ]
1,066
2015-01-01T15:38:41.000Z
2022-03-20T19:26:44.000Z
nengo/_vendor/scipy/sparse/__init__.py
Michaeljurado24/nengo
dc0419fbe571374d0a55a7f67309dfcb254a2e88
[ "BSD-2-Clause" ]
205
2015-01-25T18:08:44.000Z
2022-03-22T22:03:08.000Z
from .linalg_expm import expm
15
29
0.833333
5
30
4.8
0.8
0
0
0
0
0
0
0
0
0
0
0
0.133333
30
1
30
30
0.923077
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
3a14e5bb847ed62ced791a4395ae823ce504c5b2
138
py
Python
irispy/__init__.py
zpodushkin/irispy
e801c0c8ece0e5ad7ff1fae3cf9adb6e360cd655
[ "MIT" ]
5
2020-03-16T19:26:00.000Z
2020-04-04T09:25:50.000Z
irispy/__init__.py
zpodushkin/irispy
e801c0c8ece0e5ad7ff1fae3cf9adb6e360cd655
[ "MIT" ]
1
2020-04-05T00:06:05.000Z
2020-04-10T22:28:16.000Z
irispy/__init__.py
zpodushkin/irispy
e801c0c8ece0e5ad7ff1fae3cf9adb6e360cd655
[ "MIT" ]
null
null
null
from .dispatcher.dispatcher import Dispatcher from .types.methods import Method from .types import objects from .types.exceptions import *
34.5
45
0.833333
18
138
6.388889
0.444444
0.234783
0
0
0
0
0
0
0
0
0
0
0.108696
138
4
46
34.5
0.934959
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
1
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
3a196a15364c967fc102745148824121432b6d30
126
py
Python
app/core/saving/admin.py
joer9514/MoneyManagerApp
dd43646c599ea33753e438e0ef1e89a6fd6b1660
[ "MIT" ]
1
2022-01-14T21:29:47.000Z
2022-01-14T21:29:47.000Z
app/core/saving/admin.py
joer9514/MoneyManagerApp
dd43646c599ea33753e438e0ef1e89a6fd6b1660
[ "MIT" ]
1
2021-03-09T21:37:44.000Z
2021-03-09T21:37:44.000Z
app/core/saving/admin.py
joer9514/MoneyManagerApp
dd43646c599ea33753e438e0ef1e89a6fd6b1660
[ "MIT" ]
null
null
null
from django.contrib import admin from core.saving.models import * # Adding Django administration admin.site.register(Saving)
21
32
0.81746
17
126
6.058824
0.705882
0
0
0
0
0
0
0
0
0
0
0
0.111111
126
5
33
25.2
0.919643
0.222222
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.666667
0
0.666667
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
3a3ab1409fde0631ff79b8ed2ffc995018d1106a
24
py
Python
testsuit/list-directory/file3.py
pahaz/bashtest
27be6db6dbe19330f4a0b6b3e126cf01b52be3fc
[ "MIT" ]
41
2016-07-27T09:23:34.000Z
2021-06-30T10:57:50.000Z
testsuit/list-directory/file3.py
pahaz/py3line
0855cccac0a4fe5d5e1e95505382bc2de83c30fb
[ "MIT" ]
8
2016-08-10T19:22:47.000Z
2016-09-10T17:34:49.000Z
testsuit/list-directory/file3.py
pahaz/bashtest
27be6db6dbe19330f4a0b6b3e126cf01b52be3fc
[ "MIT" ]
4
2017-12-26T16:20:44.000Z
2019-11-24T23:02:50.000Z
import sys sys.exit(22)
8
12
0.75
5
24
3.6
0.8
0
0
0
0
0
0
0
0
0
0
0.095238
0.125
24
2
13
12
0.761905
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
0.5
0
0.5
0
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
3a50ed95e07db81f2ed439802a63641e6a0f8f0e
77
py
Python
tests/utils/helpers.py
BryceStevenWilley/mealie
20c3873980f6d5d01e86ce6ef7915d95a06d8f6a
[ "MIT" ]
1,927
2021-01-02T20:01:15.000Z
2022-03-31T22:49:18.000Z
tests/utils/helpers.py
BryceStevenWilley/mealie
20c3873980f6d5d01e86ce6ef7915d95a06d8f6a
[ "MIT" ]
545
2021-01-02T20:32:28.000Z
2022-03-31T23:37:08.000Z
tests/utils/helpers.py
BryceStevenWilley/mealie
20c3873980f6d5d01e86ce6ef7915d95a06d8f6a
[ "MIT" ]
254
2021-01-03T00:20:07.000Z
2022-03-23T22:37:21.000Z
class MatchAny: def __eq__(self, _: object) -> bool: return True
19.25
40
0.61039
9
77
4.666667
1
0
0
0
0
0
0
0
0
0
0
0
0.285714
77
3
41
25.666667
0.763636
0
0
0
0
0
0
0
0
0
0
0
0
1
0.333333
false
0
0
0.333333
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
1
1
0
0
5
28e7ad3bcafd3b66cfe1ded5977899f5d5576177
2,122
py
Python
snmp-collector/core/db/entity.py
winkemoji/snmp-collector
4a8b027920192d9cba0e969c547ecdc33f3828f6
[ "MIT" ]
1
2021-10-07T15:57:47.000Z
2021-10-07T15:57:47.000Z
snmp-collector/core/db/entity.py
winkemoji/snmp-collector
4a8b027920192d9cba0e969c547ecdc33f3828f6
[ "MIT" ]
null
null
null
snmp-collector/core/db/entity.py
winkemoji/snmp-collector
4a8b027920192d9cba0e969c547ecdc33f3828f6
[ "MIT" ]
null
null
null
from core.db.decorator import entity, DataType, field @entity(table_name="blueprints") class Blueprints: def __init__(self): self.blueprint_id = field.set_dt(DataType.INTEGER).is_pk().is_ai().is_u().build() self.name = field.set_dt(DataType.TEXT).build() self.blueprint = field.set_dt(DataType.TEXT).build() self.create_time = field.custom("TIMESTAMP NOT NULL DEFAULT (datetime(CURRENT_TIMESTAMP, 'localtime'))").build() self.tag = field.set_dt(DataType.TEXT).build() @entity(table_name="collections") class Collections: def __init__(self): self.collection_id = field.set_dt(DataType.INTEGER).is_pk().is_ai().is_u().build() self.name = field.set_dt(DataType.TEXT).is_u().build() self.c_pid = field.set_dt(DataType.INTEGER).build() self.p_pid = field.set_dt(DataType.INTEGER).build() self.s_pid = field.set_dt(DataType.INTEGER).build() self.status = field.set_dt(DataType.INTEGER).build() self.create_time = field.custom("TIMESTAMP NOT NULL DEFAULT (datetime(CURRENT_TIMESTAMP, 'localtime'))").build() @entity(table_name="collect_data_details") class CollectDataDetails: def __init__(self): self.pid = field.set_dt(DataType.INTEGER).build() self.routing_keys = field.set_dt(DataType.TEXT).build() self.binding_key = field.set_dt(DataType.TEXT).build() self.status = field.set_dt(DataType.INTEGER).build() @entity(table_name="parse_data_details") class ParseDataDetails: def __init__(self): self.pid = field.set_dt(DataType.INTEGER).build() self.routing_keys = field.set_dt(DataType.TEXT).build() self.binding_key = field.set_dt(DataType.TEXT).build() self.status = field.set_dt(DataType.INTEGER).build() @entity(table_name="save_data_details") class SaveDataDetails: def __init__(self): self.pid = field.set_dt(DataType.INTEGER).build() self.routing_keys = field.set_dt(DataType.TEXT).build() self.binding_key = field.set_dt(DataType.TEXT).build() self.status = field.set_dt(DataType.INTEGER).build()
41.607843
120
0.697455
288
2,122
4.878472
0.194444
0.125267
0.156584
0.281851
0.762278
0.762278
0.743061
0.720996
0.648399
0.619929
0
0
0.15787
2,122
50
121
42.44
0.786234
0
0
0.5
0
0
0.100848
0.02639
0
0
0
0
0
1
0.125
false
0
0.025
0
0.275
0.1
0
0
0
null
0
0
1
0
1
1
1
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
28e99ebf2b6b79298a6e8b4969127e72be5c082b
37
py
Python
src/mixt/misc/__init__.py
adrienbrunet/mixt
d725ec752ce430d135e993bc988bfdf2b8457c4b
[ "MIT" ]
27
2018-06-04T19:11:42.000Z
2022-02-23T22:46:39.000Z
src/mixt/misc/__init__.py
adrienbrunet/mixt
d725ec752ce430d135e993bc988bfdf2b8457c4b
[ "MIT" ]
7
2018-06-09T15:27:51.000Z
2021-03-11T20:00:35.000Z
src/mixt/misc/__init__.py
adrienbrunet/mixt
d725ec752ce430d135e993bc988bfdf2b8457c4b
[ "MIT" ]
3
2018-07-29T10:20:02.000Z
2021-11-18T19:55:07.000Z
"""Miscellaneous things for mixt."""
18.5
36
0.702703
4
37
6.5
1
0
0
0
0
0
0
0
0
0
0
0
0.108108
37
1
37
37
0.787879
0.810811
0
null
0
null
0
0
null
0
0
0
null
1
null
true
0
0
null
null
null
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
5
e90476d1d122411f4f58a718e6a33d0f65f7a4eb
157
py
Python
orographic_precipitation/__init__.py
rlange2/orographic-precipitation
4a269bbe285ab55dece0cb3f0fe7324ed12efde9
[ "MIT" ]
6
2020-08-03T12:50:27.000Z
2021-07-21T20:26:42.000Z
orographic_precipitation/__init__.py
rlange2/orographic-precipitation
4a269bbe285ab55dece0cb3f0fe7324ed12efde9
[ "MIT" ]
3
2020-02-24T15:57:31.000Z
2020-06-04T07:22:16.000Z
orographic_precipitation/__init__.py
rlange2/orographic-precipitation
4a269bbe285ab55dece0cb3f0fe7324ed12efde9
[ "MIT" ]
1
2020-07-16T15:29:49.000Z
2020-07-16T15:29:49.000Z
from .orographic_precipitation import compute_orographic_precip from ._version import get_versions __version__ = get_versions()['version'] del get_versions
26.166667
63
0.853503
19
157
6.473684
0.526316
0.268293
0.292683
0
0
0
0
0
0
0
0
0
0.089172
157
5
64
31.4
0.86014
0
0
0
0
0
0.044586
0
0
0
0
0
0
1
0
false
0
0.5
0
0.5
0
1
0
0
null
1
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
0
0
0
5
3a82d3bf93192373bbfd47f062113fd6dd4fb393
24,873
py
Python
qcdb/tests/test_modules.py
loriab/qccddb
d9e156ef8b313ac0633211fc6b841f84a3ddde24
[ "BSD-3-Clause" ]
8
2019-03-28T11:54:59.000Z
2022-03-19T03:31:37.000Z
qcdb/tests/test_modules.py
loriab/qccddb
d9e156ef8b313ac0633211fc6b841f84a3ddde24
[ "BSD-3-Clause" ]
39
2018-10-31T23:02:18.000Z
2021-12-12T22:11:37.000Z
qcdb/tests/test_modules.py
loriab/qccddb
d9e156ef8b313ac0633211fc6b841f84a3ddde24
[ "BSD-3-Clause" ]
9
2018-03-12T20:51:50.000Z
2022-02-28T15:18:34.000Z
import pytest from qcengine.programs.tests.standard_suite_ref import std_molecules, std_refs import qcdb from .standard_suite_runner import runner_asserter from .test_standard_suite import _processor, clsd_open_pmols from .utils import using from .test_standard_suite import _q2, _q3 #@pytest.fixture #def clsd_open_pmols(): # frame_not_important = { # name[:-4]: qcdb.Molecule.from_string(smol, name=name[:-4]) # for name, smol in std_molecules.items() # if name.endswith("-xyz") # } # frame_part_of_spec = { # name[:-4] + "-fixed": qcdb.Molecule.from_string(smol + "\nno_com\nno_reorient\n", name=name[:-4]) # for name, smol in std_molecules.items() # if name.endswith("-xyz") # } # # return {**frame_not_important, **frame_part_of_spec} # # ,-----. ,-----. ,---. ,------. ,--. ,--. ,--. # ' .--./' .--./' .-' | .-. \ | `.' | ,--,--.,--,--, ,--,--. ,---. ,---. ,--,--,--. ,---. ,--,--, ,-' '-. # | | | | `. `-. | | \ : | |'.'| |' ,-. || \' ,-. || .-. || .-. :| || .-. :| \'-. .-' # ' '--'\' '--'\.-' || '--' / | | | |\ '-' || || |\ '-' |' '-' '\ --.| | | |\ --.| || | | | # `-----' `-----'`-----' `-------' `--' `--' `--`--'`--''--' `--`--'.`- / `----'`--`--`--' `----'`--''--' `--' # `---' # <<< CCSD Management #@pytest.mark.parametrize( # "scramble", # # * this parameter alters the input molecule by Cartesian frame and/or atom ordering to imitate real-world inputs. # # * scramble dictionary are arguments to qcdb.Molecule.scramble() or qcel.models.Molecule.scramble() that computes a shifted/rotated/atom-mapped input molecule from `subjects` below and the transformations to be applied to the reference data. # # * arguments do_shift=T/F and other boolean values generate random perturbations, so multiple lines or runs makes a fuller test. # # * specific shifts etc or problematic runs can be reproduced by specifying arrays like the commented example below. note that b/c do_resort is natom-dependent, may need to exclude subjects while debugging. # # * `id`s below are numbered since `pytest -k` doesn't recognize case and so duplicate entries can be added. the 0, 1, 2, 3, 9 progression is handy for debugging since perturbations are added systematically # [ # # pytest.param({"do_shift": [ 2.660760432055, 1.477336796939, -2.098045335573], "do_rotate": [[ 0.321861140022, 0.445246880671, 0.835560064745], [-0.447874157747, 0.849136107328, -0.279958229125], [-0.834154749052, -0.28411808546 , 0.472718487209]], "do_resort": [2, 0, 1]}, id="mTTT3"), # # pytest.param({"do_shift": False, "do_rotate": False, "do_resort": False}, id="srm0"), # # pytest.param({"do_shift": True, "do_rotate": False, "do_resort": False}, id="Srm1"), # # pytest.param({"do_shift": True, "do_rotate": True, "do_resort": False}, id="SRm2"), # # pytest.param({"do_shift": False, "do_rotate": False, "do_resort": True}, id="srM3"), # # pytest.param({"do_shift": True, "do_rotate": True, "do_resort": True}, id="SRM8"), # pytest.param({"do_shift": True, "do_rotate": True, "do_resort": True}, id="SRM9"), # ], #) #@pytest.mark.parametrize( # "frame", # # * this parameter alters the input molecule by fix_com and fix_orientation to imitate user signalling frame matters or not. # [ # pytest.param("fixed"), # fix_=True (no_com/no_reorient); atres.mol.geom = atin.mol.geom aka scrambled # pytest.param("free"), # fix_=False (def) ; atres.mol.geom = qcdb (aka psi4) interna orientation # ], #) @pytest.mark.parametrize( "driver,dertype", [ pytest.param("energy", 0, id="ene0"), # pytest.param("gradient", 1, id="grd1"), # pytest.param("hessian", 2, id="hes2"), ], ) @pytest.mark.parametrize( "basis, subjects", # # this parameter, along with rhf/uhf below covers four different molecules, with nat=2-4. [ # pytest.param("cc-pvdz", ["hf", "bh3p", "bh3p"], id="dz"), pytest.param("aug-cc-pvdz", ["h2o", "nh2", "nh2"], id="adz", marks=pytest.mark.long), ], ) #@pytest.mark.parametrize( # "inp", # [ # # yapf: disable # pytest.param({"call": "c4-hf", "reference": "rhf", "fcae": "ae", "keywords": {"basis": "<>", "cfour_scf_conv": 12}, }, id="hf rhf ae: cfour", marks=using("cfour")), # pytest.param({"call": "gms-hf", "reference": "rhf", "fcae": "ae", "keywords": {"basis": "<>"}, }, id="hf rhf ae: gamess", marks=using("gamess")), # pytest.param({"call": "nwc-hf", "reference": "rhf", "fcae": "ae", "keywords": {"basis": "<>"}, }, id="hf rhf ae: nwchem", marks=using("nwchem")), # pytest.param({"call": "p4-hf", "reference": "rhf", "fcae": "ae", "keywords": {"basis": "<>", "psi4_scf_type": "pk"}, }, id="hf rhf ae: psi4", marks=using("psi4")), # # pytest.param({"call": "c4-hf", "reference": "uhf", "fcae": "ae", "keywords": {"basis": "<>", "cfour_reference": "uhf", "cfour_scf_conv": 12}, }, id="hf uhf ae: cfour", marks=using("cfour")), # pytest.param({"call": "gms-hf", "reference": "uhf", "fcae": "ae", "keywords": {"basis": "<>", "gamess_contrl__scftyp": "uhf"}, }, id="hf uhf ae: gamess", marks=using("gamess")), # pytest.param({"call": "nwc-hf", "reference": "uhf", "fcae": "ae", "keywords": {"basis": "<>", "nwchem_scf__uhf": True}, }, id="hf uhf ae: nwchem", marks=using("nwchem")), # pytest.param({"call": "p4-hf", "reference": "uhf", "fcae": "ae", "keywords": {"basis": "<>", "reference": "uhf", "psi4_scf_type": "pk"}, }, id="hf uhf ae: psi4", marks=using("psi4")), # # yapf: enable # ], #) #@pytest.mark.parametrize( # "qcprog", # [ # pytest.param("cfour", marks=using("cfour")), # pytest.param("gamess", marks=using("gamess")), # pytest.param("nwchem", marks=using("nwchem")), # pytest.param("psi4", marks=using("psi4")), # ], #) @pytest.mark.parametrize( "inp", [ # yapf: disable # pytest.param({"call": "c4-ccsd", "reference": "rhf", "fcae": "ae", "keywords": {**_c4_tight, "cfour_cc_program": "vcc", "cfour_print": 2}, }, id="ccsd rhf ae: cfour-vcc", marks=using("cfour")), # pytest.param({"call": "c4-ccsd", "reference": "rhf", "fcae": "ae", "keywords": {**_c4_tight, "cfour_cc_program": "ecc",}, }, id="ccsd rhf ae: cfour-ecc", marks=using("cfour")), # pytest.param({"call": "c4-ccsd", "reference": "rhf", "fcae": "ae", "keywords": {**_c4_tight, "cfour_cc_program": "ncc",}, }, id="ccsd rhf ae: cfour-ncc", marks=using("cfour")), # pytest.param({"call": "gms-ccsd", "reference": "rhf", "fcae": "ae", "keywords": {"gamess_ccinp__ncore": 0}, }, id="ccsd rhf ae: gamess", marks=using("gamess")), # pytest.param({"call": "nwc-ccsd", "reference": "rhf", "fcae": "ae", "keywords": {"qc_module": "tce"}, }, id="ccsd rhf ae: nwchem-tce", marks=using("nwchem")), # pytest.param({"call": "nwc-ccsd", "reference": "rhf", "fcae": "ae", "keywords": {"qc_module": "cc"}, }, id="ccsd rhf ae: nwchem-cc", marks=using("nwchem")), # pytest.param({"call": "p4-ccsd", "reference": "rhf", "fcae": "ae", "keywords": {"qc_module": "ccenergy"}, }, id="ccsd rhf ae: psi4-cc", marks=using("psi4")), # pytest.param({"call": "p4-ccsd", "reference": "rhf", "fcae": "ae", "keywords": {"qc_module": "fnocc"}, }, id="ccsd rhf ae: psi4-fnocc", marks=using("psi4")), # pytest.param({"call": "c4-ccsd", "reference": "rhf", "fcae": "fc", "keywords": {**_c4_tight, "cfour_dropmo": [1], "cfour_cc_program": "vcc", "cfour_print": 2}, }, id="ccsd rhf fc: cfour-vcc", marks=using("cfour")), # pytest.param({"call": "c4-ccsd", "reference": "rhf", "fcae": "fc", "keywords": {**_c4_tight, "cfour_dropmo": [1], "cfour_cc_program": "ecc"}, }, id="ccsd rhf fc: cfour-ecc", marks=using("cfour")), # pytest.param({"call": "c4-ccsd", "reference": "rhf", "fcae": "fc", "keywords": {**_c4_tight, "cfour_dropmo": [1], "cfour_cc_program": "ncc"}, }, id="ccsd rhf fc: cfour-ncc", marks=using("cfour")), # pytest.param({"call": "gms-ccsd", "reference": "rhf", "fcae": "fc", "keywords": {}, }, id="ccsd rhf fc: gamess", marks=using("gamess")), # pytest.param({"call": "nwc-ccsd", "reference": "rhf", "fcae": "fc", "keywords": {"nwchem_tce__freeze": 1, "qc_module": "tce"}, }, id="ccsd rhf fc: nwchem-tce", marks=using("nwchem")), # pytest.param({"call": "nwc-ccsd", "reference": "rhf", "fcae": "fc", "keywords": {"nwchem_ccsd__freeze": 1, "qc_module": "cc"}, }, id="ccsd rhf fc: nwchem-cc", marks=using("nwchem")), # pytest.param({"call": "p4-ccsd", "reference": "rhf", "fcae": "fc", "keywords": {"psi4_freeze_core": True, "qc_module": "ccenergy"}, }, id="ccsd rhf fc: psi4-cc", marks=using("psi4")), # pytest.param({"call": "p4-ccsd", "reference": "rhf", "fcae": "fc", "keywords": {"psi4_freeze_core": True, "qc_module": "fnocc"}, }, id="ccsd rhf fc: psi4-fnocc", marks=using("psi4")), pytest.param({"call": "c4-ccsd", "reference": "rhf", "fcae": "ae", "cfg": {"module_fallback": False}, "keywords": {"reference": "rhf", "freeze_core": False}, }, id="mfF ccsd rhf ae: cfour", marks=using("cfour")), pytest.param({"call": "gms-ccsd", "reference": "rhf", "fcae": "ae", "cfg": {"module_fallback": False}, "keywords": {"reference": "rhf", "freeze_core": False}, }, id="mfF ccsd rhf ae: gamess", marks=using("gamess")), pytest.param({"call": "nwc-ccsd", "reference": "rhf", "fcae": "ae", "cfg": {"module_fallback": False}, "keywords": {"reference": "rhf", "freeze_core": False}, }, id="mfF ccsd rhf ae: nwchem", marks=using("nwchem")), pytest.param({"call": "p4-ccsd", "reference": "rhf", "fcae": "ae", "cfg": {"module_fallback": False}, "keywords": {"reference": "rhf", "freeze_core": False}, }, id="mfF ccsd rhf ae: psi4", marks=using("psi4")), pytest.param({"call": "c4-ccsd", "reference": "rhf", "fcae": "fc", "cfg": {"module_fallback": False}, "keywords": {"reference": "rhf", "freeze_core": True}, }, id="mfF ccsd rhf fc: cfour", marks=using("cfour")), pytest.param({"call": "gms-ccsd", "reference": "rhf", "fcae": "fc", "cfg": {"module_fallback": False}, "keywords": {"reference": "rhf", "freeze_core": True}, }, id="mfF ccsd rhf fc: gamess", marks=using("gamess")), pytest.param({"call": "nwc-ccsd", "reference": "rhf", "fcae": "fc", "cfg": {"module_fallback": False}, "keywords": {"reference": "rhf", "freeze_core": True}, }, id="mfF ccsd rhf fc: nwchem", marks=using("nwchem")), pytest.param({"call": "p4-ccsd", "reference": "rhf", "fcae": "fc", "cfg": {"module_fallback": False}, "keywords": {"reference": "rhf", "freeze_core": True}, }, id="mfF ccsd rhf fc: psi4", marks=using("psi4")), pytest.param({"call": "c4-ccsd", "reference": "uhf", "fcae": "ae", "cfg": {"module_fallback": False}, "keywords": {"reference": "uhf", "freeze_core": False}, }, id="mfF ccsd uhf ae: cfour", marks=using("cfour")), pytest.param({"call": "gms-ccsd", "reference": "uhf", "fcae": "ae", "cfg": {"module_fallback": False}, "keywords": {"reference": "uhf", "freeze_core": False}, "error": {0: _q2}}, id="mfF ccsd uhf ae: gamess", marks=using("gamess")), pytest.param({"call": "nwc-ccsd", "reference": "uhf", "fcae": "ae", "cfg": {"module_fallback": False}, "keywords": {"reference": "uhf", "freeze_core": False}, "error": {0: _q3}}, id="mfF ccsd uhf ae: nwchem", marks=using("nwchem")), pytest.param({"call": "p4-ccsd", "reference": "uhf", "fcae": "ae", "cfg": {"module_fallback": False}, "keywords": {"reference": "uhf", "freeze_core": False}, }, id="mfF ccsd uhf ae: psi4", marks=using("psi4")), pytest.param({"call": "c4-ccsd", "reference": "rhf", "fcae": "ae", "cfg": {"module_fallback": True}, "keywords": {"reference": "rhf", "freeze_core": False}, }, id="mfT ccsd rhf ae: cfour", marks=using("cfour")), pytest.param({"call": "gms-ccsd", "reference": "rhf", "fcae": "ae", "cfg": {"module_fallback": True}, "keywords": {"reference": "rhf", "freeze_core": False}, }, id="mfT ccsd rhf ae: gamess", marks=using("gamess")), pytest.param({"call": "nwc-ccsd", "reference": "rhf", "fcae": "ae", "cfg": {"module_fallback": True}, "keywords": {"reference": "rhf", "freeze_core": False}, }, id="mfT ccsd rhf ae: nwchem", marks=using("nwchem")), pytest.param({"call": "p4-ccsd", "reference": "rhf", "fcae": "ae", "cfg": {"module_fallback": True}, "keywords": {"reference": "rhf", "freeze_core": False}, }, id="mfT ccsd rhf ae: psi4", marks=using("psi4")), pytest.param({"call": "c4-ccsd", "reference": "rhf", "fcae": "fc", "cfg": {"module_fallback": True}, "keywords": {"reference": "rhf", "freeze_core": True}, }, id="mfT ccsd rhf fc: cfour", marks=using("cfour")), pytest.param({"call": "gms-ccsd", "reference": "rhf", "fcae": "fc", "cfg": {"module_fallback": True}, "keywords": {"reference": "rhf", "freeze_core": True}, }, id="mfT ccsd rhf fc: gamess", marks=using("gamess")), pytest.param({"call": "nwc-ccsd", "reference": "rhf", "fcae": "fc", "cfg": {"module_fallback": True}, "keywords": {"reference": "rhf", "freeze_core": True}, }, id="mfT ccsd rhf fc: nwchem", marks=using("nwchem")), pytest.param({"call": "p4-ccsd", "reference": "rhf", "fcae": "fc", "cfg": {"module_fallback": True}, "keywords": {"reference": "rhf", "freeze_core": True}, }, id="mfT ccsd rhf fc: psi4", marks=using("psi4")), pytest.param({"call": "c4-ccsd", "reference": "uhf", "fcae": "ae", "cfg": {"module_fallback": True}, "keywords": {"reference": "uhf", "freeze_core": False}, }, id="mfT ccsd uhf ae: cfour", marks=using("cfour")), pytest.param({"call": "gms-ccsd", "reference": "uhf", "fcae": "ae", "cfg": {"module_fallback": True}, "keywords": {"reference": "uhf", "freeze_core": False}, "error": {0: _q2} }, id="mfT ccsd uhf ae: gamess", marks=using("gamess")), pytest.param({"call": "nwc-ccsd", "reference": "uhf", "fcae": "ae", "cfg": {"module_fallback": True}, "keywords": {"reference": "uhf", "freeze_core": False}, }, id="mfT ccsd uhf ae: nwchem", marks=using("nwchem")), pytest.param({"call": "p4-ccsd", "reference": "uhf", "fcae": "ae", "cfg": {"module_fallback": True}, "keywords": {"reference": "uhf", "freeze_core": False}, }, id="mfT ccsd uhf ae: psi4", marks=using("psi4")), # # "cfour_occupation": [[3, 1, 1, 0], [3, 0, 1, 0]] # pytest.param({"call": "c4-ccsd", "reference": "uhf", "fcae": "ae", "keywords": {**_c4_tight, "cfour_REFerence": "UHF", "cfour_cc_program": "vcc", "cfour_print": 2}, }, id="ccsd uhf ae: cfour-vcc", marks=using("cfour")), # pytest.param({"call": "c4-ccsd", "reference": "uhf", "fcae": "ae", "keywords": {**_c4_tight, "cfour_REFerence": "UHF", "cfour_cc_program": "ecc"}, }, id="ccsd uhf ae: cfour-ecc", marks=using("cfour")), # pytest.param({"call": "gms-ccsd", "reference": "uhf", "fcae": "ae", "keywords": {"gamess_contrl__scftyp": "uhf", "gamess_ccinp__ncore": 0}, "error": {0: _q2 }}, id="ccsd uhf ae: gamess", marks=using("gamess")), # pytest.param({"call": "nwc-ccsd", "reference": "uhf", "fcae": "ae", "keywords": {"nwchem_scf__uhf": True, "qc_module": "tce"}, }, id="ccsd uhf ae: nwchem-tce", marks=using("nwchem")), # pytest.param({"call": "nwc-ccsd", "reference": "uhf", "fcae": "ae", "keywords": {"nwchem_scf__uhf": True, "qc_module": "cc"}, "error": {0: _q3 }}, id="ccsd uhf ae: nwchem-cc", marks=using("nwchem")), # pytest.param({"call": "p4-ccsd", "reference": "uhf", "fcae": "ae", "keywords": {"reference": "uhf", "qc_module": "ccenergy"}, }, id="ccsd uhf ae: psi4", marks=using("psi4")), # # pytest.param({"call": "c4-ccsd", "reference": "uhf", "fcae": "fc", "keywords": {**_c4_tight, "cfour_REFerence": "UHF", "cfour_dropmo": [1], "cfour_cc_program": "vcc", "cfour_print": 2}, }, id="ccsd uhf fc: cfour-vcc", marks=using("cfour")), # pytest.param({"call": "c4-ccsd", "reference": "uhf", "fcae": "fc", "keywords": {**_c4_tight, "cfour_REFerence": "UHF", "cfour_dropmo": [1], "cfour_cc_program": "ecc"}, }, id="ccsd uhf fc: cfour-ecc", marks=using("cfour")), # pytest.param({"call": "gms-ccsd", "reference": "uhf", "fcae": "fc", "keywords": {"gamess_contrl__scftyp": "uhf"}, "error": {0: _q2 }}, id="ccsd uhf fc: gamess", marks=using("gamess")), # pytest.param({"call": "nwc-ccsd", "reference": "uhf", "fcae": "fc", "keywords": {"nwchem_scf__uhf": True, "nwchem_tce__freeze": 1, "qc_module": "tce"}, }, id="ccsd uhf fc: nwchem-tce", marks=using("nwchem")), # pytest.param({"call": "nwc-ccsd", "reference": "uhf", "fcae": "fc", "keywords": {"nwchem_scf__uhf": True, "nwchem_ccsd__freeze": 1, "qc_module": "cc"}, "error": {0: _q3 }}, id="ccsd uhf fc: nwchem-cc", marks=using("nwchem")), # pytest.param({"call": "p4-ccsd", "reference": "uhf", "fcae": "fc", "keywords": {"psi4_freeze_core": True, "reference": "uhf", "qc_module": "ccenergy"}, }, id="ccsd uhf fc: psi4-cc", marks=using("psi4")), # # pytest.param({"call": "c4-ccsd", "reference": "rohf", "fcae": "ae", "keywords": {**_c4_tight, "cfour_REFerence": "roHF", "cfour_cc_program": "vcc", "cfour_print": 2}, }, id="ccsd rohf ae: cfour-vcc", marks=using("cfour")), # pytest.param({"call": "c4-ccsd", "reference": "rohf", "fcae": "ae", "keywords": {**_c4_tight, "cfour_REFerence": "roHF", "cfour_cc_program": "ecc"}, }, id="ccsd rohf ae: cfour-ecc", marks=using("cfour")), # pytest.param({"call": "gms-ccsd", "reference": "rohf", "fcae": "ae", "keywords": {"gamess_contrl__scftyp": "rohf", "gamess_ccinp__ncore": 0, "gamess_ccinp__maxcc": 50}, }, id="ccsd rohf ae: gamess", marks=using("gamess")), # pytest.param({"call": "nwc-ccsd", "reference": "rohf", "fcae": "ae", "keywords": {"nwchem_scf__rohf": True, "qc_module": "tce"}, }, id="ccsd rohf ae: nwchem-tce", marks=using("nwchem")), # pytest.param({"call": "nwc-ccsd", "reference": "rohf", "fcae": "ae", "keywords": {"nwchem_scf__rohf": True, "qc_module": "cc"}, "error": {0: _q3 }}, id="ccsd rohf ae: nwchem", marks=using("nwchem")), # pytest.param({"call": "p4-ccsd", "reference": "rohf", "fcae": "ae", "keywords": {"reference": "rohf", "qc_module": "ccenergy"}, }, id="ccsd rohf ae: psi4-cc", marks=using("psi4")), # # pytest.param({"call": "c4-ccsd", "reference": "rohf", "fcae": "fc", "keywords": {**_c4_tight, "cfour_REFerence": "roHF", "cfour_dropmo": [1], "cfour_orbitals": 0, "cfour_cc_program": "vcc", "cfour_print": 2}, }, id="ccsd rohf fc: 0cfour-vcc", marks=using("cfour")), # pytest.param({"call": "c4-ccsd", "reference": "rohf", "fcae": "fc", "keywords": {**_c4_tight, "cfour_REFerence": "roHF", "cfour_dropmo": [1], "cfour_orbitals": 0, "cfour_cc_program": "ecc"}, }, id="ccsd rohf fc: 0cfour-ecc", marks=using("cfour")), # pytest.param({"call": "gms-ccsd", "reference": "rohf", "fcae": "fc", "keywords": {"gamess_contrl__scftyp": "rohf", "gamess_ccinp__iconv": 9, "gamess_scf__conv": 9}, "wrong": {0: _w2 }}, id="ccsd rohf fc: gamess", marks=using("gamess")), # pytest.param({"call": "nwc-ccsd", "reference": "rohf", "fcae": "fc", "keywords": {"nwchem_scf__rohf": True, "nwchem_tce__freeze": 1, "qc_module": "tce"}, }, id="ccsd rohf fc: nwchem-tce", marks=using("nwchem")), # pytest.param({"call": "nwc-ccsd", "reference": "rohf", "fcae": "fc", "keywords": {"nwchem_scf__rohf": True, "nwchem_ccsd__freeze": 1, "qc_module": "cc"}, "error": {0: _q3 }}, id="ccsd rohf fc: nwchem-cc", marks=using("nwchem")), # pytest.param({"call": "p4-ccsd", "reference": "rohf", "fcae": "fc", "keywords": {"reference": "rohf", "psi4_freeze_core": True, "qc_module": "ccenergy", "psi4_e_convergence": 8, "psi4_r_convergence": 7}, }, id="ccsd rohf fc: psi4-cc", marks=using("psi4")), # yapf: enable ], ) def test_ccsd_energy_management(inp, driver, dertype, basis, subjects, clsd_open_pmols, request): #def test_ccsd_energy_management(inp, scramble, frame, driver, dertype, basis, subjects, clsd_open_pmols, request): runner_asserter( *_processor(inp, dertype, basis, subjects, clsd_open_pmols, request, driver) #, scramble=scramble, frame=frame) )
128.875648
301
0.48028
2,572
24,873
4.514774
0.105754
0.085257
0.093007
0.055115
0.812091
0.793834
0.74888
0.697554
0.683862
0.674819
0
0.020244
0.308889
24,873
192
302
129.546875
0.655265
0.722269
0
0.115385
0
0
0.391369
0
0
0
0
0
0.038462
1
0.019231
false
0
0.134615
0
0.153846
0
0
0
0
null
0
0
0
1
1
1
0
0
1
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
3a9de2622f104ebefc840f5ee576833d95a9721d
924
py
Python
ornitho/model/__init__.py
dda-dev/ornitho-client-python
94d09774026786c021f35cae8cc74b65a28075d9
[ "MIT" ]
3
2020-06-17T17:58:54.000Z
2022-03-27T17:26:07.000Z
ornitho/model/__init__.py
dda-dev/ornitho-client-python
94d09774026786c021f35cae8cc74b65a28075d9
[ "MIT" ]
null
null
null
ornitho/model/__init__.py
dda-dev/ornitho-client-python
94d09774026786c021f35cae8cc74b65a28075d9
[ "MIT" ]
1
2021-12-17T13:13:10.000Z
2021-12-17T13:13:10.000Z
# flake8: noqa from ornitho.model.detail import Detail from ornitho.model.entity import Entity from ornitho.model.family import Family from ornitho.model.field import Field from ornitho.model.field_option import FieldOption from ornitho.model.form import Form from ornitho.model.local_admin_unit import LocalAdminUnit from ornitho.model.media import Media from ornitho.model.modification_type import ModificationType from ornitho.model.observation import EstimationCode, Observation, Precision, Source from ornitho.model.observer import Observer from ornitho.model.place import Place from ornitho.model.protocol import Protocol from ornitho.model.relation import Relation, RelationType from ornitho.model.right import Right from ornitho.model.site import MapLayer, Site from ornitho.model.species import Species from ornitho.model.taxo_group import TaxonomicGroup from ornitho.model.territorial_unit import TerritorialUnit
42
84
0.859307
127
924
6.204724
0.307087
0.265228
0.385787
0.053299
0
0
0
0
0
0
0
0.001192
0.091991
924
21
85
44
0.938021
0.012987
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
0
0
0
null
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
3ace4f1ec4f15e54e7fe12f88eda0190e0760a05
107
py
Python
goban/__init__.py
eterevsky/goban
d2e9b81850007f8eb1405af739967d3fd3896430
[ "MIT" ]
null
null
null
goban/__init__.py
eterevsky/goban
d2e9b81850007f8eb1405af739967d3fd3896430
[ "MIT" ]
null
null
null
goban/__init__.py
eterevsky/goban
d2e9b81850007f8eb1405af739967d3fd3896430
[ "MIT" ]
null
null
null
from .board import Board from .gtp import GtpEngine, GtpError, EngineError from .tournament import run_game
35.666667
49
0.831776
15
107
5.866667
0.666667
0
0
0
0
0
0
0
0
0
0
0
0.121495
107
3
50
35.666667
0.93617
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
3ad71c7d5e70201fe99ec4ad89aed003b81279e6
149
py
Python
pysam/version.py
arogozhnikov/pysam
22626cd835503c33f777e8e9f4684130e87177f9
[ "MIT" ]
1
2020-11-12T09:46:51.000Z
2020-11-12T09:46:51.000Z
pysam/version.py
fo40225/pysam
7cfb1ead3393c901d6eaf33cc0b945ef480af586
[ "MIT" ]
null
null
null
pysam/version.py
fo40225/pysam
7cfb1ead3393c901d6eaf33cc0b945ef480af586
[ "MIT" ]
null
null
null
# pysam versioning information __version__ = "0.16.0.1" __samtools_version__ = "1.10" __bcftools_version__ = "1.10.2" __htslib_version__ = "1.10.2"
21.285714
31
0.744966
22
149
4.181818
0.545455
0.26087
0.326087
0.23913
0
0
0
0
0
0
0
0.121212
0.114094
149
6
32
24.833333
0.575758
0.187919
0
0
0
0
0.201681
0
0
0
0
0
0
1
0
false
0
0
0
0
0
1
0
0
null
1
1
1
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
3ae07373c11db1b45ac01a694c35101be462e93e
180
py
Python
pytodo/core/views.py
paulohos06/pytodo
7cbac4d7e266574bb35b054468077176398f375e
[ "MIT" ]
null
null
null
pytodo/core/views.py
paulohos06/pytodo
7cbac4d7e266574bb35b054468077176398f375e
[ "MIT" ]
124
2020-10-15T14:57:44.000Z
2022-03-27T14:06:30.000Z
pytodo/core/views.py
paulohos06/pytodo
7cbac4d7e266574bb35b054468077176398f375e
[ "MIT" ]
null
null
null
from django.http import HttpResponseRedirect from django.urls import reverse # Create your views here. def home(request): return HttpResponseRedirect(reverse("admin:index"))
22.5
55
0.794444
22
180
6.5
0.772727
0.13986
0
0
0
0
0
0
0
0
0
0
0.127778
180
7
56
25.714286
0.910828
0.127778
0
0
0
0
0.070968
0
0
0
0
0
0
1
0.25
false
0
0.5
0.25
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
1
1
0
0
0
5
3aedb2cec9a0c64e6a21be32ee64d9c70bf2efdd
30
py
Python
language-python-test/test/programs/imaginary/empty.py
wbadart/language-python
6c048c215ff7fe4a5d5cc36ba3c17a666af74821
[ "BSD-3-Clause" ]
137
2015-02-13T21:03:23.000Z
2021-11-24T03:53:55.000Z
language-python-test/test/programs/imaginary/empty.py
wbadart/language-python
6c048c215ff7fe4a5d5cc36ba3c17a666af74821
[ "BSD-3-Clause" ]
4
2015-04-01T13:49:13.000Z
2019-07-09T19:28:56.000Z
language-python-test/test/programs/imaginary/empty.py
wbadart/language-python
6c048c215ff7fe4a5d5cc36ba3c17a666af74821
[ "BSD-3-Clause" ]
8
2015-04-25T03:47:52.000Z
2019-07-27T06:33:56.000Z
# Intentionally empty program
15
29
0.833333
3
30
8.333333
1
0
0
0
0
0
0
0
0
0
0
0
0.133333
30
1
30
30
0.961538
0.9
0
null
0
null
0
0
null
0
0
0
null
1
null
true
0
0
null
null
null
1
1
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
1
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
0
0
0
0
0
5
aaffef11fa95a42e8181b0c2fc05261a98c7169f
1,253
py
Python
src/lslidar_ws/build/lslidar_c16/lslidar_c16_msgs/cmake/lslidar_c16_msgs-genmsg-context.py
Louis-AD-git/racecar_ws
3c5cb561d1aee11d80a7f3847e0334e93f345513
[ "MIT" ]
null
null
null
src/lslidar_ws/build/lslidar_c16/lslidar_c16_msgs/cmake/lslidar_c16_msgs-genmsg-context.py
Louis-AD-git/racecar_ws
3c5cb561d1aee11d80a7f3847e0334e93f345513
[ "MIT" ]
null
null
null
src/lslidar_ws/build/lslidar_c16/lslidar_c16_msgs/cmake/lslidar_c16_msgs-genmsg-context.py
Louis-AD-git/racecar_ws
3c5cb561d1aee11d80a7f3847e0334e93f345513
[ "MIT" ]
null
null
null
# generated from genmsg/cmake/pkg-genmsg.context.in messages_str = "/home/lzh/racecar_ws/src/lslidar_ws/src/lslidar_c16/lslidar_c16_msgs/msg/LslidarC16Layer.msg;/home/lzh/racecar_ws/src/lslidar_ws/src/lslidar_c16/lslidar_c16_msgs/msg/LslidarC16Packet.msg;/home/lzh/racecar_ws/src/lslidar_ws/src/lslidar_c16/lslidar_c16_msgs/msg/LslidarC16Point.msg;/home/lzh/racecar_ws/src/lslidar_ws/src/lslidar_c16/lslidar_c16_msgs/msg/LslidarC16Scan.msg;/home/lzh/racecar_ws/src/lslidar_ws/src/lslidar_c16/lslidar_c16_msgs/msg/LslidarC16Sweep.msg;/home/lzh/racecar_ws/src/lslidar_ws/src/lslidar_c16/lslidar_c16_msgs/msg/LslidarC16ScanUnified.msg" services_str = "" pkg_name = "lslidar_c16_msgs" dependencies_str = "std_msgs;sensor_msgs" langs = "gencpp;geneus;genlisp;gennodejs;genpy" dep_include_paths_str = "lslidar_c16_msgs;/home/lzh/racecar_ws/src/lslidar_ws/src/lslidar_c16/lslidar_c16_msgs/msg;std_msgs;/opt/ros/melodic/share/std_msgs/cmake/../msg;sensor_msgs;/opt/ros/melodic/share/sensor_msgs/cmake/../msg;geometry_msgs;/opt/ros/melodic/share/geometry_msgs/cmake/../msg" PYTHON_EXECUTABLE = "/usr/bin/python2" package_has_static_sources = '' == 'TRUE' genmsg_check_deps_script = "/opt/ros/melodic/share/genmsg/cmake/../../../lib/genmsg/genmsg_check_deps.py"
104.416667
580
0.828412
202
1,253
4.826733
0.287129
0.164103
0.172308
0.114872
0.499487
0.431795
0.431795
0.431795
0.431795
0.431795
0
0.036916
0.027135
1,253
11
581
113.909091
0.76292
0.039106
0
0
1
0.222222
0.831115
0.784526
0
0
0
0
0
1
0
false
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
1
1
1
1
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
c93bf9ee523d23f8f855331753dac07beece58ea
1,197
py
Python
applications/kolaborativa/routes.py
amaurirg/Web2Py
235571cd2273a858cbc8f291731672eadf6b8206
[ "BSD-3-Clause" ]
null
null
null
applications/kolaborativa/routes.py
amaurirg/Web2Py
235571cd2273a858cbc8f291731672eadf6b8206
[ "BSD-3-Clause" ]
null
null
null
applications/kolaborativa/routes.py
amaurirg/Web2Py
235571cd2273a858cbc8f291731672eadf6b8206
[ "BSD-3-Clause" ]
null
null
null
#coding: utf-8 BASE = '' routes_in = ( (BASE + '/index', BASE + '/kolaborativa/default/index'), (BASE + '/principal', BASE + '/kolaborativa/default/principal'), (BASE + '/user/$anything', BASE + '/kolaborativa/default/user/$anything'), (BASE + '/user_info/$anything', BASE + '/kolaborativa/default/user_info/$anything'), (BASE + '/projects/$anything', BASE + '/kolaborativa/default/projects/$anything'), (BASE + '/create_project', BASE + '/kolaborativa/default/create_project'), (BASE + '/edit_project/$anything', BASE + '/kolaborativa/default/edit_project/$anything'), (BASE + '/download/$anything', BASE + '/kolaborativa/default/download/$anything'), (BASE + '/call/$anything', BASE + '/kolaborativa/default/call$anything'), (BASE + '/call/json/$anything', BASE + '/kolaborativa/default/call/json/$anything'), (BASE + '/data/$anything', BASE + '/kolaborativa/default/data/$anything'), (BASE + '/search', BASE + '/kolaborativa/default/search.load'), (BASE + '/results', BASE + '/kolaborativa/default/results'), (BASE + '/$username', BASE + '/kolaborativa/default/user_info/$username'), ) routes_out = [(x, y) for (y, x) in routes_in]
54.409091
94
0.6533
127
1,197
6.07874
0.228346
0.248705
0.417098
0.321244
0.226684
0
0
0
0
0
0
0.000968
0.137009
1,197
21
95
57
0.74637
0.01086
0
0
0
0
0.60186
0.450549
0
0
0
0
0
1
0
false
0
0
0
0
0
0
0
0
null
1
1
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
1
null
0
0
0
0
0
0
0
0
0
0
0
0
0
5
c954d2c948a7c7079f4452d2e25f86655bc11692
81
py
Python
tests/test_cli.py
osteth/HBCTF
7a66fe515431b030618da70270aec66d1b7101b4
[ "MIT" ]
5
2017-04-25T14:12:49.000Z
2019-01-13T09:17:45.000Z
tests/test_cli.py
osteth/HBCTF
7a66fe515431b030618da70270aec66d1b7101b4
[ "MIT" ]
4
2017-04-27T01:56:06.000Z
2017-05-25T20:51:58.000Z
tests/test_cli.py
osteth/HBCTF
7a66fe515431b030618da70270aec66d1b7101b4
[ "MIT" ]
3
2017-04-27T01:28:44.000Z
2021-07-27T06:50:15.000Z
import re from click.testing import CliRunner from HBCTF.scripts import cli
9
35
0.790123
12
81
5.333333
0.75
0
0
0
0
0
0
0
0
0
0
0
0.185185
81
8
36
10.125
0.969697
0
0
0
0
0
0
0
0
0
0
0
0
1
0
true
0
1
0
1
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
1
0
0
5
a30d3629175c679c3a6e5f4b64d84d61f8223307
175
py
Python
script.py
HackerUSA-CE/PPP-math-module-solution
7a227d9d4c58c83bce7bf55c2e3e14b309060b2f
[ "MIT" ]
null
null
null
script.py
HackerUSA-CE/PPP-math-module-solution
7a227d9d4c58c83bce7bf55c2e3e14b309060b2f
[ "MIT" ]
null
null
null
script.py
HackerUSA-CE/PPP-math-module-solution
7a227d9d4c58c83bce7bf55c2e3e14b309060b2f
[ "MIT" ]
null
null
null
from math_package.math_module import add from math_package.sub_package.math_helper import list_to if __name__ == '__main__': print(list_to(5)) print(add(*list_to(5)))
29.166667
56
0.765714
29
175
4.068966
0.517241
0.152542
0.254237
0
0
0
0
0
0
0
0
0.013072
0.125714
175
6
57
29.166667
0.75817
0
0
0
0
0
0.045455
0
0
0
0
0
0
1
0
true
0
0.4
0
0.4
0.4
1
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
0
0
0
0
5
a359b22d671c3d63ed75c7d56a4325ab3d8556ec
181
py
Python
aicsimageio/tests/conftest.py
ieivanov/aicsimageio
e3823c41ab4e873fef5381fd8a29b788b4dcb0d8
[ "BSD-3-Clause" ]
16
2020-03-31T12:53:11.000Z
2022-01-28T19:29:49.000Z
aicsimageio/tests/conftest.py
ieivanov/aicsimageio
e3823c41ab4e873fef5381fd8a29b788b4dcb0d8
[ "BSD-3-Clause" ]
37
2020-03-20T23:39:45.000Z
2022-03-07T18:26:04.000Z
aicsimageio/tests/conftest.py
ieivanov/aicsimageio
e3823c41ab4e873fef5381fd8a29b788b4dcb0d8
[ "BSD-3-Clause" ]
6
2021-06-11T17:59:54.000Z
2022-02-21T01:38:57.000Z
#!/usr/bin/env python # -*- coding: utf-8 -*- from pathlib import Path import pytest @pytest.fixture def resources_dir() -> Path: return Path(__file__).parent / "resources"
15.083333
46
0.685083
24
181
4.958333
0.791667
0
0
0
0
0
0
0
0
0
0
0.006623
0.165746
181
11
47
16.454545
0.781457
0.232044
0
0
0
0
0.065693
0
0
0
0
0
0
1
0.2
true
0
0.4
0.2
0.8
0
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
1
0
1
1
1
0
0
5
a367df5c5ec715f3889a2be8c5b6a9c41709209e
190
py
Python
samples/sample_plugin_b.py
kazurrr/raspberry-gpio-emulator
17e52223af93d0cb4b07ea9de05c6b317e4429b0
[ "Apache-2.0" ]
52
2017-04-07T10:44:35.000Z
2022-03-24T02:27:03.000Z
samples/sample_plugin_b.py
kazurrr/raspberry-gpio-emulator
17e52223af93d0cb4b07ea9de05c6b317e4429b0
[ "Apache-2.0" ]
8
2016-12-21T10:48:11.000Z
2021-11-25T09:43:20.000Z
samples/sample_plugin_b.py
kazurrr/raspberry-gpio-emulator
17e52223af93d0cb4b07ea9de05c6b317e4429b0
[ "Apache-2.0" ]
18
2017-09-02T19:24:00.000Z
2022-03-17T21:30:06.000Z
import RPi class Plugin(RPi.Plugin): def change_gpio_in(self, chanel, is_high): print('* change_gpio_in(%d,%d)' % (chanel, is_high)) def create_plugin(): return Plugin()
17.272727
60
0.657895
28
190
4.214286
0.571429
0.169492
0.20339
0
0
0
0
0
0
0
0
0
0.194737
190
10
61
19
0.771242
0
0
0
0
0
0.121053
0.110526
0
0
0
0
0
1
0.333333
false
0
0.166667
0.166667
0.833333
0.166667
1
0
0
null
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
1
0
0
0
1
1
0
0
5
a36e3cfbbdc2d2c8e504bf85be340b194e4c73b7
124
py
Python
web/app/errors/__init__.py
mcodegeeks/containerized_webapp
39c02ed04efee4b49f2bb906177b392410d468dd
[ "MIT" ]
null
null
null
web/app/errors/__init__.py
mcodegeeks/containerized_webapp
39c02ed04efee4b49f2bb906177b392410d468dd
[ "MIT" ]
null
null
null
web/app/errors/__init__.py
mcodegeeks/containerized_webapp
39c02ed04efee4b49f2bb906177b392410d468dd
[ "MIT" ]
null
null
null
from flask import Blueprint bp = Blueprint('errors', __name__, template_folder='views') from app.errors import controllers
24.8
59
0.798387
16
124
5.875
0.75
0
0
0
0
0
0
0
0
0
0
0
0.112903
124
5
60
24.8
0.854545
0
0
0
0
0
0.088
0
0
0
0
0
0
1
0
false
0
0.666667
0
0.666667
0.666667
1
0
0
null
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
null
0
0
0
0
0
0
0
0
1
0
1
1
0
5